diff options
author | 2022-06-16 12:47:52 +0200 | |
---|---|---|
committer | 2025-04-29 23:06:41 +0200 | |
commit | 45d4cd52a8194f2ef9e0383cfb2e2a35634af6ff (patch) | |
tree | 4e8d8fcb7382a5e9e0bce5ec59939bcfbe67155a /src/devices | |
parent | 5c14bcdfcb4aefb71b5b62387c4ad05dbeb3814e (diff) |
full xtal conversionxtal
Diffstat (limited to 'src/devices')
4846 files changed, 12540 insertions, 12630 deletions
diff --git a/src/devices/bus/a1bus/a1bus.cpp b/src/devices/bus/a1bus/a1bus.cpp index 21549f5a171..cbd5616f3e0 100644 --- a/src/devices/bus/a1bus/a1bus.cpp +++ b/src/devices/bus/a1bus/a1bus.cpp @@ -27,12 +27,12 @@ template class device_finder<device_a1bus_card_interface, true>; //------------------------------------------------- // a1bus_slot_device - constructor //------------------------------------------------- -a1bus_slot_device::a1bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a1bus_slot_device::a1bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a1bus_slot_device(mconfig, A1BUS_SLOT, tag, owner, clock) { } -a1bus_slot_device::a1bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a1bus_slot_device::a1bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_single_card_slot_interface<device_a1bus_card_interface>(mconfig, *this) , m_a1bus(*this, finder_base::DUMMY_TAG) @@ -69,12 +69,12 @@ DEFINE_DEVICE_TYPE(A1BUS, a1bus_device, "a1bus", "Apple I Bus") // a1bus_device - constructor //------------------------------------------------- -a1bus_device::a1bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a1bus_device::a1bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a1bus_device(mconfig, A1BUS, tag, owner, clock) { } -a1bus_device::a1bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a1bus_device::a1bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_space(*this, finder_base::DUMMY_TAG, -1) , m_out_irq_cb(*this) diff --git a/src/devices/bus/a1bus/a1bus.h b/src/devices/bus/a1bus/a1bus.h index d1d4860113d..2b5fe79ad30 100644 --- a/src/devices/bus/a1bus/a1bus.h +++ b/src/devices/bus/a1bus/a1bus.h @@ -24,8 +24,8 @@ class a1bus_slot_device : public device_t, public device_single_card_slot_interf public: // construction/destruction template <typename T, typename U> - a1bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&a1bus_tag, U &&opts, const char *dflt) - : a1bus_slot_device(mconfig, tag, owner, clock) + a1bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&a1bus_tag, U &&opts, const char *dflt) + : a1bus_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -33,10 +33,10 @@ public: set_fixed(false); m_a1bus.set_tag(std::forward<T>(a1bus_tag)); } - a1bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a1bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: - a1bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a1bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -55,7 +55,7 @@ class a1bus_device : public device_t { public: // construction/destruction - a1bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a1bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration template <typename T> void set_space(T &&tag, int spacenum) { m_space.set_tag(std::forward<T>(tag), spacenum); } @@ -75,7 +75,7 @@ public: DECLARE_WRITE_LINE_MEMBER( nmi_w ); protected: - a1bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a1bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; diff --git a/src/devices/bus/a1bus/a1cassette.cpp b/src/devices/bus/a1bus/a1cassette.cpp index 56cd198bac8..14fdcf5ed70 100644 --- a/src/devices/bus/a1bus/a1cassette.cpp +++ b/src/devices/bus/a1bus/a1cassette.cpp @@ -41,13 +41,13 @@ class a1bus_cassette_device: { public: // construction/destruction - a1bus_cassette_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a1bus_cassette_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t cassette_r(offs_t offset); void cassette_w(offs_t offset, uint8_t data); protected: - a1bus_cassette_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a1bus_cassette_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -89,12 +89,12 @@ const tiny_rom_entry *a1bus_cassette_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a1bus_cassette_device::a1bus_cassette_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a1bus_cassette_device::a1bus_cassette_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a1bus_cassette_device(mconfig, A1BUS_CASSETTE, tag, owner, clock) { } -a1bus_cassette_device::a1bus_cassette_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a1bus_cassette_device::a1bus_cassette_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a1bus_card_interface(mconfig, *this) , m_cassette(*this, "cassette") diff --git a/src/devices/bus/a1bus/a1cffa.cpp b/src/devices/bus/a1bus/a1cffa.cpp index 9818caf9fc6..7a97b9ade6e 100644 --- a/src/devices/bus/a1bus/a1cffa.cpp +++ b/src/devices/bus/a1bus/a1cffa.cpp @@ -38,13 +38,13 @@ class a1bus_cffa_device: { public: // construction/destruction - a1bus_cffa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a1bus_cffa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t cffa_r(offs_t offset); void cffa_w(offs_t offset, uint8_t data); protected: - a1bus_cffa_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a1bus_cffa_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -78,12 +78,12 @@ const tiny_rom_entry *a1bus_cffa_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a1bus_cffa_device::a1bus_cffa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a1bus_cffa_device::a1bus_cffa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a1bus_cffa_device(mconfig, A1BUS_CFFA, tag, owner, clock) { } -a1bus_cffa_device::a1bus_cffa_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a1bus_cffa_device::a1bus_cffa_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a1bus_card_interface(mconfig, *this) , m_ata(*this, CFFA_ATA_TAG) diff --git a/src/devices/bus/a2bus/4play.cpp b/src/devices/bus/a2bus/4play.cpp index c51ef306cff..cfa261a3235 100644 --- a/src/devices/bus/a2bus/4play.cpp +++ b/src/devices/bus/a2bus/4play.cpp @@ -25,10 +25,10 @@ class a2bus_4play_device: { public: // construction/destruction - a2bus_4play_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_4play_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_4play_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_4play_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual ioport_constructor device_input_ports() const override; @@ -93,12 +93,12 @@ ioport_constructor a2bus_4play_device::device_input_ports() const // LIVE DEVICE //************************************************************************** -a2bus_4play_device::a2bus_4play_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_4play_device::a2bus_4play_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_4play_device(mconfig, A2BUS_4PLAY, tag, owner, clock) { } -a2bus_4play_device::a2bus_4play_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_4play_device::a2bus_4play_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_p1(*this, "p1"), diff --git a/src/devices/bus/a2bus/a2alfam2.cpp b/src/devices/bus/a2bus/a2alfam2.cpp index 72815dcce53..5b6288b8313 100644 --- a/src/devices/bus/a2bus/a2alfam2.cpp +++ b/src/devices/bus/a2bus/a2alfam2.cpp @@ -30,14 +30,14 @@ class a2bus_alfam2_device: public device_a2bus_card_interface { public: - a2bus_alfam2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : + a2bus_alfam2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_alfam2_device(mconfig, A2BUS_ALFAM2, tag, owner, clock) { } protected: // construction/destruction - a2bus_alfam2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_alfam2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -60,7 +60,7 @@ private: class a2bus_aesms_device : public a2bus_alfam2_device { public: - a2bus_aesms_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : + a2bus_aesms_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_alfam2_device(mconfig, A2BUS_AESMS, tag, owner, clock) { } @@ -92,14 +92,14 @@ void a2bus_alfam2_device::device_add_mconfig(machine_config &config) SPEAKER(config, "alf_l").front_left(); SPEAKER(config, "alf_r").front_right(); - SN76489(config, m_sn1, 1020484); + SN76489(config, m_sn1, XTAL::u(1020484)); m_sn1->add_route(ALL_OUTPUTS, "alf_l", 0.50); - SN76489(config, m_sn2, 1020484); + SN76489(config, m_sn2, XTAL::u(1020484)); m_sn2->add_route(ALL_OUTPUTS, "alf_l", 0.50); m_sn2->add_route(ALL_OUTPUTS, "alf_r", 0.50); - SN76489(config, m_sn3, 1020484); + SN76489(config, m_sn3, XTAL::u(1020484)); m_sn3->add_route(ALL_OUTPUTS, "alf_r", 0.50); } @@ -108,17 +108,17 @@ void a2bus_aesms_device::device_add_mconfig(machine_config &config) SPEAKER(config, "alf_l").front_left(); SPEAKER(config, "alf_r").front_right(); - SN76489(config, m_sn1, 1020484); + SN76489(config, m_sn1, XTAL::u(1020484)); m_sn1->add_route(ALL_OUTPUTS, "alf_l", 0.50); - SN76489(config, m_sn2, 1020484); + SN76489(config, m_sn2, XTAL::u(1020484)); m_sn2->add_route(ALL_OUTPUTS, "alf_l", 0.50); m_sn2->add_route(ALL_OUTPUTS, "alf_r", 0.50); - SN76489(config, m_sn3, 1020484); + SN76489(config, m_sn3, XTAL::u(1020484)); m_sn3->add_route(ALL_OUTPUTS, "alf_r", 0.50); - SN76489(config, m_sn4, 1020484); + SN76489(config, m_sn4, XTAL::u(1020484)); m_sn4->add_route(ALL_OUTPUTS, "alf_l", 0.50); m_sn4->add_route(ALL_OUTPUTS, "alf_r", 0.50); } @@ -127,7 +127,7 @@ void a2bus_aesms_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_alfam2_device::a2bus_alfam2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_alfam2_device::a2bus_alfam2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_sn1(*this, SN1_TAG), diff --git a/src/devices/bus/a2bus/a2applicard.cpp b/src/devices/bus/a2bus/a2applicard.cpp index 5395295a207..b9d13751658 100644 --- a/src/devices/bus/a2bus/a2applicard.cpp +++ b/src/devices/bus/a2bus/a2applicard.cpp @@ -41,13 +41,13 @@ class a2bus_applicard_device: { public: // construction/destruction - a2bus_applicard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_applicard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t z80_io_r(offs_t offset); void z80_io_w(offs_t offset, uint8_t data); protected: - a2bus_applicard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_applicard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -95,7 +95,7 @@ void a2bus_applicard_device::z80_io(address_map &map) void a2bus_applicard_device::device_add_mconfig(machine_config &config) { - Z80(config, m_z80, 6000000); // Z80 runs at 6 MHz + Z80(config, m_z80, XTAL::u(6000000)); // Z80 runs at 6 MHz m_z80->set_addrmap(AS_PROGRAM, &a2bus_applicard_device::z80_mem); m_z80->set_addrmap(AS_IO, &a2bus_applicard_device::z80_io); } @@ -113,7 +113,7 @@ const tiny_rom_entry *a2bus_applicard_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_applicard_device::a2bus_applicard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_applicard_device::a2bus_applicard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_z80(*this, Z80_TAG), @@ -122,7 +122,7 @@ a2bus_applicard_device::a2bus_applicard_device(const machine_config &mconfig, de { } -a2bus_applicard_device::a2bus_applicard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_applicard_device::a2bus_applicard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_applicard_device(mconfig, A2BUS_APPLICARD, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2arcadebd.cpp b/src/devices/bus/a2bus/a2arcadebd.cpp index 85c0cfc02d2..2c338cc6cd3 100644 --- a/src/devices/bus/a2bus/a2arcadebd.cpp +++ b/src/devices/bus/a2bus/a2arcadebd.cpp @@ -42,10 +42,10 @@ class a2bus_arcboard_device: { public: // construction/destruction - a2bus_arcboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_arcboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_arcboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_arcboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -74,19 +74,19 @@ void a2bus_arcboard_device::device_add_mconfig(machine_config &config) SCREEN(config, SCREEN_TAG, SCREEN_TYPE_RASTER); SPEAKER(config, "mono").front_center(); - AY8910(config, m_ay, 1022727).add_route(ALL_OUTPUTS, "mono", 1.0); + AY8910(config, m_ay, XTAL::u(1022727)).add_route(ALL_OUTPUTS, "mono", 1.0); } //************************************************************************** // LIVE DEVICE //************************************************************************** -a2bus_arcboard_device::a2bus_arcboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_arcboard_device::a2bus_arcboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_arcboard_device(mconfig, A2BUS_ARCADEBOARD, tag, owner, clock) { } -a2bus_arcboard_device::a2bus_arcboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_arcboard_device::a2bus_arcboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_tms(*this, TMS_TAG), diff --git a/src/devices/bus/a2bus/a2bus.cpp b/src/devices/bus/a2bus/a2bus.cpp index deb322f67a8..7f374924973 100644 --- a/src/devices/bus/a2bus/a2bus.cpp +++ b/src/devices/bus/a2bus/a2bus.cpp @@ -91,12 +91,12 @@ template class device_finder<device_a2bus_card_interface, true>; //------------------------------------------------- // a2bus_slot_device - constructor //------------------------------------------------- -a2bus_slot_device::a2bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a2bus_slot_device::a2bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_slot_device(mconfig, A2BUS_SLOT, tag, owner, clock) { } -a2bus_slot_device::a2bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2bus_slot_device::a2bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_single_card_slot_interface<device_a2bus_card_interface>(mconfig, *this) , m_a2bus(*this, finder_base::DUMMY_TAG) @@ -132,12 +132,12 @@ DEFINE_DEVICE_TYPE(A2BUS, a2bus_device, "a2bus", "Apple II Bus") // a2bus_device - constructor //------------------------------------------------- -a2bus_device::a2bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a2bus_device::a2bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_device(mconfig, A2BUS, tag, owner, clock) { } -a2bus_device::a2bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2bus_device::a2bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_maincpu_space(*this, finder_base::DUMMY_TAG, -1) , m_out_irq_cb(*this) diff --git a/src/devices/bus/a2bus/a2bus.h b/src/devices/bus/a2bus/a2bus.h index 5a10f06de39..625c12d31e0 100644 --- a/src/devices/bus/a2bus/a2bus.h +++ b/src/devices/bus/a2bus/a2bus.h @@ -26,7 +26,7 @@ #define INH_WRITE 0x02 // 7M = XTAL(14'318'181) / 2 or XTAL(28'636'363) / 4 (for IIgs) -static constexpr uint32_t A2BUS_7M_CLOCK = 7159090; +static constexpr XTAL A2BUS_7M_CLOCK = XTAL(14'318'181) / 2; //************************************************************************** // TYPE DEFINITIONS @@ -45,7 +45,7 @@ public: { } template <typename T, typename U> - a2bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&a2bus_tag, U &&opts, const char *dflt) + a2bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&a2bus_tag, U &&opts, const char *dflt) : a2bus_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -54,10 +54,10 @@ public: set_fixed(false); m_a2bus.set_tag(std::forward<T>(a2bus_tag)); } - a2bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = A2BUS_7M_CLOCK); + a2bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = A2BUS_7M_CLOCK); protected: - a2bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -78,7 +78,7 @@ class a2bus_device : public device_t friend class a2bus_mcms2_device; public: // construction/destruction - a2bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration template <typename T> void set_space(T &&tag, int spacenum) { m_maincpu_space.set_tag(std::forward<T>(tag), spacenum); } @@ -103,7 +103,7 @@ public: DECLARE_WRITE_LINE_MEMBER( nmi_w ); protected: - a2bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; diff --git a/src/devices/bus/a2bus/a2cffa.cpp b/src/devices/bus/a2bus/a2cffa.cpp index 3839b338ae1..43c4ddd8c51 100644 --- a/src/devices/bus/a2bus/a2cffa.cpp +++ b/src/devices/bus/a2bus/a2cffa.cpp @@ -45,7 +45,7 @@ class a2bus_cffa2000_device: { protected: // construction/destruction - a2bus_cffa2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_cffa2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -73,7 +73,7 @@ private: class a2bus_cffa2_device : public a2bus_cffa2000_device, public device_nvram_interface { public: - a2bus_cffa2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_cffa2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_config_nvram_interface overrides @@ -85,7 +85,7 @@ protected: class a2bus_cffa2_6502_device : public a2bus_cffa2000_device, public device_nvram_interface { public: - a2bus_cffa2_6502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_cffa2_6502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; protected: @@ -130,7 +130,7 @@ const tiny_rom_entry *a2bus_cffa2_6502_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_cffa2000_device::a2bus_cffa2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_cffa2000_device::a2bus_cffa2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_ata(*this, CFFA2_ATA_TAG), @@ -139,13 +139,13 @@ a2bus_cffa2000_device::a2bus_cffa2000_device(const machine_config &mconfig, devi { } -a2bus_cffa2_device::a2bus_cffa2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_cffa2_device::a2bus_cffa2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_cffa2000_device(mconfig, A2BUS_CFFA2, tag, owner, clock), device_nvram_interface(mconfig, *this) { } -a2bus_cffa2_6502_device::a2bus_cffa2_6502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_cffa2_6502_device::a2bus_cffa2_6502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_cffa2000_device(mconfig, A2BUS_CFFA2_6502, tag, owner, clock), device_nvram_interface(mconfig, *this) { diff --git a/src/devices/bus/a2bus/a2corvus.cpp b/src/devices/bus/a2bus/a2corvus.cpp index b2e845f3d2c..9430356844f 100644 --- a/src/devices/bus/a2bus/a2corvus.cpp +++ b/src/devices/bus/a2bus/a2corvus.cpp @@ -73,7 +73,7 @@ ROM_END void a2bus_corvus_device::device_add_mconfig(machine_config &config) { - CORVUS_HDC(config, m_corvushd, 0); + CORVUS_HDC(config, m_corvushd); HARDDISK(config, "harddisk1", "corvus_hdd"); HARDDISK(config, "harddisk2", "corvus_hdd"); HARDDISK(config, "harddisk3", "corvus_hdd"); @@ -93,14 +93,14 @@ const tiny_rom_entry *a2bus_corvus_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_corvus_device::a2bus_corvus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_corvus_device::a2bus_corvus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_corvushd(*this, CORVUS_HD_TAG), m_rom(nullptr) { } -a2bus_corvus_device::a2bus_corvus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_corvus_device::a2bus_corvus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_corvus_device(mconfig, A2BUS_CORVUS, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2corvus.h b/src/devices/bus/a2bus/a2corvus.h index a6d1a232eee..028dc89f43c 100644 --- a/src/devices/bus/a2bus/a2corvus.h +++ b/src/devices/bus/a2bus/a2corvus.h @@ -27,10 +27,10 @@ class a2bus_corvus_device: { public: // construction/destruction - a2bus_corvus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_corvus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_corvus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_corvus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/a2diskiing.cpp b/src/devices/bus/a2bus/a2diskiing.cpp index f6c4808462a..4549beb4c39 100644 --- a/src/devices/bus/a2bus/a2diskiing.cpp +++ b/src/devices/bus/a2bus/a2diskiing.cpp @@ -129,7 +129,7 @@ const tiny_rom_entry *a2bus_agat9flop_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -diskiing_device::diskiing_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +diskiing_device::diskiing_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_wozfdc(*this, WOZFDC_TAG), @@ -138,17 +138,17 @@ diskiing_device::diskiing_device(const machine_config &mconfig, device_type type { } -a2bus_diskiing_device::a2bus_diskiing_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_diskiing_device::a2bus_diskiing_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : diskiing_device(mconfig, A2BUS_DISKIING, tag, owner, clock) { } -a2bus_diskiing13_device::a2bus_diskiing13_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_diskiing13_device::a2bus_diskiing13_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : diskiing_device(mconfig, A2BUS_DISKIING13, tag, owner, clock) { } -a2bus_applesurance_device::a2bus_applesurance_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_applesurance_device::a2bus_applesurance_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : diskiing_device(mconfig, A2BUS_APPLESURANCE, tag, owner, clock), m_c800_bank(1) { diff --git a/src/devices/bus/a2bus/a2diskiing.h b/src/devices/bus/a2bus/a2diskiing.h index 1d6e2f93f99..6f246eea8c9 100644 --- a/src/devices/bus/a2bus/a2diskiing.h +++ b/src/devices/bus/a2bus/a2diskiing.h @@ -32,7 +32,7 @@ class diskiing_device: { protected: // construction/destruction - diskiing_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + diskiing_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -56,13 +56,13 @@ private: class a2bus_diskiing_device: public diskiing_device { public: - a2bus_diskiing_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_diskiing_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class a2bus_diskiing13_device: public diskiing_device { public: - a2bus_diskiing13_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_diskiing13_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -75,7 +75,7 @@ private: class a2bus_applesurance_device: public diskiing_device { public: - a2bus_applesurance_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_applesurance_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/a2bus/a2dx1.cpp b/src/devices/bus/a2bus/a2dx1.cpp index ae8f80091b1..4395471f94d 100644 --- a/src/devices/bus/a2bus/a2dx1.cpp +++ b/src/devices/bus/a2bus/a2dx1.cpp @@ -28,10 +28,10 @@ class a2bus_dx1_device: { public: // construction/destruction - a2bus_dx1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_dx1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_dx1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_dx1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_add_mconfig(machine_config &config) override; @@ -56,8 +56,8 @@ protected: void a2bus_dx1_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "speaker").front_center(); - DAC_8BIT_R2R(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.5); // unknown DAC - DAC_8BIT_R2R(config, m_dacvol, 0) + DAC_8BIT_R2R(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.5); // unknown DAC + DAC_8BIT_R2R(config, m_dacvol) .set_output_range(0, 1) .add_route(0, "dac", 1.0, DAC_INPUT_RANGE_HI) .add_route(0, "dac", -1.0, DAC_INPUT_RANGE_LO); // unknown DAC @@ -67,7 +67,7 @@ void a2bus_dx1_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_dx1_device::a2bus_dx1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_dx1_device::a2bus_dx1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_dac(*this, "dac"), @@ -75,7 +75,7 @@ a2bus_dx1_device::a2bus_dx1_device(const machine_config &mconfig, device_type ty { } -a2bus_dx1_device::a2bus_dx1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_dx1_device::a2bus_dx1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_dx1_device(mconfig, A2BUS_DX1, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2eauxslot.cpp b/src/devices/bus/a2bus/a2eauxslot.cpp index 36b99cbe6aa..25147f0f3f5 100644 --- a/src/devices/bus/a2bus/a2eauxslot.cpp +++ b/src/devices/bus/a2bus/a2eauxslot.cpp @@ -24,12 +24,12 @@ DEFINE_DEVICE_TYPE(A2EAUXSLOT_SLOT, a2eauxslot_slot_device, "a2eauxslot_slot", " //------------------------------------------------- // a2eauxslot_slot_device - constructor //------------------------------------------------- -a2eauxslot_slot_device::a2eauxslot_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a2eauxslot_slot_device::a2eauxslot_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2eauxslot_slot_device(mconfig, A2EAUXSLOT_SLOT, tag, owner, clock) { } -a2eauxslot_slot_device::a2eauxslot_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2eauxslot_slot_device::a2eauxslot_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_single_card_slot_interface<device_a2eauxslot_card_interface>(mconfig, *this) , m_a2eauxslot(*this, finder_base::DUMMY_TAG) @@ -57,12 +57,12 @@ DEFINE_DEVICE_TYPE(A2EAUXSLOT, a2eauxslot_device, "a2eauxslot", "Apple IIe AUX B // a2eauxslot_device - constructor //------------------------------------------------- -a2eauxslot_device::a2eauxslot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a2eauxslot_device::a2eauxslot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2eauxslot_device(mconfig, A2EAUXSLOT, tag, owner, clock) { } -a2eauxslot_device::a2eauxslot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2eauxslot_device::a2eauxslot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_space(*this, finder_base::DUMMY_TAG, -1) , m_out_irq_cb(*this) diff --git a/src/devices/bus/a2bus/a2eauxslot.h b/src/devices/bus/a2bus/a2eauxslot.h index 0eefe28db1d..e4b53cfbd2e 100644 --- a/src/devices/bus/a2bus/a2eauxslot.h +++ b/src/devices/bus/a2bus/a2eauxslot.h @@ -31,7 +31,7 @@ public: // construction/destruction template <typename T, typename U> a2eauxslot_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&slottag, U &&opts, char const *dflt) - : a2eauxslot_slot_device(mconfig, tag, owner, 0) + : a2eauxslot_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -40,14 +40,14 @@ public: m_a2eauxslot.set_tag(std::forward<T>(slottag)); } - a2eauxslot_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + a2eauxslot_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // device-level overrides virtual void device_resolve_objects() override; virtual void device_start() override { } protected: - a2eauxslot_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2eauxslot_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // configuration required_device<a2eauxslot_device> m_a2eauxslot; @@ -62,7 +62,7 @@ class a2eauxslot_device : public device_t { public: // construction/destruction - a2eauxslot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2eauxslot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration template <typename T> void set_space(T &&tag, int spacenum) { m_space.set_tag(std::forward<T>(tag), spacenum); } @@ -79,7 +79,7 @@ public: DECLARE_WRITE_LINE_MEMBER( nmi_w ); protected: - a2eauxslot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2eauxslot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; diff --git a/src/devices/bus/a2bus/a2echoii.cpp b/src/devices/bus/a2bus/a2echoii.cpp index 604dc7ae1c6..cbd3710e3d8 100644 --- a/src/devices/bus/a2bus/a2echoii.cpp +++ b/src/devices/bus/a2bus/a2echoii.cpp @@ -53,12 +53,12 @@ class a2bus_echoii_device: { public: // construction/destruction - a2bus_echoii_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_echoii_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); required_device<tms5220_device> m_tms; protected: - a2bus_echoii_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_echoii_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -88,7 +88,7 @@ private: void a2bus_echoii_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "echoii").front_center(); - tms5220_device &tms(TMS5220(config, TMS_TAG, 640000)); + tms5220_device &tms(TMS5220(config, TMS_TAG, XTAL::u(640000))); // Note the Echo II card has an R/C circuit (and sometimes a 'FREQ' potentiometer) to control the tms5220[c]'s clock frequency; 640khz is // the nominal '8khz' value according to the TMS5220 datasheet. // The EchoIIb card however has a 74LS92 which divides the apple2's Q3 ((14.318/7)MHz asymmetrical) clock by 6 to produce a 681.809khz/2 @@ -107,14 +107,14 @@ void a2bus_echoii_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_echoii_device::a2bus_echoii_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_echoii_device::a2bus_echoii_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_tms(*this, TMS_TAG) { } -a2bus_echoii_device::a2bus_echoii_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_echoii_device::a2bus_echoii_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_echoii_device(mconfig, A2BUS_ECHOII, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2eext80col.cpp b/src/devices/bus/a2bus/a2eext80col.cpp index 1c7a4fe77b3..f779425e9db 100644 --- a/src/devices/bus/a2bus/a2eext80col.cpp +++ b/src/devices/bus/a2bus/a2eext80col.cpp @@ -26,12 +26,12 @@ DEFINE_DEVICE_TYPE(A2EAUX_EXT80COL, a2eaux_ext80col_device, "a2eext80", "Apple I // LIVE DEVICE //************************************************************************** -a2eaux_ext80col_device::a2eaux_ext80col_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2eaux_ext80col_device::a2eaux_ext80col_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2eaux_ext80col_device(mconfig, A2EAUX_EXT80COL, tag, owner, clock) { } -a2eaux_ext80col_device::a2eaux_ext80col_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2eaux_ext80col_device::a2eaux_ext80col_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2eauxslot_card_interface(mconfig, *this) { diff --git a/src/devices/bus/a2bus/a2eext80col.h b/src/devices/bus/a2bus/a2eext80col.h index 239a22e1484..9cc494a4c2a 100644 --- a/src/devices/bus/a2bus/a2eext80col.h +++ b/src/devices/bus/a2bus/a2eext80col.h @@ -25,10 +25,10 @@ class a2eaux_ext80col_device: { public: // construction/destruction - a2eaux_ext80col_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2eaux_ext80col_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2eaux_ext80col_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2eaux_ext80col_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/a2eramworks3.cpp b/src/devices/bus/a2bus/a2eramworks3.cpp index 11dcf3cae68..a72c3ba70a4 100644 --- a/src/devices/bus/a2bus/a2eramworks3.cpp +++ b/src/devices/bus/a2bus/a2eramworks3.cpp @@ -30,24 +30,24 @@ DEFINE_DEVICE_TYPE(A2EAUX_FRANKLIN512, a2eaux_franklin512_device, "a2ef512", "Fr // LIVE DEVICE //************************************************************************** -a2eaux_ramworks3_device::a2eaux_ramworks3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2eaux_ramworks3_device::a2eaux_ramworks3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2eaux_ramworks3_device(mconfig, A2EAUX_RAMWORKS3, tag, owner, clock) { } -a2eaux_ramworks3_device::a2eaux_ramworks3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2eaux_ramworks3_device::a2eaux_ramworks3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2eauxslot_card_interface(mconfig, *this), m_bank(0) { } -a2eaux_franklin384_device::a2eaux_franklin384_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2eaux_franklin384_device::a2eaux_franklin384_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2eaux_ramworks3_device(mconfig, A2EAUX_FRANKLIN384, tag, owner, clock) { } -a2eaux_franklin512_device::a2eaux_franklin512_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2eaux_franklin512_device::a2eaux_franklin512_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2eaux_ramworks3_device(mconfig, A2EAUX_FRANKLIN512, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2eramworks3.h b/src/devices/bus/a2bus/a2eramworks3.h index fc083445e3c..693b12ea226 100644 --- a/src/devices/bus/a2bus/a2eramworks3.h +++ b/src/devices/bus/a2bus/a2eramworks3.h @@ -23,10 +23,10 @@ class a2eaux_ramworks3_device: { public: // construction/destruction - a2eaux_ramworks3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2eaux_ramworks3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2eaux_ramworks3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2eaux_ramworks3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -48,7 +48,7 @@ private: class a2eaux_franklin384_device: public a2eaux_ramworks3_device { public: - a2eaux_franklin384_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2eaux_franklin384_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void write_c07x(u8 offset, u8 data) override; @@ -57,7 +57,7 @@ protected: class a2eaux_franklin512_device: public a2eaux_ramworks3_device { public: - a2eaux_franklin512_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2eaux_franklin512_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void write_c07x(u8 offset, u8 data) override; diff --git a/src/devices/bus/a2bus/a2estd80col.cpp b/src/devices/bus/a2bus/a2estd80col.cpp index ab5d4bc48d1..7642b7211c6 100644 --- a/src/devices/bus/a2bus/a2estd80col.cpp +++ b/src/devices/bus/a2bus/a2estd80col.cpp @@ -21,12 +21,12 @@ DEFINE_DEVICE_TYPE(A2EAUX_STD80COL, a2eaux_std80col_device, "a2estd80", "Apple I // LIVE DEVICE //************************************************************************** -a2eaux_std80col_device::a2eaux_std80col_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2eaux_std80col_device::a2eaux_std80col_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2eaux_std80col_device(mconfig, A2EAUX_STD80COL, tag, owner, clock) { } -a2eaux_std80col_device::a2eaux_std80col_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2eaux_std80col_device::a2eaux_std80col_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2eauxslot_card_interface(mconfig, *this) { diff --git a/src/devices/bus/a2bus/a2estd80col.h b/src/devices/bus/a2bus/a2estd80col.h index d66a42a7495..78bdbd1b25f 100644 --- a/src/devices/bus/a2bus/a2estd80col.h +++ b/src/devices/bus/a2bus/a2estd80col.h @@ -25,10 +25,10 @@ class a2eaux_std80col_device: { public: // construction/destruction - a2eaux_std80col_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2eaux_std80col_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2eaux_std80col_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2eaux_std80col_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/a2hsscsi.cpp b/src/devices/bus/a2bus/a2hsscsi.cpp index b2043c20f30..d4779082092 100644 --- a/src/devices/bus/a2bus/a2hsscsi.cpp +++ b/src/devices/bus/a2bus/a2hsscsi.cpp @@ -97,7 +97,7 @@ const tiny_rom_entry *a2bus_hsscsi_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_hsscsi_device::a2bus_hsscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_hsscsi_device::a2bus_hsscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_ncr5380(*this, SCSI_5380_TAG), @@ -106,7 +106,7 @@ a2bus_hsscsi_device::a2bus_hsscsi_device(const machine_config &mconfig, device_t { } -a2bus_hsscsi_device::a2bus_hsscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_hsscsi_device::a2bus_hsscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_hsscsi_device(mconfig, A2BUS_HSSCSI, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2hsscsi.h b/src/devices/bus/a2bus/a2hsscsi.h index be200ccde0d..55c97948bb9 100644 --- a/src/devices/bus/a2bus/a2hsscsi.h +++ b/src/devices/bus/a2bus/a2hsscsi.h @@ -26,14 +26,14 @@ class a2bus_hsscsi_device: { public: // construction/destruction - a2bus_hsscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_hsscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } DECLARE_WRITE_LINE_MEMBER( drq_w ); protected: - a2bus_hsscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_hsscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/a2iwm.cpp b/src/devices/bus/a2bus/a2iwm.cpp index 74adc23ffa8..81bb8a5323c 100644 --- a/src/devices/bus/a2bus/a2iwm.cpp +++ b/src/devices/bus/a2bus/a2iwm.cpp @@ -59,7 +59,7 @@ const tiny_rom_entry *a2bus_iwm_card_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_iwm_device::a2bus_iwm_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_iwm_device::a2bus_iwm_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_iwm(*this, "iwm"), @@ -67,12 +67,12 @@ a2bus_iwm_device::a2bus_iwm_device(const machine_config &mconfig, device_type ty { } -a2bus_iwm_int_device::a2bus_iwm_int_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_iwm_int_device::a2bus_iwm_int_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_iwm_device(mconfig, A2BUS_IWM, tag, owner, clock) { } -a2bus_iwm_card_device::a2bus_iwm_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_iwm_card_device::a2bus_iwm_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_iwm_device(mconfig, A2BUS_IWM_CARD, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2iwm.h b/src/devices/bus/a2bus/a2iwm.h index 3f0fe974d3a..d7249565dc6 100644 --- a/src/devices/bus/a2bus/a2iwm.h +++ b/src/devices/bus/a2bus/a2iwm.h @@ -29,7 +29,7 @@ class a2bus_iwm_device: { protected: // construction/destruction - a2bus_iwm_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_iwm_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -50,13 +50,13 @@ private: class a2bus_iwm_int_device: public a2bus_iwm_device { public: - a2bus_iwm_int_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_iwm_int_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class a2bus_iwm_card_device: public a2bus_iwm_device { public: - a2bus_iwm_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_iwm_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/a2bus/a2mcms.cpp b/src/devices/bus/a2bus/a2mcms.cpp index f23a647f4a8..362e3843820 100644 --- a/src/devices/bus/a2bus/a2mcms.cpp +++ b/src/devices/bus/a2bus/a2mcms.cpp @@ -52,7 +52,7 @@ void a2bus_mcms1_device::device_add_mconfig(machine_config &config) SPEAKER(config, "mcms_l").front_left(); SPEAKER(config, "mcms_r").front_right(); - MCMS(config, m_mcms, 1000000); + MCMS(config, m_mcms, XTAL::u(1000000)); m_mcms->irq_cb().set(FUNC(a2bus_mcms1_device::irq_w)); m_mcms->add_route(0, "mcms_l", 1.0); m_mcms->add_route(1, "mcms_r", 1.0); @@ -62,14 +62,14 @@ void a2bus_mcms1_device::device_add_mconfig(machine_config &config) // LIVE DEVICE - Card 1 //************************************************************************** -a2bus_mcms1_device::a2bus_mcms1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_mcms1_device::a2bus_mcms1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_mcms(*this, ENGINE_TAG) { } -a2bus_mcms1_device::a2bus_mcms1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_mcms1_device::a2bus_mcms1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_mcms1_device(mconfig, A2BUS_MCMS1, tag, owner, clock) { } @@ -139,13 +139,13 @@ WRITE_LINE_MEMBER(a2bus_mcms1_device::irq_w) // LIVE DEVICE - Card 2 //************************************************************************** -a2bus_mcms2_device::a2bus_mcms2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_mcms2_device::a2bus_mcms2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_card1(nullptr), m_engine(nullptr) { } -a2bus_mcms2_device::a2bus_mcms2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_mcms2_device::a2bus_mcms2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_mcms2_device(mconfig, A2BUS_MCMS2, tag, owner, clock) { } @@ -196,7 +196,7 @@ void a2bus_mcms2_device::write_cnxx(uint8_t offset, uint8_t data) Sound device implementation */ -mcms_device::mcms_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mcms_device::mcms_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MCMS, tag, owner, clock), device_sound_interface(mconfig, *this), m_write_irq(*this), m_stream(nullptr), m_timer(nullptr), m_clrtimer(nullptr), m_pBusDevice(nullptr), m_enabled(false), m_mastervol(0), m_rand(0) diff --git a/src/devices/bus/a2bus/a2mcms.h b/src/devices/bus/a2bus/a2mcms.h index 371c74c54fa..3340fdcbc1d 100644 --- a/src/devices/bus/a2bus/a2mcms.h +++ b/src/devices/bus/a2bus/a2mcms.h @@ -25,7 +25,7 @@ class mcms_device : public device_t, public device_sound_interface { public: // construction/destruction - mcms_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mcms_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void voiceregs_w(offs_t offset, uint8_t data); void control_w(offs_t offset, uint8_t data); @@ -67,7 +67,7 @@ class a2bus_mcms1_device: { public: // construction/destruction - a2bus_mcms1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_mcms1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // comms from card 2 (oscillator parameter writes) mcms_device *get_engine(void); @@ -75,7 +75,7 @@ public: required_device<mcms_device> m_mcms; protected: - a2bus_mcms1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_mcms1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -98,10 +98,10 @@ class a2bus_mcms2_device: { public: // construction/destruction - a2bus_mcms2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_mcms2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_mcms2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_mcms2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/a2memexp.cpp b/src/devices/bus/a2bus/a2memexp.cpp index 4c10de81848..1984b00c13a 100644 --- a/src/devices/bus/a2bus/a2memexp.cpp +++ b/src/devices/bus/a2bus/a2memexp.cpp @@ -48,7 +48,7 @@ public: protected: // construction/destruction - a2bus_memexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_memexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -71,13 +71,13 @@ private: class a2bus_memexpapple_device : public a2bus_memexp_device { public: - a2bus_memexpapple_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_memexpapple_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class a2bus_ramfactor_device : public a2bus_memexp_device { public: - a2bus_ramfactor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ramfactor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -113,7 +113,7 @@ const tiny_rom_entry *a2bus_ramfactor_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_memexp_device::a2bus_memexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_memexp_device::a2bus_memexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_isramfactor(false), m_bankhior(0), m_addrmask(0), m_rom(*this, MEMEXP_ROM_REGION), @@ -121,7 +121,7 @@ a2bus_memexp_device::a2bus_memexp_device(const machine_config &mconfig, device_t { } -a2bus_memexpapple_device::a2bus_memexpapple_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_memexpapple_device::a2bus_memexpapple_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_memexp_device(mconfig, A2BUS_MEMEXP, tag, owner, clock) { m_isramfactor = false; @@ -129,7 +129,7 @@ a2bus_memexpapple_device::a2bus_memexpapple_device(const machine_config &mconfig m_addrmask = 0xfffff; } -a2bus_ramfactor_device::a2bus_ramfactor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ramfactor_device::a2bus_ramfactor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_memexp_device(mconfig, A2BUS_RAMFACTOR, tag, owner, clock) { m_isramfactor = true; diff --git a/src/devices/bus/a2bus/a2midi.cpp b/src/devices/bus/a2bus/a2midi.cpp index f1cc7ecb2a6..392fea79bae 100644 --- a/src/devices/bus/a2bus/a2midi.cpp +++ b/src/devices/bus/a2bus/a2midi.cpp @@ -37,10 +37,10 @@ class a2bus_midi_device: { public: // construction/destruction - a2bus_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -66,11 +66,11 @@ private: void a2bus_midi_device::device_add_mconfig(machine_config &config) { - PTM6840(config, m_ptm, 1021800); - m_ptm->set_external_clocks(1021800.0f, 1021800.0f, 1021800.0f); + PTM6840(config, m_ptm, XTAL::u(1021800)); + m_ptm->set_external_clocks(XTAL::u(1021800), XTAL::u(1021800), XTAL::u(1021800)); m_ptm->irq_callback().set(FUNC(a2bus_midi_device::ptm_irq_w)); - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("mdout", FUNC(midi_port_device::write_txd)); m_acia->irq_handler().set(FUNC(a2bus_midi_device::acia_irq_w)); @@ -78,7 +78,7 @@ void a2bus_midi_device::device_add_mconfig(machine_config &config) MIDI_PORT(config, "mdout", midiout_slot, "midiout"); - clock_device &acia_clock(CLOCK(config, "acia_clock", 31250*16)); + clock_device &acia_clock(CLOCK(config, "acia_clock", XTAL::u(31250*16))); acia_clock.signal_handler().set(FUNC(a2bus_midi_device::write_acia_clock)); } @@ -86,12 +86,12 @@ void a2bus_midi_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_midi_device::a2bus_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_midi_device::a2bus_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_midi_device(mconfig, A2BUS_MIDI, tag, owner, clock) { } -a2bus_midi_device::a2bus_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_midi_device::a2bus_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_ptm(*this, MIDI_PTM_TAG), diff --git a/src/devices/bus/a2bus/a2mockingboard.cpp b/src/devices/bus/a2bus/a2mockingboard.cpp index 0968d55c9a0..56c956950ab 100644 --- a/src/devices/bus/a2bus/a2mockingboard.cpp +++ b/src/devices/bus/a2bus/a2mockingboard.cpp @@ -54,7 +54,7 @@ public: protected: // construction/destruction - a2bus_ayboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_ayboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -80,7 +80,7 @@ protected: class a2bus_mockingboard_device : public a2bus_ayboard_device { public: - a2bus_mockingboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_mockingboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void via1_out_b(u8 data) override; protected: @@ -99,7 +99,7 @@ private: class a2bus_phasor_device : public a2bus_ayboard_device { public: - a2bus_phasor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_phasor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void via1_out_b(u8 data) override; void via2_out_b(u8 data) override; @@ -124,7 +124,7 @@ private: class a2bus_echoplus_device : public a2bus_ayboard_device { public: - a2bus_echoplus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_echoplus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -145,13 +145,13 @@ protected: void a2bus_ayboard_device::add_common_devices(machine_config &config) { - MOS6522(config, m_via1, 1022727); + MOS6522(config, m_via1, XTAL::u(1022727)); m_via1->readpa_handler().set(FUNC(a2bus_ayboard_device::via1_in_a)); m_via1->writepa_handler().set(FUNC(a2bus_ayboard_device::via1_out_a)); m_via1->writepb_handler().set(FUNC(a2bus_ayboard_device::via1_out_b)); m_via1->irq_handler().set(FUNC(a2bus_ayboard_device::via1_irq_w)); - MOS6522(config, m_via2, 1022727); + MOS6522(config, m_via2, XTAL::u(1022727)); m_via2->readpa_handler().set(FUNC(a2bus_ayboard_device::via2_in_a)); m_via2->writepa_handler().set(FUNC(a2bus_ayboard_device::via2_out_a)); m_via2->writepb_handler().set(FUNC(a2bus_ayboard_device::via2_out_b)); @@ -159,7 +159,7 @@ void a2bus_ayboard_device::add_common_devices(machine_config &config) SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - AY8913(config, m_ay1, 1022727); + AY8913(config, m_ay1, XTAL::u(1022727)); m_ay1->add_route(ALL_OUTPUTS, "lspeaker", 0.5); } @@ -167,7 +167,7 @@ void a2bus_ayboard_device::device_add_mconfig(machine_config &config) { add_common_devices(config); - AY8913(config, m_ay2, 1022727); + AY8913(config, m_ay2, XTAL::u(1022727)); m_ay2->add_route(ALL_OUTPUTS, "rspeaker", 0.5); } @@ -178,10 +178,10 @@ void a2bus_mockingboard_device::device_add_mconfig(machine_config &config) m_via1->writepb_handler().set(FUNC(a2bus_mockingboard_device::via1_out_b)); m_via1->cb2_handler().set(FUNC(a2bus_mockingboard_device::write_via1_cb2)); - AY8913(config, m_ay2, 1022727); + AY8913(config, m_ay2, XTAL::u(1022727)); m_ay2->add_route(ALL_OUTPUTS, "rspeaker", 0.5); - VOTRAX_SC01(config, m_sc01, 1022727); + VOTRAX_SC01(config, m_sc01, XTAL::u(1022727)); m_sc01->ar_callback().set(m_via1, FUNC(via6522_device::write_cb1)); m_sc01->add_route(ALL_OUTPUTS, "lspeaker", 1.0); m_sc01->add_route(ALL_OUTPUTS, "rspeaker", 1.0); @@ -196,9 +196,9 @@ void a2bus_phasor_device::device_add_mconfig(machine_config &config) SPEAKER(config, "lspeaker2").front_left(); SPEAKER(config, "rspeaker2").front_right(); - AY8913(config, m_ay2, 1022727); - AY8913(config, m_ay3, 1022727); - AY8913(config, m_ay4, 1022727); + AY8913(config, m_ay2, XTAL::u(1022727)); + AY8913(config, m_ay3, XTAL::u(1022727)); + AY8913(config, m_ay4, XTAL::u(1022727)); m_ay2->add_route(ALL_OUTPUTS, "lspeaker2", 0.5); m_ay3->add_route(ALL_OUTPUTS, "rspeaker", 0.5); m_ay4->add_route(ALL_OUTPUTS, "rspeaker2", 0.5); @@ -211,11 +211,11 @@ void a2bus_echoplus_device::device_add_mconfig(machine_config &config) config.device_remove(VIA2_TAG); m_via1->writepb_handler().set(FUNC(a2bus_ayboard_device::via1_out_b)); - AY8913(config, m_ay2, 1022727); + AY8913(config, m_ay2, XTAL::u(1022727)); m_ay2->add_route(ALL_OUTPUTS, "rspeaker", 0.5); SPEAKER(config, "echosp").front_center(); - TMS5220(config, m_tms, 640000); + TMS5220(config, m_tms, XTAL::u(640000)); // echo+ has a TSP5220C soldered down on it m_tms->add_route(ALL_OUTPUTS, "echosp", 1.0); } @@ -224,7 +224,7 @@ void a2bus_echoplus_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_ayboard_device::a2bus_ayboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ayboard_device::a2bus_ayboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_via1(*this, VIA1_TAG), @@ -236,13 +236,13 @@ a2bus_ayboard_device::a2bus_ayboard_device(const machine_config &mconfig, device { } -a2bus_mockingboard_device::a2bus_mockingboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_mockingboard_device::a2bus_mockingboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ayboard_device(mconfig, A2BUS_MOCKINGBOARD, tag, owner, clock), m_sc01(*this, "sc01") { } -a2bus_phasor_device::a2bus_phasor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_phasor_device::a2bus_phasor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ayboard_device(mconfig, A2BUS_PHASOR, tag, owner, clock), m_ay3(*this, AY3_TAG), m_ay4(*this, AY4_TAG), @@ -250,7 +250,7 @@ a2bus_phasor_device::a2bus_phasor_device(const machine_config &mconfig, const ch { } -a2bus_echoplus_device::a2bus_echoplus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_echoplus_device::a2bus_echoplus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ayboard_device(mconfig, A2BUS_ECHOPLUS, tag, owner, clock), m_tms(*this, E2P_TMS_TAG) { @@ -628,10 +628,10 @@ void a2bus_phasor_device::set_clocks() } else { - m_ay1->set_clock(1022727); - m_ay2->set_clock(1022727); - m_ay3->set_clock(1022727); - m_ay4->set_clock(1022727); + m_ay1->set_clock(XTAL::u(1022727)); + m_ay2->set_clock(XTAL::u(1022727)); + m_ay3->set_clock(XTAL::u(1022727)); + m_ay4->set_clock(XTAL::u(1022727)); } } diff --git a/src/devices/bus/a2bus/a2parprn.cpp b/src/devices/bus/a2bus/a2parprn.cpp index c79f04f6da8..4acbf05bac6 100644 --- a/src/devices/bus/a2bus/a2parprn.cpp +++ b/src/devices/bus/a2bus/a2parprn.cpp @@ -14,7 +14,7 @@ namespace { class a2bus_parprn_device : public device_t, public device_a2bus_card_interface { public: - a2bus_parprn_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + a2bus_parprn_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // device_a2bus_card_interface implementation virtual u8 read_c0nx(u8 offset) override; @@ -104,7 +104,7 @@ INPUT_PORTS_END -a2bus_parprn_device::a2bus_parprn_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : +a2bus_parprn_device::a2bus_parprn_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, A2BUS_PARPRN, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_printer_conn(*this, "prn"), diff --git a/src/devices/bus/a2bus/a2pic.cpp b/src/devices/bus/a2bus/a2pic.cpp index 537abe313ad..f4f311e22b0 100644 --- a/src/devices/bus/a2bus/a2pic.cpp +++ b/src/devices/bus/a2bus/a2pic.cpp @@ -14,7 +14,7 @@ namespace { class a2bus_pic_device : public device_t, public device_a2bus_card_interface { public: - a2bus_pic_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + a2bus_pic_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // DIP switch/jumper handlers DECLARE_INPUT_CHANGED_MEMBER(sw1_strobe); @@ -126,7 +126,7 @@ INPUT_PORTS_END -a2bus_pic_device::a2bus_pic_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : +a2bus_pic_device::a2bus_pic_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, A2BUS_PIC, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_printer_conn(*this, "prn"), diff --git a/src/devices/bus/a2bus/a2sam.cpp b/src/devices/bus/a2bus/a2sam.cpp index ecedc1eaa61..03921c099b8 100644 --- a/src/devices/bus/a2bus/a2sam.cpp +++ b/src/devices/bus/a2bus/a2sam.cpp @@ -28,7 +28,7 @@ class a2bus_sam_device: { public: // construction/destruction - a2bus_sam_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : + a2bus_sam_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, A2BUS_SAM, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_dac(*this, "dac") @@ -54,7 +54,7 @@ protected: void a2bus_sam_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "speaker").front_center(); - DAC_8BIT_R2R(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.5); // unknown DAC + DAC_8BIT_R2R(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.5); // unknown DAC } } // anonymous namespace diff --git a/src/devices/bus/a2bus/a2scsi.cpp b/src/devices/bus/a2bus/a2scsi.cpp index fb3e7e8e222..b5cfdb65903 100644 --- a/src/devices/bus/a2bus/a2scsi.cpp +++ b/src/devices/bus/a2bus/a2scsi.cpp @@ -90,7 +90,7 @@ const tiny_rom_entry *a2bus_scsi_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_scsi_device::a2bus_scsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_scsi_device::a2bus_scsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_ncr5380(*this, SCSI_5380_TAG), @@ -98,7 +98,7 @@ a2bus_scsi_device::a2bus_scsi_device(const machine_config &mconfig, device_type { } -a2bus_scsi_device::a2bus_scsi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_scsi_device::a2bus_scsi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_scsi_device(mconfig, A2BUS_SCSI, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2scsi.h b/src/devices/bus/a2bus/a2scsi.h index 098e7848563..06a49fd9115 100644 --- a/src/devices/bus/a2bus/a2scsi.h +++ b/src/devices/bus/a2bus/a2scsi.h @@ -26,12 +26,12 @@ class a2bus_scsi_device: { public: // construction/destruction - a2bus_scsi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_scsi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( drq_w ); protected: - a2bus_scsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_scsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/a2sd.cpp b/src/devices/bus/a2bus/a2sd.cpp index c5f1e743d0f..f20c57acfdc 100644 --- a/src/devices/bus/a2bus/a2sd.cpp +++ b/src/devices/bus/a2bus/a2sd.cpp @@ -62,9 +62,9 @@ ROM_END //------------------------------------------------- void a2bus_a2sd_device::device_add_mconfig(machine_config &config) { - AT28C64B(config, m_flash, 0); + AT28C64B(config, m_flash); - SPI_SDCARD(config, m_sdcard, 0); + SPI_SDCARD(config, m_sdcard); m_sdcard->spi_miso_callback().set(FUNC(a2bus_a2sd_device::spi_miso_w)); } @@ -81,7 +81,7 @@ const tiny_rom_entry *a2bus_a2sd_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_a2sd_device::a2bus_a2sd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_a2sd_device::a2bus_a2sd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_flash(*this, "flash"), @@ -90,7 +90,7 @@ a2bus_a2sd_device::a2bus_a2sd_device(const machine_config &mconfig, device_type { } -a2bus_a2sd_device::a2bus_a2sd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_a2sd_device::a2bus_a2sd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_a2sd_device(mconfig, A2BUS_A2SD, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2sd.h b/src/devices/bus/a2bus/a2sd.h index 88414ec39d3..fe0730e11d2 100644 --- a/src/devices/bus/a2bus/a2sd.h +++ b/src/devices/bus/a2bus/a2sd.h @@ -27,10 +27,10 @@ class a2bus_a2sd_device: { public: // construction/destruction - a2bus_a2sd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_a2sd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_a2sd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_a2sd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/a2softcard.cpp b/src/devices/bus/a2bus/a2softcard.cpp index bab2ea728f8..24a16a650b8 100644 --- a/src/devices/bus/a2bus/a2softcard.cpp +++ b/src/devices/bus/a2bus/a2softcard.cpp @@ -47,14 +47,14 @@ void a2bus_softcard_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_softcard_device::a2bus_softcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_softcard_device::a2bus_softcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_z80(*this, Z80_TAG), m_bEnabled(false), m_FirstZ80Boot(false) { } -a2bus_softcard_device::a2bus_softcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_softcard_device::a2bus_softcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_softcard_device(mconfig, A2BUS_SOFTCARD, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2softcard.h b/src/devices/bus/a2bus/a2softcard.h index de2ee0e220b..2767f6b73f7 100644 --- a/src/devices/bus/a2bus/a2softcard.h +++ b/src/devices/bus/a2bus/a2softcard.h @@ -23,10 +23,10 @@ class a2bus_softcard_device: { public: // construction/destruction - a2bus_softcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_softcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_softcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_softcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/a2ssc.cpp b/src/devices/bus/a2bus/a2ssc.cpp index 61ab1efc30b..1c77983e713 100644 --- a/src/devices/bus/a2bus/a2ssc.cpp +++ b/src/devices/bus/a2bus/a2ssc.cpp @@ -32,10 +32,10 @@ class a2bus_ssc_device: { public: // construction/destruction - a2bus_ssc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ssc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_ssc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_ssc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -63,7 +63,7 @@ class apricorn_ssi_device : public a2bus_ssc_device { public: // construction/destruction - apricorn_ssi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apricorn_ssi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -269,7 +269,7 @@ ioport_constructor apricorn_ssi_device::device_input_ports() const void a2bus_ssc_device::device_add_mconfig(machine_config &config) { - MOS6551(config, m_acia, 0); + MOS6551(config, m_acia); m_acia->set_xtal(1.8432_MHz_XTAL); m_acia->irq_handler().set(FUNC(a2bus_ssc_device::acia_irq_w)); m_acia->txd_handler().set("rs232", FUNC(rs232_port_device::write_txd)); @@ -301,12 +301,12 @@ const tiny_rom_entry *apricorn_ssi_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_ssc_device::a2bus_ssc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ssc_device::a2bus_ssc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ssc_device(mconfig, A2BUS_SSC, tag, owner, clock) { } -a2bus_ssc_device::a2bus_ssc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ssc_device::a2bus_ssc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_dsw1(*this, "DSW1"), @@ -317,7 +317,7 @@ a2bus_ssc_device::a2bus_ssc_device(const machine_config &mconfig, device_type ty { } -apricorn_ssi_device::apricorn_ssi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +apricorn_ssi_device::apricorn_ssi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ssc_device(mconfig, APRICORN_SSI, tag, owner, clock), m_alt_bank(false) { diff --git a/src/devices/bus/a2bus/a2superdrive.cpp b/src/devices/bus/a2bus/a2superdrive.cpp index 7fb5820caa9..285d6dd0e80 100644 --- a/src/devices/bus/a2bus/a2superdrive.cpp +++ b/src/devices/bus/a2bus/a2superdrive.cpp @@ -55,10 +55,10 @@ class a2bus_superdrive_device: { public: // construction/destruction - a2bus_superdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_superdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_superdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_superdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -138,7 +138,7 @@ void a2bus_superdrive_device::device_add_mconfig(machine_config &config) -a2bus_superdrive_device::a2bus_superdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_superdrive_device::a2bus_superdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_65c02(*this, "superdrive_65c02"), @@ -149,7 +149,7 @@ a2bus_superdrive_device::a2bus_superdrive_device(const machine_config &mconfig, m_side(0) { } -a2bus_superdrive_device::a2bus_superdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +a2bus_superdrive_device::a2bus_superdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): a2bus_superdrive_device(mconfig, A2BUS_SUPERDRIVE, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2swyft.cpp b/src/devices/bus/a2bus/a2swyft.cpp index 6d9701d3a04..ac10b27924e 100644 --- a/src/devices/bus/a2bus/a2swyft.cpp +++ b/src/devices/bus/a2bus/a2swyft.cpp @@ -37,12 +37,12 @@ class a2bus_swyft_device: { public: // construction/destruction - a2bus_swyft_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_swyft_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; protected: - a2bus_swyft_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_swyft_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -73,12 +73,12 @@ const tiny_rom_entry *a2bus_swyft_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_swyft_device::a2bus_swyft_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_swyft_device::a2bus_swyft_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_swyft_device(mconfig, A2BUS_SWYFT, tag, owner, clock) { } -a2bus_swyft_device::a2bus_swyft_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_swyft_device::a2bus_swyft_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_rom(*this, SWYFT_ROM_REGION) diff --git a/src/devices/bus/a2bus/a2themill.cpp b/src/devices/bus/a2bus/a2themill.cpp index 44925c4c68b..837f0a584c6 100644 --- a/src/devices/bus/a2bus/a2themill.cpp +++ b/src/devices/bus/a2bus/a2themill.cpp @@ -68,7 +68,7 @@ ioport_constructor a2bus_themill_device::device_input_ports() const void a2bus_themill_device::device_add_mconfig(machine_config &config) { - MC6809E(config, m_6809, 1021800); // 6809E runs at ~1 MHz as per Stellation Two's print ads + MC6809E(config, m_6809, XTAL::u(1021800)); // 6809E runs at ~1 MHz as per Stellation Two's print ads m_6809->set_addrmap(AS_PROGRAM, &a2bus_themill_device::m6809_mem); } @@ -76,7 +76,7 @@ void a2bus_themill_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_themill_device::a2bus_themill_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2bus_themill_device::a2bus_themill_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a2bus_card_interface(mconfig, *this) , m_6809(*this, "m6809") @@ -88,7 +88,7 @@ a2bus_themill_device::a2bus_themill_device(const machine_config &mconfig, device { } -a2bus_themill_device::a2bus_themill_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_themill_device::a2bus_themill_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_themill_device(mconfig, A2BUS_THEMILL, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2themill.h b/src/devices/bus/a2bus/a2themill.h index 59f0c2316d1..71285642c3d 100644 --- a/src/devices/bus/a2bus/a2themill.h +++ b/src/devices/bus/a2bus/a2themill.h @@ -25,10 +25,10 @@ class a2bus_themill_device: { public: // construction/destruction - a2bus_themill_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_themill_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_themill_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_themill_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/a2thunderclock.cpp b/src/devices/bus/a2bus/a2thunderclock.cpp index c109be5c276..260de5c5d4b 100644 --- a/src/devices/bus/a2bus/a2thunderclock.cpp +++ b/src/devices/bus/a2bus/a2thunderclock.cpp @@ -55,10 +55,10 @@ class a2bus_thunderclock_device: { public: // construction/destruction - a2bus_thunderclock_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_thunderclock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_thunderclock_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_thunderclock_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -107,7 +107,7 @@ const tiny_rom_entry *a2bus_thunderclock_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_thunderclock_device::a2bus_thunderclock_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_thunderclock_device::a2bus_thunderclock_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_upd1990ac(*this, THUNDERCLOCK_UPD1990_TAG), @@ -116,7 +116,7 @@ a2bus_thunderclock_device::a2bus_thunderclock_device(const machine_config &mconf { } -a2bus_thunderclock_device::a2bus_thunderclock_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_thunderclock_device::a2bus_thunderclock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_thunderclock_device(mconfig, A2BUS_THUNDERCLOCK, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2ultraterm.cpp b/src/devices/bus/a2bus/a2ultraterm.cpp index 468c7402c46..fea8fa92aa1 100644 --- a/src/devices/bus/a2bus/a2ultraterm.cpp +++ b/src/devices/bus/a2bus/a2ultraterm.cpp @@ -104,7 +104,7 @@ class a2bus_videx160_device: { protected: // construction/destruction - a2bus_videx160_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_videx160_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -135,7 +135,7 @@ private: class a2bus_ultraterm_device : public a2bus_videx160_device { public: - a2bus_ultraterm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ultraterm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; @@ -143,7 +143,7 @@ public: class a2bus_ultratermenh_device : public a2bus_videx160_device { public: - a2bus_ultratermenh_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ultratermenh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; @@ -188,7 +188,7 @@ const tiny_rom_entry *a2bus_ultratermenh_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_videx160_device::a2bus_videx160_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_videx160_device::a2bus_videx160_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_framecnt(0), m_ctrl1(0), m_ctrl2(0), @@ -199,12 +199,12 @@ a2bus_videx160_device::a2bus_videx160_device(const machine_config &mconfig, devi { } -a2bus_ultraterm_device::a2bus_ultraterm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ultraterm_device::a2bus_ultraterm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_videx160_device(mconfig, A2BUS_ULTRATERM, tag, owner, clock) { } -a2bus_ultratermenh_device::a2bus_ultratermenh_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ultratermenh_device::a2bus_ultratermenh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_videx160_device(mconfig, A2BUS_ULTRATERMENH, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2videoterm.cpp b/src/devices/bus/a2bus/a2videoterm.cpp index c5c75fc3323..3b17a680593 100644 --- a/src/devices/bus/a2bus/a2videoterm.cpp +++ b/src/devices/bus/a2bus/a2videoterm.cpp @@ -106,7 +106,7 @@ class a2bus_videx80_device: { protected: // construction/destruction - a2bus_videx80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_videx80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -134,7 +134,7 @@ protected: class a2bus_videoterm_device : public a2bus_videx80_device { public: - a2bus_videoterm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_videoterm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; @@ -142,7 +142,7 @@ public: class a2bus_ap16_device : public a2bus_videx80_device { public: - a2bus_ap16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ap16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; virtual const tiny_rom_entry *device_rom_region() const override; @@ -155,7 +155,7 @@ protected: class a2bus_ap16alt_device : public a2bus_videx80_device { public: - a2bus_ap16alt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ap16alt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; virtual const tiny_rom_entry *device_rom_region() const override; @@ -167,7 +167,7 @@ protected: class a2bus_vtc1_device : public a2bus_videx80_device { public: - a2bus_vtc1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_vtc1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; virtual const tiny_rom_entry *device_rom_region() const override; @@ -176,7 +176,7 @@ public: class a2bus_aevm80_device : public a2bus_videx80_device { public: - a2bus_aevm80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_aevm80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; virtual const tiny_rom_entry *device_rom_region() const override; @@ -275,7 +275,7 @@ const tiny_rom_entry *a2bus_aevm80_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_videx80_device::a2bus_videx80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_videx80_device::a2bus_videx80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_crtc(*this, VIDEOTERM_MC6845_NAME), @@ -286,28 +286,28 @@ a2bus_videx80_device::a2bus_videx80_device(const machine_config &mconfig, device { } -a2bus_videoterm_device::a2bus_videoterm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_videoterm_device::a2bus_videoterm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_videx80_device(mconfig, A2BUS_VIDEOTERM, tag, owner, clock) { } -a2bus_ap16_device::a2bus_ap16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ap16_device::a2bus_ap16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_videx80_device(mconfig, A2BUS_IBSAP16, tag, owner, clock) { } -a2bus_ap16alt_device::a2bus_ap16alt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ap16alt_device::a2bus_ap16alt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_videx80_device(mconfig, A2BUS_IBSAP16ALT, tag, owner, clock) { } -a2bus_vtc1_device::a2bus_vtc1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_vtc1_device::a2bus_vtc1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_videx80_device(mconfig, A2BUS_VTC1, tag, owner, clock) { m_char_width = 11; } -a2bus_aevm80_device::a2bus_aevm80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_aevm80_device::a2bus_aevm80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_videx80_device(mconfig, A2BUS_AEVIEWMASTER80, tag, owner, clock) { m_char_width = 10; diff --git a/src/devices/bus/a2bus/a2vulcan.cpp b/src/devices/bus/a2bus/a2vulcan.cpp index 889e7df5de3..632b9c16b58 100644 --- a/src/devices/bus/a2bus/a2vulcan.cpp +++ b/src/devices/bus/a2bus/a2vulcan.cpp @@ -90,7 +90,7 @@ class a2bus_vulcanbase_device: { protected: // construction/destruction - a2bus_vulcanbase_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_vulcanbase_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -117,7 +117,7 @@ private: class a2bus_vulcan_device : public a2bus_vulcanbase_device { public: - a2bus_vulcan_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_vulcan_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -127,7 +127,7 @@ protected: class a2bus_vulcaniie_device : public a2bus_vulcanbase_device { public: - a2bus_vulcaniie_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_vulcaniie_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -137,7 +137,7 @@ protected: class a2bus_vulcangold_device : public a2bus_vulcanbase_device { public: - a2bus_vulcangold_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_vulcangold_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -179,7 +179,7 @@ const tiny_rom_entry *a2bus_vulcangold_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_vulcanbase_device::a2bus_vulcanbase_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_vulcanbase_device::a2bus_vulcanbase_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_ata(*this, VULCAN_ATA_TAG), @@ -188,17 +188,17 @@ a2bus_vulcanbase_device::a2bus_vulcanbase_device(const machine_config &mconfig, { } -a2bus_vulcan_device::a2bus_vulcan_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_vulcan_device::a2bus_vulcan_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_vulcanbase_device(mconfig, A2BUS_VULCAN, tag, owner, clock) { } -a2bus_vulcaniie_device::a2bus_vulcaniie_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_vulcaniie_device::a2bus_vulcaniie_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_vulcanbase_device(mconfig, A2BUS_VULCANIIE, tag, owner, clock) { } -a2bus_vulcangold_device::a2bus_vulcangold_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_vulcangold_device::a2bus_vulcangold_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_vulcanbase_device(mconfig, A2BUS_VULCANGOLD, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/a2zipdrive.cpp b/src/devices/bus/a2bus/a2zipdrive.cpp index 9a59af1a431..77accaf4105 100644 --- a/src/devices/bus/a2bus/a2zipdrive.cpp +++ b/src/devices/bus/a2bus/a2zipdrive.cpp @@ -98,7 +98,7 @@ class a2bus_zipdrivebase_device: { protected: // construction/destruction - a2bus_zipdrivebase_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_zipdrivebase_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -120,13 +120,13 @@ protected: class a2bus_zipdrive_device : public a2bus_zipdrivebase_device { public: - a2bus_zipdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_zipdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class a2bus_focusdrive_device : public a2bus_zipdrivebase_device { public: - a2bus_focusdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_focusdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; @@ -166,7 +166,7 @@ const tiny_rom_entry *a2bus_focusdrive_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_zipdrivebase_device::a2bus_zipdrivebase_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_zipdrivebase_device::a2bus_zipdrivebase_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_ata(*this, ZIPDRIVE_ATA_TAG), @@ -175,12 +175,12 @@ a2bus_zipdrivebase_device::a2bus_zipdrivebase_device(const machine_config &mconf { } -a2bus_zipdrive_device::a2bus_zipdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_zipdrive_device::a2bus_zipdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_zipdrivebase_device(mconfig, A2BUS_ZIPDRIVE, tag, owner, clock) { } -a2bus_focusdrive_device::a2bus_focusdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_focusdrive_device::a2bus_focusdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_zipdrivebase_device(mconfig, A2BUS_FOCUSDRIVE, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/ace2x00.cpp b/src/devices/bus/a2bus/ace2x00.cpp index ccea01c4ecc..922fea05c81 100644 --- a/src/devices/bus/a2bus/ace2x00.cpp +++ b/src/devices/bus/a2bus/ace2x00.cpp @@ -41,18 +41,18 @@ void a2bus_ace2x00_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_ace2x00_device::a2bus_ace2x00_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ace2x00_device::a2bus_ace2x00_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_rom(nullptr) { } -a2bus_ace2x00_slot1_device::a2bus_ace2x00_slot1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ace2x00_slot1_device::a2bus_ace2x00_slot1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ace2x00_device(mconfig, A2BUS_ACE2X00_SLOT1, tag, owner, clock) { } -a2bus_ace2x00_slot6_device::a2bus_ace2x00_slot6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ace2x00_slot6_device::a2bus_ace2x00_slot6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ace2x00_device(mconfig, A2BUS_ACE2X00_SLOT6, tag, owner, clock), m_iwm(*this, "iwm"), m_floppy(*this, "%u", 0U) diff --git a/src/devices/bus/a2bus/ace2x00.h b/src/devices/bus/a2bus/ace2x00.h index 9714f5aa965..2f041728df2 100644 --- a/src/devices/bus/a2bus/ace2x00.h +++ b/src/devices/bus/a2bus/ace2x00.h @@ -28,7 +28,7 @@ class a2bus_ace2x00_device: { public: // construction/destruction - a2bus_ace2x00_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_ace2x00_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -47,7 +47,7 @@ protected: class a2bus_ace2x00_slot1_device : public a2bus_ace2x00_device { public: - a2bus_ace2x00_slot1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ace2x00_slot1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: }; @@ -55,7 +55,7 @@ protected: class a2bus_ace2x00_slot6_device : public a2bus_ace2x00_device { public: - a2bus_ace2x00_slot6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ace2x00_slot6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/a2bus/agat7langcard.cpp b/src/devices/bus/a2bus/agat7langcard.cpp index 05a8b87d3c3..70beed95351 100644 --- a/src/devices/bus/a2bus/agat7langcard.cpp +++ b/src/devices/bus/a2bus/agat7langcard.cpp @@ -32,13 +32,13 @@ DEFINE_DEVICE_TYPE(A2BUS_AGAT7LANGCARD, a2bus_agat7langcard_device, "a7lang", "A // LIVE DEVICE //************************************************************************** -a2bus_agat7langcard_device::a2bus_agat7langcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_agat7langcard_device::a2bus_agat7langcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_inh_state(0), m_dxxx_bank(0), m_main_bank(0), m_csr(0) { } -a2bus_agat7langcard_device::a2bus_agat7langcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_agat7langcard_device::a2bus_agat7langcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_agat7langcard_device(mconfig, A2BUS_AGAT7LANGCARD, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/agat7langcard.h b/src/devices/bus/a2bus/agat7langcard.h index e7dae54ebfb..2884b273a1d 100644 --- a/src/devices/bus/a2bus/agat7langcard.h +++ b/src/devices/bus/a2bus/agat7langcard.h @@ -25,10 +25,10 @@ class a2bus_agat7langcard_device: { public: // construction/destruction - a2bus_agat7langcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_agat7langcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_agat7langcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_agat7langcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/agat7ports.cpp b/src/devices/bus/a2bus/agat7ports.cpp index afd196d6549..36c0e5dd7bc 100644 --- a/src/devices/bus/a2bus/agat7ports.cpp +++ b/src/devices/bus/a2bus/agat7ports.cpp @@ -63,7 +63,7 @@ void a2bus_agat7_ports_device::device_add_mconfig(machine_config &config) output_latch_device ¢_data_out(OUTPUT_LATCH(config, "cent_data_out")); m_centronics->set_output_latch(cent_data_out); - I8251(config, m_d10, 0); + I8251(config, m_d10); } //------------------------------------------------- @@ -80,7 +80,7 @@ ioport_constructor a2bus_agat7_ports_device::device_input_ports() const // LIVE DEVICE //************************************************************************** -a2bus_agat7_ports_device::a2bus_agat7_ports_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2bus_agat7_ports_device::a2bus_agat7_ports_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a2bus_card_interface(mconfig, *this) , m_printer_cfg(*this, "PRINTER_CFG") @@ -90,7 +90,7 @@ a2bus_agat7_ports_device::a2bus_agat7_ports_device(const machine_config &mconfig { } -a2bus_agat7_ports_device::a2bus_agat7_ports_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_agat7_ports_device::a2bus_agat7_ports_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_agat7_ports_device(mconfig, A2BUS_AGAT7_PORTS, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/agat7ports.h b/src/devices/bus/a2bus/agat7ports.h index 2ee4f38b4dd..51fc7230af3 100644 --- a/src/devices/bus/a2bus/agat7ports.h +++ b/src/devices/bus/a2bus/agat7ports.h @@ -30,10 +30,10 @@ class a2bus_agat7_ports_device: { public: // construction/destruction - a2bus_agat7_ports_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_agat7_ports_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_agat7_ports_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_agat7_ports_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/agat7ram.cpp b/src/devices/bus/a2bus/agat7ram.cpp index ef0b7a3a335..a0a8bd37127 100644 --- a/src/devices/bus/a2bus/agat7ram.cpp +++ b/src/devices/bus/a2bus/agat7ram.cpp @@ -32,13 +32,13 @@ DEFINE_DEVICE_TYPE(A2BUS_AGAT7RAM, a2bus_agat7ram_device, "a7ram", "Agat-7 32K R // LIVE DEVICE //************************************************************************** -a2bus_agat7ram_device::a2bus_agat7ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_agat7ram_device::a2bus_agat7ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_inh_state(0), m_main_bank(0), m_csr(0) { } -a2bus_agat7ram_device::a2bus_agat7ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_agat7ram_device::a2bus_agat7ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_agat7ram_device(mconfig, A2BUS_AGAT7RAM, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/agat7ram.h b/src/devices/bus/a2bus/agat7ram.h index 6b8529fcb7b..81d65af83bc 100644 --- a/src/devices/bus/a2bus/agat7ram.h +++ b/src/devices/bus/a2bus/agat7ram.h @@ -25,10 +25,10 @@ class a2bus_agat7ram_device: { public: // construction/destruction - a2bus_agat7ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_agat7ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_agat7ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_agat7ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/agat840k_hle.cpp b/src/devices/bus/a2bus/agat840k_hle.cpp index cd6d01389b4..f0fdd572a0a 100644 --- a/src/devices/bus/a2bus/agat840k_hle.cpp +++ b/src/devices/bus/a2bus/agat840k_hle.cpp @@ -83,7 +83,7 @@ const tiny_rom_entry *a2bus_agat840k_hle_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_agat840k_hle_device::a2bus_agat840k_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2bus_agat840k_hle_device::a2bus_agat840k_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a2bus_card_interface(mconfig, *this) , m_floppy_image(*this, "floppy%u", 0U) @@ -95,7 +95,7 @@ a2bus_agat840k_hle_device::a2bus_agat840k_hle_device(const machine_config &mconf { } -a2bus_agat840k_hle_device::a2bus_agat840k_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_agat840k_hle_device::a2bus_agat840k_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_agat840k_hle_device(mconfig, A2BUS_AGAT840K_HLE, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/agat840k_hle.h b/src/devices/bus/a2bus/agat840k_hle.h index a497f2bc7aa..5866344bad1 100644 --- a/src/devices/bus/a2bus/agat840k_hle.h +++ b/src/devices/bus/a2bus/agat840k_hle.h @@ -35,7 +35,7 @@ public: }; // construction/destruction - a2bus_agat840k_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_agat840k_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t d14_i_b(); uint8_t d15_i_a(); @@ -51,7 +51,7 @@ public: protected: // construction/destruction - a2bus_agat840k_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_agat840k_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/agat_fdc.cpp b/src/devices/bus/a2bus/agat_fdc.cpp index dc88c7ea39e..ce6ffe84934 100644 --- a/src/devices/bus/a2bus/agat_fdc.cpp +++ b/src/devices/bus/a2bus/agat_fdc.cpp @@ -104,7 +104,7 @@ const tiny_rom_entry *a2bus_agat_fdc_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_agat_fdc_device::a2bus_agat_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2bus_agat_fdc_device::a2bus_agat_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a2bus_card_interface(mconfig, *this) , m_d14(*this, "d14") @@ -116,7 +116,7 @@ a2bus_agat_fdc_device::a2bus_agat_fdc_device(const machine_config &mconfig, devi { } -a2bus_agat_fdc_device::a2bus_agat_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_agat_fdc_device::a2bus_agat_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_agat_fdc_device(mconfig, A2BUS_AGAT_FDC, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/agat_fdc.h b/src/devices/bus/a2bus/agat_fdc.h index 84bfd82b268..e7e72811171 100644 --- a/src/devices/bus/a2bus/agat_fdc.h +++ b/src/devices/bus/a2bus/agat_fdc.h @@ -32,7 +32,7 @@ class a2bus_agat_fdc_device: { public: // construction/destruction - a2bus_agat_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_agat_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t d14_i_b(); uint8_t d15_i_a(); @@ -45,7 +45,7 @@ public: protected: // construction/destruction - a2bus_agat_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_agat_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/booti.cpp b/src/devices/bus/a2bus/booti.cpp index 39c6b1055ba..734282e7302 100644 --- a/src/devices/bus/a2bus/booti.cpp +++ b/src/devices/bus/a2bus/booti.cpp @@ -45,10 +45,10 @@ class a2bus_booti_device: { public: // construction/destruction - a2bus_booti_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_booti_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_booti_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_booti_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -80,7 +80,7 @@ private: void a2bus_booti_device::device_add_mconfig(machine_config &config) { - AT28C64B(config, "flash", 0); + AT28C64B(config, "flash"); CH376(config, "ch376"); } @@ -98,7 +98,7 @@ const tiny_rom_entry *a2bus_booti_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_booti_device::a2bus_booti_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_booti_device::a2bus_booti_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_flash(*this, "flash"), @@ -107,7 +107,7 @@ a2bus_booti_device::a2bus_booti_device(const machine_config &mconfig, device_typ { } -a2bus_booti_device::a2bus_booti_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_booti_device::a2bus_booti_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_booti_device(mconfig, A2BUS_BOOTI, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/byte8251.cpp b/src/devices/bus/a2bus/byte8251.cpp index ffe6c6325c0..f5d87b133b5 100644 --- a/src/devices/bus/a2bus/byte8251.cpp +++ b/src/devices/bus/a2bus/byte8251.cpp @@ -45,7 +45,7 @@ class a2bus_byte8251_device : public device_t, public device_a2bus_card_interfac { public: // construction/destruction - a2bus_byte8251_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + a2bus_byte8251_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(rate_changed); @@ -68,7 +68,7 @@ private: required_ioport m_switches; }; -a2bus_byte8251_device::a2bus_byte8251_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +a2bus_byte8251_device::a2bus_byte8251_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, A2BUS_BYTE8251, tag, owner, clock) , device_a2bus_card_interface(mconfig, *this) , m_usart(*this, "8251") @@ -131,7 +131,7 @@ ioport_constructor a2bus_byte8251_device::device_input_ports() const void a2bus_byte8251_device::device_add_mconfig(machine_config &config) { - I8251(config, m_usart, 1021800); // CLK tied to ϕ1 signal from bus pin 38 + I8251(config, m_usart, XTAL::u(1021800)); // CLK tied to ϕ1 signal from bus pin 38 m_usart->txd_handler().set("rs232", FUNC(rs232_port_device::write_txd)); MM5307AA(config, m_brg, A2BUS_7M_CLOCK / 8); diff --git a/src/devices/bus/a2bus/ccs7710.cpp b/src/devices/bus/a2bus/ccs7710.cpp index 17f8cdfe80e..fe6b15f0af1 100644 --- a/src/devices/bus/a2bus/ccs7710.cpp +++ b/src/devices/bus/a2bus/ccs7710.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(A2BUS_CCS7710, ccs7710_device, "ccs7710", "CCS Model 7710 Asy // DEVICE IMPLEMENTATION //************************************************************************** -ccs7710_device::ccs7710_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ccs7710_device::ccs7710_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, A2BUS_CCS7710, tag, owner, clock) , device_a2bus_card_interface(mconfig, *this) , m_acia(*this, "acia") diff --git a/src/devices/bus/a2bus/ccs7710.h b/src/devices/bus/a2bus/ccs7710.h index db2a7616891..5b3db8a7073 100644 --- a/src/devices/bus/a2bus/ccs7710.h +++ b/src/devices/bus/a2bus/ccs7710.h @@ -19,7 +19,7 @@ class ccs7710_device : public device_t, public device_a2bus_card_interface { public: // device type constructor - ccs7710_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ccs7710_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/a2bus/cmsscsi.cpp b/src/devices/bus/a2bus/cmsscsi.cpp index 77a7ade3e6f..f0876e57972 100644 --- a/src/devices/bus/a2bus/cmsscsi.cpp +++ b/src/devices/bus/a2bus/cmsscsi.cpp @@ -88,7 +88,7 @@ const tiny_rom_entry *a2bus_cmsscsi_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_cmsscsi_device::a2bus_cmsscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_cmsscsi_device::a2bus_cmsscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_ncr5380(*this, SCSI_5380_TAG), @@ -96,7 +96,7 @@ a2bus_cmsscsi_device::a2bus_cmsscsi_device(const machine_config &mconfig, device { } -a2bus_cmsscsi_device::a2bus_cmsscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_cmsscsi_device::a2bus_cmsscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_cmsscsi_device(mconfig, A2BUS_CMSSCSI, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/cmsscsi.h b/src/devices/bus/a2bus/cmsscsi.h index 8e417d76bc0..4d7a2ae6a56 100644 --- a/src/devices/bus/a2bus/cmsscsi.h +++ b/src/devices/bus/a2bus/cmsscsi.h @@ -26,12 +26,12 @@ class a2bus_cmsscsi_device: { public: // construction/destruction - a2bus_cmsscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_cmsscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( drq_w ); protected: - a2bus_cmsscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_cmsscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/computereyes2.cpp b/src/devices/bus/a2bus/computereyes2.cpp index 979472d00ef..f1ec52c54df 100644 --- a/src/devices/bus/a2bus/computereyes2.cpp +++ b/src/devices/bus/a2bus/computereyes2.cpp @@ -28,10 +28,10 @@ class a2bus_computereyes2_device: { public: // construction/destruction - a2bus_computereyes2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_computereyes2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_computereyes2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_computereyes2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -66,14 +66,14 @@ void a2bus_computereyes2_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_computereyes2_device::a2bus_computereyes2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_computereyes2_device::a2bus_computereyes2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_picture(*this, "srcimg") { } -a2bus_computereyes2_device::a2bus_computereyes2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_computereyes2_device::a2bus_computereyes2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_computereyes2_device(mconfig, A2BUS_COMPUTEREYES2, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/corvfdc01.cpp b/src/devices/bus/a2bus/corvfdc01.cpp index 212f49ed20b..be53e109f6f 100644 --- a/src/devices/bus/a2bus/corvfdc01.cpp +++ b/src/devices/bus/a2bus/corvfdc01.cpp @@ -103,7 +103,7 @@ const tiny_rom_entry *a2bus_corvfdc01_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_corvfdc01_device::a2bus_corvfdc01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_corvfdc01_device::a2bus_corvfdc01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_wdfdc(*this, FDC01_FDC_TAG), @@ -115,7 +115,7 @@ a2bus_corvfdc01_device::a2bus_corvfdc01_device(const machine_config &mconfig, de { } -a2bus_corvfdc01_device::a2bus_corvfdc01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_corvfdc01_device::a2bus_corvfdc01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_corvfdc01_device(mconfig, A2BUS_CORVFDC01, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/corvfdc01.h b/src/devices/bus/a2bus/corvfdc01.h index 5c92107fcbe..76e7f1b95f2 100644 --- a/src/devices/bus/a2bus/corvfdc01.h +++ b/src/devices/bus/a2bus/corvfdc01.h @@ -28,10 +28,10 @@ class a2bus_corvfdc01_device: { public: // construction/destruction - a2bus_corvfdc01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_corvfdc01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_corvfdc01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_corvfdc01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/corvfdc02.cpp b/src/devices/bus/a2bus/corvfdc02.cpp index 12c7aed06ac..cdddec35de1 100644 --- a/src/devices/bus/a2bus/corvfdc02.cpp +++ b/src/devices/bus/a2bus/corvfdc02.cpp @@ -77,7 +77,7 @@ const tiny_rom_entry *a2bus_corvfdc02_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_corvfdc02_device::a2bus_corvfdc02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_corvfdc02_device::a2bus_corvfdc02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_fdc(*this, FDC02_FDC_TAG), @@ -88,7 +88,7 @@ a2bus_corvfdc02_device::a2bus_corvfdc02_device(const machine_config &mconfig, de { } -a2bus_corvfdc02_device::a2bus_corvfdc02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_corvfdc02_device::a2bus_corvfdc02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_corvfdc02_device(mconfig, A2BUS_CORVFDC02, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/corvfdc02.h b/src/devices/bus/a2bus/corvfdc02.h index 825d68d564b..213c1bdfe36 100644 --- a/src/devices/bus/a2bus/corvfdc02.h +++ b/src/devices/bus/a2bus/corvfdc02.h @@ -28,10 +28,10 @@ class a2bus_corvfdc02_device: { public: // construction/destruction - a2bus_corvfdc02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_corvfdc02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_corvfdc02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_corvfdc02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/excel9.cpp b/src/devices/bus/a2bus/excel9.cpp index 706cb3c4f63..5fd27dea399 100644 --- a/src/devices/bus/a2bus/excel9.cpp +++ b/src/devices/bus/a2bus/excel9.cpp @@ -52,7 +52,7 @@ ROM_END void a2bus_excel9_device::device_add_mconfig(machine_config &config) { - MC6809E(config, m_6809, 1021800); // 6809E runs at ~1 MHz + MC6809E(config, m_6809, XTAL::u(1021800)); // 6809E runs at ~1 MHz m_6809->set_addrmap(AS_PROGRAM, &a2bus_excel9_device::m6809_mem); } @@ -69,7 +69,7 @@ const tiny_rom_entry *a2bus_excel9_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_excel9_device::a2bus_excel9_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2bus_excel9_device::a2bus_excel9_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a2bus_card_interface(mconfig, *this) , m_6809(*this, "m6809") @@ -83,7 +83,7 @@ a2bus_excel9_device::a2bus_excel9_device(const machine_config &mconfig, device_t { } -a2bus_excel9_device::a2bus_excel9_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_excel9_device::a2bus_excel9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_excel9_device(mconfig, A2BUS_EXCEL9, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/excel9.h b/src/devices/bus/a2bus/excel9.h index 2814cd6e394..a1fd57fc577 100644 --- a/src/devices/bus/a2bus/excel9.h +++ b/src/devices/bus/a2bus/excel9.h @@ -25,10 +25,10 @@ class a2bus_excel9_device: { public: // construction/destruction - a2bus_excel9_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_excel9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_excel9_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_excel9_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/ezcgi.cpp b/src/devices/bus/a2bus/ezcgi.cpp index 3ebccb45518..b5a78c766f4 100644 --- a/src/devices/bus/a2bus/ezcgi.cpp +++ b/src/devices/bus/a2bus/ezcgi.cpp @@ -36,10 +36,10 @@ class a2bus_ezcgi_device: { public: // construction/destruction - a2bus_ezcgi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ezcgi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_ezcgi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_ezcgi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -61,10 +61,10 @@ class a2bus_ezcgi_9938_device: { public: // construction/destruction - a2bus_ezcgi_9938_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ezcgi_9938_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_ezcgi_9938_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_ezcgi_9938_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -86,10 +86,10 @@ class a2bus_ezcgi_9958_device: { public: // construction/destruction - a2bus_ezcgi_9958_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ezcgi_9958_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_ezcgi_9958_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_ezcgi_9958_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -158,36 +158,36 @@ void a2bus_ezcgi_9958_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_ezcgi_device::a2bus_ezcgi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ezcgi_device::a2bus_ezcgi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ezcgi_device(mconfig, A2BUS_EZCGI, tag, owner, clock) { } -a2bus_ezcgi_device::a2bus_ezcgi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ezcgi_device::a2bus_ezcgi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_tms(*this, TMS_TAG) { } -a2bus_ezcgi_9938_device::a2bus_ezcgi_9938_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ezcgi_9938_device::a2bus_ezcgi_9938_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ezcgi_9938_device(mconfig, A2BUS_EZCGI_9938, tag, owner, clock) { } -a2bus_ezcgi_9938_device::a2bus_ezcgi_9938_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ezcgi_9938_device::a2bus_ezcgi_9938_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_tms(*this, TMS_TAG) { } -a2bus_ezcgi_9958_device::a2bus_ezcgi_9958_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ezcgi_9958_device::a2bus_ezcgi_9958_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ezcgi_9958_device(mconfig, A2BUS_EZCGI_9958, tag, owner, clock) { } -a2bus_ezcgi_9958_device::a2bus_ezcgi_9958_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ezcgi_9958_device::a2bus_ezcgi_9958_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_tms(*this, TMS_TAG) diff --git a/src/devices/bus/a2bus/grafex.cpp b/src/devices/bus/a2bus/grafex.cpp index 6855ebe174a..d7486a8d68e 100644 --- a/src/devices/bus/a2bus/grafex.cpp +++ b/src/devices/bus/a2bus/grafex.cpp @@ -46,10 +46,10 @@ class a2bus_grafex_device : public device_t, { public: // construction/destruction - a2bus_grafex_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_grafex_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_grafex_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_grafex_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_add_mconfig(machine_config &config) override; @@ -89,12 +89,12 @@ void a2bus_grafex_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_grafex_device::a2bus_grafex_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_grafex_device::a2bus_grafex_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_grafex_device(mconfig, A2BUS_GRAFEX, tag, owner, clock) { } -a2bus_grafex_device::a2bus_grafex_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_grafex_device::a2bus_grafex_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_gdc(*this, "upd7220"), diff --git a/src/devices/bus/a2bus/grappler.cpp b/src/devices/bus/a2bus/grappler.cpp index 933b9b3357f..0ad56766acf 100644 --- a/src/devices/bus/a2bus/grappler.cpp +++ b/src/devices/bus/a2bus/grappler.cpp @@ -63,7 +63,7 @@ public: virtual u8 read_c800(u16 offset) override; protected: - a2bus_grappler_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + a2bus_grappler_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // signal state u8 busy_in() const { return m_busy_in; } @@ -100,7 +100,7 @@ private: }; -a2bus_grappler_device_base::a2bus_grappler_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) : +a2bus_grappler_device_base::a2bus_grappler_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_printer_conn(*this, "prn"), @@ -230,7 +230,7 @@ void a2bus_grappler_device_base::set_slct_in(s32 param) class a2bus_grappler_device : public a2bus_grappler_device_base { public: - a2bus_grappler_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + a2bus_grappler_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // device_a2bus_card_interface implementation virtual u8 read_c0nx(u8 offset) override; @@ -260,7 +260,7 @@ private: }; -a2bus_grappler_device::a2bus_grappler_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : +a2bus_grappler_device::a2bus_grappler_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a2bus_grappler_device_base(mconfig, A2BUS_GRAPPLER, tag, owner, clock), m_strobe(1U), m_ack_latch(1U), @@ -443,7 +443,7 @@ public: virtual void write_cnxx(u8 offset, u8 data) override; protected: - a2bus_grapplerplus_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + a2bus_grapplerplus_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device_t implementation virtual ioport_constructor device_input_ports() const override; @@ -472,7 +472,7 @@ private: }; -a2bus_grapplerplus_device_base::a2bus_grapplerplus_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) : +a2bus_grapplerplus_device_base::a2bus_grapplerplus_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : a2bus_grappler_device_base(mconfig, type, tag, owner, clock), m_s1(*this, "S1"), m_ack_latch(1U), @@ -619,7 +619,7 @@ void a2bus_grapplerplus_device_base::set_ack_in(s32 param) class a2bus_grapplerplus_device : public a2bus_grapplerplus_device_base { public: - a2bus_grapplerplus_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + a2bus_grapplerplus_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // DIP switch handlers virtual DECLARE_INPUT_CHANGED_MEMBER(sw_msb) override; @@ -653,7 +653,7 @@ private: }; -a2bus_grapplerplus_device::a2bus_grapplerplus_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : +a2bus_grapplerplus_device::a2bus_grapplerplus_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a2bus_grapplerplus_device_base(mconfig, A2BUS_GRAPPLERPLUS, tag, owner, clock), m_strobe_timer(nullptr), m_data_latch(0xffU), @@ -842,7 +842,7 @@ TIMER_CALLBACK_MEMBER(a2bus_grapplerplus_device::update_strobe) class a2bus_buf_grapplerplus_device : public a2bus_grapplerplus_device_base { public: - a2bus_buf_grapplerplus_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : + a2bus_buf_grapplerplus_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a2bus_buf_grapplerplus_device(mconfig, A2BUS_BUFGRAPPLERPLUS, tag, owner, clock) { } @@ -851,7 +851,7 @@ public: virtual u8 read_c0nx(u8 offset) override; protected: - a2bus_buf_grapplerplus_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + a2bus_buf_grapplerplus_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device_t implementation virtual tiny_rom_entry const *device_rom_region() const override { return ROM_NAME(bufgrapplerplus); } @@ -895,7 +895,7 @@ private: -a2bus_buf_grapplerplus_device::a2bus_buf_grapplerplus_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) : +a2bus_buf_grapplerplus_device::a2bus_buf_grapplerplus_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : a2bus_grapplerplus_device_base(mconfig, type, tag, owner, clock), m_mcu(*this, "mcu"), m_ram(), @@ -1223,7 +1223,7 @@ void a2bus_buf_grapplerplus_device::clear_ibusy(s32 param) class a2bus_buf_grapplerplus_reva_device : public a2bus_buf_grapplerplus_device { public: - a2bus_buf_grapplerplus_reva_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : + a2bus_buf_grapplerplus_reva_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a2bus_buf_grapplerplus_device(mconfig, A2BUS_BUFGRAPPLERPLUSA, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/lancegs.cpp b/src/devices/bus/a2bus/lancegs.cpp index cca53536c2e..bcda172a191 100644 --- a/src/devices/bus/a2bus/lancegs.cpp +++ b/src/devices/bus/a2bus/lancegs.cpp @@ -63,10 +63,10 @@ class a2bus_lancegs_device: { public: // construction/destruction - a2bus_lancegs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_lancegs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_lancegs_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_lancegs_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; virtual const tiny_rom_entry *device_rom_region() const override; @@ -89,12 +89,12 @@ private: // LIVE DEVICE //************************************************************************** -a2bus_lancegs_device::a2bus_lancegs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_lancegs_device::a2bus_lancegs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_lancegs_device(mconfig, A2BUS_LANCEGS, tag, owner, clock) { } -a2bus_lancegs_device::a2bus_lancegs_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_lancegs_device::a2bus_lancegs_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_netinf(*this, "smc91c96"), @@ -106,7 +106,7 @@ a2bus_lancegs_device::a2bus_lancegs_device(const machine_config &mconfig, device void a2bus_lancegs_device::device_add_mconfig(machine_config &config) { SMC91C96(config, m_netinf, 20_MHz_XTAL); // Datasheet fig 12.26, pg 122. - I2C_24C04(config, m_i2cmem, 0).set_address(0x80).set_e0(1); + I2C_24C04(config, m_i2cmem).set_address(0x80).set_e0(1); m_netinf->irq_handler().set(FUNC(a2bus_lancegs_device::netinf_irq_w)); } diff --git a/src/devices/bus/a2bus/laser128.cpp b/src/devices/bus/a2bus/laser128.cpp index ecddbc66b14..5fcdf24caf7 100644 --- a/src/devices/bus/a2bus/laser128.cpp +++ b/src/devices/bus/a2bus/laser128.cpp @@ -41,18 +41,18 @@ void a2bus_laser128_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_laser128_device::a2bus_laser128_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_laser128_device::a2bus_laser128_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_rom(nullptr), m_slot7_bank(0), m_bParPrinter(false), m_slot7_ram_bank(0) { } -a2bus_laser128_device::a2bus_laser128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_laser128_device::a2bus_laser128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_laser128_device(mconfig, A2BUS_LASER128, tag, owner, clock) { } -a2bus_laser128_orig_device::a2bus_laser128_orig_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_laser128_orig_device::a2bus_laser128_orig_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_laser128_device(mconfig, A2BUS_LASER128_ORIG, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/laser128.h b/src/devices/bus/a2bus/laser128.h index 9858e3889f7..82b53e15f6a 100644 --- a/src/devices/bus/a2bus/laser128.h +++ b/src/devices/bus/a2bus/laser128.h @@ -25,13 +25,13 @@ class a2bus_laser128_device: { public: // construction/destruction - a2bus_laser128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_laser128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // special config API void set_parallel_printer(bool bPrinterIsParallel) { m_bParPrinter = bPrinterIsParallel; } protected: - a2bus_laser128_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_laser128_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -57,7 +57,7 @@ private: class a2bus_laser128_orig_device: public a2bus_laser128_device { public: - a2bus_laser128_orig_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_laser128_orig_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual uint8_t read_c800(uint16_t offset) override; diff --git a/src/devices/bus/a2bus/mouse.cpp b/src/devices/bus/a2bus/mouse.cpp index 6a40c244a40..f5003d02e3b 100644 --- a/src/devices/bus/a2bus/mouse.cpp +++ b/src/devices/bus/a2bus/mouse.cpp @@ -95,14 +95,14 @@ class a2bus_mouse_device: { public: // construction/destruction - a2bus_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; virtual ioport_constructor device_input_ports() const override; protected: - a2bus_mouse_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_mouse_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; virtual void device_start() override; @@ -183,14 +183,14 @@ ioport_constructor a2bus_mouse_device::device_input_ports() const void a2bus_mouse_device::device_add_mconfig(machine_config &config) { - M68705P3(config, m_mcu, 2043600); + M68705P3(config, m_mcu, XTAL::u(2043600)); m_mcu->porta_r().set(FUNC(a2bus_mouse_device::mcu_port_a_r)); m_mcu->portb_r().set(FUNC(a2bus_mouse_device::mcu_port_b_r)); m_mcu->porta_w().set(FUNC(a2bus_mouse_device::mcu_port_a_w)); m_mcu->portb_w().set(FUNC(a2bus_mouse_device::mcu_port_b_w)); m_mcu->portc_w().set(FUNC(a2bus_mouse_device::mcu_port_c_w)); - PIA6821(config, m_pia, 1021800); + PIA6821(config, m_pia, XTAL::u(1021800)); m_pia->writepa_handler().set(FUNC(a2bus_mouse_device::pia_out_a)); m_pia->writepb_handler().set(FUNC(a2bus_mouse_device::pia_out_b)); m_pia->tspb_handler().set_constant(0x00); @@ -212,7 +212,7 @@ const tiny_rom_entry *a2bus_mouse_device::device_rom_region() const LIVE DEVICE ***************************************************************************/ -a2bus_mouse_device::a2bus_mouse_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_mouse_device::a2bus_mouse_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_pia(*this, MOUSE_PIA_TAG), @@ -225,7 +225,7 @@ a2bus_mouse_device::a2bus_mouse_device(const machine_config &mconfig, device_typ { } -a2bus_mouse_device::a2bus_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_mouse_device::a2bus_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_mouse_device(mconfig, A2BUS_MOUSE, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/nippelclock.cpp b/src/devices/bus/a2bus/nippelclock.cpp index 047e13422e0..b86e8291ec2 100644 --- a/src/devices/bus/a2bus/nippelclock.cpp +++ b/src/devices/bus/a2bus/nippelclock.cpp @@ -55,14 +55,14 @@ WRITE_LINE_MEMBER(a2bus_nippelclock_device::irq_w) // LIVE DEVICE //************************************************************************** -a2bus_nippelclock_device::a2bus_nippelclock_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2bus_nippelclock_device::a2bus_nippelclock_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a2bus_card_interface(mconfig, *this) , m_rtc(*this, "rtc") { } -a2bus_nippelclock_device::a2bus_nippelclock_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_nippelclock_device::a2bus_nippelclock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_nippelclock_device(mconfig, A2BUS_NIPPELCLOCK, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/nippelclock.h b/src/devices/bus/a2bus/nippelclock.h index d2ac6f14c7f..4bc93e89fa6 100644 --- a/src/devices/bus/a2bus/nippelclock.h +++ b/src/devices/bus/a2bus/nippelclock.h @@ -26,10 +26,10 @@ class a2bus_nippelclock_device: { public: // construction/destruction - a2bus_nippelclock_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_nippelclock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_nippelclock_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_nippelclock_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/pc_xporter.cpp b/src/devices/bus/a2bus/pc_xporter.cpp index 06a87cc1820..2fa23e450cf 100644 --- a/src/devices/bus/a2bus/pc_xporter.cpp +++ b/src/devices/bus/a2bus/pc_xporter.cpp @@ -107,12 +107,12 @@ class a2bus_pcxporter_device: { public: // construction/destruction - a2bus_pcxporter_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_pcxporter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); [[maybe_unused]] uint16_t pc_bios_r(offs_t offset); // TODO: hook up to something? protected: - a2bus_pcxporter_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_pcxporter_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -252,7 +252,7 @@ void a2bus_pcxporter_device::device_add_mconfig(machine_config &config) PIC8259(config, m_pic8259); m_pic8259->out_int_callback().set_inputline(m_v30, 0); - ISA8(config, m_isabus, 0); + ISA8(config, m_isabus); m_isabus->set_memspace(m_v30, AS_PROGRAM); m_isabus->set_iospace(m_v30, AS_IO); m_isabus->irq2_callback().set(m_pic8259, FUNC(pic8259_device::ir2_w)); @@ -273,15 +273,15 @@ void a2bus_pcxporter_device::device_add_mconfig(machine_config &config) SPEAKER(config, "mono").front_center(); SPEAKER_SOUND(config, m_speaker).add_route(ALL_OUTPUTS, "mono", 1.00); - ISA8_SLOT(config, "isa1", 0, m_isabus, pc_isa8_cards, "cga", true); // FIXME: determine ISA bus clock - ISA8_SLOT(config, "isa2", 0, m_isabus, pc_isa8_cards, "fdc_xt", true); + ISA8_SLOT(config, "isa1", m_isabus, pc_isa8_cards, "cga", true); // FIXME: determine ISA bus clock + ISA8_SLOT(config, "isa2", m_isabus, pc_isa8_cards, "fdc_xt", true); } //************************************************************************** // LIVE DEVICE //************************************************************************** -a2bus_pcxporter_device::a2bus_pcxporter_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_pcxporter_device::a2bus_pcxporter_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_v30(*this, "v30"), @@ -294,7 +294,7 @@ a2bus_pcxporter_device::a2bus_pcxporter_device(const machine_config &mconfig, de { } -a2bus_pcxporter_device::a2bus_pcxporter_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_pcxporter_device::a2bus_pcxporter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_pcxporter_device(mconfig, A2BUS_PCXPORTER, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/prodosromdrive.cpp b/src/devices/bus/a2bus/prodosromdrive.cpp index d9275384a00..9cdc1c1bdc4 100644 --- a/src/devices/bus/a2bus/prodosromdrive.cpp +++ b/src/devices/bus/a2bus/prodosromdrive.cpp @@ -33,10 +33,10 @@ class a2bus_pdromdrive_device : public device_t, { public: // construction/destruction - a2bus_pdromdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_pdromdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_pdromdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_pdromdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual const tiny_rom_entry *device_rom_region() const override; @@ -56,12 +56,12 @@ private: // LIVE DEVICE //************************************************************************** -a2bus_pdromdrive_device::a2bus_pdromdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_pdromdrive_device::a2bus_pdromdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_pdromdrive_device(mconfig, A2BUS_PRODOSROMDRIVE, tag, owner, clock) { } -a2bus_pdromdrive_device::a2bus_pdromdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_pdromdrive_device::a2bus_pdromdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_rom(*this, "romdrive") diff --git a/src/devices/bus/a2bus/q68.cpp b/src/devices/bus/a2bus/q68.cpp index 4729f450e4a..c98513be043 100644 --- a/src/devices/bus/a2bus/q68.cpp +++ b/src/devices/bus/a2bus/q68.cpp @@ -107,7 +107,7 @@ const tiny_rom_entry *a2bus_68k_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_68k_device::a2bus_68k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a2bus_68k_device::a2bus_68k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a2bus_card_interface(mconfig, *this) , m_m68008(*this, "m68008") @@ -115,12 +115,12 @@ a2bus_68k_device::a2bus_68k_device(const machine_config &mconfig, device_type ty { } -a2bus_q68_device::a2bus_q68_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_q68_device::a2bus_q68_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_68k_device(mconfig, A2BUS_Q68, tag, owner, clock) { } -a2bus_q68plus_device::a2bus_q68plus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_q68plus_device::a2bus_q68plus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_68k_device(mconfig, A2BUS_Q68PLUS, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/q68.h b/src/devices/bus/a2bus/q68.h index 34664a284f0..32f63838a06 100644 --- a/src/devices/bus/a2bus/q68.h +++ b/src/devices/bus/a2bus/q68.h @@ -33,7 +33,7 @@ class a2bus_68k_device: public device_a2bus_card_interface { protected: - a2bus_68k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_68k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -56,7 +56,7 @@ private: class a2bus_q68_device : public a2bus_68k_device { public: - a2bus_q68_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_q68_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -68,7 +68,7 @@ private: class a2bus_q68plus_device : public a2bus_68k_device { public: - a2bus_q68plus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_q68plus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static auto parent_rom_device_type() { return &A2BUS_Q68; } diff --git a/src/devices/bus/a2bus/ramcard128k.cpp b/src/devices/bus/a2bus/ramcard128k.cpp index 0736e39c5d4..a5a6b98dc0f 100644 --- a/src/devices/bus/a2bus/ramcard128k.cpp +++ b/src/devices/bus/a2bus/ramcard128k.cpp @@ -29,13 +29,13 @@ DEFINE_DEVICE_TYPE(A2BUS_RAMCARD128K, a2bus_ssramcard_device, "ssram128", "Satur // LIVE DEVICE //************************************************************************** -a2bus_ssramcard_device::a2bus_ssramcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ssramcard_device::a2bus_ssramcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_inh_state(0), m_last_offset(0), m_dxxx_bank(0), m_main_bank(0) { } -a2bus_ssramcard_device::a2bus_ssramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ssramcard_device::a2bus_ssramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ssramcard_device(mconfig, A2BUS_RAMCARD128K, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/ramcard128k.h b/src/devices/bus/a2bus/ramcard128k.h index ee3ac683514..1fd5573d74a 100644 --- a/src/devices/bus/a2bus/ramcard128k.h +++ b/src/devices/bus/a2bus/ramcard128k.h @@ -25,10 +25,10 @@ class a2bus_ssramcard_device: { public: // construction/destruction - a2bus_ssramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ssramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_ssramcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_ssramcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/ramcard16k.cpp b/src/devices/bus/a2bus/ramcard16k.cpp index cd91ce64230..612367d5776 100644 --- a/src/devices/bus/a2bus/ramcard16k.cpp +++ b/src/devices/bus/a2bus/ramcard16k.cpp @@ -29,13 +29,13 @@ DEFINE_DEVICE_TYPE(A2BUS_RAMCARD16K, a2bus_ramcard_device, "a2ram16k", "Apple II // LIVE DEVICE //************************************************************************** -a2bus_ramcard_device::a2bus_ramcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ramcard_device::a2bus_ramcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_inh_state(0), m_prewrite(false), m_dxxx_bank(0) { } -a2bus_ramcard_device::a2bus_ramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ramcard_device::a2bus_ramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ramcard_device(mconfig, A2BUS_RAMCARD16K, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/ramcard16k.h b/src/devices/bus/a2bus/ramcard16k.h index 21edcd7a7fd..0e35520bc30 100644 --- a/src/devices/bus/a2bus/ramcard16k.h +++ b/src/devices/bus/a2bus/ramcard16k.h @@ -25,10 +25,10 @@ class a2bus_ramcard_device: { public: // construction/destruction - a2bus_ramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_ramcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_ramcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/sider.cpp b/src/devices/bus/a2bus/sider.cpp index d2722c8bb77..4241cb30b3b 100644 --- a/src/devices/bus/a2bus/sider.cpp +++ b/src/devices/bus/a2bus/sider.cpp @@ -140,7 +140,7 @@ const tiny_rom_entry *a2bus_sider1card_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_sider_device::a2bus_sider_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_sider_device::a2bus_sider_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_sasibus(*this, "sasibus"), @@ -151,12 +151,12 @@ a2bus_sider_device::a2bus_sider_device(const machine_config &mconfig, device_typ { } -a2bus_sider2card_device::a2bus_sider2card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_sider2card_device::a2bus_sider2card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_sider_device(mconfig, A2BUS_SIDER2, tag, owner, clock) { } -a2bus_sider1card_device::a2bus_sider1card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_sider1card_device::a2bus_sider1card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_sider_device(mconfig, A2BUS_SIDER1, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/sider.h b/src/devices/bus/a2bus/sider.h index 6bb5ed3c036..ed7f56e5ede 100644 --- a/src/devices/bus/a2bus/sider.h +++ b/src/devices/bus/a2bus/sider.h @@ -27,7 +27,7 @@ class a2bus_sider_device: public device_a2bus_card_interface { protected: - a2bus_sider_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_sider_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -53,14 +53,14 @@ private: class a2bus_sider2card_device: public a2bus_sider_device { public: - a2bus_sider2card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_sider2card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; class a2bus_sider1card_device: public a2bus_sider_device { public: - a2bus_sider1card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_sider1card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; diff --git a/src/devices/bus/a2bus/softcard3.cpp b/src/devices/bus/a2bus/softcard3.cpp index fb3da1eb291..1b3d24e809f 100644 --- a/src/devices/bus/a2bus/softcard3.cpp +++ b/src/devices/bus/a2bus/softcard3.cpp @@ -60,7 +60,7 @@ void a2bus_softcard3_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_softcard3_device::a2bus_softcard3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_softcard3_device::a2bus_softcard3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_z80(*this, "z80"), @@ -72,7 +72,7 @@ a2bus_softcard3_device::a2bus_softcard3_device(const machine_config &mconfig, de { } -a2bus_softcard3_device::a2bus_softcard3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_softcard3_device::a2bus_softcard3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_softcard3_device(mconfig, A2BUS_SOFTCARD3, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/softcard3.h b/src/devices/bus/a2bus/softcard3.h index a048c9e754d..cb7d27539e1 100644 --- a/src/devices/bus/a2bus/softcard3.h +++ b/src/devices/bus/a2bus/softcard3.h @@ -25,12 +25,12 @@ class a2bus_softcard3_device: public: // construction/destruction - a2bus_softcard3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_softcard3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void z80_io_w(offs_t offset, uint8_t data); protected: - a2bus_softcard3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_softcard3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/ssbapple.cpp b/src/devices/bus/a2bus/ssbapple.cpp index c4ad0f7684b..0aae9420bee 100644 --- a/src/devices/bus/a2bus/ssbapple.cpp +++ b/src/devices/bus/a2bus/ssbapple.cpp @@ -35,13 +35,13 @@ class a2bus_ssb_device: { public: // construction/destruction - a2bus_ssb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ssb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type imperfect_features() { return feature::SOUND; } required_device<tms5220_device> m_tms; protected: - a2bus_ssb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_ssb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -64,7 +64,7 @@ protected: void a2bus_ssb_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "ssbapple").front_center(); - TMS5220(config, m_tms, 640000); // guess - this gives 8 kHz output according to the datasheet + TMS5220(config, m_tms, XTAL::u(640000)); // guess - this gives 8 kHz output according to the datasheet m_tms->add_route(ALL_OUTPUTS, "ssbapple", 1.0); } @@ -72,14 +72,14 @@ void a2bus_ssb_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_ssb_device::a2bus_ssb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ssb_device::a2bus_ssb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_tms(*this, TMS_TAG) { } -a2bus_ssb_device::a2bus_ssb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ssb_device::a2bus_ssb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ssb_device(mconfig, A2BUS_SSBAPPLE, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/ssprite.cpp b/src/devices/bus/a2bus/ssprite.cpp index 2fdecb117c9..14889c2a83d 100644 --- a/src/devices/bus/a2bus/ssprite.cpp +++ b/src/devices/bus/a2bus/ssprite.cpp @@ -39,10 +39,10 @@ class a2bus_ssprite_device: { public: // construction/destruction - a2bus_ssprite_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_ssprite_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_ssprite_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_ssprite_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -72,20 +72,20 @@ void a2bus_ssprite_device::device_add_mconfig(machine_config &config) SCREEN(config, SCREEN_TAG, SCREEN_TYPE_RASTER); SPEAKER(config, "mono").front_center(); - AY8912(config, m_ay, 1022727).add_route(ALL_OUTPUTS, "mono", 1.0); - TMS5220(config, m_tms5220, 640000).add_route(ALL_OUTPUTS, "mono", 1.0); + AY8912(config, m_ay, XTAL::u(1022727)).add_route(ALL_OUTPUTS, "mono", 1.0); + TMS5220(config, m_tms5220, XTAL::u(640000)).add_route(ALL_OUTPUTS, "mono", 1.0); } //************************************************************************** // LIVE DEVICE //************************************************************************** -a2bus_ssprite_device::a2bus_ssprite_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ssprite_device::a2bus_ssprite_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_ssprite_device(mconfig, A2BUS_SSPRITE, tag, owner, clock) { } -a2bus_ssprite_device::a2bus_ssprite_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_ssprite_device::a2bus_ssprite_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_tms(*this, TMS_TAG), diff --git a/src/devices/bus/a2bus/suprterminal.cpp b/src/devices/bus/a2bus/suprterminal.cpp index 796937bebcb..f064c569e66 100644 --- a/src/devices/bus/a2bus/suprterminal.cpp +++ b/src/devices/bus/a2bus/suprterminal.cpp @@ -47,10 +47,10 @@ class a2bus_suprterminal_device: { public: // construction/destruction - a2bus_suprterminal_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + a2bus_suprterminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_suprterminal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + a2bus_suprterminal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -103,12 +103,12 @@ const tiny_rom_entry *a2bus_suprterminal_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_suprterminal_device::a2bus_suprterminal_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +a2bus_suprterminal_device::a2bus_suprterminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_suprterminal_device(mconfig, A2BUS_SUPRTERMINAL, tag, owner, clock) { } -a2bus_suprterminal_device::a2bus_suprterminal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +a2bus_suprterminal_device::a2bus_suprterminal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_crtc(*this, "crtc"), diff --git a/src/devices/bus/a2bus/timemasterho.cpp b/src/devices/bus/a2bus/timemasterho.cpp index 8dbef3a5a37..fa6c30df595 100644 --- a/src/devices/bus/a2bus/timemasterho.cpp +++ b/src/devices/bus/a2bus/timemasterho.cpp @@ -86,10 +86,10 @@ class a2bus_timemasterho_device: { public: // construction/destruction - a2bus_timemasterho_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_timemasterho_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_timemasterho_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_timemasterho_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -138,13 +138,13 @@ ioport_constructor a2bus_timemasterho_device::device_input_ports() const void a2bus_timemasterho_device::device_add_mconfig(machine_config &config) { - PIA6821(config, m_pia, 1021800); + PIA6821(config, m_pia, XTAL::u(1021800)); m_pia->writepa_handler().set(FUNC(a2bus_timemasterho_device::pia_out_a)); m_pia->writepb_handler().set(FUNC(a2bus_timemasterho_device::pia_out_b)); m_pia->irqa_handler().set(FUNC(a2bus_timemasterho_device::pia_irqa_w)); m_pia->irqb_handler().set(FUNC(a2bus_timemasterho_device::pia_irqb_w)); - MSM5832(config, m_msm5832, 32768); + MSM5832(config, m_msm5832, XTAL::u(32768)); } //------------------------------------------------- @@ -160,7 +160,7 @@ const tiny_rom_entry *a2bus_timemasterho_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -a2bus_timemasterho_device::a2bus_timemasterho_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_timemasterho_device::a2bus_timemasterho_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_pia(*this, TIMEMASTER_PIA_TAG), @@ -170,7 +170,7 @@ a2bus_timemasterho_device::a2bus_timemasterho_device(const machine_config &mconf { } -a2bus_timemasterho_device::a2bus_timemasterho_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_timemasterho_device::a2bus_timemasterho_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_timemasterho_device(mconfig, A2BUS_TIMEMASTERHO, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/titan3plus2.cpp b/src/devices/bus/a2bus/titan3plus2.cpp index e04dc03448a..4c1a3970828 100644 --- a/src/devices/bus/a2bus/titan3plus2.cpp +++ b/src/devices/bus/a2bus/titan3plus2.cpp @@ -49,14 +49,14 @@ void a2bus_titan3plus2_device::device_add_mconfig(machine_config &config) APPLE2_GAMEIO(config, m_gameio, apple2_gameio_device::default_options, nullptr); } -a2bus_titan3plus2_device::a2bus_titan3plus2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_titan3plus2_device::a2bus_titan3plus2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_gameio(*this, "gameio"), m_inh_state(0), m_last_offset(0), m_dxxx_bank(0), m_main_bank(0), m_enabled(false) { } -a2bus_titan3plus2_device::a2bus_titan3plus2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_titan3plus2_device::a2bus_titan3plus2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_titan3plus2_device(mconfig, A2BUS_TITAN3PLUS2, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/titan3plus2.h b/src/devices/bus/a2bus/titan3plus2.h index f162f115d8e..9b9326e14a3 100644 --- a/src/devices/bus/a2bus/titan3plus2.h +++ b/src/devices/bus/a2bus/titan3plus2.h @@ -26,10 +26,10 @@ class a2bus_titan3plus2_device: { public: // construction/destruction - a2bus_titan3plus2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_titan3plus2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_titan3plus2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_titan3plus2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a2bus/transwarp.cpp b/src/devices/bus/a2bus/transwarp.cpp index a87f724a704..d3288b67966 100644 --- a/src/devices/bus/a2bus/transwarp.cpp +++ b/src/devices/bus/a2bus/transwarp.cpp @@ -136,7 +136,7 @@ void a2bus_transwarp_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a2bus_transwarp_device::a2bus_transwarp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +a2bus_transwarp_device::a2bus_transwarp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_bEnabled(false), @@ -147,7 +147,7 @@ a2bus_transwarp_device::a2bus_transwarp_device(const machine_config &mconfig, de { } -a2bus_transwarp_device::a2bus_transwarp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2bus_transwarp_device::a2bus_transwarp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_transwarp_device(mconfig, A2BUS_TRANSWARP, tag, owner, clock) { } diff --git a/src/devices/bus/a2bus/transwarp.h b/src/devices/bus/a2bus/transwarp.h index 1213ea26c8b..7846ef23f9e 100644 --- a/src/devices/bus/a2bus/transwarp.h +++ b/src/devices/bus/a2bus/transwarp.h @@ -23,10 +23,10 @@ class a2bus_transwarp_device: { public: // construction/destruction - a2bus_transwarp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2bus_transwarp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a2bus_transwarp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a2bus_transwarp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // overrides of device_t functions virtual void device_start() override; diff --git a/src/devices/bus/a2bus/uniprint.cpp b/src/devices/bus/a2bus/uniprint.cpp index 9bc72a4f2bd..b0be885c3ad 100644 --- a/src/devices/bus/a2bus/uniprint.cpp +++ b/src/devices/bus/a2bus/uniprint.cpp @@ -15,7 +15,7 @@ namespace { class a2bus_uniprint_device : public device_t, public device_a2bus_card_interface { public: - a2bus_uniprint_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + a2bus_uniprint_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // device_a2bus_card_interface implementation virtual u8 read_c0nx(u8 offset) override; @@ -88,7 +88,7 @@ INPUT_PORTS_START(uniprint) INPUT_PORTS_END -a2bus_uniprint_device::a2bus_uniprint_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : +a2bus_uniprint_device::a2bus_uniprint_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, A2BUS_UNIPRINT, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_printer_conn(*this, "prn"), diff --git a/src/devices/bus/a2bus/uthernet.cpp b/src/devices/bus/a2bus/uthernet.cpp index 6f3a8d21b47..1487f088a0c 100644 --- a/src/devices/bus/a2bus/uthernet.cpp +++ b/src/devices/bus/a2bus/uthernet.cpp @@ -25,13 +25,13 @@ class a2bus_uthernet_device: { public: // construction/destruction - a2bus_uthernet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : + a2bus_uthernet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a2bus_uthernet_device(mconfig, A2BUS_UTHERNET, tag, owner, clock) { } protected: - a2bus_uthernet_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : + a2bus_uthernet_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_a2bus_card_interface(mconfig, *this), m_netinf(*this, "cs8900a") diff --git a/src/devices/bus/a2gameio/computereyes.cpp b/src/devices/bus/a2gameio/computereyes.cpp index 38b100586e4..7303b671512 100644 --- a/src/devices/bus/a2gameio/computereyes.cpp +++ b/src/devices/bus/a2gameio/computereyes.cpp @@ -22,7 +22,7 @@ class apple2_compeyes_device : public device_t, public device_a2gameio_interface { public: // construction/destruction - apple2_compeyes_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + apple2_compeyes_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -48,7 +48,7 @@ private: // DEVICE IMPLEMENTATION //************************************************************************** -apple2_compeyes_device::apple2_compeyes_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +apple2_compeyes_device::apple2_compeyes_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APPLE2_COMPUTEREYES, tag, owner, clock) , device_a2gameio_interface(mconfig, *this) , m_picture(*this, "srcimg") diff --git a/src/devices/bus/a2gameio/gameio.cpp b/src/devices/bus/a2gameio/gameio.cpp index 9a600776a90..82b210c8f64 100644 --- a/src/devices/bus/a2gameio/gameio.cpp +++ b/src/devices/bus/a2gameio/gameio.cpp @@ -62,7 +62,7 @@ // device type definition DEFINE_DEVICE_TYPE(APPLE2_GAMEIO, apple2_gameio_device, "a2gameio", "Apple II Game I/O Connector") -apple2_gameio_device::apple2_gameio_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +apple2_gameio_device::apple2_gameio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APPLE2_GAMEIO, tag, owner, clock) , device_single_card_slot_interface<device_a2gameio_interface>(mconfig, *this) , m_intf(nullptr) diff --git a/src/devices/bus/a2gameio/gameio.h b/src/devices/bus/a2gameio/gameio.h index 7ff1771b17b..10ff3241264 100644 --- a/src/devices/bus/a2gameio/gameio.h +++ b/src/devices/bus/a2gameio/gameio.h @@ -25,11 +25,11 @@ class apple2_gameio_device : public device_t, public device_single_card_slot_int { public: // construction/destruction - apple2_gameio_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + apple2_gameio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> apple2_gameio_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : apple2_gameio_device(mconfig, tag, owner, 0U) + : apple2_gameio_device(mconfig, tag, owner) { option_reset(); opts(*this); diff --git a/src/devices/bus/a2gameio/gizmo.cpp b/src/devices/bus/a2gameio/gizmo.cpp index 999fdf94ded..eee0419e053 100644 --- a/src/devices/bus/a2gameio/gizmo.cpp +++ b/src/devices/bus/a2gameio/gizmo.cpp @@ -19,7 +19,7 @@ class apple2_gizmo_device : public device_t, public device_a2gameio_interface { public: // construction/destruction - apple2_gizmo_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + apple2_gizmo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -55,7 +55,7 @@ INPUT_PORTS_END // DEVICE IMPLEMENTATION //************************************************************************** -apple2_gizmo_device::apple2_gizmo_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +apple2_gizmo_device::apple2_gizmo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APPLE2_GIZMO, tag, owner, clock) , device_a2gameio_interface(mconfig, *this) , m_player1(*this, "joystick_p1") diff --git a/src/devices/bus/a2gameio/joyport.cpp b/src/devices/bus/a2gameio/joyport.cpp index 1c2f1118216..943f5e3d33b 100644 --- a/src/devices/bus/a2gameio/joyport.cpp +++ b/src/devices/bus/a2gameio/joyport.cpp @@ -25,7 +25,7 @@ class apple2_joyport_device : public device_t, public device_a2gameio_interface { public: // construction/destruction - apple2_joyport_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + apple2_joyport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -69,7 +69,7 @@ INPUT_PORTS_END // DEVICE IMPLEMENTATION //************************************************************************** -apple2_joyport_device::apple2_joyport_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +apple2_joyport_device::apple2_joyport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APPLE2_JOYPORT, tag, owner, clock) , device_a2gameio_interface(mconfig, *this) , m_player1(*this, "joystick_p1") diff --git a/src/devices/bus/a2gameio/joystick.cpp b/src/devices/bus/a2gameio/joystick.cpp index 498b32757e2..737ddf9ea5e 100644 --- a/src/devices/bus/a2gameio/joystick.cpp +++ b/src/devices/bus/a2gameio/joystick.cpp @@ -17,7 +17,7 @@ class apple2_joystick_device : public device_t, public device_a2gameio_interface { public: // construction/destruction - apple2_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + apple2_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -93,7 +93,7 @@ INPUT_PORTS_END // DEVICE IMPLEMENTATION //************************************************************************** -apple2_joystick_device::apple2_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +apple2_joystick_device::apple2_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APPLE2_JOYSTICK, tag, owner, clock) , device_a2gameio_interface(mconfig, *this) , m_joy_x(*this, "joystick_%u_x", 1U) diff --git a/src/devices/bus/a2gameio/paddles.cpp b/src/devices/bus/a2gameio/paddles.cpp index 5f0955fba89..ee38902b826 100644 --- a/src/devices/bus/a2gameio/paddles.cpp +++ b/src/devices/bus/a2gameio/paddles.cpp @@ -17,7 +17,7 @@ class apple2_paddles_device : public device_t, public device_a2gameio_interface { public: // construction/destruction - apple2_paddles_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + apple2_paddles_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -68,7 +68,7 @@ INPUT_PORTS_END // DEVICE IMPLEMENTATION //************************************************************************** -apple2_paddles_device::apple2_paddles_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +apple2_paddles_device::apple2_paddles_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APPLE2_PADDLES, tag, owner, clock) , device_a2gameio_interface(mconfig, *this) , m_pdl(*this, "paddle_%u", 1U) diff --git a/src/devices/bus/a7800/a78_slot.cpp b/src/devices/bus/a7800/a78_slot.cpp index cee7d3bd99f..d40cdc6a2a0 100644 --- a/src/devices/bus/a7800/a78_slot.cpp +++ b/src/devices/bus/a7800/a78_slot.cpp @@ -111,7 +111,7 @@ void device_a78_cart_interface::nvram_alloc(uint32_t size) //------------------------------------------------- // a78_cart_slot_device - constructor //------------------------------------------------- -a78_cart_slot_device::a78_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_cart_slot_device::a78_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, A78_CART_SLOT, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_slot_interface(mconfig, *this) diff --git a/src/devices/bus/a7800/a78_slot.h b/src/devices/bus/a7800/a78_slot.h index d27a175e3d1..80051d4c99f 100644 --- a/src/devices/bus/a7800/a78_slot.h +++ b/src/devices/bus/a7800/a78_slot.h @@ -90,14 +90,14 @@ public: // construction/destruction template <typename T> a78_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : a78_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : a78_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - a78_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + a78_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~a78_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/a7800/cpuwiz.cpp b/src/devices/bus/a7800/cpuwiz.cpp index 3a8c3cc1546..6cd92b53124 100644 --- a/src/devices/bus/a7800/cpuwiz.cpp +++ b/src/devices/bus/a7800/cpuwiz.cpp @@ -41,24 +41,24 @@ DEFINE_DEVICE_TYPE(A78_ROM_MEGACART, a78_megacart_device, "a78_megacart", "Atari DEFINE_DEVICE_TYPE(A78_ROM_P450_VB, a78_rom_p450_vb_device, "a78_versapokey", "Atari 7800 VersaBoard + POKEY @ 0x450 Cart") -a78_versaboard_device::a78_versaboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a78_versaboard_device::a78_versaboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_sg_device(mconfig, type, tag, owner, clock), m_ram_bank(0) { } -a78_versaboard_device::a78_versaboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_versaboard_device::a78_versaboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_versaboard_device(mconfig, A78_ROM_VERSABOARD, tag, owner, clock) { } -a78_megacart_device::a78_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_megacart_device::a78_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_versaboard_device(mconfig, A78_ROM_MEGACART, tag, owner, clock) { } -a78_rom_p450_vb_device::a78_rom_p450_vb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_p450_vb_device::a78_rom_p450_vb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_versaboard_device(mconfig, A78_ROM_P450_VB, tag, owner, clock) , m_pokey450(*this, "pokey450") { diff --git a/src/devices/bus/a7800/cpuwiz.h b/src/devices/bus/a7800/cpuwiz.h index e55c637592f..148f8c936d5 100644 --- a/src/devices/bus/a7800/cpuwiz.h +++ b/src/devices/bus/a7800/cpuwiz.h @@ -15,7 +15,7 @@ class a78_versaboard_device : public a78_rom_sg_device { public: // construction/destruction - a78_versaboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_versaboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -26,7 +26,7 @@ public: virtual void write_40xx(offs_t offset, uint8_t data) override; protected: - a78_versaboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a78_versaboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); int m_ram_bank; }; @@ -38,7 +38,7 @@ class a78_megacart_device : public a78_versaboard_device { public: // construction/destruction - a78_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual void write_40xx(offs_t offset, uint8_t data) override; @@ -53,7 +53,7 @@ class a78_rom_p450_vb_device : public a78_versaboard_device { public: // construction/destruction - a78_rom_p450_vb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_p450_vb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_04xx(offs_t offset) override { if (offset >= 0x50 && offset < 0x60) return m_pokey450->read(offset & 0x0f); else return 0xff; } diff --git a/src/devices/bus/a7800/hiscore.cpp b/src/devices/bus/a7800/hiscore.cpp index a0c821552d8..3c1199d51c4 100644 --- a/src/devices/bus/a7800/hiscore.cpp +++ b/src/devices/bus/a7800/hiscore.cpp @@ -20,7 +20,7 @@ DEFINE_DEVICE_TYPE(A78_HISCORE, a78_hiscore_device, "a78_hiscore", "Atari 7800 High Score Cart") -a78_hiscore_device::a78_hiscore_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_hiscore_device::a78_hiscore_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_device(mconfig, A78_HISCORE, tag, owner, clock) , m_hscslot(*this, "hsc_slot") { diff --git a/src/devices/bus/a7800/hiscore.h b/src/devices/bus/a7800/hiscore.h index b9dc9674212..8e932fe209a 100644 --- a/src/devices/bus/a7800/hiscore.h +++ b/src/devices/bus/a7800/hiscore.h @@ -15,7 +15,7 @@ class a78_hiscore_device : public a78_rom_device { public: // construction/destruction - a78_hiscore_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_hiscore_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_04xx(offs_t offset) override; diff --git a/src/devices/bus/a7800/rom.cpp b/src/devices/bus/a7800/rom.cpp index 9e715ddcf2c..5762dcbc4b7 100644 --- a/src/devices/bus/a7800/rom.cpp +++ b/src/devices/bus/a7800/rom.cpp @@ -43,87 +43,87 @@ DEFINE_DEVICE_TYPE(A78_ROM_P450_SG_RAM, a78_rom_p450_sg_ram_device, "a78_p450_t6 DEFINE_DEVICE_TYPE(A78_ROM_P450_SG9, a78_rom_p450_sg9_device, "a78_p450_ta", "Atari 7800 ROM Carts w/SuperGame 9Banks + POKEY @ 0x0450") -a78_rom_device::a78_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a78_rom_device::a78_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a78_cart_interface( mconfig, *this ) { } -a78_rom_device::a78_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_device::a78_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_device(mconfig, A78_ROM, tag, owner, clock) { } -a78_rom_pokey_device::a78_rom_pokey_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a78_rom_pokey_device::a78_rom_pokey_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_device(mconfig, type, tag, owner, clock) , m_pokey(*this, "pokey") { } -a78_rom_pokey_device::a78_rom_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_pokey_device::a78_rom_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_pokey_device(mconfig, A78_ROM_POKEY, tag, owner, clock) { } -a78_rom_mram_device::a78_rom_mram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a78_rom_mram_device::a78_rom_mram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_device(mconfig, type, tag, owner, clock) { } -a78_rom_mram_device::a78_rom_mram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_mram_device::a78_rom_mram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_mram_device(mconfig, A78_ROM_MRAM, tag, owner, clock) { } -a78_rom_sg_device::a78_rom_sg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a78_rom_sg_device::a78_rom_sg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_device(mconfig, type, tag, owner, clock) , m_bank(0) { } -a78_rom_sg_device::a78_rom_sg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_sg_device::a78_rom_sg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_sg_device(mconfig, A78_ROM_SG, tag, owner, clock) { } -a78_rom_sg_pokey_device::a78_rom_sg_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_sg_pokey_device::a78_rom_sg_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_sg_device(mconfig, A78_ROM_SG_POKEY, tag, owner, clock) , m_pokey(*this, "pokey") { } -a78_rom_sg_ram_device::a78_rom_sg_ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a78_rom_sg_ram_device::a78_rom_sg_ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_sg_device(mconfig, type, tag, owner, clock) { } -a78_rom_sg_ram_device::a78_rom_sg_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_sg_ram_device::a78_rom_sg_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_sg_ram_device(mconfig, A78_ROM_SG_RAM, tag, owner, clock) { } -a78_rom_sg9_device::a78_rom_sg9_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a78_rom_sg9_device::a78_rom_sg9_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_sg_device(mconfig, type, tag, owner, clock) { } -a78_rom_sg9_device::a78_rom_sg9_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_sg9_device::a78_rom_sg9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_sg9_device(mconfig, A78_ROM_SG9, tag, owner, clock) { } -a78_rom_abs_device::a78_rom_abs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_abs_device::a78_rom_abs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_device(mconfig, A78_ROM_ABSOLUTE, tag, owner, clock) , m_bank(0) { } -a78_rom_act_device::a78_rom_act_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_act_device::a78_rom_act_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_device(mconfig, A78_ROM_ACTIVISION, tag, owner, clock) , m_bank(0) { @@ -131,25 +131,25 @@ a78_rom_act_device::a78_rom_act_device(const machine_config &mconfig, const char -a78_rom_p450_device::a78_rom_p450_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_p450_device::a78_rom_p450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_device(mconfig, A78_ROM_P450, tag, owner, clock) , m_pokey450(*this, "pokey450") { } -a78_rom_p450_pokey_device::a78_rom_p450_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_p450_pokey_device::a78_rom_p450_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_pokey_device(mconfig, A78_ROM_P450_POKEY, tag, owner, clock) , m_pokey450(*this, "pokey450") { } -a78_rom_p450_sg_ram_device::a78_rom_p450_sg_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_p450_sg_ram_device::a78_rom_p450_sg_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_sg_ram_device(mconfig, A78_ROM_P450_SG_RAM, tag, owner, clock) , m_pokey450(*this, "pokey450") { } -a78_rom_p450_sg9_device::a78_rom_p450_sg9_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_rom_p450_sg9_device::a78_rom_p450_sg9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_sg9_device(mconfig, A78_ROM_P450_SG9, tag, owner, clock) , m_pokey450(*this, "pokey450") { diff --git a/src/devices/bus/a7800/rom.h b/src/devices/bus/a7800/rom.h index 8237b07c8ac..a51e1876a28 100644 --- a/src/devices/bus/a7800/rom.h +++ b/src/devices/bus/a7800/rom.h @@ -16,13 +16,13 @@ class a78_rom_device : public device_t, { public: // construction/destruction - a78_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_40xx(offs_t offset) override; protected: - a78_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a78_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -36,14 +36,14 @@ class a78_rom_pokey_device : public a78_rom_device { public: // construction/destruction - a78_rom_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_40xx(offs_t offset) override; virtual void write_40xx(offs_t offset, uint8_t data) override; protected: - a78_rom_pokey_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a78_rom_pokey_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; @@ -57,14 +57,14 @@ class a78_rom_mram_device : public a78_rom_device { public: // construction/destruction - a78_rom_mram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_mram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_40xx(offs_t offset) override; virtual void write_40xx(offs_t offset, uint8_t data) override; protected: - a78_rom_mram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a78_rom_mram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -74,14 +74,14 @@ class a78_rom_sg_device : public a78_rom_device { public: // construction/destruction - a78_rom_sg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_sg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_40xx(offs_t offset) override; virtual void write_40xx(offs_t offset, uint8_t data) override; protected: - a78_rom_sg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a78_rom_sg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -97,7 +97,7 @@ class a78_rom_sg_pokey_device : public a78_rom_sg_device { public: // construction/destruction - a78_rom_sg_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_sg_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_40xx(offs_t offset) override; @@ -116,14 +116,14 @@ class a78_rom_sg_ram_device : public a78_rom_sg_device { public: // construction/destruction - a78_rom_sg_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_sg_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_40xx(offs_t offset) override; virtual void write_40xx(offs_t offset, uint8_t data) override; protected: - a78_rom_sg_ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a78_rom_sg_ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -133,14 +133,14 @@ class a78_rom_sg9_device : public a78_rom_sg_device { public: // construction/destruction - a78_rom_sg9_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_sg9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_40xx(offs_t offset) override; virtual void write_40xx(offs_t offset, uint8_t data) override; protected: - a78_rom_sg9_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a78_rom_sg9_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -150,7 +150,7 @@ class a78_rom_abs_device : public a78_rom_device { public: // construction/destruction - a78_rom_abs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_abs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_40xx(offs_t offset) override; @@ -171,7 +171,7 @@ class a78_rom_act_device : public a78_rom_device { public: // construction/destruction - a78_rom_act_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_act_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_40xx(offs_t offset) override; @@ -194,7 +194,7 @@ class a78_rom_p450_device : public a78_rom_device { public: // construction/destruction - a78_rom_p450_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_p450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_04xx(offs_t offset) override { if (offset >= 0x50 && offset < 0x60) return m_pokey450->read(offset & 0x0f); else return 0xff; } @@ -213,7 +213,7 @@ class a78_rom_p450_pokey_device : public a78_rom_pokey_device { public: // construction/destruction - a78_rom_p450_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_p450_pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_04xx(offs_t offset) override { if (offset >= 0x50 && offset < 0x60) return m_pokey450->read(offset & 0x0f); else return 0xff; } @@ -232,7 +232,7 @@ class a78_rom_p450_sg_ram_device : public a78_rom_sg_ram_device { public: // construction/destruction - a78_rom_p450_sg_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_p450_sg_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_04xx(offs_t offset) override { if (offset >= 0x50 && offset < 0x60) return m_pokey450->read(offset & 0x0f); else return 0xff; } @@ -251,7 +251,7 @@ class a78_rom_p450_sg9_device : public a78_rom_sg9_device { public: // construction/destruction - a78_rom_p450_sg9_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_rom_p450_sg9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_04xx(offs_t offset) override { if (offset >= 0x50 && offset < 0x60) return m_pokey450->read(offset & 0x0f); else return 0xff; } diff --git a/src/devices/bus/a7800/xboard.cpp b/src/devices/bus/a7800/xboard.cpp index bee85d76c98..95609e06152 100644 --- a/src/devices/bus/a7800/xboard.cpp +++ b/src/devices/bus/a7800/xboard.cpp @@ -57,7 +57,7 @@ DEFINE_DEVICE_TYPE(A78_XBOARD, a78_xboard_device, "a78_xboard", "Atari 7800 XBoa DEFINE_DEVICE_TYPE(A78_XM, a78_xm_device, "a78_xm", "Atari 7800 XM expansion module") -a78_xboard_device::a78_xboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a78_xboard_device::a78_xboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : a78_rom_device(mconfig, type, tag, owner, clock) , m_xbslot(*this, "xb_slot") , m_pokey(*this, "xb_pokey") @@ -66,13 +66,13 @@ a78_xboard_device::a78_xboard_device(const machine_config &mconfig, device_type } -a78_xboard_device::a78_xboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_xboard_device::a78_xboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_xboard_device(mconfig, A78_XBOARD, tag, owner, clock) { } -a78_xm_device::a78_xm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a78_xm_device::a78_xm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a78_xboard_device(mconfig, A78_XM, tag, owner, clock) , m_ym(*this, "xm_ym2151"), m_ym_enabled(0) { diff --git a/src/devices/bus/a7800/xboard.h b/src/devices/bus/a7800/xboard.h index ee4cda6c018..e69b634cdb3 100644 --- a/src/devices/bus/a7800/xboard.h +++ b/src/devices/bus/a7800/xboard.h @@ -17,7 +17,7 @@ class a78_xboard_device : public a78_rom_device { public: // construction/destruction - a78_xboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_xboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_04xx(offs_t offset) override; @@ -26,7 +26,7 @@ public: virtual void write_40xx(offs_t offset, uint8_t data) override; protected: - a78_xboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a78_xboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -44,7 +44,7 @@ class a78_xm_device : public a78_xboard_device { public: // construction/destruction - a78_xm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a78_xm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_04xx(offs_t offset) override; diff --git a/src/devices/bus/a800/a800_slot.cpp b/src/devices/bus/a800/a800_slot.cpp index 089cd8778bb..249b20e30f1 100644 --- a/src/devices/bus/a800/a800_slot.cpp +++ b/src/devices/bus/a800/a800_slot.cpp @@ -102,7 +102,7 @@ void device_a800_cart_interface::nvram_alloc(uint32_t size) //------------------------------------------------- // ****_cart_slot_device - constructor //------------------------------------------------- -a800_cart_slot_device::a800_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a800_cart_slot_device::a800_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_single_card_slot_interface<device_a800_cart_interface>(mconfig, *this) @@ -111,19 +111,19 @@ a800_cart_slot_device::a800_cart_slot_device(const machine_config &mconfig, devi { } -a800_cart_slot_device::a800_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a800_cart_slot_device::a800_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_cart_slot_device(mconfig, A800_CART_SLOT, tag, owner, clock) { } -a5200_cart_slot_device::a5200_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a5200_cart_slot_device::a5200_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_cart_slot_device(mconfig, A5200_CART_SLOT, tag, owner, clock) { } -xegs_cart_slot_device::xegs_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +xegs_cart_slot_device::xegs_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_cart_slot_device(mconfig, XEGS_CART_SLOT, tag, owner, clock) { } diff --git a/src/devices/bus/a800/a800_slot.h b/src/devices/bus/a800/a800_slot.h index 71b79dbe1b5..019064fffcb 100644 --- a/src/devices/bus/a800/a800_slot.h +++ b/src/devices/bus/a800/a800_slot.h @@ -92,14 +92,14 @@ public: // construction/destruction template <typename T> a800_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : a800_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : a800_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - a800_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + a800_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~a800_cart_slot_device(); // image-level overrides @@ -124,7 +124,7 @@ public: void write_d5xx(offs_t offset, uint8_t data); protected: - a800_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a800_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -146,14 +146,14 @@ public: // construction/destruction template <typename T> a5200_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : a5200_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : a5200_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - a5200_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a5200_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~a5200_cart_slot_device(); virtual const char *file_extensions() const noexcept override { return "bin,rom,car,a52"; } @@ -170,14 +170,14 @@ public: // construction/destruction template <typename T> xegs_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : xegs_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : xegs_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - xegs_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xegs_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~xegs_cart_slot_device(); virtual const char *file_extensions() const noexcept override { return "bin,rom,car"; } diff --git a/src/devices/bus/a800/a8sio.cpp b/src/devices/bus/a800/a8sio.cpp index 41fb3f863e5..a46161cb3ab 100644 --- a/src/devices/bus/a800/a8sio.cpp +++ b/src/devices/bus/a800/a8sio.cpp @@ -51,7 +51,7 @@ DEFINE_DEVICE_TYPE(A8SIO, a8sio_device, "a8sio", "Atari 8 bit SIO Slot") // a8sio_device - constructor //------------------------------------------------- -a8sio_device::a8sio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a8sio_device::a8sio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, A8SIO, tag, owner, clock) , device_single_card_slot_interface<device_a8sio_card_interface>(mconfig, *this) , m_out_clock_in_cb(*this) diff --git a/src/devices/bus/a800/a8sio.h b/src/devices/bus/a800/a8sio.h index 643dffe19a5..a08f6ff9011 100644 --- a/src/devices/bus/a800/a8sio.h +++ b/src/devices/bus/a800/a8sio.h @@ -44,14 +44,14 @@ class a8sio_device : public device_t, public device_single_card_slot_interface<d public: // construction/destruction a8sio_device(machine_config const &mconfig, char const *tag, device_t *owner, char const *dflt) - : a8sio_device(mconfig, tag, owner, (uint32_t)0) + : a8sio_device(mconfig, tag, owner) { option_reset(); a8sio_cards(*this); set_default_option(dflt); set_fixed(false); } - a8sio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a8sio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration auto clock_in() { return m_out_clock_in_cb.bind(); } @@ -73,7 +73,7 @@ public: DECLARE_WRITE_LINE_MEMBER( interrupt_w ); // pin 13 protected: - a8sio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a8sio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; diff --git a/src/devices/bus/a800/atari1050.cpp b/src/devices/bus/a800/atari1050.cpp index 12191d4cc72..cd37fc2aea0 100644 --- a/src/devices/bus/a800/atari1050.cpp +++ b/src/devices/bus/a800/atari1050.cpp @@ -25,7 +25,7 @@ // device type definition DEFINE_DEVICE_TYPE(ATARI1050, atari1050_device, "atari1050", "Atari 1050 Dual Density Disk Drive") -atari1050_device::atari1050_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +atari1050_device::atari1050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ATARI1050, tag, owner, clock) , device_a8sio_card_interface(mconfig, *this) , m_pia(*this, "pia") diff --git a/src/devices/bus/a800/atari1050.h b/src/devices/bus/a800/atari1050.h index 48e32b86430..449bebe93b8 100644 --- a/src/devices/bus/a800/atari1050.h +++ b/src/devices/bus/a800/atari1050.h @@ -19,7 +19,7 @@ class atari1050_device : public device_t, public device_a8sio_card_interface { public: - atari1050_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + atari1050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/a800/atari810.cpp b/src/devices/bus/a800/atari810.cpp index 69b5bd09d2f..85563a009b1 100644 --- a/src/devices/bus/a800/atari810.cpp +++ b/src/devices/bus/a800/atari810.cpp @@ -23,7 +23,7 @@ // device type definition DEFINE_DEVICE_TYPE(ATARI810, atari810_device, "atari810", "Atari 810 Disk Drive") -atari810_device::atari810_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +atari810_device::atari810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ATARI810, tag, owner, clock) , device_a8sio_card_interface(mconfig, *this) , m_pia(*this, "pia") diff --git a/src/devices/bus/a800/atari810.h b/src/devices/bus/a800/atari810.h index 1bbe8db0f8c..a7bf74942e4 100644 --- a/src/devices/bus/a800/atari810.h +++ b/src/devices/bus/a800/atari810.h @@ -19,7 +19,7 @@ class atari810_device : public device_t, public device_a8sio_card_interface { public: - atari810_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + atari810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/a800/cassette.cpp b/src/devices/bus/a800/cassette.cpp index 32d9fe0b390..34027261cc6 100644 --- a/src/devices/bus/a800/cassette.cpp +++ b/src/devices/bus/a800/cassette.cpp @@ -39,12 +39,12 @@ void a8sio_cassette_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -a8sio_cassette_device::a8sio_cassette_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a8sio_cassette_device::a8sio_cassette_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a8sio_cassette_device(mconfig, A8SIO_CASSETTE, tag, owner, clock) { } -a8sio_cassette_device::a8sio_cassette_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a8sio_cassette_device::a8sio_cassette_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a8sio_card_interface(mconfig, *this) , m_cassette(*this, "cassette") diff --git a/src/devices/bus/a800/cassette.h b/src/devices/bus/a800/cassette.h index d1c91c5a2fa..e897cb82839 100644 --- a/src/devices/bus/a800/cassette.h +++ b/src/devices/bus/a800/cassette.h @@ -27,12 +27,12 @@ class a8sio_cassette_device { public: // construction/destruction - a8sio_cassette_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a8sio_cassette_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER( motor_w ) override; protected: - a8sio_cassette_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a8sio_cassette_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/a800/oss.cpp b/src/devices/bus/a800/oss.cpp index f25dfcce130..d237d5d7030 100644 --- a/src/devices/bus/a800/oss.cpp +++ b/src/devices/bus/a800/oss.cpp @@ -21,25 +21,25 @@ DEFINE_DEVICE_TYPE(A800_ROM_OSS43, a800_rom_oss43_device, "a800_043m", "Atari 8 DEFINE_DEVICE_TYPE(A800_ROM_OSS91, a800_rom_oss91_device, "a800_m091", "Atari 800 ROM Carts OSS-M091") -a800_rom_oss8k_device::a800_rom_oss8k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_oss8k_device::a800_rom_oss8k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_OSS8K, tag, owner, clock), m_bank(0) { } -a800_rom_oss34_device::a800_rom_oss34_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_oss34_device::a800_rom_oss34_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_OSS34, tag, owner, clock), m_bank(0) { } -a800_rom_oss43_device::a800_rom_oss43_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_oss43_device::a800_rom_oss43_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_OSS43, tag, owner, clock), m_bank(0) { } -a800_rom_oss91_device::a800_rom_oss91_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_oss91_device::a800_rom_oss91_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_OSS91, tag, owner, clock), m_bank(0) { } diff --git a/src/devices/bus/a800/oss.h b/src/devices/bus/a800/oss.h index 65527039825..246f2f24291 100644 --- a/src/devices/bus/a800/oss.h +++ b/src/devices/bus/a800/oss.h @@ -14,7 +14,7 @@ class a800_rom_oss8k_device : public a800_rom_device { public: // construction/destruction - a800_rom_oss8k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_oss8k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_d5xx(offs_t offset, uint8_t data) override; @@ -34,7 +34,7 @@ class a800_rom_oss34_device : public a800_rom_device { public: // construction/destruction - a800_rom_oss34_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_oss34_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_d5xx(offs_t offset, uint8_t data) override; @@ -54,7 +54,7 @@ class a800_rom_oss43_device : public a800_rom_device { public: // construction/destruction - a800_rom_oss43_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_oss43_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_d5xx(offs_t offset, uint8_t data) override; @@ -74,7 +74,7 @@ class a800_rom_oss91_device : public a800_rom_device { public: // construction/destruction - a800_rom_oss91_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_oss91_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_d5xx(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/a800/rom.cpp b/src/devices/bus/a800/rom.cpp index 4ea7729c909..a32edcc35c6 100644 --- a/src/devices/bus/a800/rom.cpp +++ b/src/devices/bus/a800/rom.cpp @@ -32,60 +32,60 @@ DEFINE_DEVICE_TYPE(A5200_ROM_2CHIPS, a5200_rom_2chips_device, "a5200_16k2c", DEFINE_DEVICE_TYPE(A5200_ROM_BBSB, a5200_rom_bbsb_device, "a5200_bbsb", "Atari 5200 ROM Cart BBSB") -a800_rom_device::a800_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a800_rom_device::a800_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_a800_cart_interface( mconfig, *this ) { } -a800_rom_device::a800_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_device::a800_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM, tag, owner, clock) { } -a800_rom_bbsb_device::a800_rom_bbsb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_bbsb_device::a800_rom_bbsb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_BBSB, tag, owner, clock) { } -xegs_rom_device::xegs_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +xegs_rom_device::xegs_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, XEGS_ROM, tag, owner, clock) , m_bank(0) { } -a800_rom_williams_device::a800_rom_williams_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_williams_device::a800_rom_williams_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_WILLIAMS, tag, owner, clock) , m_bank(0) { } -a800_rom_express_device::a800_rom_express_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_express_device::a800_rom_express_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_EXPRESS, tag, owner, clock) , m_bank(0) { } -a800_rom_turbo_device::a800_rom_turbo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_turbo_device::a800_rom_turbo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_TURBO, tag, owner, clock) , m_bank(0) { } -a800_rom_telelink2_device::a800_rom_telelink2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_telelink2_device::a800_rom_telelink2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_TELELINK2, tag, owner, clock) { } -a800_rom_microcalc_device::a800_rom_microcalc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_microcalc_device::a800_rom_microcalc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_MICROCALC, tag, owner, clock) , m_bank(0) { @@ -108,13 +108,13 @@ a800_rom_corina_sram_device::a800_rom_corina_sram_device(const machine_config &m { } -a5200_rom_2chips_device::a5200_rom_2chips_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a5200_rom_2chips_device::a5200_rom_2chips_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A5200_ROM_2CHIPS, tag, owner, clock) { } -a5200_rom_bbsb_device::a5200_rom_bbsb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a5200_rom_bbsb_device::a5200_rom_bbsb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A5200_ROM_BBSB, tag, owner, clock) { } diff --git a/src/devices/bus/a800/rom.h b/src/devices/bus/a800/rom.h index 759cb5a7854..47410121720 100644 --- a/src/devices/bus/a800/rom.h +++ b/src/devices/bus/a800/rom.h @@ -15,12 +15,12 @@ class a800_rom_device : public device_t, { public: // construction/destruction - a800_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; protected: - a800_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a800_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -34,7 +34,7 @@ class a800_rom_bbsb_device : public a800_rom_device { public: // construction/destruction - a800_rom_bbsb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_bbsb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_80xx(offs_t offset, uint8_t data) override; @@ -54,7 +54,7 @@ class a800_rom_williams_device : public a800_rom_device { public: // construction/destruction - a800_rom_williams_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_williams_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_d5xx(offs_t offset, uint8_t data) override; @@ -74,7 +74,7 @@ class a800_rom_express_device : public a800_rom_device { public: // construction/destruction - a800_rom_express_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_express_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_d5xx(offs_t offset, uint8_t data) override; @@ -94,7 +94,7 @@ class a800_rom_blizzard_device : public a800_rom_device { public: // construction/destruction - a800_rom_blizzard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_blizzard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; @@ -111,7 +111,7 @@ class a800_rom_turbo_device : public a800_rom_device { public: // construction/destruction - a800_rom_turbo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_turbo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_d5xx(offs_t offset, uint8_t data) override; @@ -131,7 +131,7 @@ class a800_rom_telelink2_device : public a800_rom_device { public: // construction/destruction - a800_rom_telelink2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_telelink2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_80xx(offs_t offset, uint8_t data) override; @@ -146,7 +146,7 @@ class a800_rom_microcalc_device : public a800_rom_device { public: // construction/destruction - a800_rom_microcalc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_microcalc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_d5xx(offs_t offset, uint8_t data) override; @@ -203,7 +203,7 @@ class xegs_rom_device : public a800_rom_device { public: // construction/destruction - xegs_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xegs_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -223,7 +223,7 @@ class a5200_rom_2chips_device : public a800_rom_device { public: // construction/destruction - a5200_rom_2chips_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a5200_rom_2chips_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; }; @@ -235,7 +235,7 @@ class a5200_rom_bbsb_device : public a800_rom_device { public: // construction/destruction - a5200_rom_bbsb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a5200_rom_bbsb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_80xx(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/a800/sparta.cpp b/src/devices/bus/a800/sparta.cpp index 8b8242d8dad..aae67a335e0 100644 --- a/src/devices/bus/a800/sparta.cpp +++ b/src/devices/bus/a800/sparta.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(A800_ROM_SPARTADOS, a800_rom_spartados_device, "a800_sparta", "Atari 800 SpartaDOS ROM Carts") -a800_rom_spartados_device::a800_rom_spartados_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a800_rom_spartados_device::a800_rom_spartados_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a800_rom_device(mconfig, A800_ROM_SPARTADOS, tag, owner, clock) , m_bank(0) , m_subslot_enabled(0) diff --git a/src/devices/bus/a800/sparta.h b/src/devices/bus/a800/sparta.h index ea211472f31..0d3798e9fa3 100644 --- a/src/devices/bus/a800/sparta.h +++ b/src/devices/bus/a800/sparta.h @@ -14,7 +14,7 @@ class a800_rom_spartados_device : public a800_rom_device { public: // construction/destruction - a800_rom_spartados_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a800_rom_spartados_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_80xx(offs_t offset) override; virtual void write_d5xx(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/abcbus/abc890.cpp b/src/devices/bus/abcbus/abc890.cpp index 9374096f38b..b0d76352697 100644 --- a/src/devices/bus/abcbus/abc890.cpp +++ b/src/devices/bus/abcbus/abc890.cpp @@ -127,38 +127,38 @@ void abc856_device::device_add_mconfig(machine_config &config) // abc890_device - constructor //------------------------------------------------- -abc890_device::abc890_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +abc890_device::abc890_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_abcbus_card_interface(mconfig, *this) { } -abc890_device::abc890_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc890_device::abc890_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : abc890_device(mconfig, ABC890, tag, owner, clock) { } -abc_expansion_unit_device::abc_expansion_unit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc_expansion_unit_device::abc_expansion_unit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : abc890_device(mconfig, ABC_EXPANSION_UNIT, tag, owner, clock) { } -abc894_device::abc894_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc894_device::abc894_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : abc890_device(mconfig, ABC894, tag, owner, clock) { } -abc850_device::abc850_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc850_device::abc850_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : abc890_device(mconfig, ABC850, tag, owner, clock) { } -abc852_device::abc852_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc852_device::abc852_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : abc890_device(mconfig, ABC852, tag, owner, clock) { } -abc856_device::abc856_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc856_device::abc856_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : abc890_device(mconfig, ABC856, tag, owner, clock) { } diff --git a/src/devices/bus/abcbus/abc890.h b/src/devices/bus/abcbus/abc890.h index 5a56b9804fe..70f5b97e838 100644 --- a/src/devices/bus/abcbus/abc890.h +++ b/src/devices/bus/abcbus/abc890.h @@ -26,10 +26,10 @@ class abc890_device : public device_t, { public: // construction/destruction - abc890_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc890_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - abc890_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + abc890_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -58,7 +58,7 @@ class abc_expansion_unit_device : public abc890_device { public: // construction/destruction - abc_expansion_unit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc_expansion_unit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -72,7 +72,7 @@ class abc894_device : public abc890_device { public: // construction/destruction - abc894_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc894_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -86,7 +86,7 @@ class abc850_device : public abc890_device { public: // construction/destruction - abc850_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc850_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -100,7 +100,7 @@ class abc852_device : public abc890_device { public: // construction/destruction - abc852_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc852_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -114,7 +114,7 @@ class abc856_device : public abc890_device { public: // construction/destruction - abc856_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc856_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/abcbus/abcbus.cpp b/src/devices/bus/abcbus/abcbus.cpp index 5e0adb49c3f..e0335f56aac 100644 --- a/src/devices/bus/abcbus/abcbus.cpp +++ b/src/devices/bus/abcbus/abcbus.cpp @@ -38,7 +38,7 @@ device_abcbus_card_interface::device_abcbus_card_interface(const machine_config // abcbus_slot_device - constructor //------------------------------------------------- -abcbus_slot_device::abcbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abcbus_slot_device::abcbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABCBUS_SLOT, tag, owner, clock), device_single_card_slot_interface<device_abcbus_card_interface>(mconfig, *this), m_write_irq(*this), diff --git a/src/devices/bus/abcbus/abcbus.h b/src/devices/bus/abcbus/abcbus.h index e8ce92a2d9b..e1a1940ec21 100644 --- a/src/devices/bus/abcbus/abcbus.h +++ b/src/devices/bus/abcbus/abcbus.h @@ -158,9 +158,9 @@ class abcbus_slot_device : public device_t, { public: // construction/destruction - abcbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abcbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> - abcbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + abcbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : abcbus_slot_device(mconfig, tag, owner, clock) { option_reset(); diff --git a/src/devices/bus/abcbus/cadmouse.cpp b/src/devices/bus/abcbus/cadmouse.cpp index 7a4d90916f9..222a7113fa7 100644 --- a/src/devices/bus/abcbus/cadmouse.cpp +++ b/src/devices/bus/abcbus/cadmouse.cpp @@ -140,7 +140,7 @@ void abc_cadmouse_device::device_add_mconfig(machine_config &config) // abc_cadmouse_device - constructor //------------------------------------------------- -abc_cadmouse_device::abc_cadmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +abc_cadmouse_device::abc_cadmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC_CADMOUSE, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_maincpu(*this, Z80_TAG) diff --git a/src/devices/bus/abcbus/cadmouse.h b/src/devices/bus/abcbus/cadmouse.h index 317c67e97aa..aef4abfe991 100644 --- a/src/devices/bus/abcbus/cadmouse.h +++ b/src/devices/bus/abcbus/cadmouse.h @@ -17,7 +17,7 @@ class abc_cadmouse_device : public device_t, { public: // construction/destruction - abc_cadmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc_cadmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Flag non working features static constexpr feature_type unemulated_features() { return feature::MOUSE | feature::GRAPHICS; } diff --git a/src/devices/bus/abcbus/db4106.cpp b/src/devices/bus/abcbus/db4106.cpp index edd604f610c..8fb2e3c0112 100644 --- a/src/devices/bus/abcbus/db4106.cpp +++ b/src/devices/bus/abcbus/db4106.cpp @@ -70,7 +70,7 @@ void databoard_4106_device::databoard_4106_io(address_map &map) void databoard_4106_device::device_add_mconfig(machine_config &config) { - Z80(config, m_maincpu, 4000000); + Z80(config, m_maincpu, XTAL::u(4000000)); m_maincpu->set_memory_map(&databoard_4106_device::databoard_4106_mem); m_maincpu->set_io_map(&databoard_4106_device::databoard_4106_io); } @@ -103,7 +103,7 @@ ioport_constructor databoard_4106_device::device_input_ports() const // databoard_4106_device - constructor //------------------------------------------------- -databoard_4106_device::databoard_4106_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +databoard_4106_device::databoard_4106_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DATABOARD_4106, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_maincpu(*this, Z80_TAG) diff --git a/src/devices/bus/abcbus/db4106.h b/src/devices/bus/abcbus/db4106.h index 74e49631dbe..ad54f511c19 100644 --- a/src/devices/bus/abcbus/db4106.h +++ b/src/devices/bus/abcbus/db4106.h @@ -27,7 +27,7 @@ class databoard_4106_device : public device_t, { public: // construction/destruction - databoard_4106_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + databoard_4106_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/abcbus/db4107.cpp b/src/devices/bus/abcbus/db4107.cpp index 0b9ab0ed062..2e31f02f5ab 100644 --- a/src/devices/bus/abcbus/db4107.cpp +++ b/src/devices/bus/abcbus/db4107.cpp @@ -96,11 +96,11 @@ void databoard_4107_device::databoard_4107_io(address_map &map) void databoard_4107_device::device_add_mconfig(machine_config &config) { - Z80(config, m_maincpu, 4000000); + Z80(config, m_maincpu, XTAL::u(4000000)); m_maincpu->set_memory_map(&databoard_4107_device::databoard_4107_mem); m_maincpu->set_io_map(&databoard_4107_device::databoard_4107_io); - Z80DMA(config, m_dma, 4000000); + Z80DMA(config, m_dma, XTAL::u(4000000)); } @@ -131,7 +131,7 @@ ioport_constructor databoard_4107_device::device_input_ports() const // databoard_4107_device - constructor //------------------------------------------------- -databoard_4107_device::databoard_4107_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +databoard_4107_device::databoard_4107_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DATABOARD_4107, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_maincpu(*this, Z80_TAG), diff --git a/src/devices/bus/abcbus/db4107.h b/src/devices/bus/abcbus/db4107.h index 4ae301084ca..4db86a3f041 100644 --- a/src/devices/bus/abcbus/db4107.h +++ b/src/devices/bus/abcbus/db4107.h @@ -28,7 +28,7 @@ class databoard_4107_device : public device_t, { public: // construction/destruction - databoard_4107_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + databoard_4107_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/abcbus/db4112.cpp b/src/devices/bus/abcbus/db4112.cpp index a2631f0b244..6054d4acc21 100644 --- a/src/devices/bus/abcbus/db4112.cpp +++ b/src/devices/bus/abcbus/db4112.cpp @@ -74,7 +74,7 @@ void abc_databoard_4112_device::databoard_4112_io(address_map &map) void abc_databoard_4112_device::device_add_mconfig(machine_config &config) { - Z80(config, m_maincpu, 4000000); + Z80(config, m_maincpu, XTAL::u(4000000)); m_maincpu->set_memory_map(&abc_databoard_4112_device::databoard_4112_mem); m_maincpu->set_io_map(&abc_databoard_4112_device::databoard_4112_io); } @@ -107,7 +107,7 @@ ioport_constructor abc_databoard_4112_device::device_input_ports() const // abc_databoard_4112_device - constructor //------------------------------------------------- -abc_databoard_4112_device::abc_databoard_4112_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc_databoard_4112_device::abc_databoard_4112_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DATABOARD_4112, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_maincpu(*this, Z80_TAG) diff --git a/src/devices/bus/abcbus/db4112.h b/src/devices/bus/abcbus/db4112.h index c28da004297..0f8aae355df 100644 --- a/src/devices/bus/abcbus/db4112.h +++ b/src/devices/bus/abcbus/db4112.h @@ -27,7 +27,7 @@ class abc_databoard_4112_device : public device_t, { public: // construction/destruction - abc_databoard_4112_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc_databoard_4112_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/abcbus/fd2.cpp b/src/devices/bus/abcbus/fd2.cpp index b23daa8ebd7..eb16b40e80b 100644 --- a/src/devices/bus/abcbus/fd2.cpp +++ b/src/devices/bus/abcbus/fd2.cpp @@ -271,7 +271,7 @@ void abc_fd2_device::device_add_mconfig(machine_config &config) // abc_fd2_device - constructor //------------------------------------------------- -abc_fd2_device::abc_fd2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc_fd2_device::abc_fd2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC_FD2, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_maincpu(*this, Z80_TAG), diff --git a/src/devices/bus/abcbus/fd2.h b/src/devices/bus/abcbus/fd2.h index a476b66c821..15c55a2e393 100644 --- a/src/devices/bus/abcbus/fd2.h +++ b/src/devices/bus/abcbus/fd2.h @@ -32,7 +32,7 @@ class abc_fd2_device : public device_t, { public: // construction/destruction - abc_fd2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc_fd2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/abcbus/lux10828.cpp b/src/devices/bus/abcbus/lux10828.cpp index e349cd76bb5..2c54c6cf825 100644 --- a/src/devices/bus/abcbus/lux10828.cpp +++ b/src/devices/bus/abcbus/lux10828.cpp @@ -403,7 +403,7 @@ ioport_constructor luxor_55_10828_device::device_input_ports() const // luxor_55_10828_device - constructor //------------------------------------------------- -luxor_55_10828_device::luxor_55_10828_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +luxor_55_10828_device::luxor_55_10828_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LUXOR_55_10828, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_maincpu(*this, Z80_TAG), diff --git a/src/devices/bus/abcbus/lux10828.h b/src/devices/bus/abcbus/lux10828.h index c5bf46a8c89..55e3fce585f 100644 --- a/src/devices/bus/abcbus/lux10828.h +++ b/src/devices/bus/abcbus/lux10828.h @@ -54,7 +54,7 @@ class luxor_55_10828_device : public device_t, { public: // construction/destruction - luxor_55_10828_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + luxor_55_10828_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/abcbus/lux21046.cpp b/src/devices/bus/abcbus/lux21046.cpp index 7dd4ebfb791..6b496722ccc 100644 --- a/src/devices/bus/abcbus/lux21046.cpp +++ b/src/devices/bus/abcbus/lux21046.cpp @@ -710,12 +710,12 @@ ioport_constructor abc850_floppy_device::device_input_ports() const // luxor_55_21046_device - constructor //------------------------------------------------- -luxor_55_21046_device::luxor_55_21046_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +luxor_55_21046_device::luxor_55_21046_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : luxor_55_21046_device(mconfig, LUXOR_55_21046, tag, owner, clock) { } -luxor_55_21046_device::luxor_55_21046_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +luxor_55_21046_device::luxor_55_21046_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_floppy0(*this, SAB1793_TAG":0"), @@ -738,27 +738,27 @@ luxor_55_21046_device::luxor_55_21046_device(const machine_config &mconfig, devi { } -abc830_device::abc830_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc830_device::abc830_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : luxor_55_21046_device(mconfig, ABC830, tag, owner, clock) { } -abc832_device::abc832_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc832_device::abc832_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : luxor_55_21046_device(mconfig, ABC832, tag, owner, clock) { } -abc834_device::abc834_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc834_device::abc834_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : luxor_55_21046_device(mconfig, ABC834, tag, owner, clock) { } -abc838_device::abc838_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc838_device::abc838_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : luxor_55_21046_device(mconfig, ABC838, tag, owner, clock) { } -abc850_floppy_device::abc850_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc850_floppy_device::abc850_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : luxor_55_21046_device(mconfig, ABC850_FLOPPY, tag, owner, clock) { } diff --git a/src/devices/bus/abcbus/lux21046.h b/src/devices/bus/abcbus/lux21046.h index 735de99641c..b18f393b4b2 100644 --- a/src/devices/bus/abcbus/lux21046.h +++ b/src/devices/bus/abcbus/lux21046.h @@ -53,10 +53,10 @@ class luxor_55_21046_device : public device_t, { public: // construction/destruction - luxor_55_21046_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + luxor_55_21046_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - luxor_55_21046_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + luxor_55_21046_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -127,7 +127,7 @@ class abc830_device : public luxor_55_21046_device { public: // construction/destruction - abc830_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc830_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -142,7 +142,7 @@ class abc832_device : public luxor_55_21046_device { public: // construction/destruction - abc832_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc832_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -157,7 +157,7 @@ class abc834_device : public luxor_55_21046_device { public: // construction/destruction - abc834_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc834_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -172,7 +172,7 @@ class abc838_device : public luxor_55_21046_device { public: // construction/destruction - abc838_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc838_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -187,7 +187,7 @@ class abc850_floppy_device : public luxor_55_21046_device { public: // construction/destruction - abc850_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc850_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/abcbus/lux21056.cpp b/src/devices/bus/abcbus/lux21056.cpp index f14ea5a0f68..970ced7ab57 100644 --- a/src/devices/bus/abcbus/lux21056.cpp +++ b/src/devices/bus/abcbus/lux21056.cpp @@ -334,7 +334,7 @@ ioport_constructor luxor_55_21056_device::device_input_ports() const // luxor_55_21056_device - constructor //------------------------------------------------- -luxor_55_21056_device::luxor_55_21056_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +luxor_55_21056_device::luxor_55_21056_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LUXOR_55_21056, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_maincpu(*this, Z80_TAG), diff --git a/src/devices/bus/abcbus/lux21056.h b/src/devices/bus/abcbus/lux21056.h index 812bb8325a3..c7f06bf2b30 100644 --- a/src/devices/bus/abcbus/lux21056.h +++ b/src/devices/bus/abcbus/lux21056.h @@ -30,7 +30,7 @@ class luxor_55_21056_device : public device_t, { public: // construction/destruction - luxor_55_21056_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + luxor_55_21056_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/abcbus/lux4105.cpp b/src/devices/bus/abcbus/lux4105.cpp index 324fd542ac7..48369bb8f82 100644 --- a/src/devices/bus/abcbus/lux4105.cpp +++ b/src/devices/bus/abcbus/lux4105.cpp @@ -136,7 +136,7 @@ ioport_constructor luxor_4105_device::device_input_ports() const // luxor_4105_device - constructor //------------------------------------------------- -luxor_4105_device::luxor_4105_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +luxor_4105_device::luxor_4105_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LUXOR_4105, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_sasi(*this, "sasi:7:scsicb"), diff --git a/src/devices/bus/abcbus/lux4105.h b/src/devices/bus/abcbus/lux4105.h index dde20ad3075..179fa47ca47 100644 --- a/src/devices/bus/abcbus/lux4105.h +++ b/src/devices/bus/abcbus/lux4105.h @@ -30,7 +30,7 @@ class luxor_4105_device : public device_t, { public: // construction/destruction - luxor_4105_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + luxor_4105_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/abcbus/memcard.cpp b/src/devices/bus/abcbus/memcard.cpp index e8cd5464ae7..af82487d28e 100644 --- a/src/devices/bus/abcbus/memcard.cpp +++ b/src/devices/bus/abcbus/memcard.cpp @@ -110,7 +110,7 @@ const tiny_rom_entry *abc_memory_card_device::device_rom_region() const // abc_memory_card_device - constructor //------------------------------------------------- -abc_memory_card_device::abc_memory_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc_memory_card_device::abc_memory_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC_MEMORY_CARD, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_dos_rom(*this, "dos"), diff --git a/src/devices/bus/abcbus/memcard.h b/src/devices/bus/abcbus/memcard.h index dae0a14fd50..09ffc2b4c12 100644 --- a/src/devices/bus/abcbus/memcard.h +++ b/src/devices/bus/abcbus/memcard.h @@ -25,7 +25,7 @@ class abc_memory_card_device : public device_t, public device_abcbus_card_interf { public: // construction/destruction - abc_memory_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc_memory_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/abcbus/ram.cpp b/src/devices/bus/abcbus/ram.cpp index 563964041c5..11b823a2381 100644 --- a/src/devices/bus/abcbus/ram.cpp +++ b/src/devices/bus/abcbus/ram.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(ABC80_16KB_RAM_CARD, abc80_16kb_ram_card_device, "abc80_16kb" // abc80_16kb_ram_card_device - constructor //------------------------------------------------- -abc80_16kb_ram_card_device::abc80_16kb_ram_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc80_16kb_ram_card_device::abc80_16kb_ram_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC80_16KB_RAM_CARD, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_ram(*this, "ram", 0x4000, ENDIANNESS_LITTLE) diff --git a/src/devices/bus/abcbus/ram.h b/src/devices/bus/abcbus/ram.h index cf552c6412f..eb8016f570d 100644 --- a/src/devices/bus/abcbus/ram.h +++ b/src/devices/bus/abcbus/ram.h @@ -25,7 +25,7 @@ class abc80_16kb_ram_card_device : public device_t, public device_abcbus_card_in { public: // construction/destruction - abc80_16kb_ram_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc80_16kb_ram_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/abcbus/sio.cpp b/src/devices/bus/abcbus/sio.cpp index 326d4f07a73..ba3bca1a884 100644 --- a/src/devices/bus/abcbus/sio.cpp +++ b/src/devices/bus/abcbus/sio.cpp @@ -79,7 +79,7 @@ const tiny_rom_entry *abc_sio_device::device_rom_region() const void abc_sio_device::device_add_mconfig(machine_config &config) { Z80CTC(config, m_ctc, XTAL(4'915'200)); - Z80DART(config, m_sio, 0); + Z80DART(config, m_sio); } @@ -92,7 +92,7 @@ void abc_sio_device::device_add_mconfig(machine_config &config) // abc_sio_device - constructor //------------------------------------------------- -abc_sio_device::abc_sio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +abc_sio_device::abc_sio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC_SIO, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_ctc(*this, Z80CTC_TAG), diff --git a/src/devices/bus/abcbus/sio.h b/src/devices/bus/abcbus/sio.h index 156939808df..90e9f364666 100644 --- a/src/devices/bus/abcbus/sio.h +++ b/src/devices/bus/abcbus/sio.h @@ -22,7 +22,7 @@ class abc_sio_device : public device_t, { public: // construction/destruction - abc_sio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc_sio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/abcbus/slutprov.cpp b/src/devices/bus/abcbus/slutprov.cpp index 8ca4bc5934e..79b69ee5863 100644 --- a/src/devices/bus/abcbus/slutprov.cpp +++ b/src/devices/bus/abcbus/slutprov.cpp @@ -41,7 +41,7 @@ const tiny_rom_entry *abc_slutprov_device::device_rom_region() const // abc_slutprov_device - constructor //------------------------------------------------- -abc_slutprov_device::abc_slutprov_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +abc_slutprov_device::abc_slutprov_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC_SLUTPROV, tag, owner, clock), device_abcbus_card_interface(mconfig, *this) { diff --git a/src/devices/bus/abcbus/slutprov.h b/src/devices/bus/abcbus/slutprov.h index 16f6b0e9f79..9eb6319d376 100644 --- a/src/devices/bus/abcbus/slutprov.h +++ b/src/devices/bus/abcbus/slutprov.h @@ -20,7 +20,7 @@ class abc_slutprov_device : public device_t, { public: // construction/destruction - abc_slutprov_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc_slutprov_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/abcbus/ssa.cpp b/src/devices/bus/abcbus/ssa.cpp index c17c2e2a826..e8e79c84822 100644 --- a/src/devices/bus/abcbus/ssa.cpp +++ b/src/devices/bus/abcbus/ssa.cpp @@ -113,7 +113,7 @@ const tiny_rom_entry *abc_super_smartaid_device::device_rom_region() const // abc_super_smartaid_device - constructor //------------------------------------------------- -abc_super_smartaid_device::abc_super_smartaid_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc_super_smartaid_device::abc_super_smartaid_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC_SUPER_SMARTAID, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/bus/abcbus/ssa.h b/src/devices/bus/abcbus/ssa.h index f8f94bd2f93..81cbbdcd3de 100644 --- a/src/devices/bus/abcbus/ssa.h +++ b/src/devices/bus/abcbus/ssa.h @@ -27,7 +27,7 @@ class abc_super_smartaid_device : public device_t, { public: // construction/destruction - abc_super_smartaid_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc_super_smartaid_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/abcbus/uni800.cpp b/src/devices/bus/abcbus/uni800.cpp index 2b38faac748..aa54f6ee2d6 100644 --- a/src/devices/bus/abcbus/uni800.cpp +++ b/src/devices/bus/abcbus/uni800.cpp @@ -72,7 +72,7 @@ const tiny_rom_entry *abc_uni800_device::device_rom_region() const // abc_uni800_device - constructor //------------------------------------------------- -abc_uni800_device::abc_uni800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +abc_uni800_device::abc_uni800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC_UNI800, tag, owner, clock), device_abcbus_card_interface(mconfig, *this) { diff --git a/src/devices/bus/abcbus/uni800.h b/src/devices/bus/abcbus/uni800.h index c6eb9400d40..8d8c341a6d4 100644 --- a/src/devices/bus/abcbus/uni800.h +++ b/src/devices/bus/abcbus/uni800.h @@ -20,7 +20,7 @@ class abc_uni800_device : public device_t, { public: // construction/destruction - abc_uni800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc_uni800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/abcbus/unidisk.cpp b/src/devices/bus/abcbus/unidisk.cpp index 4661bc1fc03..57a429e51aa 100644 --- a/src/devices/bus/abcbus/unidisk.cpp +++ b/src/devices/bus/abcbus/unidisk.cpp @@ -75,7 +75,7 @@ void abc_unidisk_device::unidisk_io(address_map &map) void abc_unidisk_device::device_add_mconfig(machine_config &config) { - TMS9995(config, m_maincpu, 12000000); + TMS9995(config, m_maincpu, XTAL::u(12000000)); m_maincpu->set_addrmap(AS_PROGRAM, &abc_unidisk_device::unidisk_mem); m_maincpu->set_addrmap(AS_IO, &abc_unidisk_device::unidisk_io); } @@ -108,7 +108,7 @@ ioport_constructor abc_unidisk_device::device_input_ports() const // abc_unidisk_device - constructor //------------------------------------------------- -abc_unidisk_device::abc_unidisk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc_unidisk_device::abc_unidisk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC_UNIDISK, tag, owner, clock), device_abcbus_card_interface(mconfig, *this), m_maincpu(*this, TMS9995_TAG) diff --git a/src/devices/bus/abcbus/unidisk.h b/src/devices/bus/abcbus/unidisk.h index 6d95e34208e..54d365e11e9 100644 --- a/src/devices/bus/abcbus/unidisk.h +++ b/src/devices/bus/abcbus/unidisk.h @@ -27,7 +27,7 @@ class abc_unidisk_device : public device_t, { public: // construction/destruction - abc_unidisk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc_unidisk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/abckb/abc77.cpp b/src/devices/bus/abckb/abc77.cpp index 442ff553e2f..38415a5ad66 100644 --- a/src/devices/bus/abckb/abc77.cpp +++ b/src/devices/bus/abckb/abc77.cpp @@ -413,7 +413,7 @@ inline void abc77_device::key_down(int state) // abc77_device - constructor //------------------------------------------------- -abc77_device::abc77_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +abc77_device::abc77_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), abc_keyboard_interface(mconfig, *this), m_maincpu(*this, I8035_TAG), @@ -428,10 +428,10 @@ abc77_device::abc77_device(const machine_config &mconfig, device_type type, cons { } -abc55_device::abc55_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc55_device::abc55_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : abc77_device(mconfig, ABC55, tag, owner, clock) { } -abc77_device::abc77_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc77_device::abc77_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : abc77_device(mconfig, ABC77, tag, owner, clock) { } diff --git a/src/devices/bus/abckb/abc77.h b/src/devices/bus/abckb/abc77.h index 4982c746570..139a2803fd6 100644 --- a/src/devices/bus/abckb/abc77.h +++ b/src/devices/bus/abckb/abc77.h @@ -30,12 +30,12 @@ class abc77_device : public device_t, public abc_keyboard_interface { public: // construction/destruction - abc77_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc77_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER( keyboard_reset ); protected: - abc77_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + abc77_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -89,7 +89,7 @@ class abc55_device : public abc77_device { public: // construction/destruction - abc55_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc55_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/abckb/abc800kb.cpp b/src/devices/bus/abckb/abc800kb.cpp index 39f00d3347c..0bf5ee08193 100644 --- a/src/devices/bus/abckb/abc800kb.cpp +++ b/src/devices/bus/abckb/abc800kb.cpp @@ -317,7 +317,7 @@ void abc800_keyboard_device::key_down(int state) // abc800_keyboard_device - constructor //------------------------------------------------- -abc800_keyboard_device::abc800_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc800_keyboard_device::abc800_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC800_KEYBOARD, tag, owner, clock), abc_keyboard_interface(mconfig, *this), m_maincpu(*this, I8048_TAG), diff --git a/src/devices/bus/abckb/abc800kb.h b/src/devices/bus/abckb/abc800kb.h index 39f54e2f854..0921ce80656 100644 --- a/src/devices/bus/abckb/abc800kb.h +++ b/src/devices/bus/abckb/abc800kb.h @@ -29,7 +29,7 @@ class abc800_keyboard_device : public device_t, { public: // construction/destruction - abc800_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc800_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // abc_keyboard_interface overrides virtual void txd_w(int state) override; diff --git a/src/devices/bus/abckb/abc99.cpp b/src/devices/bus/abckb/abc99.cpp index b1a5c6a0a6d..58f71286e1f 100644 --- a/src/devices/bus/abckb/abc99.cpp +++ b/src/devices/bus/abckb/abc99.cpp @@ -178,7 +178,7 @@ void abc99_device::device_add_mconfig(machine_config &config) // sound hardware SPEAKER(config, "mono").front_center(); - SPEAKER_SOUND(config, m_speaker, 0).add_route(ALL_OUTPUTS, "mono", 0.25); + SPEAKER_SOUND(config, m_speaker).add_route(ALL_OUTPUTS, "mono", 0.25); } @@ -470,7 +470,7 @@ void abc99_device::key_down(int state) // abc99_device - constructor //------------------------------------------------- -abc99_device::abc99_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc99_device::abc99_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC99, tag, owner, clock), abc_keyboard_interface(mconfig, *this), m_serial_timer(nullptr), m_mouse_timer(nullptr), m_maincpu(*this, I8035_Z2_TAG), diff --git a/src/devices/bus/abckb/abc99.h b/src/devices/bus/abckb/abc99.h index d2c30db1f4f..f14ce0376da 100644 --- a/src/devices/bus/abckb/abc99.h +++ b/src/devices/bus/abckb/abc99.h @@ -29,7 +29,7 @@ class abc99_device : public device_t, { public: // construction/destruction - abc99_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + abc99_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER( keyboard_reset ); diff --git a/src/devices/bus/abckb/abckb.cpp b/src/devices/bus/abckb/abckb.cpp index 32af6f47178..af9224d9e78 100644 --- a/src/devices/bus/abckb/abckb.cpp +++ b/src/devices/bus/abckb/abckb.cpp @@ -43,7 +43,7 @@ abc_keyboard_interface::abc_keyboard_interface(const machine_config &mconfig, de // abc_keyboard_port_device - constructor //------------------------------------------------- -abc_keyboard_port_device::abc_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +abc_keyboard_port_device::abc_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ABC_KEYBOARD_PORT, tag, owner, clock), device_single_card_slot_interface<abc_keyboard_interface>(mconfig, *this), m_out_rx_handler(*this), diff --git a/src/devices/bus/abckb/abckb.h b/src/devices/bus/abckb/abckb.h index 63b8b2c799e..2dbb95ac18e 100644 --- a/src/devices/bus/abckb/abckb.h +++ b/src/devices/bus/abckb/abckb.h @@ -24,7 +24,7 @@ public: // construction/destruction template <typename T> abc_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : abc_keyboard_port_device(mconfig, tag, owner, 0) + : abc_keyboard_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -32,7 +32,7 @@ public: set_fixed(false); } - abc_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + abc_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto out_rx_handler() { return m_out_rx_handler.bind(); } auto out_trxc_handler() { return m_out_trxc_handler.bind(); } diff --git a/src/devices/bus/acorn/atom/discpack.cpp b/src/devices/bus/acorn/atom/discpack.cpp index 2f2024b86b0..6b5e185d1bf 100644 --- a/src/devices/bus/acorn/atom/discpack.cpp +++ b/src/devices/bus/acorn/atom/discpack.cpp @@ -67,7 +67,7 @@ const tiny_rom_entry *atom_discpack_device::device_rom_region() const // atom_discpack_device - constructor //------------------------------------------------- -atom_discpack_device::atom_discpack_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atom_discpack_device::atom_discpack_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ATOM_DISCPACK, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_dos_rom(*this, "dos_rom") diff --git a/src/devices/bus/acorn/atom/discpack.h b/src/devices/bus/acorn/atom/discpack.h index cff8a09005d..b679d1d04f0 100644 --- a/src/devices/bus/acorn/atom/discpack.h +++ b/src/devices/bus/acorn/atom/discpack.h @@ -27,7 +27,7 @@ class atom_discpack_device : { public: // construction/destruction - atom_discpack_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atom_discpack_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); diff --git a/src/devices/bus/acorn/atom/econet.cpp b/src/devices/bus/acorn/atom/econet.cpp index 70c92ff3489..e91ef84c2c0 100644 --- a/src/devices/bus/acorn/atom/econet.cpp +++ b/src/devices/bus/acorn/atom/econet.cpp @@ -29,12 +29,12 @@ void atom_econet_device::device_add_mconfig(machine_config &config) m_adlc->out_txd_cb().set(m_econet, FUNC(econet_device::host_data_w)); m_adlc->out_irq_cb().set(FUNC(atom_econet_device::bus_irq_w)); - ECONET(config, m_econet, 0); + ECONET(config, m_econet); m_econet->clk_wr_callback().set(m_adlc, FUNC(mc6854_device::txc_w)); m_econet->clk_wr_callback().append(m_adlc, FUNC(mc6854_device::rxc_w)); m_econet->data_wr_callback().set(m_adlc, FUNC(mc6854_device::set_rx)); - econet_slot_device &slot(ECONET_SLOT(config, "econet254", 0)); + econet_slot_device &slot(ECONET_SLOT(config, "econet254")); econet_devices(slot); slot.set_slot(254); } @@ -47,7 +47,7 @@ void atom_econet_device::device_add_mconfig(machine_config &config) // atom_econet_device - constructor //------------------------------------------------- -atom_econet_device::atom_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atom_econet_device::atom_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ATOM_ECONET, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_adlc(*this, "mc6854") diff --git a/src/devices/bus/acorn/atom/econet.h b/src/devices/bus/acorn/atom/econet.h index 114dc76bbeb..a9f428c9107 100644 --- a/src/devices/bus/acorn/atom/econet.h +++ b/src/devices/bus/acorn/atom/econet.h @@ -26,7 +26,7 @@ class atom_econet_device : { public: // construction/destruction - atom_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atom_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/acorn/atom/sid.cpp b/src/devices/bus/acorn/atom/sid.cpp index 4b0e1f7ff4d..f1fe9e0781d 100644 --- a/src/devices/bus/acorn/atom/sid.cpp +++ b/src/devices/bus/acorn/atom/sid.cpp @@ -39,7 +39,7 @@ void atom_sid_device::device_add_mconfig(machine_config &config) // atom_sid_device - constructor //------------------------------------------------- -atom_sid_device::atom_sid_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atom_sid_device::atom_sid_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ATOM_SID, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_sid(*this, "sid6581") diff --git a/src/devices/bus/acorn/atom/sid.h b/src/devices/bus/acorn/atom/sid.h index 8383bbdf9c8..f52841eb9ff 100644 --- a/src/devices/bus/acorn/atom/sid.h +++ b/src/devices/bus/acorn/atom/sid.h @@ -25,7 +25,7 @@ class atom_sid_device : { public: // construction/destruction - atom_sid_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atom_sid_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/acorn/bus.cpp b/src/devices/bus/acorn/bus.cpp index 55f332e6581..4c0b40bfc13 100644 --- a/src/devices/bus/acorn/bus.cpp +++ b/src/devices/bus/acorn/bus.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(ACORN_BUS_SLOT, acorn_bus_slot_device, "acorn_bus_slot", "Aco //------------------------------------------------- // acorn_bus_slot_device - constructor //------------------------------------------------- -acorn_bus_slot_device::acorn_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_bus_slot_device::acorn_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_BUS_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_acorn_bus_interface>(mconfig, *this) , m_bus(*this, finder_base::DUMMY_TAG) @@ -62,7 +62,7 @@ DEFINE_DEVICE_TYPE(ACORN_BUS, acorn_bus_device, "acorn_bus", "Acorn Bus") // acorn_bus_device - constructor //------------------------------------------------- -acorn_bus_device::acorn_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_bus_device::acorn_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_BUS, tag, owner, clock) , m_space(*this, finder_base::DUMMY_TAG, -1) , m_out_irq_cb(*this) diff --git a/src/devices/bus/acorn/bus.h b/src/devices/bus/acorn/bus.h index bfd9a980304..6422fd5df88 100644 --- a/src/devices/bus/acorn/bus.h +++ b/src/devices/bus/acorn/bus.h @@ -32,7 +32,7 @@ public: // construction/destruction template <typename T, typename U> acorn_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&bus_tag, U &&opts, const char *dflt) - : acorn_bus_slot_device(mconfig, tag, owner, 0) + : acorn_bus_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -40,7 +40,7 @@ public: set_fixed(false); m_bus.set_tag(std::forward<T>(bus_tag)); } - acorn_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device-level overrides @@ -60,7 +60,7 @@ class acorn_bus_device : public device_t { public: // construction/destruction - acorn_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration template <typename T> void set_space(T &&tag, int spacenum) { m_space.set_tag(std::forward<T>(tag), spacenum); } diff --git a/src/devices/bus/acorn/cms/4080term.cpp b/src/devices/bus/acorn/cms/4080term.cpp index 97946af1406..a7fa28b6be8 100644 --- a/src/devices/bus/acorn/cms/4080term.cpp +++ b/src/devices/bus/acorn/cms/4080term.cpp @@ -77,7 +77,7 @@ void cms_4080term_device::device_add_mconfig(machine_config &config) GFXDECODE(config, "gfxdecode", "palette", gfx_cms_4080term); PALETTE(config, "palette", palette_device::RGB_3BIT); - EF9345(config, m_ef9345, 0); + EF9345(config, m_ef9345); m_ef9345->set_screen("screen"); m_ef9345->set_palette_tag("palette"); @@ -88,7 +88,7 @@ void cms_4080term_device::device_add_mconfig(machine_config &config) m_via->ca2_handler().set(m_centronics, FUNC(centronics_device::write_strobe)); m_via->irq_handler().set(FUNC(cms_4080term_device::bus_irq_w)); - MOS6551(config, m_acia, 0); + MOS6551(config, m_acia); m_acia->set_xtal(1.8432_MHz_XTAL); m_acia->txd_handler().set(m_rs232, FUNC(rs232_port_device::write_txd)); m_acia->rts_handler().set(m_rs232, FUNC(rs232_port_device::write_rts)); @@ -123,7 +123,7 @@ const tiny_rom_entry *cms_4080term_device::device_rom_region() const // cms_4080term_device - constructor //------------------------------------------------- -cms_4080term_device::cms_4080term_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cms_4080term_device::cms_4080term_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CMS_4080TERM, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_via(*this, "via") diff --git a/src/devices/bus/acorn/cms/4080term.h b/src/devices/bus/acorn/cms/4080term.h index 14d1beacd43..7d98c67d76c 100644 --- a/src/devices/bus/acorn/cms/4080term.h +++ b/src/devices/bus/acorn/cms/4080term.h @@ -30,7 +30,7 @@ class cms_4080term_device : { public: // construction/destruction - cms_4080term_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cms_4080term_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); TIMER_DEVICE_CALLBACK_MEMBER(update_scanline); diff --git a/src/devices/bus/acorn/cms/fdc.cpp b/src/devices/bus/acorn/cms/fdc.cpp index f918309bb76..40c4637059d 100644 --- a/src/devices/bus/acorn/cms/fdc.cpp +++ b/src/devices/bus/acorn/cms/fdc.cpp @@ -56,7 +56,7 @@ void cms_fdc_device::device_add_mconfig(machine_config &config) // cms_fdc_device - constructor //------------------------------------------------- -cms_fdc_device::cms_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cms_fdc_device::cms_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CMS_FDC, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_fdc(*this, "wd1770") diff --git a/src/devices/bus/acorn/cms/fdc.h b/src/devices/bus/acorn/cms/fdc.h index 99a92c34dc7..4b26fbe261c 100644 --- a/src/devices/bus/acorn/cms/fdc.h +++ b/src/devices/bus/acorn/cms/fdc.h @@ -27,7 +27,7 @@ class cms_fdc_device : { public: // construction/destruction - cms_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cms_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); diff --git a/src/devices/bus/acorn/cms/hires.cpp b/src/devices/bus/acorn/cms/hires.cpp index de42be218cd..080801881fa 100644 --- a/src/devices/bus/acorn/cms/hires.cpp +++ b/src/devices/bus/acorn/cms/hires.cpp @@ -53,7 +53,7 @@ void cms_hires_device::device_add_mconfig(machine_config &config) // cms_hires_device - constructor //------------------------------------------------- -cms_hires_device::cms_hires_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cms_hires_device::cms_hires_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CMS_HIRES, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_screen(*this, "screen") diff --git a/src/devices/bus/acorn/cms/hires.h b/src/devices/bus/acorn/cms/hires.h index f79d7af383b..d02018e2f9d 100644 --- a/src/devices/bus/acorn/cms/hires.h +++ b/src/devices/bus/acorn/cms/hires.h @@ -26,7 +26,7 @@ class cms_hires_device : { public: // construction/destruction - cms_hires_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cms_hires_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/acorn/cms/ieee.cpp b/src/devices/bus/acorn/cms/ieee.cpp index 06d9b47f0dd..b53a265aed5 100644 --- a/src/devices/bus/acorn/cms/ieee.cpp +++ b/src/devices/bus/acorn/cms/ieee.cpp @@ -58,7 +58,7 @@ void cms_ieee_device::device_add_mconfig(machine_config &config) // cms_ieee_device - constructor //------------------------------------------------- -cms_ieee_device::cms_ieee_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cms_ieee_device::cms_ieee_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CMS_IEEE, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_ieee(*this, IEEE488_TAG) diff --git a/src/devices/bus/acorn/cms/ieee.h b/src/devices/bus/acorn/cms/ieee.h index 48352d4a100..c77abce6dd1 100644 --- a/src/devices/bus/acorn/cms/ieee.h +++ b/src/devices/bus/acorn/cms/ieee.h @@ -24,7 +24,7 @@ class cms_ieee_device: { public: // construction/destruction - cms_ieee_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cms_ieee_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/acorn/system/32k.cpp b/src/devices/bus/acorn/system/32k.cpp index 00eb80050e9..6d6673fb00a 100644 --- a/src/devices/bus/acorn/system/32k.cpp +++ b/src/devices/bus/acorn/system/32k.cpp @@ -60,7 +60,7 @@ ioport_constructor acorn_32k_device::device_input_ports() const // acorn_32k_device - constructor //------------------------------------------------- -acorn_32k_device::acorn_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_32k_device::acorn_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_32K, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_links(*this, "LINKS") diff --git a/src/devices/bus/acorn/system/32k.h b/src/devices/bus/acorn/system/32k.h index f3d3b76be5c..9dc5ba37b51 100644 --- a/src/devices/bus/acorn/system/32k.h +++ b/src/devices/bus/acorn/system/32k.h @@ -26,7 +26,7 @@ class acorn_32k_device : { public: // construction/destruction - acorn_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/acorn/system/8k.cpp b/src/devices/bus/acorn/system/8k.cpp index b2e1c7bb3d2..e48d9f908a6 100644 --- a/src/devices/bus/acorn/system/8k.cpp +++ b/src/devices/bus/acorn/system/8k.cpp @@ -83,7 +83,7 @@ void acorn_8k_device::device_add_mconfig(machine_config &config) // acorn_8k_device - constructor //------------------------------------------------- -acorn_8k_device::acorn_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_8k_device::acorn_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_8K, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_rom(*this, "rom%u", 0) diff --git a/src/devices/bus/acorn/system/8k.h b/src/devices/bus/acorn/system/8k.h index 09f089c1563..6420f6383fe 100644 --- a/src/devices/bus/acorn/system/8k.h +++ b/src/devices/bus/acorn/system/8k.h @@ -29,7 +29,7 @@ class acorn_8k_device : { public: // construction/destruction - acorn_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/acorn/system/cass.cpp b/src/devices/bus/acorn/system/cass.cpp index 6e5b8faf40c..98f239ea930 100644 --- a/src/devices/bus/acorn/system/cass.cpp +++ b/src/devices/bus/acorn/system/cass.cpp @@ -30,7 +30,7 @@ void acorn_cass_device::device_add_mconfig(machine_config &config) SPEAKER(config, "mono").front_center(); WAVE(config, "wave", "cassette").add_route(ALL_OUTPUTS, "mono", 0.25); - CASSETTE(config, "cassette", 0); + CASSETTE(config, "cassette"); TIMER(config, "cass_c").configure_periodic(FUNC(acorn_cass_device::cass_c), attotime::from_hz(4800)); TIMER(config, "cass_p").configure_periodic(FUNC(acorn_cass_device::cass_p), attotime::from_hz(40000)); } @@ -44,7 +44,7 @@ void acorn_cass_device::device_add_mconfig(machine_config &config) // acorn_cass_device - constructor //------------------------------------------------- -acorn_cass_device::acorn_cass_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_cass_device::acorn_cass_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_CASS, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_cass(*this, "cassette") diff --git a/src/devices/bus/acorn/system/cass.h b/src/devices/bus/acorn/system/cass.h index 02a323bb994..23e6b79eb8d 100644 --- a/src/devices/bus/acorn/system/cass.h +++ b/src/devices/bus/acorn/system/cass.h @@ -28,7 +28,7 @@ class acorn_cass_device : { public: // construction/destruction - acorn_cass_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_cass_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/acorn/system/econet.cpp b/src/devices/bus/acorn/system/econet.cpp index f8a0737e456..e24fb7ea53d 100644 --- a/src/devices/bus/acorn/system/econet.cpp +++ b/src/devices/bus/acorn/system/econet.cpp @@ -30,7 +30,7 @@ void acorn_econet_device::device_add_mconfig(machine_config &config) m_adlc->out_txd_cb().set(m_econet, FUNC(econet_device::host_data_w)); m_adlc->out_irq_cb().set(FUNC(acorn_econet_device::bus_irq_w)); - ECONET(config, m_econet, 0); + ECONET(config, m_econet); m_econet->clk_wr_callback().set(m_adlc, FUNC(mc6854_device::txc_w)); m_econet->clk_wr_callback().append(m_adlc, FUNC(mc6854_device::rxc_w)); m_econet->data_wr_callback().set(m_adlc, FUNC(mc6854_device::set_rx)); @@ -46,7 +46,7 @@ void acorn_econet_device::device_add_mconfig(machine_config &config) // acorn_econet_device - constructor //------------------------------------------------- -acorn_econet_device::acorn_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_econet_device::acorn_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_ECONET, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_adlc(*this, "mc6854") diff --git a/src/devices/bus/acorn/system/econet.h b/src/devices/bus/acorn/system/econet.h index b5e470975c9..07d3e15ce8c 100644 --- a/src/devices/bus/acorn/system/econet.h +++ b/src/devices/bus/acorn/system/econet.h @@ -28,7 +28,7 @@ class acorn_econet_device : { public: // construction/destruction - acorn_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/acorn/system/fdc.cpp b/src/devices/bus/acorn/system/fdc.cpp index 397fbb9ac50..a77bd3c933b 100644 --- a/src/devices/bus/acorn/system/fdc.cpp +++ b/src/devices/bus/acorn/system/fdc.cpp @@ -61,7 +61,7 @@ void acorn_fdc_device::device_add_mconfig(machine_config &config) // acorn_fdc_device - constructor //------------------------------------------------- -acorn_fdc_device::acorn_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_fdc_device::acorn_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_FDC, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_fdc(*this, "i8271") diff --git a/src/devices/bus/acorn/system/fdc.h b/src/devices/bus/acorn/system/fdc.h index f943b1f6767..60c68f670e9 100644 --- a/src/devices/bus/acorn/system/fdc.h +++ b/src/devices/bus/acorn/system/fdc.h @@ -29,7 +29,7 @@ class acorn_fdc_device : { public: // construction/destruction - acorn_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); diff --git a/src/devices/bus/acorn/system/vdu40.cpp b/src/devices/bus/acorn/system/vdu40.cpp index 7bc8629ac35..236848d5294 100644 --- a/src/devices/bus/acorn/system/vdu40.cpp +++ b/src/devices/bus/acorn/system/vdu40.cpp @@ -53,7 +53,7 @@ void acorn_vdu40_device::device_add_mconfig(machine_config &config) // acorn_vdu40_device - constructor //------------------------------------------------- -acorn_vdu40_device::acorn_vdu40_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_vdu40_device::acorn_vdu40_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_VDU40, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_screen(*this, "screen") diff --git a/src/devices/bus/acorn/system/vdu40.h b/src/devices/bus/acorn/system/vdu40.h index ff80a76d1ea..1b961343cb4 100644 --- a/src/devices/bus/acorn/system/vdu40.h +++ b/src/devices/bus/acorn/system/vdu40.h @@ -30,7 +30,7 @@ class acorn_vdu40_device : { public: // construction/destruction - acorn_vdu40_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_vdu40_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/acorn/system/vdu80.cpp b/src/devices/bus/acorn/system/vdu80.cpp index 77bad0bf32c..e3bb1f6fb43 100644 --- a/src/devices/bus/acorn/system/vdu80.cpp +++ b/src/devices/bus/acorn/system/vdu80.cpp @@ -118,7 +118,7 @@ const tiny_rom_entry *acorn_vdu80_device::device_rom_region() const // acorn_vdu80_device - constructor //------------------------------------------------- -acorn_vdu80_device::acorn_vdu80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_vdu80_device::acorn_vdu80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_VDU80, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_chargen(*this, "chargen") diff --git a/src/devices/bus/acorn/system/vdu80.h b/src/devices/bus/acorn/system/vdu80.h index 8ebb7e0a327..2f1c33d7d76 100644 --- a/src/devices/bus/acorn/system/vdu80.h +++ b/src/devices/bus/acorn/system/vdu80.h @@ -29,7 +29,7 @@ class acorn_vdu80_device : { public: // construction/destruction - acorn_vdu80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_vdu80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/acorn/system/vib.cpp b/src/devices/bus/acorn/system/vib.cpp index bf685daac95..4a4be409e40 100644 --- a/src/devices/bus/acorn/system/vib.cpp +++ b/src/devices/bus/acorn/system/vib.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(ACORN_VIB, acorn_vib_device, "acorn_vib", "Acorn Versatile In // acorn_vib_device - constructor //------------------------------------------------- -acorn_vib_device::acorn_vib_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_vib_device::acorn_vib_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_VIB, tag, owner, clock) , device_acorn_bus_interface(mconfig, *this) , m_ppi8255(*this, "ppi8255") @@ -149,7 +149,7 @@ void acorn_vib_device::device_add_mconfig(machine_config &config) { INPUT_MERGER_ANY_HIGH(config, m_irqs).output_handler().set(FUNC(acorn_vib_device::irq_w)); - MOS6522(config, m_via6522, 1'000'000); // TODO: derive clock from bus (pin 29 = ϕ2) + MOS6522(config, m_via6522, XTAL::u(1'000'000)); // TODO: derive clock from bus (pin 29 = ϕ2) m_via6522->writepa_handler().set("cent_data_out", FUNC(output_latch_device::write)); m_via6522->ca2_handler().set(m_centronics, FUNC(centronics_device::write_strobe)); m_via6522->irq_handler().set(m_irqs, FUNC(input_merger_device::in_w<0>)); diff --git a/src/devices/bus/acorn/system/vib.h b/src/devices/bus/acorn/system/vib.h index bd4d886e281..e5d6ad34ccd 100644 --- a/src/devices/bus/acorn/system/vib.h +++ b/src/devices/bus/acorn/system/vib.h @@ -33,7 +33,7 @@ class acorn_vib_device : { public: // construction/destruction - acorn_vib_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_vib_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/adam/adamlink.cpp b/src/devices/bus/adam/adamlink.cpp index 4dc2d44b3d7..b8a5d7d14f1 100644 --- a/src/devices/bus/adam/adamlink.cpp +++ b/src/devices/bus/adam/adamlink.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(ADAMLINK, adamlink_device, "adamlink", "AdamLink modem") // adamlink_device - constructor //------------------------------------------------- -adamlink_device::adamlink_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adamlink_device::adamlink_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAMLINK, tag, owner, clock) , device_adam_expansion_slot_card_interface(mconfig, *this) { diff --git a/src/devices/bus/adam/adamlink.h b/src/devices/bus/adam/adamlink.h index 6fb07f81c6f..ed2a2c04769 100644 --- a/src/devices/bus/adam/adamlink.h +++ b/src/devices/bus/adam/adamlink.h @@ -26,7 +26,7 @@ class adamlink_device : public device_t, { public: // construction/destruction - adamlink_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adamlink_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/adam/exp.cpp b/src/devices/bus/adam/exp.cpp index 5a2098b2cfe..01929356ab5 100644 --- a/src/devices/bus/adam/exp.cpp +++ b/src/devices/bus/adam/exp.cpp @@ -51,7 +51,7 @@ device_adam_expansion_slot_card_interface::device_adam_expansion_slot_card_inter // adam_expansion_slot_device - constructor //------------------------------------------------- -adam_expansion_slot_device::adam_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adam_expansion_slot_device::adam_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAM_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_adam_expansion_slot_card_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/adam/exp.h b/src/devices/bus/adam/exp.h index 01d73774bdb..09c399684aa 100644 --- a/src/devices/bus/adam/exp.h +++ b/src/devices/bus/adam/exp.h @@ -29,7 +29,7 @@ class adam_expansion_slot_device : public device_t, public: // construction/destruction template <typename T> - adam_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) + adam_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts, char const *dflt) : adam_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -37,7 +37,7 @@ public: set_default_option(dflt); set_fixed(false); } - adam_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adam_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~adam_expansion_slot_device() { } auto irq() { return m_write_irq.bind(); } diff --git a/src/devices/bus/adam/ide.cpp b/src/devices/bus/adam/ide.cpp index 114e9eeb2e6..eb2b35a1eea 100644 --- a/src/devices/bus/adam/ide.cpp +++ b/src/devices/bus/adam/ide.cpp @@ -81,7 +81,7 @@ void powermate_ide_device::device_add_mconfig(machine_config &config) // powermate_ide_device - constructor //------------------------------------------------- -powermate_ide_device::powermate_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +powermate_ide_device::powermate_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAM_IDE, tag, owner, clock), device_adam_expansion_slot_card_interface(mconfig, *this), m_ata(*this, ATA_TAG), diff --git a/src/devices/bus/adam/ide.h b/src/devices/bus/adam/ide.h index fc01088eeec..9908e5661df 100644 --- a/src/devices/bus/adam/ide.h +++ b/src/devices/bus/adam/ide.h @@ -28,7 +28,7 @@ class powermate_ide_device : public device_t, { public: // construction/destruction - powermate_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + powermate_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/adam/ram.cpp b/src/devices/bus/adam/ram.cpp index 65dc13f2246..232d2566839 100644 --- a/src/devices/bus/adam/ram.cpp +++ b/src/devices/bus/adam/ram.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(ADAM_RAM, adam_ram_expansion_device, "adam_ram", "Adam 64KB R // adam_ram_expansion_device - constructor //------------------------------------------------- -adam_ram_expansion_device::adam_ram_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adam_ram_expansion_device::adam_ram_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAM_RAM, tag, owner, clock), device_adam_expansion_slot_card_interface(mconfig, *this), m_ram(*this, "ram", 0x10000, ENDIANNESS_LITTLE) diff --git a/src/devices/bus/adam/ram.h b/src/devices/bus/adam/ram.h index c1997bf77c4..984e5870fea 100644 --- a/src/devices/bus/adam/ram.h +++ b/src/devices/bus/adam/ram.h @@ -26,7 +26,7 @@ class adam_ram_expansion_device : public device_t, { public: // construction/destruction - adam_ram_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adam_ram_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/adamnet/adamnet.cpp b/src/devices/bus/adamnet/adamnet.cpp index 18b91c4fb8c..db559db9125 100644 --- a/src/devices/bus/adamnet/adamnet.cpp +++ b/src/devices/bus/adamnet/adamnet.cpp @@ -52,7 +52,7 @@ device_adamnet_card_interface::~device_adamnet_card_interface() //------------------------------------------------- // adamnet_slot_device - constructor //------------------------------------------------- -adamnet_slot_device::adamnet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adamnet_slot_device::adamnet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAMNET_SLOT, tag, owner, clock), device_single_card_slot_interface<device_adamnet_card_interface>(mconfig, *this), m_bus(*this, finder_base::DUMMY_TAG) @@ -80,7 +80,7 @@ void adamnet_slot_device::device_start() // adamnet_device - constructor //------------------------------------------------- -adamnet_device::adamnet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adamnet_device::adamnet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAMNET, tag, owner, clock), m_txd(1), m_reset(CLEAR_LINE) diff --git a/src/devices/bus/adamnet/adamnet.h b/src/devices/bus/adamnet/adamnet.h index a064ce24f2f..9489721f9b4 100644 --- a/src/devices/bus/adamnet/adamnet.h +++ b/src/devices/bus/adamnet/adamnet.h @@ -26,7 +26,7 @@ class adamnet_device : public device_t { public: // construction/destruction - adamnet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adamnet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void add_device(device_t *target); @@ -76,7 +76,7 @@ public: // construction/destruction template <typename T, typename U> adamnet_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bus, U &&opts, char const *dflt) - : adamnet_slot_device(mconfig, tag, owner, (uint32_t)0) + : adamnet_slot_device(mconfig, tag, owner) { set_bus(std::forward<T>(bus)); option_reset(); @@ -84,7 +84,7 @@ public: set_default_option(dflt); set_fixed(false); } - adamnet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adamnet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device-level overrides diff --git a/src/devices/bus/adamnet/ddp.cpp b/src/devices/bus/adamnet/ddp.cpp index b4a17e909cd..57978229adc 100644 --- a/src/devices/bus/adamnet/ddp.cpp +++ b/src/devices/bus/adamnet/ddp.cpp @@ -103,7 +103,7 @@ void adam_digital_data_pack_device::device_add_mconfig(machine_config &config) // adam_digital_data_pack_device - constructor //------------------------------------------------- -adam_digital_data_pack_device::adam_digital_data_pack_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adam_digital_data_pack_device::adam_digital_data_pack_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAM_DDP, tag, owner, clock), device_adamnet_card_interface(mconfig, *this), m_maincpu(*this, M6801_TAG), diff --git a/src/devices/bus/adamnet/ddp.h b/src/devices/bus/adamnet/ddp.h index c6fa66f98d3..aaeeb32af69 100644 --- a/src/devices/bus/adamnet/ddp.h +++ b/src/devices/bus/adamnet/ddp.h @@ -29,7 +29,7 @@ class adam_digital_data_pack_device : public device_t, { public: // construction/destruction - adam_digital_data_pack_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adam_digital_data_pack_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/adamnet/fdc.cpp b/src/devices/bus/adamnet/fdc.cpp index 1b7753cfe17..25db73483c4 100644 --- a/src/devices/bus/adamnet/fdc.cpp +++ b/src/devices/bus/adamnet/fdc.cpp @@ -163,7 +163,7 @@ ioport_constructor adam_fdc_device::device_input_ports() const // adam_fdc_device - constructor //------------------------------------------------- -adam_fdc_device::adam_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adam_fdc_device::adam_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAM_FDC, tag, owner, clock), device_adamnet_card_interface(mconfig, *this), m_maincpu(*this, M6801_TAG), diff --git a/src/devices/bus/adamnet/fdc.h b/src/devices/bus/adamnet/fdc.h index d4d1cc33a01..95e499d1b46 100644 --- a/src/devices/bus/adamnet/fdc.h +++ b/src/devices/bus/adamnet/fdc.h @@ -30,7 +30,7 @@ class adam_fdc_device : public device_t, { public: // construction/destruction - adam_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adam_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/adamnet/kb.cpp b/src/devices/bus/adamnet/kb.cpp index 840bb898e25..bb250c83ec4 100644 --- a/src/devices/bus/adamnet/kb.cpp +++ b/src/devices/bus/adamnet/kb.cpp @@ -210,7 +210,7 @@ ioport_constructor adam_keyboard_device::device_input_ports() const // adam_keyboard_device - constructor //------------------------------------------------- -adam_keyboard_device::adam_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adam_keyboard_device::adam_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAM_KB, tag, owner, clock), device_adamnet_card_interface(mconfig, *this), m_maincpu(*this, M6801_TAG), diff --git a/src/devices/bus/adamnet/kb.h b/src/devices/bus/adamnet/kb.h index 167ff1fc46d..3eb9f3de7a0 100644 --- a/src/devices/bus/adamnet/kb.h +++ b/src/devices/bus/adamnet/kb.h @@ -27,7 +27,7 @@ class adam_keyboard_device : public device_t, { public: // construction/destruction - adam_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adam_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/adamnet/printer.cpp b/src/devices/bus/adamnet/printer.cpp index 841fa76b138..ea0d5f5f188 100644 --- a/src/devices/bus/adamnet/printer.cpp +++ b/src/devices/bus/adamnet/printer.cpp @@ -85,7 +85,7 @@ void adam_printer_device::device_add_mconfig(machine_config &config) // adam_printer_device - constructor //------------------------------------------------- -adam_printer_device::adam_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adam_printer_device::adam_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAM_PRN, tag, owner, clock), device_adamnet_card_interface(mconfig, *this), m_maincpu(*this, M6801_TAG) diff --git a/src/devices/bus/adamnet/printer.h b/src/devices/bus/adamnet/printer.h index 376db4a9a99..1c71e9709e7 100644 --- a/src/devices/bus/adamnet/printer.h +++ b/src/devices/bus/adamnet/printer.h @@ -27,7 +27,7 @@ class adam_printer_device : public device_t, { public: // construction/destruction - adam_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adam_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/adamnet/spi.cpp b/src/devices/bus/adamnet/spi.cpp index 008a99a2bfa..d7756d9dfcb 100644 --- a/src/devices/bus/adamnet/spi.cpp +++ b/src/devices/bus/adamnet/spi.cpp @@ -83,7 +83,7 @@ void adam_spi_device::device_add_mconfig(machine_config &config) // adam_spi_device - constructor //------------------------------------------------- -adam_spi_device::adam_spi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adam_spi_device::adam_spi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADAM_SPI, tag, owner, clock) , device_adamnet_card_interface(mconfig, *this) , m_maincpu(*this, "m6801") diff --git a/src/devices/bus/adamnet/spi.h b/src/devices/bus/adamnet/spi.h index 36e2ba60789..404058b958b 100644 --- a/src/devices/bus/adamnet/spi.h +++ b/src/devices/bus/adamnet/spi.h @@ -30,7 +30,7 @@ class adam_spi_device : public device_t, { public: // construction/destruction - adam_spi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adam_spi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/adb/a9m0330.cpp b/src/devices/bus/adb/a9m0330.cpp index 8d3f9226299..adc6d810df3 100644 --- a/src/devices/bus/adb/a9m0330.cpp +++ b/src/devices/bus/adb/a9m0330.cpp @@ -185,7 +185,7 @@ const tiny_rom_entry *a9m0330_device::device_rom_region() const DEVICE IMPLEMENTATION ***************************************************************************/ -a9m0330_device::a9m0330_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +a9m0330_device::a9m0330_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adb_device(mconfig, ADB_A9M0330, tag, owner, clock), adb_slot_card_interface(mconfig, *this, DEVICE_SELF) , m_mcu(*this, "mcu") diff --git a/src/devices/bus/adb/a9m0330.h b/src/devices/bus/adb/a9m0330.h index 1d44a28bba8..c376aca62d3 100644 --- a/src/devices/bus/adb/a9m0330.h +++ b/src/devices/bus/adb/a9m0330.h @@ -14,7 +14,7 @@ class a9m0330_device : public adb_device, public adb_slot_card_interface { public: - a9m0330_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + a9m0330_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/adb/a9m0331.cpp b/src/devices/bus/adb/a9m0331.cpp index f0178dc4386..4e9e14067e0 100644 --- a/src/devices/bus/adb/a9m0331.cpp +++ b/src/devices/bus/adb/a9m0331.cpp @@ -52,7 +52,7 @@ ioport_constructor a9m0331_device::device_input_ports() const -------------------------------------------------*/ void a9m0331_device::device_add_mconfig(machine_config &config) { - M68705P3(config, m_mcu, 2048000); + M68705P3(config, m_mcu, XTAL::u(2048000)); m_mcu->porta_r().set(FUNC(a9m0331_device::mcu_port_a_r)); m_mcu->portb_r().set(FUNC(a9m0331_device::mcu_port_b_r)); m_mcu->portc_r().set(FUNC(a9m0331_device::mcu_port_c_r)); @@ -73,7 +73,7 @@ const tiny_rom_entry *a9m0331_device::device_rom_region() const DEVICE IMPLEMENTATION ***************************************************************************/ -a9m0331_device::a9m0331_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a9m0331_device::a9m0331_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adb_device(mconfig, ADB_A9M0331, tag, owner, clock), adb_slot_card_interface(mconfig, *this, DEVICE_SELF), m_mcu(*this, "mcu") diff --git a/src/devices/bus/adb/a9m0331.h b/src/devices/bus/adb/a9m0331.h index f6fd1d145ab..cf6e94e394b 100644 --- a/src/devices/bus/adb/a9m0331.h +++ b/src/devices/bus/adb/a9m0331.h @@ -14,7 +14,7 @@ class a9m0331_device : public adb_device, public adb_slot_card_interface { public: - a9m0331_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a9m0331_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/adb/adb.cpp b/src/devices/bus/adb/adb.cpp index cdf0810369a..913dc1ad024 100644 --- a/src/devices/bus/adb/adb.cpp +++ b/src/devices/bus/adb/adb.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(ADB_CONNECTOR, adb_connector, "adbslot", "ADB connector") -adb_connector::adb_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adb_connector::adb_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADB_CONNECTOR, tag, owner, clock), device_single_card_slot_interface<adb_slot_card_interface>(mconfig, *this) { @@ -43,7 +43,7 @@ adb_slot_card_interface::adb_slot_card_interface(const machine_config &mconfig, -adb_device::adb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +adb_device::adb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_adb_cb(*this), m_poweron_cb(*this) diff --git a/src/devices/bus/adb/adb.h b/src/devices/bus/adb/adb.h index e6b15e8f61d..db4be20dcf5 100644 --- a/src/devices/bus/adb/adb.h +++ b/src/devices/bus/adb/adb.h @@ -20,7 +20,7 @@ class adb_connector: public device_t, public device_single_card_slot_interface<a public: template <typename T> adb_connector(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt, bool fixed = false) - : adb_connector(mconfig, tag, owner, 0) + : adb_connector(mconfig, tag, owner) { option_reset(); opts(*this); @@ -28,7 +28,7 @@ public: set_fixed(fixed); } - adb_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + adb_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~adb_connector() = default; adb_device *get_device(); @@ -58,7 +58,7 @@ public: static void default_devices(device_slot_interface &device); protected: - adb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + adb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/adb/adbhle.cpp b/src/devices/bus/adb/adbhle.cpp index 369595ef143..2c756a26b35 100644 --- a/src/devices/bus/adb/adbhle.cpp +++ b/src/devices/bus/adb/adbhle.cpp @@ -10,7 +10,7 @@ DEFINE_DEVICE_TYPE(ADB_HLE, adb_hle_device, "adbhle", "ADB HLE") -adb_hle_device::adb_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adb_hle_device::adb_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adb_device(mconfig, ADB_HLE, tag, owner, clock), adb_slot_card_interface(mconfig, *this, DEVICE_SELF) { diff --git a/src/devices/bus/adb/adbhle.h b/src/devices/bus/adb/adbhle.h index 24dff3ad2fe..46146339f92 100644 --- a/src/devices/bus/adb/adbhle.h +++ b/src/devices/bus/adb/adbhle.h @@ -15,7 +15,7 @@ class adb_hle_device : public adb_device, public adb_slot_card_interface { public: - adb_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adb_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/amiga/keyboard/a1200.cpp b/src/devices/bus/amiga/keyboard/a1200.cpp index 4877903d73a..76ee506b8bc 100644 --- a/src/devices/bus/amiga/keyboard/a1200.cpp +++ b/src/devices/bus/amiga/keyboard/a1200.cpp @@ -102,7 +102,7 @@ ROM_END // LIVE DEVICE //************************************************************************** -a1200_kbd_device::a1200_kbd_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +a1200_kbd_device::a1200_kbd_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, A1200_KBD, tag, owner, clock) , device_amiga_keyboard_interface(mconfig, *this) , m_rows(*this, "ROW%u", 0) diff --git a/src/devices/bus/amiga/keyboard/a1200.h b/src/devices/bus/amiga/keyboard/a1200.h index 4cbba0616db..6131db77149 100644 --- a/src/devices/bus/amiga/keyboard/a1200.h +++ b/src/devices/bus/amiga/keyboard/a1200.h @@ -24,7 +24,7 @@ class a1200_kbd_device : public device_t, public device_amiga_keyboard_interface { public: // construction/destruction - a1200_kbd_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + a1200_kbd_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // from host virtual DECLARE_WRITE_LINE_MEMBER(kdat_w) override; diff --git a/src/devices/bus/amiga/keyboard/a2000.cpp b/src/devices/bus/amiga/keyboard/a2000.cpp index 59aac50b652..8d01e4c4d85 100644 --- a/src/devices/bus/amiga/keyboard/a2000.cpp +++ b/src/devices/bus/amiga/keyboard/a2000.cpp @@ -103,7 +103,7 @@ public: protected: // construction/destruction - a2000_kbd_g80_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock) + a2000_kbd_g80_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_amiga_keyboard_interface(mconfig, *this) , m_rows(*this, "ROW%u", 0U) @@ -614,7 +614,7 @@ INPUT_PORTS_END class a2000_kbd_g80_us_device : public a2000_kbd_g80_device { public: - a2000_kbd_g80_us_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) + a2000_kbd_g80_us_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a2000_kbd_g80_device(mconfig, A2000_KBD_G80_US, tag, owner, clock) { } @@ -630,7 +630,7 @@ protected: class a2000_kbd_g80_de_device : public a2000_kbd_g80_device { public: - a2000_kbd_g80_de_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) + a2000_kbd_g80_de_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a2000_kbd_g80_device(mconfig, A2000_KBD_G80_DE, tag, owner, clock) { } @@ -648,7 +648,7 @@ protected: class a2000_kbd_g80_se_device : public a2000_kbd_g80_device { public: - a2000_kbd_g80_se_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) + a2000_kbd_g80_se_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a2000_kbd_g80_device(mconfig, A2000_KBD_G80_SE, tag, owner, clock) { } @@ -666,7 +666,7 @@ protected: class a2000_kbd_g80_dk_device : public a2000_kbd_g80_device { public: - a2000_kbd_g80_dk_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) + a2000_kbd_g80_dk_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a2000_kbd_g80_device(mconfig, A2000_KBD_G80_DK, tag, owner, clock) { } @@ -684,7 +684,7 @@ protected: class a2000_kbd_g80_gb_device : public a2000_kbd_g80_device { public: - a2000_kbd_g80_gb_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) + a2000_kbd_g80_gb_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a2000_kbd_g80_device(mconfig, A2000_KBD_G80_GB, tag, owner, clock) { } diff --git a/src/devices/bus/amiga/keyboard/keyboard.cpp b/src/devices/bus/amiga/keyboard/keyboard.cpp index 141998a15fa..c097bc1f8c6 100644 --- a/src/devices/bus/amiga/keyboard/keyboard.cpp +++ b/src/devices/bus/amiga/keyboard/keyboard.cpp @@ -32,7 +32,7 @@ template class device_finder<device_amiga_keyboard_interface, true>; // amiga_keyboard_bus_device - constructor //------------------------------------------------- -amiga_keyboard_bus_device::amiga_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +amiga_keyboard_bus_device::amiga_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AMIGA_KEYBOARD_INTERFACE, tag, owner, clock), device_single_card_slot_interface<device_amiga_keyboard_interface>(mconfig, *this), m_kbd(nullptr), diff --git a/src/devices/bus/amiga/keyboard/keyboard.h b/src/devices/bus/amiga/keyboard/keyboard.h index ce11d82ba32..cb90bc9b333 100644 --- a/src/devices/bus/amiga/keyboard/keyboard.h +++ b/src/devices/bus/amiga/keyboard/keyboard.h @@ -33,14 +33,14 @@ public: // construction/destruction template <typename T> amiga_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : amiga_keyboard_bus_device(mconfig, tag, owner, 0) + : amiga_keyboard_bus_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - amiga_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0U); + amiga_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~amiga_keyboard_bus_device(); // callbacks diff --git a/src/devices/bus/amiga/keyboard/mitsumi.cpp b/src/devices/bus/amiga/keyboard/mitsumi.cpp index ccc68d5d1d4..a3b6c6bc12a 100644 --- a/src/devices/bus/amiga/keyboard/mitsumi.cpp +++ b/src/devices/bus/amiga/keyboard/mitsumi.cpp @@ -144,7 +144,7 @@ public: } protected: - mitsumi_keyboard_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) + mitsumi_keyboard_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_amiga_keyboard_interface(mconfig, *this) , m_mcu{ *this, "mcu" } @@ -267,7 +267,7 @@ private: class a500_keyboard_base : public mitsumi_watchdog_keyboard_base { protected: - a500_keyboard_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) + a500_keyboard_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, type, tag, owner, clock) , m_reset_merger(*this, "reset") { @@ -325,7 +325,7 @@ private: class a600_keyboard_base : public mitsumi_keyboard_base { protected: - a600_keyboard_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) + a600_keyboard_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_keyboard_base(mconfig, type, tag, owner, clock) , m_reset_merger(*this, "reset") { @@ -661,7 +661,7 @@ INPUT_PORTS_END class a500_keyboard_us : public a500_keyboard_base { public: - a500_keyboard_us(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a500_keyboard_us(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a500_keyboard_base(mconfig, A500_KBD_US, tag, owner, clock) { } @@ -674,7 +674,7 @@ protected: class a500_keyboard_de : public a500_keyboard_base { public: - a500_keyboard_de(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a500_keyboard_de(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a500_keyboard_base(mconfig, A500_KBD_DE, tag, owner, clock) { } @@ -687,7 +687,7 @@ protected: class a500_keyboard_fr : public a500_keyboard_base { public: - a500_keyboard_fr(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a500_keyboard_fr(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a500_keyboard_base(mconfig, A500_KBD_FR, tag, owner, clock) { } @@ -700,7 +700,7 @@ protected: class a500_keyboard_it : public a500_keyboard_base { public: - a500_keyboard_it(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a500_keyboard_it(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a500_keyboard_base(mconfig, A500_KBD_IT, tag, owner, clock) { } @@ -713,7 +713,7 @@ protected: class a500_keyboard_se : public a500_keyboard_base { public: - a500_keyboard_se(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a500_keyboard_se(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a500_keyboard_base(mconfig, A500_KBD_SE, tag, owner, clock) { } @@ -726,7 +726,7 @@ protected: class a500_keyboard_es : public a500_keyboard_base { public: - a500_keyboard_es(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a500_keyboard_es(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a500_keyboard_base(mconfig, A500_KBD_ES, tag, owner, clock) { } @@ -739,7 +739,7 @@ protected: class a500_keyboard_dk : public a500_keyboard_base { public: - a500_keyboard_dk(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a500_keyboard_dk(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a500_keyboard_base(mconfig, A500_KBD_DK, tag, owner, clock) { } @@ -752,7 +752,7 @@ protected: class a500_keyboard_ch : public a500_keyboard_base { public: - a500_keyboard_ch(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a500_keyboard_ch(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a500_keyboard_base(mconfig, A500_KBD_CH, tag, owner, clock) { } @@ -765,7 +765,7 @@ protected: class a500_keyboard_no : public a500_keyboard_base { public: - a500_keyboard_no(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a500_keyboard_no(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a500_keyboard_base(mconfig, A500_KBD_NO, tag, owner, clock) { } @@ -778,7 +778,7 @@ protected: class a500_keyboard_gb : public a500_keyboard_base { public: - a500_keyboard_gb(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a500_keyboard_gb(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a500_keyboard_base(mconfig, A500_KBD_GB, tag, owner, clock) { } @@ -796,7 +796,7 @@ protected: class a600_keyboard_us : public a600_keyboard_base { public: - a600_keyboard_us(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a600_keyboard_us(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a600_keyboard_base(mconfig, A600_KBD_US, tag, owner, clock) { } @@ -809,7 +809,7 @@ protected: class a600_keyboard_de : public a600_keyboard_base { public: - a600_keyboard_de(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a600_keyboard_de(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a600_keyboard_base(mconfig, A600_KBD_DE, tag, owner, clock) { } @@ -822,7 +822,7 @@ protected: class a600_keyboard_fr : public a600_keyboard_base { public: - a600_keyboard_fr(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a600_keyboard_fr(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a600_keyboard_base(mconfig, A600_KBD_FR, tag, owner, clock) { } @@ -835,7 +835,7 @@ protected: class a600_keyboard_it : public a600_keyboard_base { public: - a600_keyboard_it(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a600_keyboard_it(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a600_keyboard_base(mconfig, A600_KBD_IT, tag, owner, clock) { } @@ -848,7 +848,7 @@ protected: class a600_keyboard_se : public a600_keyboard_base { public: - a600_keyboard_se(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a600_keyboard_se(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a600_keyboard_base(mconfig, A600_KBD_SE, tag, owner, clock) { } @@ -861,7 +861,7 @@ protected: class a600_keyboard_es : public a600_keyboard_base { public: - a600_keyboard_es(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a600_keyboard_es(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a600_keyboard_base(mconfig, A600_KBD_ES, tag, owner, clock) { } @@ -874,7 +874,7 @@ protected: class a600_keyboard_dk : public a600_keyboard_base { public: - a600_keyboard_dk(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a600_keyboard_dk(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a600_keyboard_base(mconfig, A600_KBD_DK, tag, owner, clock) { } @@ -887,7 +887,7 @@ protected: class a600_keyboard_ch : public a600_keyboard_base { public: - a600_keyboard_ch(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a600_keyboard_ch(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a600_keyboard_base(mconfig, A600_KBD_CH, tag, owner, clock) { } @@ -900,7 +900,7 @@ protected: class a600_keyboard_no : public a600_keyboard_base { public: - a600_keyboard_no(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a600_keyboard_no(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a600_keyboard_base(mconfig, A600_KBD_NO, tag, owner, clock) { } @@ -913,7 +913,7 @@ protected: class a600_keyboard_gb : public a600_keyboard_base { public: - a600_keyboard_gb(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a600_keyboard_gb(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a600_keyboard_base(mconfig, A600_KBD_GB, tag, owner, clock) { } @@ -931,7 +931,7 @@ protected: class a1000_keyboard_us : public a1000_keyboard_base { public: - a1000_keyboard_us(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a1000_keyboard_us(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a1000_keyboard_base(mconfig, A1000_KBD_US, tag, owner, clock) { } @@ -942,7 +942,7 @@ protected: class a1000_keyboard_de : public a1000_keyboard_base { public: - a1000_keyboard_de(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a1000_keyboard_de(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a1000_keyboard_base(mconfig, A1000_KBD_DE, tag, owner, clock) { } @@ -955,7 +955,7 @@ protected: class a1000_keyboard_fr : public a1000_keyboard_base { public: - a1000_keyboard_fr(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a1000_keyboard_fr(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a1000_keyboard_base(mconfig, A1000_KBD_FR, tag, owner, clock) { } @@ -968,7 +968,7 @@ protected: class a1000_keyboard_it : public a1000_keyboard_base { public: - a1000_keyboard_it(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a1000_keyboard_it(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a1000_keyboard_base(mconfig, A1000_KBD_IT, tag, owner, clock) { } @@ -981,7 +981,7 @@ protected: class a1000_keyboard_se : public a1000_keyboard_base { public: - a1000_keyboard_se(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a1000_keyboard_se(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a1000_keyboard_base(mconfig, A1000_KBD_SE, tag, owner, clock) { } @@ -994,7 +994,7 @@ protected: class a1000_keyboard_dk : public a1000_keyboard_base { public: - a1000_keyboard_dk(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a1000_keyboard_dk(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a1000_keyboard_base(mconfig, A1000_KBD_DK, tag, owner, clock) { } @@ -1007,7 +1007,7 @@ protected: class a1000_keyboard_gb : public a1000_keyboard_base { public: - a1000_keyboard_gb(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a1000_keyboard_gb(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : a1000_keyboard_base(mconfig, A1000_KBD_GB, tag, owner, clock) { } @@ -1025,7 +1025,7 @@ protected: class a2000_keyboard_us : public mitsumi_watchdog_keyboard_base { public: - a2000_keyboard_us(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a2000_keyboard_us(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, A2000_KBD_US, tag, owner, clock) { } @@ -1036,7 +1036,7 @@ protected: class a2000_keyboard_de : public mitsumi_watchdog_keyboard_base { public: - a2000_keyboard_de(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a2000_keyboard_de(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, A2000_KBD_DE, tag, owner, clock) { } @@ -1049,7 +1049,7 @@ protected: class a2000_keyboard_fr : public mitsumi_watchdog_keyboard_base { public: - a2000_keyboard_fr(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a2000_keyboard_fr(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, A2000_KBD_FR, tag, owner, clock) { } @@ -1062,7 +1062,7 @@ protected: class a2000_keyboard_it : public mitsumi_watchdog_keyboard_base { public: - a2000_keyboard_it(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a2000_keyboard_it(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, A2000_KBD_IT, tag, owner, clock) { } @@ -1075,7 +1075,7 @@ protected: class a2000_keyboard_se : public mitsumi_watchdog_keyboard_base { public: - a2000_keyboard_se(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a2000_keyboard_se(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, A2000_KBD_SE, tag, owner, clock) { } @@ -1088,7 +1088,7 @@ protected: class a2000_keyboard_es : public mitsumi_watchdog_keyboard_base { public: - a2000_keyboard_es(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a2000_keyboard_es(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, A2000_KBD_ES, tag, owner, clock) { } @@ -1101,7 +1101,7 @@ protected: class a2000_keyboard_dk : public mitsumi_watchdog_keyboard_base { public: - a2000_keyboard_dk(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a2000_keyboard_dk(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, A2000_KBD_DK, tag, owner, clock) { } @@ -1114,7 +1114,7 @@ protected: class a2000_keyboard_ch : public mitsumi_watchdog_keyboard_base { public: - a2000_keyboard_ch(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a2000_keyboard_ch(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, A2000_KBD_CH, tag, owner, clock) { } @@ -1127,7 +1127,7 @@ protected: class a2000_keyboard_no : public mitsumi_watchdog_keyboard_base { public: - a2000_keyboard_no(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a2000_keyboard_no(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, A2000_KBD_NO, tag, owner, clock) { } @@ -1140,7 +1140,7 @@ protected: class a2000_keyboard_gb : public mitsumi_watchdog_keyboard_base { public: - a2000_keyboard_gb(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + a2000_keyboard_gb(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mitsumi_watchdog_keyboard_base(mconfig, A2000_KBD_GB, tag, owner, clock) { } diff --git a/src/devices/bus/amiga/zorro/a2052.cpp b/src/devices/bus/amiga/zorro/a2052.cpp index 379a75270c5..e51d020085a 100644 --- a/src/devices/bus/amiga/zorro/a2052.cpp +++ b/src/devices/bus/amiga/zorro/a2052.cpp @@ -50,7 +50,7 @@ ioport_constructor a2052_device::device_input_ports() const // a2052_device - constructor //------------------------------------------------- -a2052_device::a2052_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2052_device::a2052_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ZORRO_A2052, tag, owner, clock), device_zorro2_card_interface(mconfig, *this), m_config(*this, "config") diff --git a/src/devices/bus/amiga/zorro/a2052.h b/src/devices/bus/amiga/zorro/a2052.h index f64bf06196d..046a8dc7879 100644 --- a/src/devices/bus/amiga/zorro/a2052.h +++ b/src/devices/bus/amiga/zorro/a2052.h @@ -29,7 +29,7 @@ class a2052_device : public device_t, public device_zorro2_card_interface, publi { public: // construction/destruction - a2052_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2052_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override ATTR_COLD; diff --git a/src/devices/bus/amiga/zorro/a2058.cpp b/src/devices/bus/amiga/zorro/a2058.cpp index 26d5f393222..c88969a80c1 100644 --- a/src/devices/bus/amiga/zorro/a2058.cpp +++ b/src/devices/bus/amiga/zorro/a2058.cpp @@ -51,7 +51,7 @@ ioport_constructor a2058_device::device_input_ports() const // a2058_device - constructor //------------------------------------------------- -a2058_device::a2058_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2058_device::a2058_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ZORRO_A2058, tag, owner, clock), device_zorro2_card_interface(mconfig, *this), m_config(*this, "config"), diff --git a/src/devices/bus/amiga/zorro/a2058.h b/src/devices/bus/amiga/zorro/a2058.h index 9b361b403e4..5e3b9f774c8 100644 --- a/src/devices/bus/amiga/zorro/a2058.h +++ b/src/devices/bus/amiga/zorro/a2058.h @@ -29,7 +29,7 @@ class a2058_device : public device_t, public device_zorro2_card_interface, publi { public: // construction/destruction - a2058_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2058_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override ATTR_COLD; diff --git a/src/devices/bus/amiga/zorro/a2065.cpp b/src/devices/bus/amiga/zorro/a2065.cpp index a76b289bb7f..6f34016a6b9 100644 --- a/src/devices/bus/amiga/zorro/a2065.cpp +++ b/src/devices/bus/amiga/zorro/a2065.cpp @@ -50,7 +50,7 @@ void a2065_device::device_add_mconfig(machine_config &config) // a2065_device - constructor //------------------------------------------------- -a2065_device::a2065_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2065_device::a2065_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ZORRO_A2065, tag, owner, clock), device_zorro2_card_interface(mconfig, *this), m_lance(*this, "lance") diff --git a/src/devices/bus/amiga/zorro/a2065.h b/src/devices/bus/amiga/zorro/a2065.h index 43e66c29678..fdb5e4a52ed 100644 --- a/src/devices/bus/amiga/zorro/a2065.h +++ b/src/devices/bus/amiga/zorro/a2065.h @@ -30,7 +30,7 @@ class a2065_device : public device_t, public device_zorro2_card_interface, publi { public: // construction/destruction - a2065_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2065_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t host_ram_r(offs_t offset); void host_ram_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/bus/amiga/zorro/a2232.cpp b/src/devices/bus/amiga/zorro/a2232.cpp index b9d6726bc7e..4dd94a3f971 100644 --- a/src/devices/bus/amiga/zorro/a2232.cpp +++ b/src/devices/bus/amiga/zorro/a2232.cpp @@ -117,7 +117,7 @@ void a2232_device::device_add_mconfig(machine_config &config) // a2232_device - constructor //------------------------------------------------- -a2232_device::a2232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2232_device::a2232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ZORRO_A2232, tag, owner, clock), device_zorro2_card_interface(mconfig, *this), m_iocpu(*this, "iocpu"), diff --git a/src/devices/bus/amiga/zorro/a2232.h b/src/devices/bus/amiga/zorro/a2232.h index e8a5da3258c..a703f0cec7e 100644 --- a/src/devices/bus/amiga/zorro/a2232.h +++ b/src/devices/bus/amiga/zorro/a2232.h @@ -36,7 +36,7 @@ class a2232_device : public device_t, public device_zorro2_card_interface, publi { public: // construction/destruction - a2232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // zorro slot uint16_t shared_ram_r(offs_t offset, uint16_t mem_mask = ~0); diff --git a/src/devices/bus/amiga/zorro/a590.cpp b/src/devices/bus/amiga/zorro/a590.cpp index 3fe72c69a42..f804bee8263 100644 --- a/src/devices/bus/amiga/zorro/a590.cpp +++ b/src/devices/bus/amiga/zorro/a590.cpp @@ -119,20 +119,20 @@ ioport_constructor a2091_device::device_input_ports() const void dmac_hdc_device_base::wd33c93(device_t *device) { - device->set_clock(10000000); + device->set_clock(XTAL::u(10000000)); downcast<wd33c93a_device *>(device)->irq_cb().set(*this, FUNC(dmac_hdc_device_base::scsi_irq_w)); downcast<wd33c93a_device *>(device)->drq_cb().set(*this, FUNC(dmac_hdc_device_base::scsi_drq_w)); } void dmac_hdc_device_base::device_add_mconfig(machine_config &config) { - amiga_dmac_device &dmac(AMIGA_DMAC(config, "dmac", 0)); + amiga_dmac_device &dmac(AMIGA_DMAC(config, "dmac")); dmac.scsi_read_handler().set(FUNC(dmac_hdc_device_base::dmac_scsi_r)); dmac.scsi_write_handler().set(FUNC(dmac_hdc_device_base::dmac_scsi_w)); dmac.int_handler().set(FUNC(dmac_hdc_device_base::dmac_int_w)); dmac.cfgout_handler().set(FUNC(dmac_hdc_device_base::dmac_cfgout_w)); - NSCSI_BUS(config, "scsi", 0); + NSCSI_BUS(config, "scsi"); NSCSI_CONNECTOR(config, "scsi:0", default_scsi_devices, nullptr, false); NSCSI_CONNECTOR(config, "scsi:1", default_scsi_devices, "harddisk", false); NSCSI_CONNECTOR(config, "scsi:3", default_scsi_devices, nullptr, false); @@ -214,7 +214,7 @@ const tiny_rom_entry *dmac_hdc_device_base::device_rom_region() const // dmac_hdc_device_base - constructor //------------------------------------------------- -dmac_hdc_device_base::dmac_hdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dmac_hdc_device_base::dmac_hdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_int6(false), m_dmac(*this, "dmac"), @@ -222,7 +222,7 @@ dmac_hdc_device_base::dmac_hdc_device_base(const machine_config &mconfig, device { } -a590_device::a590_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a590_device::a590_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmac_hdc_device_base(mconfig, ZORRO_A590, tag, owner, clock), device_exp_card_interface(mconfig, *this), m_dips(*this, "dips"), @@ -232,7 +232,7 @@ a590_device::a590_device(const machine_config &mconfig, const char *tag, device_ { } -a2091_device::a2091_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a2091_device::a2091_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmac_hdc_device_base(mconfig, ZORRO_A2091, tag, owner, clock), device_zorro2_card_interface(mconfig, *this), m_jp1(*this, "jp1"), diff --git a/src/devices/bus/amiga/zorro/a590.h b/src/devices/bus/amiga/zorro/a590.h index ab2a71bb0ce..82b4ef1af7c 100644 --- a/src/devices/bus/amiga/zorro/a590.h +++ b/src/devices/bus/amiga/zorro/a590.h @@ -30,7 +30,7 @@ class dmac_hdc_device_base : public device_t { protected: // construction/destruction - dmac_hdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dmac_hdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override ATTR_COLD; @@ -75,7 +75,7 @@ class a590_device : public dmac_hdc_device_base, public device_exp_card_interfac { public: // construction/destruction - a590_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a590_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -106,7 +106,7 @@ class a2091_device : public dmac_hdc_device_base, public device_zorro2_card_inte { public: // construction/destruction - a2091_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a2091_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/amiga/zorro/action_replay.cpp b/src/devices/bus/amiga/zorro/action_replay.cpp index 9466305049d..40d43350535 100644 --- a/src/devices/bus/amiga/zorro/action_replay.cpp +++ b/src/devices/bus/amiga/zorro/action_replay.cpp @@ -101,24 +101,24 @@ const tiny_rom_entry *action_replay_mk3_device::device_rom_region() const // action_replay_device_base - constructor //------------------------------------------------- -action_replay_device_base::action_replay_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +action_replay_device_base::action_replay_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_exp_card_interface(mconfig, *this), m_button(*this, "freeze") { } -action_replay_mk1_device::action_replay_mk1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +action_replay_mk1_device::action_replay_mk1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : action_replay_device_base(mconfig, ZORRO_ACTION_REPLAY_MK1, tag, owner, clock) { } -action_replay_mk2_device::action_replay_mk2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +action_replay_mk2_device::action_replay_mk2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : action_replay_device_base(mconfig, ZORRO_ACTION_REPLAY_MK2, tag, owner, clock) { } -action_replay_mk3_device::action_replay_mk3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +action_replay_mk3_device::action_replay_mk3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : action_replay_device_base(mconfig, ZORRO_ACTION_REPLAY_MK3, tag, owner, clock) { } diff --git a/src/devices/bus/amiga/zorro/action_replay.h b/src/devices/bus/amiga/zorro/action_replay.h index 18a3c6c6456..74b309a8c78 100644 --- a/src/devices/bus/amiga/zorro/action_replay.h +++ b/src/devices/bus/amiga/zorro/action_replay.h @@ -31,7 +31,7 @@ public: protected: // construction/destruction - action_replay_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + action_replay_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override ATTR_COLD; @@ -48,7 +48,7 @@ class action_replay_mk1_device : public action_replay_device_base { public: // construction/destruction - action_replay_mk1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + action_replay_mk1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -59,7 +59,7 @@ class action_replay_mk2_device : public action_replay_device_base { public: // construction/destruction - action_replay_mk2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + action_replay_mk2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -70,7 +70,7 @@ class action_replay_mk3_device : public action_replay_device_base { public: // construction/destruction - action_replay_mk3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + action_replay_mk3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/amiga/zorro/buddha.cpp b/src/devices/bus/amiga/zorro/buddha.cpp index 16a27d07ff2..9f138dbe953 100644 --- a/src/devices/bus/amiga/zorro/buddha.cpp +++ b/src/devices/bus/amiga/zorro/buddha.cpp @@ -94,7 +94,7 @@ const tiny_rom_entry *buddha_device::device_rom_region() const // buddha_device - constructor //------------------------------------------------- -buddha_device::buddha_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +buddha_device::buddha_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ZORRO_BUDDHA, tag, owner, clock), device_zorro2_card_interface(mconfig, *this), m_ata_0(*this, "ata_0"), diff --git a/src/devices/bus/amiga/zorro/buddha.h b/src/devices/bus/amiga/zorro/buddha.h index 80fce2682c5..dfef57d1a86 100644 --- a/src/devices/bus/amiga/zorro/buddha.h +++ b/src/devices/bus/amiga/zorro/buddha.h @@ -30,7 +30,7 @@ class buddha_device : public device_t, public device_zorro2_card_interface, publ { public: // construction/destruction - buddha_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + buddha_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/amiga/zorro/zorro.cpp b/src/devices/bus/amiga/zorro/zorro.cpp index 6bd8b280c86..8619314fb5e 100644 --- a/src/devices/bus/amiga/zorro/zorro.cpp +++ b/src/devices/bus/amiga/zorro/zorro.cpp @@ -22,12 +22,12 @@ DEFINE_DEVICE_TYPE(ZORRO_SLOT, zorro_slot_device, "zorro_slot", "Zorro slot") // zorro_slot_device - constructor //------------------------------------------------- -zorro_slot_device::zorro_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +zorro_slot_device::zorro_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : zorro_slot_device(mconfig, ZORRO_SLOT, tag, owner, clock) { } -zorro_slot_device::zorro_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +zorro_slot_device::zorro_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_slot_interface(mconfig, *this), m_zorro_bus(*this, finder_base::DUMMY_TAG) @@ -64,7 +64,7 @@ void zorro_slot_device::device_start() // exp_slot_device - constructor //------------------------------------------------- -zorro_bus_device_base::zorro_bus_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +zorro_bus_device_base::zorro_bus_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_space(*this, finder_base::DUMMY_TAG, -1), m_ovr_handler(*this), @@ -111,12 +111,12 @@ DEFINE_DEVICE_TYPE(EXP_SLOT, exp_slot_device, "exp_slot", "86-pin expansion slot // exp_slot_device - constructor //------------------------------------------------- -exp_slot_device::exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +exp_slot_device::exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : exp_slot_device(mconfig, EXP_SLOT, tag, owner, clock) { } -exp_slot_device::exp_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +exp_slot_device::exp_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : zorro_bus_device_base(mconfig, type, tag, owner, clock), m_ipl_handler(*this), m_dev(nullptr) @@ -185,12 +185,12 @@ DEFINE_DEVICE_TYPE(ZORRO2, zorro2_bus_device, "zorro2", "Zorro-II bus") // zorro2_bus_device - constructor //------------------------------------------------- -zorro2_bus_device::zorro2_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +zorro2_bus_device::zorro2_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : zorro2_bus_device(mconfig, ZORRO2, tag, owner, clock) { } -zorro2_bus_device::zorro2_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +zorro2_bus_device::zorro2_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : zorro_bus_device_base(mconfig, type, tag, owner, clock), m_eint1_handler(*this), m_eint4_handler(*this), diff --git a/src/devices/bus/amiga/zorro/zorro.h b/src/devices/bus/amiga/zorro/zorro.h index 632a5de9f6a..286fa081332 100644 --- a/src/devices/bus/amiga/zorro/zorro.h +++ b/src/devices/bus/amiga/zorro/zorro.h @@ -160,10 +160,10 @@ class zorro_slot_device : public device_t, public device_slot_interface { public: // construction/destruction - zorro_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + zorro_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T, typename O> zorro_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&zorrotag, O &&opts, const char *dflt) - : zorro_slot_device(mconfig, tag, owner, 0) + : zorro_slot_device(mconfig, tag, owner) { set_zorro_slot(std::forward<T>(zorrotag)); option_reset(); @@ -176,7 +176,7 @@ public: template <class T> void set_zorro_slot(T &&zorro_tag) { m_zorro_bus.set_tag(zorro_tag); } protected: - zorro_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + zorro_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override ATTR_COLD; @@ -217,7 +217,7 @@ public: protected: // construction/destruction - zorro_bus_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + zorro_bus_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override ATTR_COLD; @@ -237,7 +237,7 @@ class exp_slot_device : public zorro_bus_device_base { public: // construction/destruction - exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto ipl_handler() { return m_ipl_handler.bind(); } @@ -251,7 +251,7 @@ public: virtual void fc_w(int code) override; protected: - exp_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + exp_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override ATTR_COLD; @@ -272,7 +272,7 @@ class zorro2_bus_device : public zorro_bus_device_base { public: // construction/destruction - zorro2_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + zorro2_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~zorro2_bus_device(); auto eint1_handler() { return m_eint1_handler.bind(); } @@ -295,7 +295,7 @@ public: virtual void fc_w(int code) override; protected: - zorro2_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + zorro2_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override ATTR_COLD; diff --git a/src/devices/bus/apf/rom.cpp b/src/devices/bus/apf/rom.cpp index 509aa30f458..1897646acc2 100644 --- a/src/devices/bus/apf/rom.cpp +++ b/src/devices/bus/apf/rom.cpp @@ -22,22 +22,22 @@ DEFINE_DEVICE_TYPE(APF_ROM_BASIC, apf_basic_device, "apf_basic", "APF B DEFINE_DEVICE_TYPE(APF_ROM_SPACEDST, apf_spacedst_device, "apf_spacedst", "APF Space Destroyer Cart") -apf_rom_device::apf_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +apf_rom_device::apf_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_apf_cart_interface(mconfig, *this) { } -apf_rom_device::apf_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +apf_rom_device::apf_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : apf_rom_device(mconfig, APF_ROM_STD, tag, owner, clock) { } -apf_basic_device::apf_basic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +apf_basic_device::apf_basic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : apf_rom_device(mconfig, APF_ROM_BASIC, tag, owner, clock) { } -apf_spacedst_device::apf_spacedst_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +apf_spacedst_device::apf_spacedst_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : apf_rom_device(mconfig, APF_ROM_SPACEDST, tag, owner, clock) { } diff --git a/src/devices/bus/apf/rom.h b/src/devices/bus/apf/rom.h index ab129289493..b53053ec951 100644 --- a/src/devices/bus/apf/rom.h +++ b/src/devices/bus/apf/rom.h @@ -13,13 +13,13 @@ class apf_rom_device : public device_t, { public: // construction/destruction - apf_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apf_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; protected: - apf_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + apf_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -32,7 +32,7 @@ class apf_basic_device : public apf_rom_device { public: // construction/destruction - apf_basic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apf_basic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t extra_rom(offs_t offset) override; @@ -44,7 +44,7 @@ class apf_spacedst_device : public apf_rom_device { public: // construction/destruction - apf_spacedst_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apf_spacedst_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_ram(offs_t offset) override; diff --git a/src/devices/bus/apf/slot.cpp b/src/devices/bus/apf/slot.cpp index 62c8c7c02e9..b26af6f57da 100644 --- a/src/devices/bus/apf/slot.cpp +++ b/src/devices/bus/apf/slot.cpp @@ -71,7 +71,7 @@ void device_apf_cart_interface::ram_alloc(uint32_t size) //------------------------------------------------- // apf_cart_slot_device - constructor //------------------------------------------------- -apf_cart_slot_device::apf_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +apf_cart_slot_device::apf_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APF_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_apf_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/apf/slot.h b/src/devices/bus/apf/slot.h index 886135cb62b..40f6df0c66b 100644 --- a/src/devices/bus/apf/slot.h +++ b/src/devices/bus/apf/slot.h @@ -61,7 +61,7 @@ public: // construction/destruction template <typename T> apf_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : apf_cart_slot_device(mconfig, tag, owner, 0) + : apf_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -69,7 +69,7 @@ public: set_fixed(false); } - apf_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + apf_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~apf_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/apricot/expansion/expansion.cpp b/src/devices/bus/apricot/expansion/expansion.cpp index 0949e1ae781..1bafa84998c 100644 --- a/src/devices/bus/apricot/expansion/expansion.cpp +++ b/src/devices/bus/apricot/expansion/expansion.cpp @@ -20,12 +20,12 @@ DEFINE_DEVICE_TYPE(APRICOT_EXPANSION_SLOT, apricot_expansion_slot_device, "apric // 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) : +apricot_expansion_slot_device::apricot_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : 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 *tag, device_t *owner, uint32_t clock) : +apricot_expansion_slot_device::apricot_expansion_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_single_card_slot_interface<device_apricot_expansion_card_interface>(mconfig, *this) { @@ -57,7 +57,7 @@ DEFINE_DEVICE_TYPE(APRICOT_EXPANSION_BUS, apricot_expansion_bus_device, "apricot // 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) : +apricot_expansion_bus_device::apricot_expansion_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APRICOT_EXPANSION_BUS, tag, owner, clock), m_program(*this, finder_base::DUMMY_TAG, -1), m_io(*this, finder_base::DUMMY_TAG, -1), diff --git a/src/devices/bus/apricot/expansion/expansion.h b/src/devices/bus/apricot/expansion/expansion.h index f5a1994861d..4f9d107f112 100644 --- a/src/devices/bus/apricot/expansion/expansion.h +++ b/src/devices/bus/apricot/expansion/expansion.h @@ -63,17 +63,17 @@ public: // construction/destruction template <typename T> apricot_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : apricot_expansion_slot_device(mconfig, tag, owner, (uint32_t)0) + : apricot_expansion_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - 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, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: - apricot_expansion_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + apricot_expansion_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // device-level overrides virtual void device_start() override; @@ -89,7 +89,7 @@ class apricot_expansion_bus_device : public device_t { public: // construction/destruction - apricot_expansion_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apricot_expansion_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~apricot_expansion_bus_device(); template <typename T> void set_program_space(T &&tag, int spacenum) { m_program.set_tag(std::forward<T>(tag), spacenum); } diff --git a/src/devices/bus/apricot/expansion/ram.cpp b/src/devices/bus/apricot/expansion/ram.cpp index ba9b146522d..e14cf003386 100644 --- a/src/devices/bus/apricot/expansion/ram.cpp +++ b/src/devices/bus/apricot/expansion/ram.cpp @@ -43,7 +43,7 @@ ioport_constructor apricot_256k_ram_device::device_input_ports() const // apricot_256k_ram_device - constructor //------------------------------------------------- -apricot_256k_ram_device::apricot_256k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +apricot_256k_ram_device::apricot_256k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APRICOT_256K_RAM, tag, owner, clock), device_apricot_expansion_card_interface(mconfig, *this), m_sw(*this, "sw") @@ -97,7 +97,7 @@ ioport_constructor apricot_128k_ram_device::device_input_ports() const // apricot_128_512k_ram_device - constructor //------------------------------------------------- -apricot_128k_ram_device::apricot_128k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +apricot_128k_ram_device::apricot_128k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APRICOT_128K_RAM, tag, owner, clock), device_apricot_expansion_card_interface(mconfig, *this), m_strap(*this, "strap") @@ -151,7 +151,7 @@ ioport_constructor apricot_512k_ram_device::device_input_ports() const // apricot_128_512k_ram_device - constructor //------------------------------------------------- -apricot_512k_ram_device::apricot_512k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +apricot_512k_ram_device::apricot_512k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : 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 d6692b49ba7..7dd539720ec 100644 --- a/src/devices/bus/apricot/expansion/ram.h +++ b/src/devices/bus/apricot/expansion/ram.h @@ -25,7 +25,7 @@ class apricot_256k_ram_device : public device_t, public device_apricot_expansion { public: // construction/destruction - apricot_256k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apricot_256k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override; @@ -45,7 +45,7 @@ class apricot_128k_ram_device : public device_t, public device_apricot_expansion { public: // construction/destruction - apricot_128k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apricot_128k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override; @@ -65,7 +65,7 @@ class apricot_512k_ram_device : public device_t, public device_apricot_expansion { public: // construction/destruction - apricot_512k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apricot_512k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/apricot/expansion/winchester.cpp b/src/devices/bus/apricot/expansion/winchester.cpp index e48751851fb..61bdc020c38 100644 --- a/src/devices/bus/apricot/expansion/winchester.cpp +++ b/src/devices/bus/apricot/expansion/winchester.cpp @@ -50,7 +50,7 @@ void apricot_winchester_device::regs(address_map &map) void apricot_winchester_device::device_add_mconfig(machine_config &config) { - WD1010(config, m_hdc, 5000000); + WD1010(config, m_hdc, XTAL::u(5000000)); m_hdc->out_intrq_callback().set(FUNC(apricot_winchester_device::hdc_intrq_w)); m_hdc->in_data_callback().set(FUNC(apricot_winchester_device::hdc_data_r)); m_hdc->out_data_callback().set(FUNC(apricot_winchester_device::hdc_data_w)); @@ -65,8 +65,8 @@ void apricot_winchester_device::device_add_mconfig(machine_config &config) latch.q_out_cb<6>().set(FUNC(apricot_winchester_device::clksel_w)); // buffer chip read/write clock select (host or wdc) latch.q_out_cb<7>().set(FUNC(apricot_winchester_device::drive_w<1>)); - HARDDISK(config, "hdc:0", 0); - HARDDISK(config, "hdc:1", 0); + HARDDISK(config, "hdc:0"); + HARDDISK(config, "hdc:1"); } @@ -78,7 +78,7 @@ void apricot_winchester_device::device_add_mconfig(machine_config &config) // apricot_winchester_device - constructor //------------------------------------------------- -apricot_winchester_device::apricot_winchester_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +apricot_winchester_device::apricot_winchester_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APRICOT_WINCHESTER, tag, owner, clock), device_apricot_expansion_card_interface(mconfig, *this), m_hdc(*this, "hdc"), diff --git a/src/devices/bus/apricot/expansion/winchester.h b/src/devices/bus/apricot/expansion/winchester.h index fc082776d8c..051d1492efa 100644 --- a/src/devices/bus/apricot/expansion/winchester.h +++ b/src/devices/bus/apricot/expansion/winchester.h @@ -25,7 +25,7 @@ class apricot_winchester_device : public device_t, public device_apricot_expansi { public: // construction/destruction - apricot_winchester_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apricot_winchester_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/apricot/keyboard/hle.cpp b/src/devices/bus/apricot/keyboard/hle.cpp index 8a33c2952fa..c607a7bd1f8 100644 --- a/src/devices/bus/apricot/keyboard/hle.cpp +++ b/src/devices/bus/apricot/keyboard/hle.cpp @@ -221,7 +221,7 @@ void apricot_keyboard_hle_device::device_add_mconfig(machine_config &config) // apricot_keyboard_hle_device - constructor //------------------------------------------------- -apricot_keyboard_hle_device::apricot_keyboard_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +apricot_keyboard_hle_device::apricot_keyboard_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APRICOT_KEYBOARD_HLE, tag, owner, clock), device_apricot_keyboard_interface(mconfig, *this), device_buffered_serial_interface(mconfig, *this), @@ -262,8 +262,8 @@ void apricot_keyboard_hle_device::device_reset() transmit_register_reset(); set_data_frame(1, 8, PARITY_NONE, STOP_BITS_1); - set_rcv_rate(7800); - set_tra_rate(7800); + set_rcv_rate(XTAL::u(7800)); + set_tra_rate(XTAL::u(7800)); reset_key_state(); start_processing(attotime::from_hz(7800)); diff --git a/src/devices/bus/apricot/keyboard/hle.h b/src/devices/bus/apricot/keyboard/hle.h index c9738598a57..c39a6fd23e5 100644 --- a/src/devices/bus/apricot/keyboard/hle.h +++ b/src/devices/bus/apricot/keyboard/hle.h @@ -31,7 +31,7 @@ class apricot_keyboard_hle_device : public device_t, { public: // construction/destruction - apricot_keyboard_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apricot_keyboard_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual void out_w(int state) override; diff --git a/src/devices/bus/apricot/keyboard/keyboard.cpp b/src/devices/bus/apricot/keyboard/keyboard.cpp index 4a87d6b0493..d366a82e09c 100644 --- a/src/devices/bus/apricot/keyboard/keyboard.cpp +++ b/src/devices/bus/apricot/keyboard/keyboard.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(APRICOT_KEYBOARD_INTERFACE, apricot_keyboard_bus_device, "apr // apricot_keyboard_bus_device - constructor //------------------------------------------------- -apricot_keyboard_bus_device::apricot_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +apricot_keyboard_bus_device::apricot_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APRICOT_KEYBOARD_INTERFACE, tag, owner, clock), device_single_card_slot_interface<device_apricot_keyboard_interface>(mconfig, *this), m_kbd(nullptr), diff --git a/src/devices/bus/apricot/keyboard/keyboard.h b/src/devices/bus/apricot/keyboard/keyboard.h index e19605b2459..82f245a6558 100644 --- a/src/devices/bus/apricot/keyboard/keyboard.h +++ b/src/devices/bus/apricot/keyboard/keyboard.h @@ -48,14 +48,14 @@ public: // construction/destruction template <typename T> apricot_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : apricot_keyboard_bus_device(mconfig, tag, owner, 0) + : apricot_keyboard_bus_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - apricot_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apricot_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~apricot_keyboard_bus_device(); // callbacks diff --git a/src/devices/bus/apricot/video/mono.cpp b/src/devices/bus/apricot/video/mono.cpp index 424df94cea8..d6d0d0c2e6a 100644 --- a/src/devices/bus/apricot/video/mono.cpp +++ b/src/devices/bus/apricot/video/mono.cpp @@ -73,7 +73,7 @@ void apricot_mono_display_device::device_add_mconfig(machine_config &config) // apricot_mono_display_device - constructor //------------------------------------------------- -apricot_mono_display_device::apricot_mono_display_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +apricot_mono_display_device::apricot_mono_display_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APRICOT_MONO_DISPLAY, tag, owner, clock), device_apricot_video_interface(mconfig, *this), m_crtc(*this, "crtc"), diff --git a/src/devices/bus/apricot/video/mono.h b/src/devices/bus/apricot/video/mono.h index 36885bcb768..5e1ffa12cf2 100644 --- a/src/devices/bus/apricot/video/mono.h +++ b/src/devices/bus/apricot/video/mono.h @@ -26,7 +26,7 @@ class apricot_mono_display_device : public device_t, public device_apricot_video { public: // construction/destruction - apricot_mono_display_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apricot_mono_display_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/apricot/video/video.cpp b/src/devices/bus/apricot/video/video.cpp index 13e91b04a58..8cfa9498c85 100644 --- a/src/devices/bus/apricot/video/video.cpp +++ b/src/devices/bus/apricot/video/video.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(APRICOT_VIDEO_SLOT, apricot_video_slot_device, "apricot_video // apricot_video_slot_device - constructor //------------------------------------------------- -apricot_video_slot_device::apricot_video_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +apricot_video_slot_device::apricot_video_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APRICOT_VIDEO_SLOT, tag, owner, clock), device_single_card_slot_interface<device_apricot_video_interface>(mconfig, *this), m_apvid_handler(*this), diff --git a/src/devices/bus/apricot/video/video.h b/src/devices/bus/apricot/video/video.h index 5b1a8b322f8..0e9a8405d7f 100644 --- a/src/devices/bus/apricot/video/video.h +++ b/src/devices/bus/apricot/video/video.h @@ -28,7 +28,7 @@ public: // construction/destruction template <typename T> apricot_video_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, const char *dflt) - : apricot_video_slot_device(mconfig, tag, owner, uint32_t(0)) + : apricot_video_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -36,7 +36,7 @@ public: set_fixed(false); } - apricot_video_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apricot_video_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~apricot_video_slot_device(); // callbacks diff --git a/src/devices/bus/aquarius/c1541.cpp b/src/devices/bus/aquarius/c1541.cpp index 40ac2679422..90be53ad4e0 100644 --- a/src/devices/bus/aquarius/c1541.cpp +++ b/src/devices/bus/aquarius/c1541.cpp @@ -36,7 +36,7 @@ void aquarius_c1541_device::device_add_mconfig(machine_config &config) // aquarius_c1541_device - constructor //------------------------------------------------- -aquarius_c1541_device::aquarius_c1541_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aquarius_c1541_device::aquarius_c1541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AQUARIUS_C1541, tag, owner, clock) , device_aquarius_cartridge_interface(mconfig, *this) , m_iec(*this, "iec_bus") diff --git a/src/devices/bus/aquarius/c1541.h b/src/devices/bus/aquarius/c1541.h index 3a9e16e290c..dde267fc541 100644 --- a/src/devices/bus/aquarius/c1541.h +++ b/src/devices/bus/aquarius/c1541.h @@ -25,7 +25,7 @@ class aquarius_c1541_device : { public: // construction/destruction - aquarius_c1541_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aquarius_c1541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/aquarius/mini.cpp b/src/devices/bus/aquarius/mini.cpp index dee7c4cd294..12278faf306 100644 --- a/src/devices/bus/aquarius/mini.cpp +++ b/src/devices/bus/aquarius/mini.cpp @@ -117,7 +117,7 @@ void aquarius_mini_device::device_add_mconfig(machine_config &config) // aquarius_mini_device - constructor //------------------------------------------------- -aquarius_mini_device::aquarius_mini_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aquarius_mini_device::aquarius_mini_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AQUARIUS_MINI, tag, owner, clock) , device_aquarius_cartridge_interface(mconfig, *this) , m_irqs(*this, "irqs") diff --git a/src/devices/bus/aquarius/mini.h b/src/devices/bus/aquarius/mini.h index ed9cc1af641..496948078ce 100644 --- a/src/devices/bus/aquarius/mini.h +++ b/src/devices/bus/aquarius/mini.h @@ -24,7 +24,7 @@ class aquarius_mini_device: { public: // construction/destruction - aquarius_mini_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aquarius_mini_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(input_changed); diff --git a/src/devices/bus/aquarius/qdisk.cpp b/src/devices/bus/aquarius/qdisk.cpp index ba06201f554..e2ee568c091 100644 --- a/src/devices/bus/aquarius/qdisk.cpp +++ b/src/devices/bus/aquarius/qdisk.cpp @@ -78,7 +78,7 @@ void aquarius_qdisk_device::device_add_mconfig(machine_config &config) // aquarius_qdisk_device - constructor //------------------------------------------------- -aquarius_qdisk_device::aquarius_qdisk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aquarius_qdisk_device::aquarius_qdisk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AQUARIUS_QDISK, tag, owner, clock) , device_aquarius_cartridge_interface(mconfig, *this) , m_ssda(*this, "mc6852") diff --git a/src/devices/bus/aquarius/qdisk.h b/src/devices/bus/aquarius/qdisk.h index 303ed90affa..3f14f837178 100644 --- a/src/devices/bus/aquarius/qdisk.h +++ b/src/devices/bus/aquarius/qdisk.h @@ -25,7 +25,7 @@ class aquarius_qdisk_device : { public: // construction/destruction - aquarius_qdisk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aquarius_qdisk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/aquarius/ram.cpp b/src/devices/bus/aquarius/ram.cpp index 753a1fbf3a3..a2c23a74033 100644 --- a/src/devices/bus/aquarius/ram.cpp +++ b/src/devices/bus/aquarius/ram.cpp @@ -28,29 +28,29 @@ DEFINE_DEVICE_TYPE(AQUARIUS_RAM16P, aquarius_ram16p_device, "aquarius_ram16p", " // aquarius_ram_device - constructor //------------------------------------------------- -aquarius_ram_device::aquarius_ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint16_t size) +aquarius_ram_device::aquarius_ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint16_t size) : device_t(mconfig, type, tag, owner, clock) , device_aquarius_cartridge_interface(mconfig, *this) , m_ram_size(size) { } -aquarius_ram4_device::aquarius_ram4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aquarius_ram4_device::aquarius_ram4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aquarius_ram_device(mconfig, AQUARIUS_RAM4, tag, owner, clock, 0x1000) { } -aquarius_ram16_device::aquarius_ram16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aquarius_ram16_device::aquarius_ram16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aquarius_ram_device(mconfig, AQUARIUS_RAM16, tag, owner, clock, 0x4000) { } -aquarius_ram32_device::aquarius_ram32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aquarius_ram32_device::aquarius_ram32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aquarius_ram_device(mconfig, AQUARIUS_RAM32, tag, owner, clock, 0x8000) { } -aquarius_ram16p_device::aquarius_ram16p_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aquarius_ram16p_device::aquarius_ram16p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AQUARIUS_RAM16P, tag, owner, clock) , device_aquarius_cartridge_interface(mconfig, *this) { diff --git a/src/devices/bus/aquarius/ram.h b/src/devices/bus/aquarius/ram.h index 3721314bb0f..b917291bc49 100644 --- a/src/devices/bus/aquarius/ram.h +++ b/src/devices/bus/aquarius/ram.h @@ -26,7 +26,7 @@ class aquarius_ram_device : { protected: // construction/destruction - aquarius_ram_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock, uint16_t size); + aquarius_ram_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock, uint16_t size); // device-level overrides virtual void device_start() override; @@ -47,7 +47,7 @@ class aquarius_ram4_device : public aquarius_ram_device { public: // construction/destruction - aquarius_ram4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aquarius_ram4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> aquarius_ram16_device @@ -56,7 +56,7 @@ class aquarius_ram16_device : public aquarius_ram_device { public: // construction/destruction - aquarius_ram16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aquarius_ram16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> aquarius_ram32_device @@ -65,7 +65,7 @@ class aquarius_ram32_device : public aquarius_ram_device { public: // construction/destruction - aquarius_ram32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aquarius_ram32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -77,7 +77,7 @@ class aquarius_ram16p_device : { public: // construction/destruction - aquarius_ram16p_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aquarius_ram16p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/aquarius/rom.cpp b/src/devices/bus/aquarius/rom.cpp index 87f7df97079..f4c65bc1da2 100644 --- a/src/devices/bus/aquarius/rom.cpp +++ b/src/devices/bus/aquarius/rom.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(AQUARIUS_ROM, aquarius_rom_device, "aquarius_rom", "Aquarius // aquarius_rom_device - constructor //------------------------------------------------- -aquarius_rom_device::aquarius_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aquarius_rom_device::aquarius_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AQUARIUS_ROM, tag, owner, clock) , device_aquarius_cartridge_interface(mconfig, *this) { diff --git a/src/devices/bus/aquarius/rom.h b/src/devices/bus/aquarius/rom.h index 9e25f9e9ab0..dc70d6d0740 100644 --- a/src/devices/bus/aquarius/rom.h +++ b/src/devices/bus/aquarius/rom.h @@ -26,7 +26,7 @@ class aquarius_rom_device : { public: // construction/destruction - aquarius_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aquarius_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/aquarius/slot.cpp b/src/devices/bus/aquarius/slot.cpp index 2deb6149e12..68e81bf18c2 100644 --- a/src/devices/bus/aquarius/slot.cpp +++ b/src/devices/bus/aquarius/slot.cpp @@ -55,7 +55,7 @@ void device_aquarius_cartridge_interface::rom_alloc(uint32_t size) // aquarius_cartridge_slot_device - constructor //------------------------------------------------- -aquarius_cartridge_slot_device::aquarius_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aquarius_cartridge_slot_device::aquarius_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AQUARIUS_CARTRIDGE_SLOT, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_single_card_slot_interface<device_aquarius_cartridge_interface>(mconfig, *this) diff --git a/src/devices/bus/aquarius/slot.h b/src/devices/bus/aquarius/slot.h index 9ee7aaf6d2b..2f2bdf4451b 100644 --- a/src/devices/bus/aquarius/slot.h +++ b/src/devices/bus/aquarius/slot.h @@ -29,7 +29,7 @@ class aquarius_cartridge_slot_device : public device_t, public: // construction/destruction template <typename T> - aquarius_cartridge_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&slot_options, const char *default_option) + aquarius_cartridge_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&slot_options, const char *default_option) : aquarius_cartridge_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -38,7 +38,7 @@ public: set_fixed(false); } - aquarius_cartridge_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + aquarius_cartridge_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // callbacks auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/bus/aquarius/supercart.cpp b/src/devices/bus/aquarius/supercart.cpp index 2bc2ad82fd8..6deb1c0fdb4 100644 --- a/src/devices/bus/aquarius/supercart.cpp +++ b/src/devices/bus/aquarius/supercart.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(AQUARIUS_SC1, aquarius_sc1_device, "aquarius_sc1", "Aquarius // aquarius_sc1_device - constructor //------------------------------------------------- -aquarius_sc1_device::aquarius_sc1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aquarius_sc1_device::aquarius_sc1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AQUARIUS_SC1, tag, owner, clock) , device_aquarius_cartridge_interface(mconfig, *this) , m_bank(0) diff --git a/src/devices/bus/aquarius/supercart.h b/src/devices/bus/aquarius/supercart.h index 9242c1dc667..63661f3d405 100644 --- a/src/devices/bus/aquarius/supercart.h +++ b/src/devices/bus/aquarius/supercart.h @@ -26,7 +26,7 @@ class aquarius_sc1_device : { public: // construction/destruction - aquarius_sc1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aquarius_sc1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/arcadia/rom.cpp b/src/devices/bus/arcadia/rom.cpp index 60bc4b3a88e..30e64dee377 100644 --- a/src/devices/bus/arcadia/rom.cpp +++ b/src/devices/bus/arcadia/rom.cpp @@ -22,17 +22,17 @@ DEFINE_DEVICE_TYPE(ARCADIA_ROM_STD, arcadia_rom_device, "arcadia_rom", "Emers DEFINE_DEVICE_TYPE(ARCADIA_ROM_GOLF, arcadia_golf_device, "arcadia_golf", "Emerson Arcadia Golf Cart") -arcadia_rom_device::arcadia_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +arcadia_rom_device::arcadia_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_arcadia_cart_interface(mconfig, *this) { } -arcadia_rom_device::arcadia_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arcadia_rom_device::arcadia_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arcadia_rom_device(mconfig, ARCADIA_ROM_STD, tag, owner, clock) { } -arcadia_golf_device::arcadia_golf_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arcadia_golf_device::arcadia_golf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arcadia_rom_device(mconfig, ARCADIA_ROM_GOLF, tag, owner, clock) { } diff --git a/src/devices/bus/arcadia/rom.h b/src/devices/bus/arcadia/rom.h index b0ba196302e..e748a4cd746 100644 --- a/src/devices/bus/arcadia/rom.h +++ b/src/devices/bus/arcadia/rom.h @@ -15,14 +15,14 @@ class arcadia_rom_device : public device_t, { public: // construction/destruction - arcadia_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arcadia_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; virtual uint8_t extra_rom(offs_t offset) override; public: - arcadia_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + arcadia_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -35,7 +35,7 @@ class arcadia_golf_device : public arcadia_rom_device { public: // construction/destruction - arcadia_golf_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arcadia_golf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/arcadia/slot.cpp b/src/devices/bus/arcadia/slot.cpp index 1eaada68544..fee3f1b50d7 100644 --- a/src/devices/bus/arcadia/slot.cpp +++ b/src/devices/bus/arcadia/slot.cpp @@ -61,7 +61,7 @@ void device_arcadia_cart_interface::rom_alloc(uint32_t size) //------------------------------------------------- // arcadia_cart_slot_device - constructor //------------------------------------------------- -arcadia_cart_slot_device::arcadia_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +arcadia_cart_slot_device::arcadia_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EA2001_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_arcadia_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/arcadia/slot.h b/src/devices/bus/arcadia/slot.h index e9a3ed8415e..3bbbb673d4c 100644 --- a/src/devices/bus/arcadia/slot.h +++ b/src/devices/bus/arcadia/slot.h @@ -51,14 +51,14 @@ public: // construction/destruction template <typename T> arcadia_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : arcadia_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : arcadia_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - arcadia_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arcadia_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~arcadia_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/archimedes/econet/econet.cpp b/src/devices/bus/archimedes/econet/econet.cpp index e469b9f581d..9f4e037fb2d 100644 --- a/src/devices/bus/archimedes/econet/econet.cpp +++ b/src/devices/bus/archimedes/econet/econet.cpp @@ -29,7 +29,7 @@ void arc_econet_device::device_add_mconfig(machine_config &config) m_adlc->out_txd_cb().set("econet", FUNC(econet_device::host_data_w)); m_adlc->out_irq_cb().set(DEVICE_SELF_OWNER, FUNC(archimedes_econet_slot_device::efiq_w)); - econet_device &econet(ECONET(config, "econet", 0)); + econet_device &econet(ECONET(config, "econet")); econet.clk_wr_callback().set(m_adlc, FUNC(mc6854_device::txc_w)); econet.clk_wr_callback().append(m_adlc, FUNC(mc6854_device::rxc_w)); econet.data_wr_callback().set(m_adlc, FUNC(mc6854_device::set_rx)); @@ -46,7 +46,7 @@ void arc_econet_device::device_add_mconfig(machine_config &config) // archimedes_econet_device - constructor //------------------------------------------------- -arc_econet_device::arc_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_econet_device::arc_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_ECONET, tag, owner, clock) , device_archimedes_econet_interface(mconfig, *this) , m_adlc(*this, "mc6854") diff --git a/src/devices/bus/archimedes/econet/econet.h b/src/devices/bus/archimedes/econet/econet.h index 337cb077206..f41e16c62df 100644 --- a/src/devices/bus/archimedes/econet/econet.h +++ b/src/devices/bus/archimedes/econet/econet.h @@ -30,7 +30,7 @@ class arc_econet_device: { public: // construction/destruction - arc_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_econet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/archimedes/econet/midi.cpp b/src/devices/bus/archimedes/econet/midi.cpp index f6d3cc5c39b..22f14f94f14 100644 --- a/src/devices/bus/archimedes/econet/midi.cpp +++ b/src/devices/bus/archimedes/econet/midi.cpp @@ -59,19 +59,19 @@ void arc_serial_sampler_device::device_add_mconfig(machine_config &config) // arc_serial_midi_device - constructor //------------------------------------------------- -arc_serial_midi_device::arc_serial_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +arc_serial_midi_device::arc_serial_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_archimedes_econet_interface(mconfig, *this) , m_adlc(*this, "mc6854") { } -arc_serial_midi_device::arc_serial_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_serial_midi_device::arc_serial_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_serial_midi_device(mconfig, ARC_SERIAL_MIDI, tag, owner, clock) { } -arc_serial_sampler_device::arc_serial_sampler_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_serial_sampler_device::arc_serial_sampler_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_serial_midi_device(mconfig, ARC_SERIAL_SAMPLER, tag, owner, clock) { } diff --git a/src/devices/bus/archimedes/econet/midi.h b/src/devices/bus/archimedes/econet/midi.h index 140819c5caa..2b8fd206bdb 100644 --- a/src/devices/bus/archimedes/econet/midi.h +++ b/src/devices/bus/archimedes/econet/midi.h @@ -29,10 +29,10 @@ class arc_serial_midi_device: { public: // construction/destruction - arc_serial_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_serial_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - arc_serial_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + arc_serial_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -54,7 +54,7 @@ class arc_serial_sampler_device: public arc_serial_midi_device { public: // construction/destruction - arc_serial_sampler_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_serial_sampler_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::CAPTURE; } diff --git a/src/devices/bus/archimedes/econet/rtfmjoy.cpp b/src/devices/bus/archimedes/econet/rtfmjoy.cpp index c53e7c155da..cda1839008a 100644 --- a/src/devices/bus/archimedes/econet/rtfmjoy.cpp +++ b/src/devices/bus/archimedes/econet/rtfmjoy.cpp @@ -56,7 +56,7 @@ ioport_constructor arc_rtfm_joystick_device::device_input_ports() const // archimedes_rtfm_joystick_device - constructor //------------------------------------------------- -arc_rtfm_joystick_device::arc_rtfm_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_rtfm_joystick_device::arc_rtfm_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_RTFM_JOY, tag, owner, clock) , device_archimedes_econet_interface(mconfig, *this) , m_joy(*this, "JOY%u", 0U) diff --git a/src/devices/bus/archimedes/econet/rtfmjoy.h b/src/devices/bus/archimedes/econet/rtfmjoy.h index 443d5a1560b..585c1614b75 100644 --- a/src/devices/bus/archimedes/econet/rtfmjoy.h +++ b/src/devices/bus/archimedes/econet/rtfmjoy.h @@ -27,7 +27,7 @@ class arc_rtfm_joystick_device: { public: // construction/destruction - arc_rtfm_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_rtfm_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/archimedes/econet/slot.cpp b/src/devices/bus/archimedes/econet/slot.cpp index c15e13698c3..9088a796da7 100644 --- a/src/devices/bus/archimedes/econet/slot.cpp +++ b/src/devices/bus/archimedes/econet/slot.cpp @@ -41,7 +41,7 @@ device_archimedes_econet_interface::device_archimedes_econet_interface(const mac // archimedes_econet_slot_device - constructor //------------------------------------------------- -archimedes_econet_slot_device::archimedes_econet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +archimedes_econet_slot_device::archimedes_econet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARCHIMEDES_ECONET_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_archimedes_econet_interface>(mconfig, *this) , m_device(nullptr) diff --git a/src/devices/bus/archimedes/econet/slot.h b/src/devices/bus/archimedes/econet/slot.h index 4d963fd608e..ef0cf69f12f 100644 --- a/src/devices/bus/archimedes/econet/slot.h +++ b/src/devices/bus/archimedes/econet/slot.h @@ -57,7 +57,7 @@ public: set_fixed(false); } - archimedes_econet_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + archimedes_econet_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // callbacks auto efiq_handler() { return m_efiq_handler.bind(); } diff --git a/src/devices/bus/archimedes/podule/a448.cpp b/src/devices/bus/archimedes/podule/a448.cpp index 400a15722e6..960c8f3603f 100644 --- a/src/devices/bus/archimedes/podule/a448.cpp +++ b/src/devices/bus/archimedes/podule/a448.cpp @@ -28,10 +28,10 @@ public: static constexpr feature_type unemulated_features() { return feature::CAPTURE; } // construction/destruction - arc_a448_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_a448_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - arc_a448_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + arc_a448_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -54,7 +54,7 @@ class arc_a448b_device : public arc_a448_device { public: // construction/destruction - arc_a448b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_a448b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -100,7 +100,7 @@ const tiny_rom_entry *arc_a448b_device::device_rom_region() const void arc_a448_device::device_add_mconfig(machine_config &config) { - //ZN448(config, "zn448", 0); + //ZN448(config, "zn448"); } void arc_a448b_device::device_add_mconfig(machine_config &config) @@ -122,19 +122,19 @@ void arc_a448b_device::device_add_mconfig(machine_config &config) // arc_a448_device - constructor //------------------------------------------------- -arc_a448_device::arc_a448_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +arc_a448_device::arc_a448_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") { } -arc_a448_device::arc_a448_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_a448_device::arc_a448_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_a448_device(mconfig, ARC_A448, tag, owner, clock) { } -arc_a448b_device::arc_a448b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_a448b_device::arc_a448b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_a448_device(mconfig, ARC_A448B, tag, owner, clock) { } diff --git a/src/devices/bus/archimedes/podule/acejoy.cpp b/src/devices/bus/archimedes/podule/acejoy.cpp index 6cf6f2ef0e1..5473c8d9f9d 100644 --- a/src/devices/bus/archimedes/podule/acejoy.cpp +++ b/src/devices/bus/archimedes/podule/acejoy.cpp @@ -20,7 +20,7 @@ class arc_acejoy_device : { public: // construction/destruction - arc_acejoy_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_acejoy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -103,7 +103,7 @@ ioport_constructor arc_acejoy_device::device_input_ports() const // arc_acejoy_device - constructor //------------------------------------------------- -arc_acejoy_device::arc_acejoy_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_acejoy_device::arc_acejoy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_ACEJOY, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/armadeus.cpp b/src/devices/bus/archimedes/podule/armadeus.cpp index 4af99d9dd8f..04d46e1ff96 100644 --- a/src/devices/bus/archimedes/podule/armadeus.cpp +++ b/src/devices/bus/archimedes/podule/armadeus.cpp @@ -24,7 +24,7 @@ public: static constexpr feature_type unemulated_features() { return feature::CAPTURE; } // construction/destruction - arc_armadeus_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_armadeus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -71,9 +71,9 @@ const tiny_rom_entry *arc_armadeus_device::device_rom_region() const void arc_armadeus_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "speaker").front_center(); - ZN428E(config, "dac", 0).add_route(ALL_OUTPUTS, "speaker", 0.5); + ZN428E(config, "dac").add_route(ALL_OUTPUTS, "speaker", 0.5); - //ZN448(config, "zn448", 0); + //ZN448(config, "zn448"); } @@ -85,7 +85,7 @@ void arc_armadeus_device::device_add_mconfig(machine_config &config) // arc_armadeus_device - constructor //------------------------------------------------- -arc_armadeus_device::arc_armadeus_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_armadeus_device::arc_armadeus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_ARMADEUS, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/eaglem2.cpp b/src/devices/bus/archimedes/podule/eaglem2.cpp index 5180f724208..19f6f91b605 100644 --- a/src/devices/bus/archimedes/podule/eaglem2.cpp +++ b/src/devices/bus/archimedes/podule/eaglem2.cpp @@ -38,7 +38,7 @@ class arc_eaglem2_device : { public: // construction/destruction - arc_eaglem2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_eaglem2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::CAPTURE | feature::SOUND; } @@ -115,7 +115,7 @@ void arc_eaglem2_device::device_add_mconfig(machine_config &config) // arc_eaglem2_device - constructor //------------------------------------------------- -arc_eaglem2_device::arc_eaglem2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_eaglem2_device::arc_eaglem2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_EAGLEM2, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/ether1.cpp b/src/devices/bus/archimedes/podule/ether1.cpp index e4e23704360..74d2a59cfeb 100644 --- a/src/devices/bus/archimedes/podule/ether1.cpp +++ b/src/devices/bus/archimedes/podule/ether1.cpp @@ -21,7 +21,7 @@ class arc_ether1_aka25_device : { public: // construction/destruction - arc_ether1_aka25_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_ether1_aka25_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -100,7 +100,7 @@ const tiny_rom_entry *arc_ether1_aka25_device::device_rom_region() const // arc_ether1_aka25_device - constructor //------------------------------------------------- -arc_ether1_aka25_device::arc_ether1_aka25_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_ether1_aka25_device::arc_ether1_aka25_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_ETHER1_AKA25, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/etherd.cpp b/src/devices/bus/archimedes/podule/etherd.cpp index f1f4bfc4228..7f04546447e 100644 --- a/src/devices/bus/archimedes/podule/etherd.cpp +++ b/src/devices/bus/archimedes/podule/etherd.cpp @@ -21,7 +21,7 @@ class arc_etherd_device : { public: // construction/destruction - arc_etherd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_etherd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::COMMS; } @@ -89,7 +89,7 @@ void arc_etherd_device::device_add_mconfig(machine_config &config) // arc_etherd_device - constructor //------------------------------------------------- -arc_etherd_device::arc_etherd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_etherd_device::arc_etherd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_ETHERD, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/etherr.cpp b/src/devices/bus/archimedes/podule/etherr.cpp index df3ebc6a57b..adfba95caf1 100644 --- a/src/devices/bus/archimedes/podule/etherr.cpp +++ b/src/devices/bus/archimedes/podule/etherr.cpp @@ -21,7 +21,7 @@ class arc_etherr_device : { public: // construction/destruction - arc_etherr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_etherr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::COMMS; } @@ -89,7 +89,7 @@ void arc_etherr_device::device_add_mconfig(machine_config &config) // arc_etherr_device - constructor //------------------------------------------------- -arc_etherr_device::arc_etherr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_etherr_device::arc_etherr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_ETHERR, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/faxpack.cpp b/src/devices/bus/archimedes/podule/faxpack.cpp index 0ae0d375203..be02b883082 100644 --- a/src/devices/bus/archimedes/podule/faxpack.cpp +++ b/src/devices/bus/archimedes/podule/faxpack.cpp @@ -25,7 +25,7 @@ class arc_faxpack_device : { public: // construction/destruction - arc_faxpack_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_faxpack_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::CAPTURE; } @@ -108,7 +108,7 @@ void arc_faxpack_device::device_add_mconfig(machine_config &config) // arc_faxpack_device - constructor //------------------------------------------------- -arc_faxpack_device::arc_faxpack_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_faxpack_device::arc_faxpack_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_FAXPACK, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_mcu(*this, "mcu") diff --git a/src/devices/bus/archimedes/podule/greyhawk.cpp b/src/devices/bus/archimedes/podule/greyhawk.cpp index a2ffe51459b..797ada06b2d 100644 --- a/src/devices/bus/archimedes/podule/greyhawk.cpp +++ b/src/devices/bus/archimedes/podule/greyhawk.cpp @@ -24,7 +24,7 @@ class arc_greyhawk_device : { public: // construction/destruction - arc_greyhawk_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_greyhawk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::CAPTURE; } @@ -93,7 +93,7 @@ void arc_greyhawk_device::device_add_mconfig(machine_config &config) // arc_greyhawk_device - constructor //------------------------------------------------- -arc_greyhawk_device::arc_greyhawk_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_greyhawk_device::arc_greyhawk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_GREYHAWK, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/ide_be.cpp b/src/devices/bus/archimedes/podule/ide_be.cpp index 622b62a7cf1..af59cfa0992 100644 --- a/src/devices/bus/archimedes/podule/ide_be.cpp +++ b/src/devices/bus/archimedes/podule/ide_be.cpp @@ -23,7 +23,7 @@ class arc_ide_be_device : { public: // construction/destruction - arc_ide_be_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_ide_be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -93,7 +93,7 @@ void arc_ide_be_device::device_add_mconfig(machine_config &config) // arc_ide_be_device - constructor //------------------------------------------------- -arc_ide_be_device::arc_ide_be_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_ide_be_device::arc_ide_be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_IDE_BE, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/ide_rdev.cpp b/src/devices/bus/archimedes/podule/ide_rdev.cpp index ccf48d24e51..05c919fa0ac 100644 --- a/src/devices/bus/archimedes/podule/ide_rdev.cpp +++ b/src/devices/bus/archimedes/podule/ide_rdev.cpp @@ -21,7 +21,7 @@ class arc_ide_rdev_device : { public: // construction/destruction - arc_ide_rdev_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_ide_rdev_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -85,7 +85,7 @@ void arc_ide_rdev_device::device_add_mconfig(machine_config &config) // arc_ide_rdev_device - constructor //------------------------------------------------- -arc_ide_rdev_device::arc_ide_rdev_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_ide_rdev_device::arc_ide_rdev_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_IDE_RDEV, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/io.cpp b/src/devices/bus/archimedes/podule/io.cpp index 698cf94114b..5b1f43b2f90 100644 --- a/src/devices/bus/archimedes/podule/io.cpp +++ b/src/devices/bus/archimedes/podule/io.cpp @@ -42,7 +42,7 @@ class arc_io_aka_device : public device_archimedes_podule_interface { protected: - arc_io_aka_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + arc_io_aka_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -74,7 +74,7 @@ class arc_bbcio_aka10_device : public arc_io_aka_device { public: // construction/destruction - arc_bbcio_aka10_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_bbcio_aka10_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -93,7 +93,7 @@ class arc_upmidi_aka12_device : public arc_io_aka_device { public: // construction/destruction - arc_upmidi_aka12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_upmidi_aka12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -111,7 +111,7 @@ class arc_iomidi_aka15_device : public arc_io_aka_device { public: // construction/destruction - arc_iomidi_aka15_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_iomidi_aka15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -130,7 +130,7 @@ class arc_midi_aka16_device : public arc_io_aka_device { public: // construction/destruction - arc_midi_aka16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_midi_aka16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -284,7 +284,7 @@ void arc_io_aka_device::add_1mhzbus(machine_config &config) void arc_io_aka_device::add_midi_6850(machine_config &config) { - acia6850_device &acia(ACIA6850(config, "acia", 0)); + acia6850_device &acia(ACIA6850(config, "acia")); acia.irq_handler().set(m_irqs, FUNC(input_merger_device::in_w<3>)); acia.txd_handler().set("mdout", FUNC(midi_port_device::write_txd)); @@ -355,7 +355,7 @@ void arc_midi_aka16_device::device_add_mconfig(machine_config &config) // arc_io_aka_device - constructor //------------------------------------------------- -arc_io_aka_device::arc_io_aka_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +arc_io_aka_device::arc_io_aka_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") @@ -366,22 +366,22 @@ arc_io_aka_device::arc_io_aka_device(const machine_config &mconfig, device_type { } -arc_bbcio_aka10_device::arc_bbcio_aka10_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_bbcio_aka10_device::arc_bbcio_aka10_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_io_aka_device(mconfig, ARC_BBCIO_AKA10, tag, owner, clock) { } -arc_upmidi_aka12_device::arc_upmidi_aka12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_upmidi_aka12_device::arc_upmidi_aka12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_io_aka_device(mconfig, ARC_UPMIDI_AKA12, tag, owner, clock) { } -arc_iomidi_aka15_device::arc_iomidi_aka15_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_iomidi_aka15_device::arc_iomidi_aka15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_io_aka_device(mconfig, ARC_IOMIDI_AKA15, tag, owner, clock) { } -arc_midi_aka16_device::arc_midi_aka16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_midi_aka16_device::arc_midi_aka16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_io_aka_device(mconfig, ARC_MIDI_AKA16, tag, owner, clock) { } diff --git a/src/devices/bus/archimedes/podule/io_hccs.cpp b/src/devices/bus/archimedes/podule/io_hccs.cpp index 16c73b22b7d..3f4ae014259 100644 --- a/src/devices/bus/archimedes/podule/io_hccs.cpp +++ b/src/devices/bus/archimedes/podule/io_hccs.cpp @@ -26,7 +26,7 @@ class arc_upa_hccs_device : { public: // construction/destruction - arc_upa_hccs_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_upa_hccs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -106,7 +106,7 @@ void arc_upa_hccs_device::device_add_mconfig(machine_config &config) // arc_upa_hccs_device - constructor //------------------------------------------------- -arc_upa_hccs_device::arc_upa_hccs_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_upa_hccs_device::arc_upa_hccs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_UPA_HCCS, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/io_morley.cpp b/src/devices/bus/archimedes/podule/io_morley.cpp index 3e6bccc755b..b30a11c4fc3 100644 --- a/src/devices/bus/archimedes/podule/io_morley.cpp +++ b/src/devices/bus/archimedes/podule/io_morley.cpp @@ -36,7 +36,7 @@ class arc_io_morley_device : public device_archimedes_podule_interface { protected: - arc_io_morley_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + arc_io_morley_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -63,7 +63,7 @@ class arc_bbcio_aga30_device : public arc_io_morley_device { public: // construction/destruction - arc_bbcio_aga30_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_bbcio_aga30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -82,7 +82,7 @@ class arc_ua_morley_device : public arc_io_morley_device { public: // construction/destruction - arc_ua_morley_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_ua_morley_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -101,7 +101,7 @@ class arc_uma_morley_device : public arc_io_morley_device { public: // construction/destruction - arc_uma_morley_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_uma_morley_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -266,7 +266,7 @@ void arc_uma_morley_device::device_add_mconfig(machine_config &config) // arc_io_morley_device - constructor //------------------------------------------------- -arc_io_morley_device::arc_io_morley_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +arc_io_morley_device::arc_io_morley_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") @@ -276,17 +276,17 @@ arc_io_morley_device::arc_io_morley_device(const machine_config &mconfig, device { } -arc_bbcio_aga30_device::arc_bbcio_aga30_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_bbcio_aga30_device::arc_bbcio_aga30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_io_morley_device(mconfig, ARC_BBCIO_AGA30, tag, owner, clock) { } -arc_ua_morley_device::arc_ua_morley_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_ua_morley_device::arc_ua_morley_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_io_morley_device(mconfig, ARC_UA_MORLEY, tag, owner, clock) { } -arc_uma_morley_device::arc_uma_morley_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_uma_morley_device::arc_uma_morley_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_io_morley_device(mconfig, ARC_UMA_MORLEY, tag, owner, clock) { } diff --git a/src/devices/bus/archimedes/podule/io_we.cpp b/src/devices/bus/archimedes/podule/io_we.cpp index 40d5092d824..20e18398f64 100644 --- a/src/devices/bus/archimedes/podule/io_we.cpp +++ b/src/devices/bus/archimedes/podule/io_we.cpp @@ -27,7 +27,7 @@ class arc_bbcio_we_device : { public: // construction/destruction - arc_bbcio_we_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_bbcio_we_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -129,7 +129,7 @@ void arc_bbcio_we_device::device_add_mconfig(machine_config &config) // arc_bbcio_we_device - constructor //------------------------------------------------- -arc_bbcio_we_device::arc_bbcio_we_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_bbcio_we_device::arc_bbcio_we_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_BBCIO_WE, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/lark.cpp b/src/devices/bus/archimedes/podule/lark.cpp index 54bfa5cd480..7d48f7d8b1a 100644 --- a/src/devices/bus/archimedes/podule/lark.cpp +++ b/src/devices/bus/archimedes/podule/lark.cpp @@ -25,7 +25,7 @@ class arc_lark_device : { public: // construction/destruction - arc_lark_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_lark_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::CAPTURE; } @@ -122,7 +122,7 @@ const tiny_rom_entry *arc_lark_device::device_rom_region() const void arc_lark_device::device_add_mconfig(machine_config &config) { - AD1848(config, m_ad1848, 0); + AD1848(config, m_ad1848); //m_ad1848->irq().set([this](int state) { set_irq(IRQ_AD1848, state); }); // not used/connected? m_ad1848->drq().set(FUNC(arc_lark_device::playback_drq)); @@ -152,7 +152,7 @@ void arc_lark_device::device_add_mconfig(machine_config &config) // arc_lark_device - constructor //------------------------------------------------- -arc_lark_device::arc_lark_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_lark_device::arc_lark_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_LARK, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/laserd.cpp b/src/devices/bus/archimedes/podule/laserd.cpp index eb688f3735f..b839a8236b7 100644 --- a/src/devices/bus/archimedes/podule/laserd.cpp +++ b/src/devices/bus/archimedes/podule/laserd.cpp @@ -27,7 +27,7 @@ public: static constexpr feature_type unemulated_features() { return feature::PRINTER; } protected: - arc_laserd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + arc_laserd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -53,7 +53,7 @@ class arc_lbp4_device : public arc_laserd_device { public: // construction/destruction - arc_lbp4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_lbp4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -125,7 +125,7 @@ void arc_laserd_device::device_add_mconfig(machine_config &config) // arc_laserd_device - constructor //------------------------------------------------- -arc_laserd_device::arc_laserd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +arc_laserd_device::arc_laserd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") @@ -133,7 +133,7 @@ arc_laserd_device::arc_laserd_device(const machine_config &mconfig, device_type { } -arc_lbp4_device::arc_lbp4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_lbp4_device::arc_lbp4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_laserd_device(mconfig, ARC_LBP4, tag, owner, clock) { } diff --git a/src/devices/bus/archimedes/podule/midi_emr.cpp b/src/devices/bus/archimedes/podule/midi_emr.cpp index 27127471c62..dae373cf72d 100644 --- a/src/devices/bus/archimedes/podule/midi_emr.cpp +++ b/src/devices/bus/archimedes/podule/midi_emr.cpp @@ -25,7 +25,7 @@ class arc_midi2_emr_device : { public: // construction/destruction - arc_midi2_emr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_midi2_emr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -54,7 +54,7 @@ class arc_midi4_emr_device : { public: // construction/destruction - arc_midi4_emr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_midi4_emr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -159,7 +159,7 @@ void arc_midi4_emr_device::device_add_mconfig(machine_config &config) // arc_midi_emr_device - constructor //------------------------------------------------- -arc_midi2_emr_device::arc_midi2_emr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_midi2_emr_device::arc_midi2_emr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_MIDI2_EMR, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") @@ -167,7 +167,7 @@ arc_midi2_emr_device::arc_midi2_emr_device(const machine_config &mconfig, const { } -arc_midi4_emr_device::arc_midi4_emr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_midi4_emr_device::arc_midi4_emr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_MIDI4_EMR, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) { diff --git a/src/devices/bus/archimedes/podule/midimax.cpp b/src/devices/bus/archimedes/podule/midimax.cpp index b8a43a2bfae..ff13269009d 100644 --- a/src/devices/bus/archimedes/podule/midimax.cpp +++ b/src/devices/bus/archimedes/podule/midimax.cpp @@ -24,10 +24,10 @@ class arc_midimax_device : { public: // construction/destruction - arc_midimax_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_midimax_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - arc_midimax_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + arc_midimax_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -53,7 +53,7 @@ class arc_midimax2_device : public arc_midimax_device { public: // construction/destruction - arc_midimax2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_midimax2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -127,7 +127,7 @@ void arc_midimax_device::device_add_mconfig(machine_config &config) // arc_midimax_device - constructor //------------------------------------------------- -arc_midimax_device::arc_midimax_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +arc_midimax_device::arc_midimax_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") @@ -135,12 +135,12 @@ arc_midimax_device::arc_midimax_device(const machine_config &mconfig, device_typ { } -arc_midimax_device::arc_midimax_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_midimax_device::arc_midimax_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_midimax_device(mconfig, ARC_MIDIMAX, tag, owner, clock) { } -arc_midimax2_device::arc_midimax2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_midimax2_device::arc_midimax2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_midimax_device(mconfig, ARC_MIDIMAX2, tag, owner, clock) { } diff --git a/src/devices/bus/archimedes/podule/nexus.cpp b/src/devices/bus/archimedes/podule/nexus.cpp index 9ab8dd63d46..760afb528b7 100644 --- a/src/devices/bus/archimedes/podule/nexus.cpp +++ b/src/devices/bus/archimedes/podule/nexus.cpp @@ -21,7 +21,7 @@ class arc_nexus_device : { public: // construction/destruction - arc_nexus_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_nexus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::COMMS; } @@ -90,7 +90,7 @@ void arc_nexus_device::device_add_mconfig(machine_config &config) // arc_nexus_device - constructor //------------------------------------------------- -arc_nexus_device::arc_nexus_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_nexus_device::arc_nexus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_NEXUS_A500, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/rom.cpp b/src/devices/bus/archimedes/podule/rom.cpp index be073229e5e..44510e62547 100644 --- a/src/devices/bus/archimedes/podule/rom.cpp +++ b/src/devices/bus/archimedes/podule/rom.cpp @@ -25,7 +25,7 @@ class arc_rom_aka05_device : { public: // construction/destruction - arc_rom_aka05_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_rom_aka05_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::ROM; } @@ -112,7 +112,7 @@ void arc_rom_aka05_device::device_add_mconfig(machine_config &config) // arc_rom_aka05_device - constructor //------------------------------------------------- -arc_rom_aka05_device::arc_rom_aka05_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_rom_aka05_device::arc_rom_aka05_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_ROM_AKA05, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/rs423.cpp b/src/devices/bus/archimedes/podule/rs423.cpp index d3f20c03edf..78a91e711a1 100644 --- a/src/devices/bus/archimedes/podule/rs423.cpp +++ b/src/devices/bus/archimedes/podule/rs423.cpp @@ -26,7 +26,7 @@ class arc_rs423_device : { public: // construction/destruction - arc_rs423_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_rs423_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -99,7 +99,7 @@ void arc_rs423_device::device_add_mconfig(machine_config &config) // arc_rs423_device - constructor //------------------------------------------------- -arc_rs423_device::arc_rs423_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_rs423_device::arc_rs423_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_RS423, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/scan256.cpp b/src/devices/bus/archimedes/podule/scan256.cpp index 8666084c04b..b8454035e4a 100644 --- a/src/devices/bus/archimedes/podule/scan256.cpp +++ b/src/devices/bus/archimedes/podule/scan256.cpp @@ -24,7 +24,7 @@ class arc_scan256_device : { public: // construction/destruction - arc_scan256_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_scan256_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::CAPTURE; } @@ -88,7 +88,7 @@ void arc_scan256_device::device_add_mconfig(machine_config &config) // arc_scan256_device - constructor //------------------------------------------------- -arc_scan256_device::arc_scan256_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_scan256_device::arc_scan256_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_SCAN256, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/scanlight.cpp b/src/devices/bus/archimedes/podule/scanlight.cpp index 7e22683032f..348610d6383 100644 --- a/src/devices/bus/archimedes/podule/scanlight.cpp +++ b/src/devices/bus/archimedes/podule/scanlight.cpp @@ -36,12 +36,12 @@ class arc_scanlight_device : { public: // construction/destruction - arc_scanlight_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_scanlight_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::CAPTURE; } protected: - arc_scanlight_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + arc_scanlight_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -68,7 +68,7 @@ class arc_scanjunior_device : public arc_scanlight_device { public: // construction/destruction - arc_scanjunior_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_scanjunior_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -82,7 +82,7 @@ class arc_scanjunior3_device : public arc_scanlight_device { public: // construction/destruction - arc_scanjunior3_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_scanjunior3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -96,7 +96,7 @@ class arc_scanvideo_device : public arc_scanlight_device { public: // construction/destruction - arc_scanvideo_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_scanvideo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -199,7 +199,7 @@ void arc_scanvideo_device::device_add_mconfig(machine_config &config) // arc_scanlight_device - constructor //------------------------------------------------- -arc_scanlight_device::arc_scanlight_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +arc_scanlight_device::arc_scanlight_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") @@ -208,22 +208,22 @@ arc_scanlight_device::arc_scanlight_device(const machine_config &mconfig, device { } -arc_scanlight_device::arc_scanlight_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_scanlight_device::arc_scanlight_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_scanlight_device(mconfig, ARC_SCANLIGHT, tag, owner, clock) { } -arc_scanjunior_device::arc_scanjunior_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_scanjunior_device::arc_scanjunior_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_scanlight_device(mconfig, ARC_SCANJUNIOR, tag, owner, clock) { } -arc_scanjunior3_device::arc_scanjunior3_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_scanjunior3_device::arc_scanjunior3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_scanlight_device(mconfig, ARC_SCANJUNIOR3, tag, owner, clock) { } -arc_scanvideo_device::arc_scanvideo_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_scanvideo_device::arc_scanvideo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arc_scanlight_device(mconfig, ARC_SCANVIDEO, tag, owner, clock) , m_avivideo(*this, "srcavi") { diff --git a/src/devices/bus/archimedes/podule/scsi_vti.cpp b/src/devices/bus/archimedes/podule/scsi_vti.cpp index f0239dfeeb0..85b2ee04d70 100644 --- a/src/devices/bus/archimedes/podule/scsi_vti.cpp +++ b/src/devices/bus/archimedes/podule/scsi_vti.cpp @@ -29,7 +29,7 @@ class arc_scsi_vti_device : { public: // construction/destruction - arc_scsi_vti_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_scsi_vti_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type imperfect_features() { return feature::DISK; } @@ -133,7 +133,7 @@ void arc_scsi_vti_device::device_add_mconfig(machine_config &config) // arc_scsi_vti_device - constructor //------------------------------------------------- -arc_scsi_vti_device::arc_scsi_vti_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_scsi_vti_device::arc_scsi_vti_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_SCSI_VTI, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_fas216(*this, "scsi:7:fas216") diff --git a/src/devices/bus/archimedes/podule/serial.cpp b/src/devices/bus/archimedes/podule/serial.cpp index dff0fa826f9..a195607ac3f 100644 --- a/src/devices/bus/archimedes/podule/serial.cpp +++ b/src/devices/bus/archimedes/podule/serial.cpp @@ -24,7 +24,7 @@ class arc_serial_device : { public: // construction/destruction - arc_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -119,7 +119,7 @@ void arc_serial_device::device_add_mconfig(machine_config &config) // arc_serial_device - constructor //------------------------------------------------- -arc_serial_device::arc_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_serial_device::arc_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_SERIAL, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/slot.cpp b/src/devices/bus/archimedes/podule/slot.cpp index 75498df27a9..b783b7e0622 100644 --- a/src/devices/bus/archimedes/podule/slot.cpp +++ b/src/devices/bus/archimedes/podule/slot.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(ARCHIMEDES_PODULE_SLOT, archimedes_podule_slot_device, "archi //------------------------------------------------- // archimedes_podule_slot_device - constructor //------------------------------------------------- -archimedes_podule_slot_device::archimedes_podule_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +archimedes_podule_slot_device::archimedes_podule_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARCHIMEDES_PODULE_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_archimedes_podule_interface>(mconfig, *this) , m_exp(*this, finder_base::DUMMY_TAG) @@ -63,7 +63,7 @@ DEFINE_DEVICE_TYPE(ARCHIMEDES_EXPANSION_BUS, archimedes_exp_device, "archimedes_ // archimedes_exp_device - constructor //------------------------------------------------- -archimedes_exp_device::archimedes_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +archimedes_exp_device::archimedes_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARCHIMEDES_EXPANSION_BUS, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_ioc_config("podule_ioc", ENDIANNESS_LITTLE, 32, 16, 0, address_map_constructor(FUNC(archimedes_exp_device::ioc_map), this)) diff --git a/src/devices/bus/archimedes/podule/slot.h b/src/devices/bus/archimedes/podule/slot.h index eca2c54865f..56e7258ab10 100644 --- a/src/devices/bus/archimedes/podule/slot.h +++ b/src/devices/bus/archimedes/podule/slot.h @@ -41,7 +41,7 @@ public: set_fixed(false); m_exp.set_tag(std::forward<T>(bus_tag)); } - archimedes_podule_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + archimedes_podule_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -63,7 +63,7 @@ class archimedes_exp_device : public device_t, { public: // construction/destruction - archimedes_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + archimedes_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration auto out_irq_callback() { return m_out_pirq_cb.bind(); } diff --git a/src/devices/bus/archimedes/podule/spectra.cpp b/src/devices/bus/archimedes/podule/spectra.cpp index 6c144dbebf7..5718860f229 100644 --- a/src/devices/bus/archimedes/podule/spectra.cpp +++ b/src/devices/bus/archimedes/podule/spectra.cpp @@ -24,7 +24,7 @@ class arc_spectra_device : { public: // construction/destruction - arc_spectra_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_spectra_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::CAPTURE; } @@ -88,7 +88,7 @@ void arc_spectra_device::device_add_mconfig(machine_config &config) // arc_spectra_device - constructor //------------------------------------------------- -arc_spectra_device::arc_spectra_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_spectra_device::arc_spectra_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_SPECTRA, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) , m_podule_rom(*this, "podule_rom") diff --git a/src/devices/bus/archimedes/podule/tube.cpp b/src/devices/bus/archimedes/podule/tube.cpp index 84d699b4bc2..3ea106bc346 100644 --- a/src/devices/bus/archimedes/podule/tube.cpp +++ b/src/devices/bus/archimedes/podule/tube.cpp @@ -22,7 +22,7 @@ class arc_tube_device : { public: // construction/destruction - arc_tube_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arc_tube_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -62,7 +62,7 @@ void arc_tube_device::device_add_mconfig(machine_config &config) // arc_tube_device - constructor //------------------------------------------------- -arc_tube_device::arc_tube_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arc_tube_device::arc_tube_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARC_TUBE, tag, owner, clock) , device_archimedes_podule_interface(mconfig, *this) { diff --git a/src/devices/bus/astrocde/accessory.cpp b/src/devices/bus/astrocde/accessory.cpp index fb047e660d8..b54e0e85527 100644 --- a/src/devices/bus/astrocde/accessory.cpp +++ b/src/devices/bus/astrocde/accessory.cpp @@ -47,7 +47,7 @@ void device_astrocade_accessory_interface::interface_pre_start() // Bally Astrocade accessory port //************************************************************************** -astrocade_accessory_port_device::astrocade_accessory_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +astrocade_accessory_port_device::astrocade_accessory_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_ACCESSORY_PORT, tag, owner, clock) , device_single_card_slot_interface<device_astrocade_accessory_interface>(mconfig, *this) , m_ltpen(0) diff --git a/src/devices/bus/astrocde/accessory.h b/src/devices/bus/astrocde/accessory.h index 5386cd1362a..f8e2a44074b 100644 --- a/src/devices/bus/astrocde/accessory.h +++ b/src/devices/bus/astrocde/accessory.h @@ -27,7 +27,7 @@ public: // construction/destruction template <typename T, typename U> astrocade_accessory_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&screen_tag, U &&opts, char const *dflt) - : astrocade_accessory_port_device(mconfig, tag, owner, 0U) + : astrocade_accessory_port_device(mconfig, tag, owner) { m_screen.set_tag(std::forward<T>(screen_tag)); option_reset(); @@ -35,7 +35,7 @@ public: set_default_option(dflt); set_fixed(false); } - astrocade_accessory_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + astrocade_accessory_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~astrocade_accessory_port_device(); auto ltpen_handler() { return m_ltpen_handler.bind(); } diff --git a/src/devices/bus/astrocde/cassette.cpp b/src/devices/bus/astrocde/cassette.cpp index 3e4cc80deb8..5e92dedcaad 100644 --- a/src/devices/bus/astrocde/cassette.cpp +++ b/src/devices/bus/astrocde/cassette.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(ASTROCADE_CASSETTE, astrocade_cassette_device, "astrocade_cas // Bally Astrocade cassette input //************************************************************************** -astrocade_cassette_device::astrocade_cassette_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +astrocade_cassette_device::astrocade_cassette_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_CASSETTE, tag, owner, clock) , device_astrocade_ctrl_interface(mconfig, *this) , m_cassette(*this, "cassette") diff --git a/src/devices/bus/astrocde/cassette.h b/src/devices/bus/astrocde/cassette.h index d36e8a1bfd7..a6fb81a64bf 100644 --- a/src/devices/bus/astrocde/cassette.h +++ b/src/devices/bus/astrocde/cassette.h @@ -25,7 +25,7 @@ public: static constexpr feature_type imperfect_features() { return feature::TAPE; } // construction/destruction - astrocade_cassette_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + astrocade_cassette_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~astrocade_cassette_device(); // device_astrocade_ctrl_interface implementation diff --git a/src/devices/bus/astrocde/ctrl.cpp b/src/devices/bus/astrocde/ctrl.cpp index b33c8aebb49..fb98284bace 100644 --- a/src/devices/bus/astrocde/ctrl.cpp +++ b/src/devices/bus/astrocde/ctrl.cpp @@ -56,7 +56,7 @@ WRITE_LINE_MEMBER( device_astrocade_ctrl_interface::write_ltpen ) // Bally Astrocade controller port //************************************************************************** -astrocade_ctrl_port_device::astrocade_ctrl_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +astrocade_ctrl_port_device::astrocade_ctrl_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_CTRL_PORT, tag, owner, clock) , device_single_card_slot_interface<device_astrocade_ctrl_interface>(mconfig, *this) , m_ltpen(0) diff --git a/src/devices/bus/astrocde/ctrl.h b/src/devices/bus/astrocde/ctrl.h index 0273b4a80fd..c32d9eb8bb7 100644 --- a/src/devices/bus/astrocde/ctrl.h +++ b/src/devices/bus/astrocde/ctrl.h @@ -51,14 +51,14 @@ public: // construction/destruction template <typename T> astrocade_ctrl_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : astrocade_ctrl_port_device(mconfig, tag, owner, 0U) + : astrocade_ctrl_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - astrocade_ctrl_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + astrocade_ctrl_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~astrocade_ctrl_port_device(); auto ltpen_handler() { return m_ltpen_handler.bind(); } diff --git a/src/devices/bus/astrocde/exp.cpp b/src/devices/bus/astrocde/exp.cpp index a33259380f1..0d0ea58cf7b 100644 --- a/src/devices/bus/astrocde/exp.cpp +++ b/src/devices/bus/astrocde/exp.cpp @@ -35,7 +35,7 @@ device_astrocade_exp_interface::~device_astrocade_exp_interface() //------------------------------------------------- // astrocade_exp_device - constructor //------------------------------------------------- -astrocade_exp_device::astrocade_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +astrocade_exp_device::astrocade_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_EXP_SLOT, tag, owner, clock), device_single_card_slot_interface<device_astrocade_exp_interface>(mconfig, *this), m_card_mounted(false), m_card(nullptr) diff --git a/src/devices/bus/astrocde/exp.h b/src/devices/bus/astrocde/exp.h index e2ed2279135..6d8aac21cd0 100644 --- a/src/devices/bus/astrocde/exp.h +++ b/src/devices/bus/astrocde/exp.h @@ -30,14 +30,14 @@ public: // construction/destruction template <typename T> astrocade_exp_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : astrocade_exp_device(mconfig, tag, owner, (uint32_t)0) + : astrocade_exp_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - astrocade_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~astrocade_exp_device(); // device-level overrides diff --git a/src/devices/bus/astrocde/joy.cpp b/src/devices/bus/astrocde/joy.cpp index cbf75da0c5c..ea034898232 100644 --- a/src/devices/bus/astrocde/joy.cpp +++ b/src/devices/bus/astrocde/joy.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(ASTROCADE_JOY, astrocade_joy_device, "astrocade_joy", "Bally // Bally Astrocade joystick control //************************************************************************** -astrocade_joy_device::astrocade_joy_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +astrocade_joy_device::astrocade_joy_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_JOY, tag, owner, clock) , device_astrocade_ctrl_interface(mconfig, *this) , m_handle(*this, "HANDLE") diff --git a/src/devices/bus/astrocde/joy.h b/src/devices/bus/astrocde/joy.h index bb8f755c845..dbbf3353fd5 100644 --- a/src/devices/bus/astrocde/joy.h +++ b/src/devices/bus/astrocde/joy.h @@ -18,7 +18,7 @@ class astrocade_joy_device : public device_t, { public: // construction/destruction - astrocade_joy_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + astrocade_joy_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~astrocade_joy_device(); // device_astrocade_ctrl_interface implementation diff --git a/src/devices/bus/astrocde/lightpen.cpp b/src/devices/bus/astrocde/lightpen.cpp index 40a7ec415de..1d9d81b7d4e 100644 --- a/src/devices/bus/astrocde/lightpen.cpp +++ b/src/devices/bus/astrocde/lightpen.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(ASTROCADE_LIGHTPEN, astrocade_lightpen_device, "astrocade_lig // Bally Astrocade light pen input //************************************************************************** -astrocade_lightpen_device::astrocade_lightpen_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +astrocade_lightpen_device::astrocade_lightpen_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_LIGHTPEN, tag, owner, clock) , device_astrocade_accessory_interface(mconfig, *this) , m_trigger(*this, "TRIGGER") diff --git a/src/devices/bus/astrocde/lightpen.h b/src/devices/bus/astrocde/lightpen.h index dd75c807443..49991a2574d 100644 --- a/src/devices/bus/astrocde/lightpen.h +++ b/src/devices/bus/astrocde/lightpen.h @@ -19,7 +19,7 @@ class astrocade_lightpen_device : public device_t, { public: // construction/destruction - astrocade_lightpen_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + astrocade_lightpen_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~astrocade_lightpen_device(); DECLARE_INPUT_CHANGED_MEMBER(trigger); diff --git a/src/devices/bus/astrocde/ram.cpp b/src/devices/bus/astrocde/ram.cpp index 39eb299d8f6..d8fde36cc92 100644 --- a/src/devices/bus/astrocde/ram.cpp +++ b/src/devices/bus/astrocde/ram.cpp @@ -68,7 +68,7 @@ DEFINE_DEVICE_TYPE(ASTROCADE_WHITERAM, astrocade_whiteram_device, "astroca DEFINE_DEVICE_TYPE(ASTROCADE_RL64RAM, astrocade_rl64ram_device, "astrocade_rl64", "Bally Astrocade R&L RAM 64K") -astrocade_blueram_4k_device::astrocade_blueram_4k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +astrocade_blueram_4k_device::astrocade_blueram_4k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_astrocade_exp_interface(mconfig, *this) , m_write_prot(*this, "RAM_PROTECT") @@ -77,36 +77,36 @@ astrocade_blueram_4k_device::astrocade_blueram_4k_device(const machine_config &m { } -astrocade_blueram_4k_device::astrocade_blueram_4k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_blueram_4k_device::astrocade_blueram_4k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : astrocade_blueram_4k_device(mconfig, ASTROCADE_BLUERAM_4K, tag, owner, clock) { } -astrocade_blueram_16k_device::astrocade_blueram_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_blueram_16k_device::astrocade_blueram_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : astrocade_blueram_4k_device(mconfig, ASTROCADE_BLUERAM_16K, tag, owner, clock) { } -astrocade_blueram_32k_device::astrocade_blueram_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_blueram_32k_device::astrocade_blueram_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : astrocade_blueram_4k_device(mconfig, ASTROCADE_BLUERAM_32K, tag, owner, clock) { } -astrocade_viper_sys1_device::astrocade_viper_sys1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_viper_sys1_device::astrocade_viper_sys1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_VIPER_SYS1, tag, owner, clock) , device_astrocade_exp_interface(mconfig, *this) , m_write_prot(*this, "RAM_PROTECT") { } -astrocade_whiteram_device::astrocade_whiteram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_whiteram_device::astrocade_whiteram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_WHITERAM, tag, owner, clock) , device_astrocade_exp_interface(mconfig, *this) , m_write_prot(*this, "RAM_PROTECT") { } -astrocade_rl64ram_device::astrocade_rl64ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_rl64ram_device::astrocade_rl64ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_RL64RAM, tag, owner, clock) , device_astrocade_exp_interface(mconfig, *this) , m_write_prot(*this, "RAM_PROTECT") diff --git a/src/devices/bus/astrocde/ram.h b/src/devices/bus/astrocde/ram.h index 22e6e3bd590..21e9d10c857 100644 --- a/src/devices/bus/astrocde/ram.h +++ b/src/devices/bus/astrocde/ram.h @@ -16,7 +16,7 @@ class astrocade_blueram_4k_device : public device_t, public device_astrocade_exp { public: // construction/destruction - astrocade_blueram_4k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_blueram_4k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; @@ -33,7 +33,7 @@ public: void portb_w(uint8_t data); protected: - astrocade_blueram_4k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + astrocade_blueram_4k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override { m_ram.resize(0x1000); save_item(NAME(m_ram)); } virtual void device_reset() override { } @@ -51,7 +51,7 @@ class astrocade_blueram_16k_device : public astrocade_blueram_4k_device { public: // construction/destruction - astrocade_blueram_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_blueram_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override { m_ram.resize(0x4000); save_item(NAME(m_ram)); } }; @@ -62,7 +62,7 @@ class astrocade_blueram_32k_device : public astrocade_blueram_4k_device { public: // construction/destruction - astrocade_blueram_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_blueram_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override { m_ram.resize(0x8000); save_item(NAME(m_ram)); } }; @@ -73,7 +73,7 @@ class astrocade_viper_sys1_device : public device_t, public device_astrocade_exp { public: // construction/destruction - astrocade_viper_sys1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_viper_sys1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; @@ -97,7 +97,7 @@ class astrocade_whiteram_device : public device_t, public device_astrocade_exp_i { public: // construction/destruction - astrocade_whiteram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_whiteram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; @@ -121,7 +121,7 @@ class astrocade_rl64ram_device : public device_t, public device_astrocade_exp_in { public: // construction/destruction - astrocade_rl64ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_rl64ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/astrocde/rom.cpp b/src/devices/bus/astrocde/rom.cpp index e574c63ecd7..4fd04ead658 100644 --- a/src/devices/bus/astrocde/rom.cpp +++ b/src/devices/bus/astrocde/rom.cpp @@ -23,27 +23,27 @@ DEFINE_DEVICE_TYPE(ASTROCADE_ROM_512K, astrocade_rom_512k_device, "astrocade_rom DEFINE_DEVICE_TYPE(ASTROCADE_ROM_CASS, astrocade_rom_cass_device, "astrocade_rom_cass", "Bally Astrocade AstroBASIC Cart") -astrocade_rom_device::astrocade_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +astrocade_rom_device::astrocade_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_astrocade_cart_interface(mconfig, *this) { } -astrocade_rom_device::astrocade_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_rom_device::astrocade_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : astrocade_rom_device(mconfig, ASTROCADE_ROM_STD, tag, owner, clock) { } -astrocade_rom_256k_device::astrocade_rom_256k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_rom_256k_device::astrocade_rom_256k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : astrocade_rom_device(mconfig, ASTROCADE_ROM_256K, tag, owner, clock), m_base_bank(0) { } -astrocade_rom_512k_device::astrocade_rom_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_rom_512k_device::astrocade_rom_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : astrocade_rom_device(mconfig, ASTROCADE_ROM_512K, tag, owner, clock), m_base_bank(0) { } -astrocade_rom_cass_device::astrocade_rom_cass_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_rom_cass_device::astrocade_rom_cass_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : astrocade_rom_device(mconfig, ASTROCADE_ROM_CASS, tag, owner, clock) , m_cassette(*this, "cassette") { diff --git a/src/devices/bus/astrocde/rom.h b/src/devices/bus/astrocde/rom.h index 8a8db1634de..8c88248ef8d 100644 --- a/src/devices/bus/astrocde/rom.h +++ b/src/devices/bus/astrocde/rom.h @@ -16,13 +16,13 @@ class astrocade_rom_device : public device_t, { public: // construction/destruction - astrocade_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; protected: - astrocade_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + astrocade_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -35,7 +35,7 @@ class astrocade_rom_256k_device : public astrocade_rom_device { public: // construction/destruction - astrocade_rom_256k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_rom_256k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; @@ -53,7 +53,7 @@ class astrocade_rom_512k_device : public astrocade_rom_device { public: // construction/destruction - astrocade_rom_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_rom_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; @@ -71,7 +71,7 @@ class astrocade_rom_cass_device : public astrocade_rom_device { public: // construction/destruction - astrocade_rom_cass_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_rom_cass_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; diff --git a/src/devices/bus/astrocde/slot.cpp b/src/devices/bus/astrocde/slot.cpp index 6581dee5d01..06b2d961d15 100644 --- a/src/devices/bus/astrocde/slot.cpp +++ b/src/devices/bus/astrocde/slot.cpp @@ -61,7 +61,7 @@ void device_astrocade_cart_interface::rom_alloc(uint32_t size) //------------------------------------------------- // astrocade_cart_slot_device - constructor //------------------------------------------------- -astrocade_cart_slot_device::astrocade_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +astrocade_cart_slot_device::astrocade_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_astrocade_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/astrocde/slot.h b/src/devices/bus/astrocde/slot.h index 49242f2c31d..6d0bf86a9b1 100644 --- a/src/devices/bus/astrocde/slot.h +++ b/src/devices/bus/astrocde/slot.h @@ -56,14 +56,14 @@ public: // construction/destruction template <typename T> astrocade_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : astrocade_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : astrocade_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - astrocade_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + astrocade_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~astrocade_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/ata/atadev.cpp b/src/devices/bus/ata/atadev.cpp index d4e3e3cd3fa..3e37d12bcef 100644 --- a/src/devices/bus/ata/atadev.cpp +++ b/src/devices/bus/ata/atadev.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(ATA_SLOT, ata_slot_device, "ata_slot", "ATA Connector") // ata_slot_device - constructor //------------------------------------------------- -ata_slot_device::ata_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ata_slot_device::ata_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ATA_SLOT, tag, owner, clock), device_single_card_slot_interface<device_ata_interface>(mconfig, *this), m_dev(nullptr) diff --git a/src/devices/bus/ata/atadev.h b/src/devices/bus/ata/atadev.h index 41832a8d22a..43164d7de7f 100644 --- a/src/devices/bus/ata/atadev.h +++ b/src/devices/bus/ata/atadev.h @@ -51,7 +51,7 @@ class ata_slot_device : public device_t, { public: // construction/destruction - ata_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ata_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); device_ata_interface *dev() { return m_dev; } diff --git a/src/devices/bus/ata/atahle.cpp b/src/devices/bus/ata/atahle.cpp index 0ba22e2773b..a2f8de9b6a9 100644 --- a/src/devices/bus/ata/atahle.cpp +++ b/src/devices/bus/ata/atahle.cpp @@ -40,7 +40,7 @@ enum #define DEVICE1_PDIAG_TIME (attotime::from_msec(2)) #define DIAGNOSTIC_TIME (attotime::from_msec(2)) -ata_hle_device::ata_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ata_hle_device::ata_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_ata_interface(mconfig, *this), m_buffer_offset(0), diff --git a/src/devices/bus/ata/atahle.h b/src/devices/bus/ata/atahle.h index 5fcfa90c478..56cefd3b106 100644 --- a/src/devices/bus/ata/atahle.h +++ b/src/devices/bus/ata/atahle.h @@ -31,7 +31,7 @@ public: virtual DECLARE_WRITE_LINE_MEMBER(write_pdiag) override; protected: - ata_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ata_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/ata/ataintf.cpp b/src/devices/bus/ata/ataintf.cpp index d2a09e7a689..ff95998925a 100644 --- a/src/devices/bus/ata/ataintf.cpp +++ b/src/devices/bus/ata/ataintf.cpp @@ -206,7 +206,7 @@ WRITE_LINE_MEMBER( abstract_ata_interface_device::write_dmack ) elem->dev()->write_dmack(state); } -abstract_ata_interface_device::abstract_ata_interface_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +abstract_ata_interface_device::abstract_ata_interface_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_slot(*this, "%u", 0U), m_irq_handler(*this), @@ -218,7 +218,7 @@ abstract_ata_interface_device::abstract_ata_interface_device(const machine_confi DEFINE_DEVICE_TYPE(ATA_INTERFACE, ata_interface_device, "ata_interface", "ATA Interface") -ata_interface_device::ata_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ata_interface_device::ata_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : abstract_ata_interface_device(mconfig, ATA_INTERFACE, tag, owner, clock) { } diff --git a/src/devices/bus/ata/ataintf.h b/src/devices/bus/ata/ataintf.h index 8fef178553d..7259b5df73a 100644 --- a/src/devices/bus/ata/ataintf.h +++ b/src/devices/bus/ata/ataintf.h @@ -62,7 +62,7 @@ public: DECLARE_WRITE_LINE_MEMBER(write_dmack); protected: - abstract_ata_interface_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + abstract_ata_interface_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); uint16_t internal_read_cs0(offs_t offset, uint16_t mem_mask = 0xffff); uint16_t internal_read_cs1(offs_t offset, uint16_t mem_mask = 0xffff); @@ -110,7 +110,7 @@ private: class ata_interface_device : public abstract_ata_interface_device { public: - ata_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ata_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> ata_interface_device &master(T &&opts, const char *dflt = nullptr, bool fixed = false) { diff --git a/src/devices/bus/ata/atapicdr.cpp b/src/devices/bus/ata/atapicdr.cpp index fd3003f58d3..3bc77549578 100644 --- a/src/devices/bus/ata/atapicdr.cpp +++ b/src/devices/bus/ata/atapicdr.cpp @@ -11,18 +11,18 @@ DEFINE_DEVICE_TYPE(ATAPI_CDROM, atapi_cdrom_device, "cdrom", "ATAPI CD-ROM") DEFINE_DEVICE_TYPE(ATAPI_FIXED_CDROM, atapi_fixed_cdrom_device, "cdrom_fixed", "ATAPI fixed CD-ROM") -atapi_cdrom_device::atapi_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +atapi_cdrom_device::atapi_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : atapi_cdrom_device(mconfig, ATAPI_CDROM, tag, owner, clock) { } -atapi_cdrom_device::atapi_cdrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +atapi_cdrom_device::atapi_cdrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : atapi_hle_device(mconfig, type, tag, owner, clock), ultra_dma_mode(0) { } -atapi_fixed_cdrom_device::atapi_fixed_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +atapi_fixed_cdrom_device::atapi_fixed_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : atapi_cdrom_device(mconfig, ATAPI_FIXED_CDROM, tag, owner, clock) { } diff --git a/src/devices/bus/ata/atapicdr.h b/src/devices/bus/ata/atapicdr.h index c2ffbb92fee..65ad5278bab 100644 --- a/src/devices/bus/ata/atapicdr.h +++ b/src/devices/bus/ata/atapicdr.h @@ -19,14 +19,14 @@ class atapi_cdrom_device : public atapi_hle_device, public t10mmc { public: - atapi_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atapi_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_ultra_dma_mode(uint16_t mode); uint16_t *identify_device_buffer() { return m_identify_buffer; } protected: - atapi_cdrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + atapi_cdrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -44,7 +44,7 @@ protected: class atapi_fixed_cdrom_device : public atapi_cdrom_device { public: - atapi_fixed_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atapi_fixed_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; diff --git a/src/devices/bus/ata/atapihle.cpp b/src/devices/bus/ata/atapihle.cpp index b416cdf1e94..de2b07cb6d0 100644 --- a/src/devices/bus/ata/atapihle.cpp +++ b/src/devices/bus/ata/atapihle.cpp @@ -3,7 +3,7 @@ #include "emu.h" #include "atapihle.h" -atapi_hle_device::atapi_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +atapi_hle_device::atapi_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ata_hle_device(mconfig, type, tag, owner, clock), m_packet(0), m_data_size(0) diff --git a/src/devices/bus/ata/atapihle.h b/src/devices/bus/ata/atapihle.h index 8d1bb95eec4..9d091a28d58 100644 --- a/src/devices/bus/ata/atapihle.h +++ b/src/devices/bus/ata/atapihle.h @@ -47,7 +47,7 @@ public: }; protected: - atapi_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + atapi_hle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/ata/cr589.cpp b/src/devices/bus/ata/cr589.cpp index 5905a54bd54..473ba7d64a8 100644 --- a/src/devices/bus/ata/cr589.cpp +++ b/src/devices/bus/ata/cr589.cpp @@ -142,7 +142,7 @@ void matsushita_cr589_device::WriteData( uint8_t *data, int dataLength ) // device type definition DEFINE_DEVICE_TYPE(CR589, matsushita_cr589_device, "cr589", "Matsushita CR589 CD-ROM Drive") -matsushita_cr589_device::matsushita_cr589_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +matsushita_cr589_device::matsushita_cr589_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : atapi_cdrom_device(mconfig, CR589, tag, owner, clock), device_nvram_interface(mconfig, *this) { diff --git a/src/devices/bus/ata/cr589.h b/src/devices/bus/ata/cr589.h index 9b2f89d172c..fb58b658ae6 100644 --- a/src/devices/bus/ata/cr589.h +++ b/src/devices/bus/ata/cr589.h @@ -19,7 +19,7 @@ class matsushita_cr589_device : public atapi_cdrom_device, public device_nvram_interface { public: - matsushita_cr589_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + matsushita_cr589_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void ExecCommand() override; virtual void WriteData( uint8_t *data, int dataLength ) override; diff --git a/src/devices/bus/ata/gdrom.cpp b/src/devices/bus/ata/gdrom.cpp index 59a7d154d56..a0d2192d369 100644 --- a/src/devices/bus/ata/gdrom.cpp +++ b/src/devices/bus/ata/gdrom.cpp @@ -509,7 +509,7 @@ void gdrom_device::SetDevice(void *device) // device type definition DEFINE_DEVICE_TYPE(GDROM, gdrom_device, "gdrom", "GD-ROM") -gdrom_device::gdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gdrom_device::gdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : atapi_cdrom_device(mconfig, GDROM, tag, owner, clock), is_real_gdrom_disc(false) { diff --git a/src/devices/bus/ata/gdrom.h b/src/devices/bus/ata/gdrom.h index 66565e7160b..11c48071eb8 100644 --- a/src/devices/bus/ata/gdrom.h +++ b/src/devices/bus/ata/gdrom.h @@ -16,7 +16,7 @@ class gdrom_device : public atapi_cdrom_device { public: - gdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Sega GD-ROM handler diff --git a/src/devices/bus/ata/idehd.cpp b/src/devices/bus/ata/idehd.cpp index 38ea6c21c6c..080577feffc 100644 --- a/src/devices/bus/ata/idehd.cpp +++ b/src/devices/bus/ata/idehd.cpp @@ -20,7 +20,7 @@ #define TIME_FULL_STROKE_SEEK (attotime::from_usec(13000)) #define TIME_AVERAGE_ROTATIONAL_LATENCY (attotime::from_usec(1300)) -ata_mass_storage_device::ata_mass_storage_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ata_mass_storage_device::ata_mass_storage_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ata_hle_device(mconfig, type, tag, owner, clock), m_can_identify_device(0), m_num_cylinders(0), @@ -796,12 +796,12 @@ DEFINE_DEVICE_TYPE(IDE_HARDDISK, ide_hdd_device, "idehd", "IDE Hard Disk") // ide_hdd_device - constructor //------------------------------------------------- -ide_hdd_device::ide_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ide_hdd_device::ide_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ide_hdd_device(mconfig, IDE_HARDDISK, tag, owner, clock) { } -ide_hdd_device::ide_hdd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ide_hdd_device::ide_hdd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ata_mass_storage_device(mconfig, type, tag, owner, clock), m_image(*this, "image") { diff --git a/src/devices/bus/ata/idehd.h b/src/devices/bus/ata/idehd.h index 0d7a999a412..eff7653d808 100644 --- a/src/devices/bus/ata/idehd.h +++ b/src/devices/bus/ata/idehd.h @@ -36,7 +36,7 @@ public: void set_dma_transfer_time(const attotime time) { m_dma_transfer_time = time; } protected: - ata_mass_storage_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ata_mass_storage_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -90,10 +90,10 @@ class ide_hdd_device : public ata_mass_storage_device { public: // construction/destruction - ide_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ide_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - ide_hdd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ide_hdd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/ata/px320a.cpp b/src/devices/bus/ata/px320a.cpp index fabad11e967..ec78f44788a 100644 --- a/src/devices/bus/ata/px320a.cpp +++ b/src/devices/bus/ata/px320a.cpp @@ -12,7 +12,7 @@ DEFINE_DEVICE_TYPE(PX320A, px320a_device, "px320a", "PleXCombo PX-320A CD-RW/DVD-ROM Drive") -px320a_device::px320a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +px320a_device::px320a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PX320A, tag, owner, clock) , device_ata_interface(mconfig, *this) , m_frcpu(*this, "frcpu") @@ -75,7 +75,7 @@ void px320a_device::frcpu_map(address_map &map) void px320a_device::device_add_mconfig(machine_config &config) { - MB91F155A(config, m_frcpu, 16'000'000); // FR type guessed; clock unknown + MB91F155A(config, m_frcpu, XTAL::u(16'000'000)); // FR type guessed; clock unknown m_frcpu->set_addrmap(AS_PROGRAM, &px320a_device::frcpu_map); } diff --git a/src/devices/bus/ata/px320a.h b/src/devices/bus/ata/px320a.h index 938fc3a580b..5c872245df4 100644 --- a/src/devices/bus/ata/px320a.h +++ b/src/devices/bus/ata/px320a.h @@ -11,7 +11,7 @@ class px320a_device : public device_t, public device_ata_interface { public: - px320a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + px320a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/bbc/1mhzbus/1mhzbus.cpp b/src/devices/bus/bbc/1mhzbus/1mhzbus.cpp index 0af231e4eb3..cbfba97eabb 100644 --- a/src/devices/bus/bbc/1mhzbus/1mhzbus.cpp +++ b/src/devices/bus/bbc/1mhzbus/1mhzbus.cpp @@ -41,7 +41,7 @@ device_bbc_1mhzbus_interface::device_bbc_1mhzbus_interface(const machine_config // bbc_1mhzbus_slot_device - constructor //------------------------------------------------- -bbc_1mhzbus_slot_device::bbc_1mhzbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_1mhzbus_slot_device::bbc_1mhzbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_1MHZBUS_SLOT, tag, owner, clock), device_single_card_slot_interface<device_bbc_1mhzbus_interface>(mconfig, *this), m_card(nullptr), diff --git a/src/devices/bus/bbc/1mhzbus/1mhzbus.h b/src/devices/bus/bbc/1mhzbus/1mhzbus.h index 302348b6822..dcc1b26873e 100644 --- a/src/devices/bus/bbc/1mhzbus/1mhzbus.h +++ b/src/devices/bus/bbc/1mhzbus/1mhzbus.h @@ -92,7 +92,7 @@ class bbc_1mhzbus_slot_device : public device_t, public device_single_card_slot_ public: // construction/destruction template <typename T> - bbc_1mhzbus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&slot_options, const char *default_option) + bbc_1mhzbus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&slot_options, const char *default_option) : bbc_1mhzbus_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -101,7 +101,7 @@ public: set_fixed(false); } - bbc_1mhzbus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + bbc_1mhzbus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // callbacks auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/bus/bbc/1mhzbus/autoprom.cpp b/src/devices/bus/bbc/1mhzbus/autoprom.cpp index 0bf0b0cfefd..74c74c449f9 100644 --- a/src/devices/bus/bbc/1mhzbus/autoprom.cpp +++ b/src/devices/bus/bbc/1mhzbus/autoprom.cpp @@ -96,7 +96,7 @@ const tiny_rom_entry *bbc_autoprom_device::device_rom_region() const // bbc_autoprom_device - constructor //------------------------------------------------- -bbc_autoprom_device::bbc_autoprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_autoprom_device::bbc_autoprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_AUTOPROM, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_autorun(*this, "autorun") diff --git a/src/devices/bus/bbc/1mhzbus/autoprom.h b/src/devices/bus/bbc/1mhzbus/autoprom.h index 358b5819f2b..26f44b66351 100644 --- a/src/devices/bus/bbc/1mhzbus/autoprom.h +++ b/src/devices/bus/bbc/1mhzbus/autoprom.h @@ -23,7 +23,7 @@ class bbc_autoprom_device : { public: // construction/destruction - bbc_autoprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_autoprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/beebopl.cpp b/src/devices/bus/bbc/1mhzbus/beebopl.cpp index 9c3db9ca6ff..36c1cbe561f 100644 --- a/src/devices/bus/bbc/1mhzbus/beebopl.cpp +++ b/src/devices/bus/bbc/1mhzbus/beebopl.cpp @@ -47,7 +47,7 @@ void bbc_beebopl_device::device_add_mconfig(machine_config &config) // bbc_beebopl_device - constructor //------------------------------------------------- -bbc_beebopl_device::bbc_beebopl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_beebopl_device::bbc_beebopl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_BEEBOPL, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_1mhzbus(*this, "1mhzbus") diff --git a/src/devices/bus/bbc/1mhzbus/beebopl.h b/src/devices/bus/bbc/1mhzbus/beebopl.h index 618bea6af41..ba0dd7e7cbc 100644 --- a/src/devices/bus/bbc/1mhzbus/beebopl.h +++ b/src/devices/bus/bbc/1mhzbus/beebopl.h @@ -25,7 +25,7 @@ class bbc_beebopl_device : { public: // construction/destruction - bbc_beebopl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_beebopl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/beebsid.cpp b/src/devices/bus/bbc/1mhzbus/beebsid.cpp index d50449ede99..2ef317618d3 100644 --- a/src/devices/bus/bbc/1mhzbus/beebsid.cpp +++ b/src/devices/bus/bbc/1mhzbus/beebsid.cpp @@ -43,7 +43,7 @@ void bbc_beebsid_device::device_add_mconfig(machine_config &config) // bbc_beebsid_device - constructor //------------------------------------------------- -bbc_beebsid_device::bbc_beebsid_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_beebsid_device::bbc_beebsid_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_BEEBSID, tag, owner, clock), device_bbc_1mhzbus_interface(mconfig, *this), m_1mhzbus(*this, "1mhzbus"), diff --git a/src/devices/bus/bbc/1mhzbus/beebsid.h b/src/devices/bus/bbc/1mhzbus/beebsid.h index 107e875abde..ff5e6e5120a 100644 --- a/src/devices/bus/bbc/1mhzbus/beebsid.h +++ b/src/devices/bus/bbc/1mhzbus/beebsid.h @@ -25,7 +25,7 @@ class bbc_beebsid_device : { public: // construction/destruction - bbc_beebsid_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_beebsid_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/cc500.cpp b/src/devices/bus/bbc/1mhzbus/cc500.cpp index c04fc06429e..17f51de4747 100644 --- a/src/devices/bus/bbc/1mhzbus/cc500.cpp +++ b/src/devices/bus/bbc/1mhzbus/cc500.cpp @@ -93,7 +93,7 @@ const tiny_rom_entry* bbc_cc500_device::device_rom_region() const // bbc_cc500_device - constructor //------------------------------------------------- -bbc_cc500_device::bbc_cc500_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_cc500_device::bbc_cc500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_CC500, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_palette(*this, ":palette") diff --git a/src/devices/bus/bbc/1mhzbus/cc500.h b/src/devices/bus/bbc/1mhzbus/cc500.h index f99ceec100a..4831ed2526a 100644 --- a/src/devices/bus/bbc/1mhzbus/cc500.h +++ b/src/devices/bus/bbc/1mhzbus/cc500.h @@ -27,7 +27,7 @@ class bbc_cc500_device : { public: // construction/destruction - bbc_cc500_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_cc500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/cfa3000opt.cpp b/src/devices/bus/bbc/1mhzbus/cfa3000opt.cpp index e5ac755e006..2146b4d1338 100644 --- a/src/devices/bus/bbc/1mhzbus/cfa3000opt.cpp +++ b/src/devices/bus/bbc/1mhzbus/cfa3000opt.cpp @@ -77,7 +77,7 @@ ioport_constructor cfa3000_opt_device::device_input_ports() const // cfa3000_opt_device - constructor //------------------------------------------------- -cfa3000_opt_device::cfa3000_opt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cfa3000_opt_device::cfa3000_opt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CFA3000_OPT, tag, owner, clock), device_bbc_1mhzbus_interface(mconfig, *this), m_opt(*this, "OPT") diff --git a/src/devices/bus/bbc/1mhzbus/cfa3000opt.h b/src/devices/bus/bbc/1mhzbus/cfa3000opt.h index 64913e95604..cbe0ea3b270 100644 --- a/src/devices/bus/bbc/1mhzbus/cfa3000opt.h +++ b/src/devices/bus/bbc/1mhzbus/cfa3000opt.h @@ -26,7 +26,7 @@ class cfa3000_opt_device : { public: // construction/destruction - cfa3000_opt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cfa3000_opt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/cisco.cpp b/src/devices/bus/bbc/1mhzbus/cisco.cpp index e12efa906d2..eb1fd20a76a 100644 --- a/src/devices/bus/bbc/1mhzbus/cisco.cpp +++ b/src/devices/bus/bbc/1mhzbus/cisco.cpp @@ -83,7 +83,7 @@ void bbc_cisco_device::device_add_mconfig(machine_config &config) // bbc_cisco_device - constructor //------------------------------------------------- -bbc_cisco_device::bbc_cisco_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_cisco_device::bbc_cisco_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_CISCO, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , device_rtc_interface(mconfig , *this) diff --git a/src/devices/bus/bbc/1mhzbus/cisco.h b/src/devices/bus/bbc/1mhzbus/cisco.h index fdbe528db98..80507f50979 100644 --- a/src/devices/bus/bbc/1mhzbus/cisco.h +++ b/src/devices/bus/bbc/1mhzbus/cisco.h @@ -25,7 +25,7 @@ class bbc_cisco_device { public: // construction/destruction - bbc_cisco_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_cisco_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/datacentre.cpp b/src/devices/bus/bbc/1mhzbus/datacentre.cpp index f21d5af1d54..d12694f314e 100644 --- a/src/devices/bus/bbc/1mhzbus/datacentre.cpp +++ b/src/devices/bus/bbc/1mhzbus/datacentre.cpp @@ -108,7 +108,7 @@ const tiny_rom_entry *bbc_datacentre_device::device_rom_region() const // bbc_ide_device - constructor //------------------------------------------------- -bbc_datacentre_device::bbc_datacentre_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +bbc_datacentre_device::bbc_datacentre_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, BBC_DATACENTRE, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_links(*this, "LINKS") diff --git a/src/devices/bus/bbc/1mhzbus/datacentre.h b/src/devices/bus/bbc/1mhzbus/datacentre.h index c6846821e9b..597fd673bdb 100644 --- a/src/devices/bus/bbc/1mhzbus/datacentre.h +++ b/src/devices/bus/bbc/1mhzbus/datacentre.h @@ -27,7 +27,7 @@ class bbc_datacentre_device : { public: // construction/destruction - bbc_datacentre_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_datacentre_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(import_nvrest); template<int Drive> DECLARE_QUICKLOAD_LOAD_MEMBER(quickload_cb); diff --git a/src/devices/bus/bbc/1mhzbus/emrmidi.cpp b/src/devices/bus/bbc/1mhzbus/emrmidi.cpp index 6cfbacf23da..e1e1e6251c6 100644 --- a/src/devices/bus/bbc/1mhzbus/emrmidi.cpp +++ b/src/devices/bus/bbc/1mhzbus/emrmidi.cpp @@ -36,7 +36,7 @@ DEFINE_DEVICE_TYPE(BBC_EMRMIDI, bbc_emrmidi_device, "bbc_emrmidi", "EMR BBC Midi void bbc_emrmidi_device::device_add_mconfig(machine_config &config) { - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("mdout1", FUNC(midi_port_device::write_txd)); m_acia->txd_handler().append("mdout2", FUNC(midi_port_device::write_txd)); m_acia->irq_handler().set(DEVICE_SELF_OWNER, FUNC(bbc_1mhzbus_slot_device::irq_w)); @@ -60,7 +60,7 @@ void bbc_emrmidi_device::device_add_mconfig(machine_config &config) // bbc_emrmidi_device - constructor //------------------------------------------------- -bbc_emrmidi_device::bbc_emrmidi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_emrmidi_device::bbc_emrmidi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_EMRMIDI, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_acia(*this, "acia1") diff --git a/src/devices/bus/bbc/1mhzbus/emrmidi.h b/src/devices/bus/bbc/1mhzbus/emrmidi.h index 341e487ce24..228d37519f5 100644 --- a/src/devices/bus/bbc/1mhzbus/emrmidi.h +++ b/src/devices/bus/bbc/1mhzbus/emrmidi.h @@ -27,7 +27,7 @@ class bbc_emrmidi_device : { public: // construction/destruction - bbc_emrmidi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_emrmidi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/ide.cpp b/src/devices/bus/bbc/1mhzbus/ide.cpp index d5fdafb000d..103066ecc81 100644 --- a/src/devices/bus/bbc/1mhzbus/ide.cpp +++ b/src/devices/bus/bbc/1mhzbus/ide.cpp @@ -78,14 +78,14 @@ void bbc_beebide_device::device_add_mconfig(machine_config& config) // bbc_ide_device - constructor //------------------------------------------------- -bbc_ide8_device::bbc_ide8_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +bbc_ide8_device::bbc_ide8_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, BBC_IDE8, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_ide(*this, "ide") { } -bbc_beebide_device::bbc_beebide_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +bbc_beebide_device::bbc_beebide_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, BBC_BEEBIDE, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_ide(*this, "ide") diff --git a/src/devices/bus/bbc/1mhzbus/ide.h b/src/devices/bus/bbc/1mhzbus/ide.h index d326c199ce9..dfddadf1f67 100644 --- a/src/devices/bus/bbc/1mhzbus/ide.h +++ b/src/devices/bus/bbc/1mhzbus/ide.h @@ -29,7 +29,7 @@ class bbc_ide8_device : { public: // construction/destruction - bbc_ide8_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + bbc_ide8_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); protected: // device-level overrides @@ -52,7 +52,7 @@ class bbc_beebide_device : { public: // construction/destruction - bbc_beebide_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + bbc_beebide_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/ieee488.cpp b/src/devices/bus/bbc/1mhzbus/ieee488.cpp index 3ddb6a13dc1..c0bcecc85d5 100644 --- a/src/devices/bus/bbc/1mhzbus/ieee488.cpp +++ b/src/devices/bus/bbc/1mhzbus/ieee488.cpp @@ -155,7 +155,7 @@ const tiny_rom_entry *bbc_ieee488_device::device_rom_region() const // bbc_ieee488_device - constructor //------------------------------------------------- -bbc_ieee488_device::bbc_ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_ieee488_device::bbc_ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_IEEE488, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_ieee(*this, IEEE488_TAG) @@ -164,7 +164,7 @@ bbc_ieee488_device::bbc_ieee488_device(const machine_config &mconfig, const char { } -bbc_b488_device::bbc_b488_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_b488_device::bbc_b488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_B488, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_ieee(*this, IEEE488_TAG) @@ -172,7 +172,7 @@ bbc_b488_device::bbc_b488_device(const machine_config &mconfig, const char *tag, { } -//bbc_procyon_device::bbc_procyon_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +//bbc_procyon_device::bbc_procyon_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) // : device_t(mconfig, BBC_PROCYON, tag, owner, clock) // , device_bbc_1mhzbus_interface(mconfig, *this) // , m_ieee(*this, IEEE488_TAG) diff --git a/src/devices/bus/bbc/1mhzbus/ieee488.h b/src/devices/bus/bbc/1mhzbus/ieee488.h index 9b810b4bf8d..b45c860b88d 100644 --- a/src/devices/bus/bbc/1mhzbus/ieee488.h +++ b/src/devices/bus/bbc/1mhzbus/ieee488.h @@ -32,7 +32,7 @@ class bbc_ieee488_device: { public: // construction/destruction - bbc_ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -60,7 +60,7 @@ class bbc_b488_device : { public: // construction/destruction - bbc_b488_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_b488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -84,7 +84,7 @@ private: //{ //public: // // construction/destruction -// bbc_procyon_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); +// bbc_procyon_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // //protected: // // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/m2000.cpp b/src/devices/bus/bbc/1mhzbus/m2000.cpp index 8203cada22e..c9c874da0c3 100644 --- a/src/devices/bus/bbc/1mhzbus/m2000.cpp +++ b/src/devices/bus/bbc/1mhzbus/m2000.cpp @@ -30,15 +30,15 @@ void bbc_m2000_device::device_add_mconfig(machine_config &config) { INPUT_MERGER_ANY_HIGH(config, m_irqs).output_handler().set(DEVICE_SELF_OWNER, FUNC(bbc_1mhzbus_slot_device::irq_w)); - ACIA6850(config, m_acia1, 0); + ACIA6850(config, m_acia1); m_acia1->txd_handler().set("mdout1", FUNC(midi_port_device::write_txd)); m_acia1->irq_handler().set(m_irqs, FUNC(input_merger_device::in_w<0>)); - ACIA6850(config, m_acia2, 0); + ACIA6850(config, m_acia2); m_acia2->txd_handler().set("mdout2", FUNC(midi_port_device::write_txd)); m_acia2->irq_handler().set(m_irqs, FUNC(input_merger_device::in_w<1>)); - ACIA6850(config, m_acia3, 0); + ACIA6850(config, m_acia3); m_acia3->txd_handler().set("mdout3", FUNC(midi_port_device::write_txd)); m_acia3->irq_handler().set(m_irqs, FUNC(input_merger_device::in_w<2>)); @@ -66,7 +66,7 @@ void bbc_m2000_device::device_add_mconfig(machine_config &config) // bbc_m2000_device - constructor //------------------------------------------------- -bbc_m2000_device::bbc_m2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_m2000_device::bbc_m2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_M2000, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_1mhzbus(*this, "1mhzbus") diff --git a/src/devices/bus/bbc/1mhzbus/m2000.h b/src/devices/bus/bbc/1mhzbus/m2000.h index eeee1034a4e..8680d6f2287 100644 --- a/src/devices/bus/bbc/1mhzbus/m2000.h +++ b/src/devices/bus/bbc/1mhzbus/m2000.h @@ -29,7 +29,7 @@ class bbc_m2000_device : { public: // construction/destruction - bbc_m2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_m2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/m5000.cpp b/src/devices/bus/bbc/1mhzbus/m5000.cpp index ae3fd948969..77f300ec6e1 100644 --- a/src/devices/bus/bbc/1mhzbus/m5000.cpp +++ b/src/devices/bus/bbc/1mhzbus/m5000.cpp @@ -120,7 +120,7 @@ void bbc_m87_device::device_add_mconfig(machine_config &config) // bbc_hybrid_device - constructor //------------------------------------------------- -bbc_m500_device::bbc_m500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_m500_device::bbc_m500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_1mhzbus(*this, "1mhzbus") @@ -129,22 +129,22 @@ bbc_m500_device::bbc_m500_device(const machine_config &mconfig, device_type type { } -bbc_m500_device::bbc_m500_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_m500_device::bbc_m500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_m500_device(mconfig, BBC_M500, tag, owner, clock) { } -bbc_m5000_device::bbc_m5000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_m5000_device::bbc_m5000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_m500_device(mconfig, BBC_M5000, tag, owner, clock) { } -bbc_m3000_device::bbc_m3000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_m3000_device::bbc_m3000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_m500_device(mconfig, BBC_M3000, tag, owner, clock) { } -bbc_m87_device::bbc_m87_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_m87_device::bbc_m87_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_m500_device(mconfig, BBC_M87, tag, owner, clock) { } @@ -219,7 +219,7 @@ void bbc_m3000_device::jim_w(offs_t offset, uint8_t data) // htmusic_device - constructor //------------------------------------------------- -htmusic_device::htmusic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +htmusic_device::htmusic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HTMUSIC, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_counter(0) diff --git a/src/devices/bus/bbc/1mhzbus/m5000.h b/src/devices/bus/bbc/1mhzbus/m5000.h index 116bc17cebe..eaa4c19ebbe 100644 --- a/src/devices/bus/bbc/1mhzbus/m5000.h +++ b/src/devices/bus/bbc/1mhzbus/m5000.h @@ -37,7 +37,7 @@ class htmusic_device : public device_t, public device_sound_interface { public: - htmusic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + htmusic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void ram_w(offs_t offset, uint8_t data) { m_wave_ram[offset & 0x7ff] = data; } @@ -78,10 +78,10 @@ class bbc_m500_device : public device_t, public device_bbc_1mhzbus_interface { public: // construction/destruction - bbc_m500_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_m500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_m500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_m500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -109,7 +109,7 @@ class bbc_m5000_device : public bbc_m500_device { public: // construction/destruction - bbc_m5000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_m5000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -124,7 +124,7 @@ class bbc_m3000_device : public bbc_m500_device { public: // construction/destruction - bbc_m3000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_m3000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -140,7 +140,7 @@ class bbc_m87_device : public bbc_m500_device { public: // construction/destruction - bbc_m87_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_m87_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/bbc/1mhzbus/multiform.cpp b/src/devices/bus/bbc/1mhzbus/multiform.cpp index 081c488107a..52e13320446 100644 --- a/src/devices/bus/bbc/1mhzbus/multiform.cpp +++ b/src/devices/bus/bbc/1mhzbus/multiform.cpp @@ -95,7 +95,7 @@ const tiny_rom_entry *bbc_multiform_device::device_rom_region() const // bbc_multiform_device - constructor //------------------------------------------------- -bbc_multiform_device::bbc_multiform_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_multiform_device::bbc_multiform_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_MULTIFORM, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_z80(*this, "z80") diff --git a/src/devices/bus/bbc/1mhzbus/multiform.h b/src/devices/bus/bbc/1mhzbus/multiform.h index 586ebe0d7d2..769b87a0876 100644 --- a/src/devices/bus/bbc/1mhzbus/multiform.h +++ b/src/devices/bus/bbc/1mhzbus/multiform.h @@ -28,7 +28,7 @@ class bbc_multiform_device : { public: // construction/destruction - bbc_multiform_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_multiform_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t mem_r(offs_t offset); void mem_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/bbc/1mhzbus/opus3.cpp b/src/devices/bus/bbc/1mhzbus/opus3.cpp index f537eb88b54..da82188d1e8 100644 --- a/src/devices/bus/bbc/1mhzbus/opus3.cpp +++ b/src/devices/bus/bbc/1mhzbus/opus3.cpp @@ -126,7 +126,7 @@ const tiny_rom_entry *bbc_opusa_device::device_rom_region() const // bbc_opus3_device - constructor //------------------------------------------------- -bbc_opus3_device::bbc_opus3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_opus3_device::bbc_opus3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_ramdisk(*this, "ramdisk") @@ -136,12 +136,12 @@ bbc_opus3_device::bbc_opus3_device(const machine_config &mconfig, device_type ty { } -bbc_opus3_device::bbc_opus3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_opus3_device::bbc_opus3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_opus3_device(mconfig, BBC_OPUS3, tag, owner, clock) { } -bbc_opusa_device::bbc_opusa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_opusa_device::bbc_opusa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_opus3_device(mconfig, BBC_OPUSA, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/1mhzbus/opus3.h b/src/devices/bus/bbc/1mhzbus/opus3.h index 2fd06b4015f..ba44d44ea4e 100644 --- a/src/devices/bus/bbc/1mhzbus/opus3.h +++ b/src/devices/bus/bbc/1mhzbus/opus3.h @@ -27,10 +27,10 @@ class bbc_opus3_device: { public: // construction/destruction - bbc_opus3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_opus3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_opus3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_opus3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -59,7 +59,7 @@ class bbc_opusa_device : public bbc_opus3_device { public: // construction/destruction - bbc_opusa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_opusa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/pdram.cpp b/src/devices/bus/bbc/1mhzbus/pdram.cpp index 81106218fc4..fbdd63d9923 100644 --- a/src/devices/bus/bbc/1mhzbus/pdram.cpp +++ b/src/devices/bus/bbc/1mhzbus/pdram.cpp @@ -44,7 +44,7 @@ const tiny_rom_entry* bbc_pdram_device::device_rom_region() const // bbc_pdram_device - constructor //------------------------------------------------- -bbc_pdram_device::bbc_pdram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_pdram_device::bbc_pdram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_PDRAM, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_ram_page(0) diff --git a/src/devices/bus/bbc/1mhzbus/pdram.h b/src/devices/bus/bbc/1mhzbus/pdram.h index 23f5b2884ca..7f1e71d6109 100644 --- a/src/devices/bus/bbc/1mhzbus/pdram.h +++ b/src/devices/bus/bbc/1mhzbus/pdram.h @@ -22,7 +22,7 @@ class bbc_pdram_device: { public: // construction/destruction - bbc_pdram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_pdram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/pms64k.cpp b/src/devices/bus/bbc/1mhzbus/pms64k.cpp index 0c975b39f48..2633f79381d 100644 --- a/src/devices/bus/bbc/1mhzbus/pms64k.cpp +++ b/src/devices/bus/bbc/1mhzbus/pms64k.cpp @@ -38,7 +38,7 @@ void bbc_pms64k_device::device_add_mconfig(machine_config &config) // bbc_pms64k_device - constructor //------------------------------------------------- -bbc_pms64k_device::bbc_pms64k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_pms64k_device::bbc_pms64k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_PMS64K, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_nvram(*this, "nvram") diff --git a/src/devices/bus/bbc/1mhzbus/pms64k.h b/src/devices/bus/bbc/1mhzbus/pms64k.h index 8b817b7db1d..aac78a1f298 100644 --- a/src/devices/bus/bbc/1mhzbus/pms64k.h +++ b/src/devices/bus/bbc/1mhzbus/pms64k.h @@ -23,7 +23,7 @@ class bbc_pms64k_device: { public: // construction/destruction - bbc_pms64k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_pms64k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/1mhzbus/ramdisc.cpp b/src/devices/bus/bbc/1mhzbus/ramdisc.cpp index 7552042a716..ac5d12530e8 100644 --- a/src/devices/bus/bbc/1mhzbus/ramdisc.cpp +++ b/src/devices/bus/bbc/1mhzbus/ramdisc.cpp @@ -86,7 +86,7 @@ const tiny_rom_entry *bbc_ramdisc_device::device_rom_region() const // bbc_ramdisc_device - constructor //------------------------------------------------- -bbc_ramdisc_device::bbc_ramdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_ramdisc_device::bbc_ramdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_RAMDISC, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_1mhzbus(*this, "1mhzbus") diff --git a/src/devices/bus/bbc/1mhzbus/ramdisc.h b/src/devices/bus/bbc/1mhzbus/ramdisc.h index a4955921bcc..ca27e7bc309 100644 --- a/src/devices/bus/bbc/1mhzbus/ramdisc.h +++ b/src/devices/bus/bbc/1mhzbus/ramdisc.h @@ -23,7 +23,7 @@ class bbc_ramdisc_device: { public: // construction/destruction - bbc_ramdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_ramdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(power_changed); diff --git a/src/devices/bus/bbc/1mhzbus/sasi.cpp b/src/devices/bus/bbc/1mhzbus/sasi.cpp index 9a55916f8f1..16d60d94f62 100644 --- a/src/devices/bus/bbc/1mhzbus/sasi.cpp +++ b/src/devices/bus/bbc/1mhzbus/sasi.cpp @@ -72,7 +72,7 @@ void bbc_torchhd_device::device_add_mconfig(machine_config &config) // bbc_sasi_device - constructor //------------------------------------------------- -bbc_sasi_device::bbc_sasi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_sasi_device::bbc_sasi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_sasi(*this, "sasi:7:scsicb") @@ -80,12 +80,12 @@ bbc_sasi_device::bbc_sasi_device(const machine_config &mconfig, device_type type { } -bbc_sasi_device::bbc_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_sasi_device::bbc_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_sasi_device(mconfig, BBC_SASI, tag, owner, clock) { } -bbc_torchhd_device::bbc_torchhd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_torchhd_device::bbc_torchhd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_sasi_device(mconfig, BBC_TORCHHD, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/1mhzbus/sasi.h b/src/devices/bus/bbc/1mhzbus/sasi.h index e1b81125ecd..3ce5d0d6485 100644 --- a/src/devices/bus/bbc/1mhzbus/sasi.h +++ b/src/devices/bus/bbc/1mhzbus/sasi.h @@ -24,13 +24,13 @@ class bbc_sasi_device: { public: // construction/destruction - bbc_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(req_w); DECLARE_WRITE_LINE_MEMBER(sel_w); protected: - bbc_sasi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_sasi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -55,7 +55,7 @@ class bbc_torchhd_device : public bbc_sasi_device { public: // construction/destruction - bbc_torchhd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_torchhd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/bbc/1mhzbus/scsi.cpp b/src/devices/bus/bbc/1mhzbus/scsi.cpp index 26c640467b3..b3fd0cd1db8 100644 --- a/src/devices/bus/bbc/1mhzbus/scsi.cpp +++ b/src/devices/bus/bbc/1mhzbus/scsi.cpp @@ -87,19 +87,19 @@ void bbc_awhd_device::device_add_mconfig(machine_config &config) // bbc_scsi_device - constructor //------------------------------------------------- -bbc_scsi_device::bbc_scsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_scsi_device::bbc_scsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_scsi(*this, "scsi:7:scsicb") { } -bbc_scsi_device::bbc_scsi_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +bbc_scsi_device::bbc_scsi_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : bbc_scsi_device(mconfig, BBC_SCSI, tag, owner, clock) { } -bbc_awhd_device::bbc_awhd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_awhd_device::bbc_awhd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_scsi_device(mconfig, BBC_AWHD, tag, owner, clock) , m_1mhzbus(*this, "1mhzbus") { diff --git a/src/devices/bus/bbc/1mhzbus/scsi.h b/src/devices/bus/bbc/1mhzbus/scsi.h index 8a4dabbe113..5c16af7676c 100644 --- a/src/devices/bus/bbc/1mhzbus/scsi.h +++ b/src/devices/bus/bbc/1mhzbus/scsi.h @@ -24,13 +24,13 @@ class bbc_scsi_device: { public: // construction/destruction - bbc_scsi_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + bbc_scsi_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(bsy_w); DECLARE_WRITE_LINE_MEMBER(req_w); protected: - bbc_scsi_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock); + bbc_scsi_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -57,7 +57,7 @@ public: static constexpr feature_type imperfect_features() { return feature::DISK; } // construction/destruction - bbc_awhd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_awhd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/bbc/1mhzbus/sprite.cpp b/src/devices/bus/bbc/1mhzbus/sprite.cpp index ee7f5f292e7..f47ca52e0c3 100644 --- a/src/devices/bus/bbc/1mhzbus/sprite.cpp +++ b/src/devices/bus/bbc/1mhzbus/sprite.cpp @@ -41,7 +41,7 @@ void bbc_sprite_device::device_add_mconfig(machine_config &config) // bbc_sprite_device - constructor //------------------------------------------------- -bbc_sprite_device::bbc_sprite_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_sprite_device::bbc_sprite_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_SPRITE, tag, owner, clock) , device_bbc_1mhzbus_interface(mconfig, *this) , m_vdp(*this, "vdp") diff --git a/src/devices/bus/bbc/1mhzbus/sprite.h b/src/devices/bus/bbc/1mhzbus/sprite.h index 02b0cff5dc2..a6aac9f0bda 100644 --- a/src/devices/bus/bbc/1mhzbus/sprite.h +++ b/src/devices/bus/bbc/1mhzbus/sprite.h @@ -24,7 +24,7 @@ class bbc_sprite_device: { public: // construction/destruction - bbc_sprite_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_sprite_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/analogue/analogue.cpp b/src/devices/bus/bbc/analogue/analogue.cpp index 6dce6a36e99..f631033da42 100644 --- a/src/devices/bus/bbc/analogue/analogue.cpp +++ b/src/devices/bus/bbc/analogue/analogue.cpp @@ -41,7 +41,7 @@ device_bbc_analogue_interface::device_bbc_analogue_interface(const machine_confi // bbc_analogue_slot_device - constructor //------------------------------------------------- -bbc_analogue_slot_device::bbc_analogue_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_analogue_slot_device::bbc_analogue_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_ANALOGUE_SLOT, tag, owner, clock), device_single_card_slot_interface<device_bbc_analogue_interface>(mconfig, *this), m_card(nullptr), diff --git a/src/devices/bus/bbc/analogue/analogue.h b/src/devices/bus/bbc/analogue/analogue.h index bb58d2d0148..062abe5842f 100644 --- a/src/devices/bus/bbc/analogue/analogue.h +++ b/src/devices/bus/bbc/analogue/analogue.h @@ -55,7 +55,7 @@ public: set_fixed(false); } - bbc_analogue_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + bbc_analogue_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // callbacks auto lpstb_handler() { return m_lpstb_handler.bind(); } diff --git a/src/devices/bus/bbc/analogue/bitstik.cpp b/src/devices/bus/bbc/analogue/bitstik.cpp index f904e20db9f..68df8b71769 100644 --- a/src/devices/bus/bbc/analogue/bitstik.cpp +++ b/src/devices/bus/bbc/analogue/bitstik.cpp @@ -89,7 +89,7 @@ const tiny_rom_entry *bbc_bitstik2_device::device_rom_region() const // bbc_bitstik_device - constructor //------------------------------------------------- -bbc_bitstik_device::bbc_bitstik_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +bbc_bitstik_device::bbc_bitstik_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_bbc_analogue_interface(mconfig, *this), m_channel(*this, "CHANNEL%u", 0), @@ -97,12 +97,12 @@ bbc_bitstik_device::bbc_bitstik_device(const machine_config &mconfig, device_typ { } -bbc_bitstik1_device::bbc_bitstik1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_bitstik1_device::bbc_bitstik1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_bitstik_device(mconfig, BBC_BITSTIK1, tag, owner, clock) { } -bbc_bitstik2_device::bbc_bitstik2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_bitstik2_device::bbc_bitstik2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_bitstik_device(mconfig, BBC_BITSTIK2, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/analogue/bitstik.h b/src/devices/bus/bbc/analogue/bitstik.h index 494be5dec69..89747c5c1fb 100644 --- a/src/devices/bus/bbc/analogue/bitstik.h +++ b/src/devices/bus/bbc/analogue/bitstik.h @@ -31,7 +31,7 @@ class bbc_bitstik_device : { protected: // construction/destruction - bbc_bitstik_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_bitstik_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -50,7 +50,7 @@ private: class bbc_bitstik1_device : public bbc_bitstik_device { public: - bbc_bitstik1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_bitstik1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -59,7 +59,7 @@ protected: class bbc_bitstik2_device : public bbc_bitstik_device { public: - bbc_bitstik2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_bitstik2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/bbc/analogue/cfa3000a.cpp b/src/devices/bus/bbc/analogue/cfa3000a.cpp index f48234e091b..754dbbf75b9 100644 --- a/src/devices/bus/bbc/analogue/cfa3000a.cpp +++ b/src/devices/bus/bbc/analogue/cfa3000a.cpp @@ -58,7 +58,7 @@ ioport_constructor cfa3000_anlg_device::device_input_ports() const // cfa3000_anlg_device - constructor //------------------------------------------------- -cfa3000_anlg_device::cfa3000_anlg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cfa3000_anlg_device::cfa3000_anlg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CFA3000_ANLG, tag, owner, clock), device_bbc_analogue_interface(mconfig, *this), m_channel(*this, "CHANNEL%u", 0), diff --git a/src/devices/bus/bbc/analogue/cfa3000a.h b/src/devices/bus/bbc/analogue/cfa3000a.h index 8948ca586be..6662f02ceb8 100644 --- a/src/devices/bus/bbc/analogue/cfa3000a.h +++ b/src/devices/bus/bbc/analogue/cfa3000a.h @@ -26,7 +26,7 @@ class cfa3000_anlg_device : { public: // construction/destruction - cfa3000_anlg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cfa3000_anlg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/analogue/joystick.cpp b/src/devices/bus/bbc/analogue/joystick.cpp index 434ea1060b2..c938d327799 100644 --- a/src/devices/bus/bbc/analogue/joystick.cpp +++ b/src/devices/bus/bbc/analogue/joystick.cpp @@ -82,7 +82,7 @@ ioport_constructor bbc_voltmace3b_device::device_input_ports() const // bbc_joystick_device - constructor //------------------------------------------------- -bbc_joystick_device::bbc_joystick_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +bbc_joystick_device::bbc_joystick_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_bbc_analogue_interface(mconfig, *this), m_joy(*this, "JOY%u", 0), @@ -90,12 +90,12 @@ bbc_joystick_device::bbc_joystick_device(const machine_config &mconfig, device_t { } -bbc_acornjoy_device::bbc_acornjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_acornjoy_device::bbc_acornjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_joystick_device(mconfig, BBC_ACORNJOY, tag, owner, clock) { } -bbc_voltmace3b_device::bbc_voltmace3b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_voltmace3b_device::bbc_voltmace3b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_joystick_device(mconfig, BBC_VOLTMACE3B, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/analogue/joystick.h b/src/devices/bus/bbc/analogue/joystick.h index 887e87c74d7..2cefd0ab9d5 100644 --- a/src/devices/bus/bbc/analogue/joystick.h +++ b/src/devices/bus/bbc/analogue/joystick.h @@ -26,7 +26,7 @@ class bbc_joystick_device : { protected: // construction/destruction - bbc_joystick_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_joystick_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -43,7 +43,7 @@ private: class bbc_acornjoy_device : public bbc_joystick_device { public: - bbc_acornjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_acornjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; }; @@ -51,7 +51,7 @@ public: class bbc_voltmace3b_device : public bbc_joystick_device { public: - bbc_voltmace3b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_voltmace3b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; }; diff --git a/src/devices/bus/bbc/cart/click.cpp b/src/devices/bus/bbc/cart/click.cpp index 175de5eeae3..a0277210137 100644 --- a/src/devices/bus/bbc/cart/click.cpp +++ b/src/devices/bus/bbc/cart/click.cpp @@ -54,7 +54,7 @@ ioport_constructor bbc_click_device::device_input_ports() const // bbc_click_device - constructor //------------------------------------------------- -bbc_click_device::bbc_click_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_click_device::bbc_click_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_CLICK, tag, owner, clock) , device_bbc_cart_interface(mconfig, *this) { diff --git a/src/devices/bus/bbc/cart/click.h b/src/devices/bus/bbc/cart/click.h index 9f6691c4356..bd71bea4053 100644 --- a/src/devices/bus/bbc/cart/click.h +++ b/src/devices/bus/bbc/cart/click.h @@ -26,7 +26,7 @@ class bbc_click_device : public device_t, public device_bbc_cart_interface { public: // construction/destruction - bbc_click_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_click_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(click_button); diff --git a/src/devices/bus/bbc/cart/mastersd.cpp b/src/devices/bus/bbc/cart/mastersd.cpp index 1c1d21ede72..4395b9002ae 100644 --- a/src/devices/bus/bbc/cart/mastersd.cpp +++ b/src/devices/bus/bbc/cart/mastersd.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(BBC_MASTERSD, bbc_mastersd_device, "bbc_mastersd", "MasterSD void bbc_mastersd_device::device_add_mconfig(machine_config &config) { - SPI_SDCARD(config, m_sdcard, 0); + SPI_SDCARD(config, m_sdcard); m_sdcard->spi_miso_callback().set([this](int state) { m_in_bit = state; }); } @@ -38,7 +38,7 @@ void bbc_mastersd_device::device_add_mconfig(machine_config &config) // bbc_mastersd_device - constructor //------------------------------------------------- -bbc_mastersd_device::bbc_mastersd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_mastersd_device::bbc_mastersd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_MASTERSD, tag, owner, clock) , device_bbc_cart_interface(mconfig, *this) , m_sdcard(*this, "sdcard") diff --git a/src/devices/bus/bbc/cart/mastersd.h b/src/devices/bus/bbc/cart/mastersd.h index cd6d399176d..b05a613576e 100644 --- a/src/devices/bus/bbc/cart/mastersd.h +++ b/src/devices/bus/bbc/cart/mastersd.h @@ -21,7 +21,7 @@ class bbc_mastersd_device : public device_t, public device_bbc_cart_interface { public: // construction/destruction - bbc_mastersd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_mastersd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/cart/mega256.cpp b/src/devices/bus/bbc/cart/mega256.cpp index f0348df2e74..985ab6082a2 100644 --- a/src/devices/bus/bbc/cart/mega256.cpp +++ b/src/devices/bus/bbc/cart/mega256.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(BBC_MEGA256, bbc_mega256_device, "bbc_mega256", "Solidisk Meg // bbc_mega256_device - constructor //------------------------------------------------- -bbc_mega256_device::bbc_mega256_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_mega256_device::bbc_mega256_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_MEGA256, tag, owner, clock) , device_bbc_cart_interface(mconfig, *this) , m_page(0) diff --git a/src/devices/bus/bbc/cart/mega256.h b/src/devices/bus/bbc/cart/mega256.h index b6f211b694a..f6f1fdbab6a 100644 --- a/src/devices/bus/bbc/cart/mega256.h +++ b/src/devices/bus/bbc/cart/mega256.h @@ -26,7 +26,7 @@ class bbc_mega256_device : public device_t, public device_bbc_cart_interface { public: // construction/destruction - bbc_mega256_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_mega256_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/cart/mr8000.cpp b/src/devices/bus/bbc/cart/mr8000.cpp index a039936f23a..8a7e127d4c4 100644 --- a/src/devices/bus/bbc/cart/mr8000.cpp +++ b/src/devices/bus/bbc/cart/mr8000.cpp @@ -51,7 +51,7 @@ ioport_constructor bbc_mr8000_device::device_input_ports() const // bbc_mr8000_device - constructor //------------------------------------------------- -bbc_mr8000_device::bbc_mr8000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_mr8000_device::bbc_mr8000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_MR8000, tag, owner, clock) , device_bbc_cart_interface(mconfig, *this) , m_switch(*this, "SWITCH") diff --git a/src/devices/bus/bbc/cart/mr8000.h b/src/devices/bus/bbc/cart/mr8000.h index ccf79e4508e..d2d37b4ec40 100644 --- a/src/devices/bus/bbc/cart/mr8000.h +++ b/src/devices/bus/bbc/cart/mr8000.h @@ -24,7 +24,7 @@ class bbc_mr8000_device : public device_t, public device_bbc_cart_interface { public: // construction/destruction - bbc_mr8000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_mr8000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/cart/msc.cpp b/src/devices/bus/bbc/cart/msc.cpp index 05a3284e83d..ca282be539e 100644 --- a/src/devices/bus/bbc/cart/msc.cpp +++ b/src/devices/bus/bbc/cart/msc.cpp @@ -44,7 +44,7 @@ ioport_constructor bbc_msc_device::device_input_ports() const // bbc_msc_device - constructor //------------------------------------------------- -bbc_msc_device::bbc_msc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_msc_device::bbc_msc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_MSC, tag, owner, clock) , device_bbc_cart_interface(mconfig, *this) , m_button(*this, "BUTTON") diff --git a/src/devices/bus/bbc/cart/msc.h b/src/devices/bus/bbc/cart/msc.h index 4bde2113047..22affbb6d58 100644 --- a/src/devices/bus/bbc/cart/msc.h +++ b/src/devices/bus/bbc/cart/msc.h @@ -24,7 +24,7 @@ class bbc_msc_device : public device_t, public device_bbc_cart_interface { public: // construction/destruction - bbc_msc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_msc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(activate); diff --git a/src/devices/bus/bbc/cart/slot.cpp b/src/devices/bus/bbc/cart/slot.cpp index 04e01ac04db..e6517298314 100644 --- a/src/devices/bus/bbc/cart/slot.cpp +++ b/src/devices/bus/bbc/cart/slot.cpp @@ -48,7 +48,7 @@ device_bbc_cart_interface::~device_bbc_cart_interface() //------------------------------------------------- // bbc_cartslot_device - constructor //------------------------------------------------- -bbc_cartslot_device::bbc_cartslot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_cartslot_device::bbc_cartslot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : electron_cartslot_device(mconfig, BBCM_CARTSLOT, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/cart/slot.h b/src/devices/bus/bbc/cart/slot.h index 42487bee5c7..0f5c5212682 100644 --- a/src/devices/bus/bbc/cart/slot.h +++ b/src/devices/bus/bbc/cart/slot.h @@ -123,7 +123,7 @@ class bbc_cartslot_device : public electron_cartslot_device public: // construction/destruction template <typename T> - bbc_cartslot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&slot_options, const char *default_option) + bbc_cartslot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&slot_options, const char *default_option) : electron_cartslot_device(mconfig, tag, owner, clock) { option_reset(); @@ -132,7 +132,7 @@ public: set_fixed(false); } - bbc_cartslot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_cartslot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "bbcm_cart"; } virtual const char *file_extensions() const noexcept override { return "rom,bin"; } diff --git a/src/devices/bus/bbc/exp/autocue.cpp b/src/devices/bus/bbc/exp/autocue.cpp index 4c9fa193c3a..72f3d853316 100644 --- a/src/devices/bus/bbc/exp/autocue.cpp +++ b/src/devices/bus/bbc/exp/autocue.cpp @@ -44,7 +44,7 @@ void bbc_autocue_device::device_add_mconfig(machine_config &config) // bbc_autocue_device - constructor //------------------------------------------------- -bbc_autocue_device::bbc_autocue_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_autocue_device::bbc_autocue_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_AUTOCUE, tag, owner, clock) , device_bbc_exp_interface(mconfig, *this) , m_nvram(*this, "nvram") diff --git a/src/devices/bus/bbc/exp/autocue.h b/src/devices/bus/bbc/exp/autocue.h index 0151e94e9bf..933fec91721 100644 --- a/src/devices/bus/bbc/exp/autocue.h +++ b/src/devices/bus/bbc/exp/autocue.h @@ -23,7 +23,7 @@ class bbc_autocue_device : { public: // construction/destruction - bbc_autocue_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_autocue_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/exp/exp.cpp b/src/devices/bus/bbc/exp/exp.cpp index 4209249a0f9..46c11ad43cb 100644 --- a/src/devices/bus/bbc/exp/exp.cpp +++ b/src/devices/bus/bbc/exp/exp.cpp @@ -41,7 +41,7 @@ device_bbc_exp_interface::device_bbc_exp_interface(const machine_config &mconfig // bbc_exp_slot_device - constructor //------------------------------------------------- -bbc_exp_slot_device::bbc_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_exp_slot_device::bbc_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_EXP_SLOT, tag, owner, clock), device_single_card_slot_interface<device_bbc_exp_interface>(mconfig, *this), m_card(nullptr), diff --git a/src/devices/bus/bbc/exp/exp.h b/src/devices/bus/bbc/exp/exp.h index f7d695b59a5..ccf0aa49230 100644 --- a/src/devices/bus/bbc/exp/exp.h +++ b/src/devices/bus/bbc/exp/exp.h @@ -56,7 +56,7 @@ class bbc_exp_slot_device : public device_t, public device_single_card_slot_inte public: // construction/destruction template <typename T> - bbc_exp_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&slot_options, const char *default_option) + bbc_exp_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&slot_options, const char *default_option) : bbc_exp_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -65,7 +65,7 @@ public: set_fixed(false); } - bbc_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/bus/bbc/exp/mertec.cpp b/src/devices/bus/bbc/exp/mertec.cpp index c561f052460..d2019b296db 100644 --- a/src/devices/bus/bbc/exp/mertec.cpp +++ b/src/devices/bus/bbc/exp/mertec.cpp @@ -79,7 +79,7 @@ void bbc_mertec_device::device_add_mconfig(machine_config &config) // bbc_mertec_device - constructor //------------------------------------------------- -bbc_mertec_device::bbc_mertec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_mertec_device::bbc_mertec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_MERTEC, tag, owner, clock) , device_bbc_exp_interface(mconfig, *this) , m_pia(*this, "pia") diff --git a/src/devices/bus/bbc/exp/mertec.h b/src/devices/bus/bbc/exp/mertec.h index 33d71ab2ce9..ba051d7f96b 100644 --- a/src/devices/bus/bbc/exp/mertec.h +++ b/src/devices/bus/bbc/exp/mertec.h @@ -29,7 +29,7 @@ class bbc_mertec_device : { public: // construction/destruction - bbc_mertec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_mertec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: diff --git a/src/devices/bus/bbc/fdc/acorn.cpp b/src/devices/bus/bbc/fdc/acorn.cpp index 22b2cc027c8..b383f9f352f 100644 --- a/src/devices/bus/bbc/fdc/acorn.cpp +++ b/src/devices/bus/bbc/fdc/acorn.cpp @@ -135,7 +135,7 @@ const tiny_rom_entry *bbc_acorn1770_device::device_rom_region() const // bbc_acornfdc_device - constructor //------------------------------------------------- -bbc_acorn8271_device::bbc_acorn8271_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_acorn8271_device::bbc_acorn8271_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_ACORN8271, tag, owner, clock) , device_bbc_fdc_interface(mconfig, *this) , m_fdc(*this, "i8271") @@ -143,7 +143,7 @@ bbc_acorn8271_device::bbc_acorn8271_device(const machine_config &mconfig, const { } -bbc_acorn1770_device::bbc_acorn1770_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_acorn1770_device::bbc_acorn1770_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_ACORN1770, tag, owner, clock) , device_bbc_fdc_interface(mconfig, *this) , m_fdc(*this, "wd1770") diff --git a/src/devices/bus/bbc/fdc/acorn.h b/src/devices/bus/bbc/fdc/acorn.h index 347368ff29f..b973c45292e 100644 --- a/src/devices/bus/bbc/fdc/acorn.h +++ b/src/devices/bus/bbc/fdc/acorn.h @@ -30,7 +30,7 @@ class bbc_acorn8271_device : { public: // construction/destruction - bbc_acorn8271_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_acorn8271_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); @@ -59,7 +59,7 @@ class bbc_acorn1770_device : { public: // construction/destruction - bbc_acorn1770_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_acorn1770_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/fdc/ams.cpp b/src/devices/bus/bbc/fdc/ams.cpp index ef64eabd75c..b085e7e1f20 100644 --- a/src/devices/bus/bbc/fdc/ams.cpp +++ b/src/devices/bus/bbc/fdc/ams.cpp @@ -73,7 +73,7 @@ const tiny_rom_entry *bbc_ams3_device::device_rom_region() const // bbc_ams3_device - constructor //------------------------------------------------- -bbc_ams3_device::bbc_ams3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_ams3_device::bbc_ams3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_AMS3, tag, owner, clock) , device_bbc_fdc_interface(mconfig, *this) , m_fdc(*this, "i8271") diff --git a/src/devices/bus/bbc/fdc/ams.h b/src/devices/bus/bbc/fdc/ams.h index a1bdcc27696..bb4105c37af 100644 --- a/src/devices/bus/bbc/fdc/ams.h +++ b/src/devices/bus/bbc/fdc/ams.h @@ -27,7 +27,7 @@ class bbc_ams3_device : { public: // construction/destruction - bbc_ams3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_ams3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); diff --git a/src/devices/bus/bbc/fdc/cumana.cpp b/src/devices/bus/bbc/fdc/cumana.cpp index 2db9b4b2f2a..a81f83f6a4d 100644 --- a/src/devices/bus/bbc/fdc/cumana.cpp +++ b/src/devices/bus/bbc/fdc/cumana.cpp @@ -106,7 +106,7 @@ const tiny_rom_entry *bbc_cumana2_device::device_rom_region() const // bbc_cumanafdc_device - constructor //------------------------------------------------- -bbc_cumanafdc_device::bbc_cumanafdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +bbc_cumanafdc_device::bbc_cumanafdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_bbc_fdc_interface(mconfig, *this), m_fdc(*this, "mb8877a"), @@ -115,13 +115,13 @@ bbc_cumanafdc_device::bbc_cumanafdc_device(const machine_config &mconfig, device { } -bbc_cumana1_device::bbc_cumana1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_cumana1_device::bbc_cumana1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_cumanafdc_device(mconfig, BBC_CUMANA1, tag, owner, clock) { m_invert = true; } -bbc_cumana2_device::bbc_cumana2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_cumana2_device::bbc_cumana2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_cumanafdc_device(mconfig, BBC_CUMANA2, tag, owner, clock) { m_invert = false; diff --git a/src/devices/bus/bbc/fdc/cumana.h b/src/devices/bus/bbc/fdc/cumana.h index d775a68e622..f92d64b1d96 100644 --- a/src/devices/bus/bbc/fdc/cumana.h +++ b/src/devices/bus/bbc/fdc/cumana.h @@ -34,7 +34,7 @@ public: protected: // construction/destruction - bbc_cumanafdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_cumanafdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -55,7 +55,7 @@ private: class bbc_cumana1_device : public bbc_cumanafdc_device { public: - bbc_cumana1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_cumana1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -65,7 +65,7 @@ protected: class bbc_cumana2_device : public bbc_cumanafdc_device { public: - bbc_cumana2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_cumana2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/bbc/fdc/cv1797.cpp b/src/devices/bus/bbc/fdc/cv1797.cpp index 32d517f35cb..d7e9a993465 100644 --- a/src/devices/bus/bbc/fdc/cv1797.cpp +++ b/src/devices/bus/bbc/fdc/cv1797.cpp @@ -86,7 +86,7 @@ const tiny_rom_entry *bbc_cv1797_device::device_rom_region() const // bbc_cv1797_device - constructor //------------------------------------------------- -bbc_cv1797_device::bbc_cv1797_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_cv1797_device::bbc_cv1797_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_CV1797, tag, owner, clock) , device_bbc_fdc_interface(mconfig, *this) , m_fdc(*this, "fd1797") diff --git a/src/devices/bus/bbc/fdc/cv1797.h b/src/devices/bus/bbc/fdc/cv1797.h index 16b870f963c..29f52996eef 100644 --- a/src/devices/bus/bbc/fdc/cv1797.h +++ b/src/devices/bus/bbc/fdc/cv1797.h @@ -28,7 +28,7 @@ class bbc_cv1797_device : { public: // construction/destruction - bbc_cv1797_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_cv1797_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/fdc/fdc.cpp b/src/devices/bus/bbc/fdc/fdc.cpp index abfc5e109b1..505ef16b446 100644 --- a/src/devices/bus/bbc/fdc/fdc.cpp +++ b/src/devices/bus/bbc/fdc/fdc.cpp @@ -40,7 +40,7 @@ device_bbc_fdc_interface::device_bbc_fdc_interface(const machine_config &mconfig // bbc_fdc_slot_device - constructor //------------------------------------------------- -bbc_fdc_slot_device::bbc_fdc_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_fdc_slot_device::bbc_fdc_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_FDC_SLOT, tag, owner, clock), device_single_card_slot_interface<device_bbc_fdc_interface>(mconfig, *this), m_card(nullptr), diff --git a/src/devices/bus/bbc/fdc/fdc.h b/src/devices/bus/bbc/fdc/fdc.h index 7138ced7ad1..b7b724488dc 100644 --- a/src/devices/bus/bbc/fdc/fdc.h +++ b/src/devices/bus/bbc/fdc/fdc.h @@ -26,7 +26,7 @@ class bbc_fdc_slot_device : public device_t, public device_single_card_slot_inte public: // construction/destruction template <typename T> - bbc_fdc_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&slot_options, const char *default_option) + bbc_fdc_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&slot_options, const char *default_option) : bbc_fdc_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -36,7 +36,7 @@ public: set_insert_rom(true); } - bbc_fdc_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + bbc_fdc_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); void set_insert_rom(bool insert_rom) { m_insert_rom = insert_rom; } bool insert_rom() { return m_insert_rom; } diff --git a/src/devices/bus/bbc/fdc/kenda.cpp b/src/devices/bus/bbc/fdc/kenda.cpp index 801dd731200..5ef055a1224 100644 --- a/src/devices/bus/bbc/fdc/kenda.cpp +++ b/src/devices/bus/bbc/fdc/kenda.cpp @@ -99,7 +99,7 @@ const tiny_rom_entry *bbc_kenda_device::device_rom_region() const // bbc_kenda_device - constructor //------------------------------------------------- -bbc_kenda_device::bbc_kenda_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_kenda_device::bbc_kenda_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_KENDA, tag, owner, clock) , device_bbc_fdc_interface(mconfig, *this) , m_fdc(*this, "fdc") diff --git a/src/devices/bus/bbc/fdc/kenda.h b/src/devices/bus/bbc/fdc/kenda.h index 99868f062fb..8ad7c738ac6 100644 --- a/src/devices/bus/bbc/fdc/kenda.h +++ b/src/devices/bus/bbc/fdc/kenda.h @@ -25,7 +25,7 @@ class bbc_kenda_device : public device_t, public device_bbc_fdc_interface { public: // construction/destruction - bbc_kenda_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_kenda_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/fdc/opus.cpp b/src/devices/bus/bbc/fdc/opus.cpp index 2851fc3de3c..c68e034e0c5 100644 --- a/src/devices/bus/bbc/fdc/opus.cpp +++ b/src/devices/bus/bbc/fdc/opus.cpp @@ -166,7 +166,7 @@ const tiny_rom_entry *bbc_opus1770_device::device_rom_region() const // bbc_opusfdc_device - constructor //------------------------------------------------- -bbc_opus8272_device::bbc_opus8272_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_opus8272_device::bbc_opus8272_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_OPUS8272, tag, owner, clock), device_bbc_fdc_interface(mconfig, *this), m_fdc(*this, "i8272"), @@ -174,7 +174,7 @@ bbc_opus8272_device::bbc_opus8272_device(const machine_config &mconfig, const ch { } -bbc_opusfdc_device::bbc_opusfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +bbc_opusfdc_device::bbc_opusfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_bbc_fdc_interface(mconfig, *this), m_fdc(*this, "fdc"), @@ -183,17 +183,17 @@ bbc_opusfdc_device::bbc_opusfdc_device(const machine_config &mconfig, device_typ { } -bbc_opus2791_device::bbc_opus2791_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_opus2791_device::bbc_opus2791_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_opusfdc_device(mconfig, BBC_OPUS2791, tag, owner, clock) { } -bbc_opus2793_device::bbc_opus2793_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_opus2793_device::bbc_opus2793_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_opusfdc_device(mconfig, BBC_OPUS2793, tag, owner, clock) { } -bbc_opus1770_device::bbc_opus1770_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_opus1770_device::bbc_opus1770_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_opusfdc_device(mconfig, BBC_OPUS1770, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/fdc/opus.h b/src/devices/bus/bbc/fdc/opus.h index 5cca5a5c701..bbc66abef1d 100644 --- a/src/devices/bus/bbc/fdc/opus.h +++ b/src/devices/bus/bbc/fdc/opus.h @@ -26,7 +26,7 @@ class bbc_opus8272_device : { public: // construction/destruction - bbc_opus8272_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_opus8272_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -56,7 +56,7 @@ public: protected: // construction/destruction - bbc_opusfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_opusfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -74,7 +74,7 @@ private: class bbc_opus2791_device : public bbc_opusfdc_device { public: - bbc_opus2791_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_opus2791_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -84,7 +84,7 @@ protected: class bbc_opus2793_device : public bbc_opusfdc_device { public: - bbc_opus2793_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_opus2793_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -94,7 +94,7 @@ protected: class bbc_opus1770_device : public bbc_opusfdc_device { public: - bbc_opus1770_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_opus1770_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/bbc/fdc/solidisk.cpp b/src/devices/bus/bbc/fdc/solidisk.cpp index c342fc64355..3b4df171758 100644 --- a/src/devices/bus/bbc/fdc/solidisk.cpp +++ b/src/devices/bus/bbc/fdc/solidisk.cpp @@ -147,7 +147,7 @@ const tiny_rom_entry *bbc_stldfdc_1_device::device_rom_region() const // bbc_stlfdc_device - constructor //------------------------------------------------- -bbc_stlfdc_device::bbc_stlfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_stlfdc_device::bbc_stlfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_fdc_interface(mconfig, *this) , m_wd1770(*this, "wd1770") @@ -157,27 +157,27 @@ bbc_stlfdc_device::bbc_stlfdc_device(const machine_config &mconfig, device_type { } -bbc_stl1770_1_device::bbc_stl1770_1_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock) +bbc_stl1770_1_device::bbc_stl1770_1_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock) : bbc_stlfdc_device(mconfig, type, tag, owner, clock) { } -bbc_stl1770_1_device::bbc_stl1770_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_stl1770_1_device::bbc_stl1770_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_stlfdc_device(mconfig, BBC_STL1770_1, tag, owner, clock) { } -bbc_stl1770_2_device::bbc_stl1770_2_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock) +bbc_stl1770_2_device::bbc_stl1770_2_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock) : bbc_stlfdc_device(mconfig, type, tag, owner, clock) { } -bbc_stl1770_2_device::bbc_stl1770_2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_stl1770_2_device::bbc_stl1770_2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_stlfdc_device(mconfig, BBC_STL1770_2, tag, owner, clock) { } -bbc_stldfdc_1_device::bbc_stldfdc_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_stldfdc_1_device::bbc_stldfdc_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_stl1770_1_device(mconfig, BBC_STLDFDC_1, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/fdc/solidisk.h b/src/devices/bus/bbc/fdc/solidisk.h index 025db9ca332..cede8534314 100644 --- a/src/devices/bus/bbc/fdc/solidisk.h +++ b/src/devices/bus/bbc/fdc/solidisk.h @@ -33,7 +33,7 @@ public: protected: // construction/destruction - bbc_stlfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_stlfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(motor_w); DECLARE_WRITE_LINE_MEMBER(side_w); @@ -48,10 +48,10 @@ protected: class bbc_stl1770_1_device : public bbc_stlfdc_device { public: - bbc_stl1770_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_stl1770_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_stl1770_1_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock); + bbc_stl1770_1_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -67,10 +67,10 @@ protected: class bbc_stl1770_2_device : public bbc_stlfdc_device { public: - bbc_stl1770_2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_stl1770_2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_stl1770_2_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock); + bbc_stl1770_2_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -87,7 +87,7 @@ class bbc_stldfdc_1_device : public bbc_stl1770_1_device { public: // construction/destruction - bbc_stldfdc_1_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + bbc_stldfdc_1_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/fdc/udm.cpp b/src/devices/bus/bbc/fdc/udm.cpp index dc078aa8dfa..dfcc4f801fa 100644 --- a/src/devices/bus/bbc/fdc/udm.cpp +++ b/src/devices/bus/bbc/fdc/udm.cpp @@ -85,7 +85,7 @@ const tiny_rom_entry *bbc_udm_device::device_rom_region() const // bbc_udm_device - constructor //------------------------------------------------- -bbc_udm_device::bbc_udm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_udm_device::bbc_udm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_UDM, tag, owner, clock) , device_bbc_fdc_interface(mconfig, *this) , m_fdc(*this, "wd2793") diff --git a/src/devices/bus/bbc/fdc/udm.h b/src/devices/bus/bbc/fdc/udm.h index 8e21917efb8..06a7605d83f 100644 --- a/src/devices/bus/bbc/fdc/udm.h +++ b/src/devices/bus/bbc/fdc/udm.h @@ -28,7 +28,7 @@ class bbc_udm_device : { public: // construction/destruction - bbc_udm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_udm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/fdc/watford.cpp b/src/devices/bus/bbc/fdc/watford.cpp index 7f058c41838..2d4b9d6fb28 100644 --- a/src/devices/bus/bbc/fdc/watford.cpp +++ b/src/devices/bus/bbc/fdc/watford.cpp @@ -110,13 +110,13 @@ const tiny_rom_entry *bbc_weddb3_device::device_rom_region() const // bbc_watfordfdc_device - constructor //------------------------------------------------- -bbc_watfordfdc_device::bbc_watfordfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_watfordfdc_device::bbc_watfordfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_fdc_interface(mconfig, *this) { } -bbc_weddb2_device::bbc_weddb2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_weddb2_device::bbc_weddb2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_watfordfdc_device(mconfig, BBC_WEDDB2, tag, owner, clock) , m_fdc(*this, "wd1772") , m_floppy(*this, "wd1772:%u", 0) @@ -124,7 +124,7 @@ bbc_weddb2_device::bbc_weddb2_device(const machine_config &mconfig, const char * { } -bbc_weddb3_device::bbc_weddb3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_weddb3_device::bbc_weddb3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_watfordfdc_device(mconfig, BBC_WEDDB3, tag, owner, clock) , m_fdc(*this, "wd1770") , m_floppy(*this, "wd1770:%u", 0) diff --git a/src/devices/bus/bbc/fdc/watford.h b/src/devices/bus/bbc/fdc/watford.h index 37a635d2afb..51effebb2a4 100644 --- a/src/devices/bus/bbc/fdc/watford.h +++ b/src/devices/bus/bbc/fdc/watford.h @@ -30,13 +30,13 @@ public: protected: // construction/destruction - bbc_watfordfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_watfordfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; class bbc_weddb2_device : public bbc_watfordfdc_device { public: - bbc_weddb2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_weddb2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -58,7 +58,7 @@ private: class bbc_weddb3_device : public bbc_watfordfdc_device { public: - bbc_weddb3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_weddb3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/aries.cpp b/src/devices/bus/bbc/internal/aries.cpp index 1ee29009129..705374042be 100644 --- a/src/devices/bus/bbc/internal/aries.cpp +++ b/src/devices/bus/bbc/internal/aries.cpp @@ -103,24 +103,24 @@ const tiny_rom_entry *bbc_ariesb32_device::device_rom_region() const // bbc_aries_device - constructor //------------------------------------------------- -bbc_ariesb12_device::bbc_ariesb12_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_ariesb12_device::bbc_ariesb12_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) { } -bbc_ariesb12_device::bbc_ariesb12_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_ariesb12_device::bbc_ariesb12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_ariesb12_device(mconfig, BBC_ARIESB12, tag, owner, clock) { } -bbc_ariesb20_device::bbc_ariesb20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_ariesb20_device::bbc_ariesb20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_ariesb12_device(mconfig, BBC_ARIESB20, tag, owner, clock) { } -bbc_ariesb32_device::bbc_ariesb32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_ariesb32_device::bbc_ariesb32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_ariesb12_device(mconfig, BBC_ARIESB32, tag, owner, clock) , m_aries_rom(*this, "aries_rom") { diff --git a/src/devices/bus/bbc/internal/aries.h b/src/devices/bus/bbc/internal/aries.h index 9dc7383ff21..a61cd9119d3 100644 --- a/src/devices/bus/bbc/internal/aries.h +++ b/src/devices/bus/bbc/internal/aries.h @@ -30,10 +30,10 @@ class bbc_ariesb12_device : { public: // construction/destruction - bbc_ariesb12_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_ariesb12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_ariesb12_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_ariesb12_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -56,7 +56,7 @@ class bbc_ariesb20_device : public bbc_ariesb12_device { public: // construction/destruction - bbc_ariesb20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_ariesb20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -82,7 +82,7 @@ class bbc_ariesb32_device : public bbc_ariesb12_device { public: // construction/destruction - bbc_ariesb32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_ariesb32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/atpl.cpp b/src/devices/bus/bbc/internal/atpl.cpp index 94c5f8459b0..635785c8bc6 100644 --- a/src/devices/bus/bbc/internal/atpl.cpp +++ b/src/devices/bus/bbc/internal/atpl.cpp @@ -94,7 +94,7 @@ void bbc_atplswp_device::device_add_mconfig(machine_config &config) // bbc_atplsw_device - constructor //------------------------------------------------- -bbc_atplsw_device::bbc_atplsw_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_atplsw_device::bbc_atplsw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_ATPLSW, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) @@ -102,7 +102,7 @@ bbc_atplsw_device::bbc_atplsw_device(const machine_config &mconfig, const char * { } -bbc_atplswp_device::bbc_atplswp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_atplswp_device::bbc_atplswp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_ATPLSWP, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) diff --git a/src/devices/bus/bbc/internal/atpl.h b/src/devices/bus/bbc/internal/atpl.h index fe10ebb3a76..37a78d23d29 100644 --- a/src/devices/bus/bbc/internal/atpl.h +++ b/src/devices/bus/bbc/internal/atpl.h @@ -27,7 +27,7 @@ class bbc_atplsw_device : { public: // construction/destruction - bbc_atplsw_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_atplsw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -56,7 +56,7 @@ class bbc_atplswp_device : { public: // construction/destruction - bbc_atplswp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_atplswp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/cumana68k.cpp b/src/devices/bus/bbc/internal/cumana68k.cpp index 19e71ee8692..d6245606707 100644 --- a/src/devices/bus/bbc/internal/cumana68k.cpp +++ b/src/devices/bus/bbc/internal/cumana68k.cpp @@ -96,7 +96,7 @@ void bbc_cumana68k_device::device_add_mconfig(machine_config &config) downcast<nscsi_callback_device&>(*device).req_callback().append(m_pia_sasi, FUNC(pia6821_device::ca1_w)); }); - PIA6821(config, m_pia_sasi, 0); + PIA6821(config, m_pia_sasi); m_pia_sasi->readpa_handler().set(m_sasi, FUNC(nscsi_callback_device::read)); m_pia_sasi->writepa_handler().set(m_sasi, FUNC(nscsi_callback_device::write)); m_pia_sasi->writepb_handler().set(FUNC(bbc_cumana68k_device::pia_sasi_pb_w)); @@ -106,7 +106,7 @@ void bbc_cumana68k_device::device_add_mconfig(machine_config &config) m_pia_sasi->irqa_handler().set(m_irqs, FUNC(input_merger_device::in_w<0>)); m_pia_sasi->irqb_handler().set(m_irqs, FUNC(input_merger_device::in_w<1>)); - PIA6821(config, m_pia_rtc, 0); + PIA6821(config, m_pia_rtc); m_pia_rtc->readpa_handler().set([this]() { return m_mc146818_data; }); m_pia_rtc->writepa_handler().set([this](uint8_t data) { m_mc146818_data = data; }); m_pia_rtc->writepb_handler().set(FUNC(bbc_cumana68k_device::pia_rtc_pb_w)); @@ -142,7 +142,7 @@ const tiny_rom_entry *bbc_cumana68k_device::device_rom_region() const // bbc_cumana68k_device - constructor //------------------------------------------------- -bbc_cumana68k_device::bbc_cumana68k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_cumana68k_device::bbc_cumana68k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_CUMANA68K, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_m68008(*this, "m68008") diff --git a/src/devices/bus/bbc/internal/cumana68k.h b/src/devices/bus/bbc/internal/cumana68k.h index 84f545db295..2ff26571974 100644 --- a/src/devices/bus/bbc/internal/cumana68k.h +++ b/src/devices/bus/bbc/internal/cumana68k.h @@ -32,7 +32,7 @@ class bbc_cumana68k_device : { public: // construction/destruction - bbc_cumana68k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_cumana68k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void pia_rtc_pb_w(uint8_t data); void pia_sasi_pb_w(uint8_t data); diff --git a/src/devices/bus/bbc/internal/integrab.cpp b/src/devices/bus/bbc/internal/integrab.cpp index 6d69b9c34c0..b6fe1c052c1 100644 --- a/src/devices/bus/bbc/internal/integrab.cpp +++ b/src/devices/bus/bbc/internal/integrab.cpp @@ -107,7 +107,7 @@ const tiny_rom_entry *bbc_integrab_device::device_rom_region() const // bbc_integrab_device - constructor //------------------------------------------------- -bbc_integrab_device::bbc_integrab_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_integrab_device::bbc_integrab_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_INTEGRAB, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_ibos(*this, "ibos") diff --git a/src/devices/bus/bbc/internal/integrab.h b/src/devices/bus/bbc/internal/integrab.h index 679bdc44526..a804ec40190 100644 --- a/src/devices/bus/bbc/internal/integrab.h +++ b/src/devices/bus/bbc/internal/integrab.h @@ -25,7 +25,7 @@ class bbc_integrab_device : { public: // construction/destruction - bbc_integrab_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_integrab_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/internal.cpp b/src/devices/bus/bbc/internal/internal.cpp index a365b5729dc..1442b0bf5fc 100644 --- a/src/devices/bus/bbc/internal/internal.cpp +++ b/src/devices/bus/bbc/internal/internal.cpp @@ -52,7 +52,7 @@ device_bbc_internal_interface::device_bbc_internal_interface(const machine_confi // bbc_internal_slot_device - constructor //------------------------------------------------- -bbc_internal_slot_device::bbc_internal_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_internal_slot_device::bbc_internal_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_INTERNAL_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_bbc_internal_interface>(mconfig, *this) , m_irq_handler(*this) diff --git a/src/devices/bus/bbc/internal/internal.h b/src/devices/bus/bbc/internal/internal.h index 3042dd30a0b..1ffdb0186fa 100644 --- a/src/devices/bus/bbc/internal/internal.h +++ b/src/devices/bus/bbc/internal/internal.h @@ -60,7 +60,7 @@ class bbc_internal_slot_device : public device_t, public device_single_card_slot public: // construction/destruction template <typename T> - bbc_internal_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&slot_options, const char *default_option) + bbc_internal_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&slot_options, const char *default_option) : bbc_internal_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -69,7 +69,7 @@ public: set_fixed(false); } - bbc_internal_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_internal_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/bus/bbc/internal/memex.cpp b/src/devices/bus/bbc/internal/memex.cpp index 809313e4c68..d49dca9f09f 100644 --- a/src/devices/bus/bbc/internal/memex.cpp +++ b/src/devices/bus/bbc/internal/memex.cpp @@ -48,7 +48,7 @@ const tiny_rom_entry *bbc_memexb20_device::device_rom_region() const // bbc_memexb20_device - constructor //------------------------------------------------- -bbc_memexb20_device::bbc_memexb20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_memexb20_device::bbc_memexb20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_MEMEXB20, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_shadow(false) diff --git a/src/devices/bus/bbc/internal/memex.h b/src/devices/bus/bbc/internal/memex.h index 1e4f07bcb16..6ab35c7ba5a 100644 --- a/src/devices/bus/bbc/internal/memex.h +++ b/src/devices/bus/bbc/internal/memex.h @@ -21,7 +21,7 @@ class bbc_memexb20_device : public device_t, public device_bbc_internal_interfac { public: // construction/destruction - bbc_memexb20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_memexb20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/morleyaa.cpp b/src/devices/bus/bbc/internal/morleyaa.cpp index e01336c3b5c..f93a886109f 100644 --- a/src/devices/bus/bbc/internal/morleyaa.cpp +++ b/src/devices/bus/bbc/internal/morleyaa.cpp @@ -71,7 +71,7 @@ const tiny_rom_entry *bbc_morleyaa_device::device_rom_region() const // bbc_morleyaa_device - constructor //------------------------------------------------- -bbc_morleyaa_device::bbc_morleyaa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_morleyaa_device::bbc_morleyaa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_MORLEYAA, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_aa_rom(*this, "aa_rom") diff --git a/src/devices/bus/bbc/internal/morleyaa.h b/src/devices/bus/bbc/internal/morleyaa.h index f2debcff982..0d26f2b45c8 100644 --- a/src/devices/bus/bbc/internal/morleyaa.h +++ b/src/devices/bus/bbc/internal/morleyaa.h @@ -23,7 +23,7 @@ class bbc_morleyaa_device : { public: // construction/destruction - bbc_morleyaa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_morleyaa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/overlay.cpp b/src/devices/bus/bbc/internal/overlay.cpp index c46a280a316..f5959af0196 100644 --- a/src/devices/bus/bbc/internal/overlay.cpp +++ b/src/devices/bus/bbc/internal/overlay.cpp @@ -87,7 +87,7 @@ void bbc_overlay_device::device_add_mconfig(machine_config &config) // bbc_overlay_device - constructor //------------------------------------------------- -bbc_overlay_device::bbc_overlay_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_overlay_device::bbc_overlay_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_OVERLAY, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) diff --git a/src/devices/bus/bbc/internal/overlay.h b/src/devices/bus/bbc/internal/overlay.h index 3800687f5ac..6f1ac8bad30 100644 --- a/src/devices/bus/bbc/internal/overlay.h +++ b/src/devices/bus/bbc/internal/overlay.h @@ -25,7 +25,7 @@ class bbc_overlay_device : { public: // construction/destruction - bbc_overlay_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_overlay_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/peartree.cpp b/src/devices/bus/bbc/internal/peartree.cpp index 49281731097..8953c43cdfe 100644 --- a/src/devices/bus/bbc/internal/peartree.cpp +++ b/src/devices/bus/bbc/internal/peartree.cpp @@ -101,19 +101,19 @@ void bbc_mr4800_device::device_add_mconfig(machine_config &config) // bbc_mr3000_device - constructor //------------------------------------------------- -bbc_mr3000_device::bbc_mr3000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_mr3000_device::bbc_mr3000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) { } -bbc_mr3000_device::bbc_mr3000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_mr3000_device::bbc_mr3000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_mr3000_device(mconfig, BBC_MR3000, tag, owner, clock) { } -bbc_mr4200_device::bbc_mr4200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_mr4200_device::bbc_mr4200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_mr3000_device(mconfig, BBC_MR4200, tag, owner, clock) , m_wp(*this, "wp") { @@ -123,7 +123,7 @@ bbc_mr4200_device::bbc_mr4200_device(const machine_config &mconfig, const char * // bbc_mr4300_device - constructor //------------------------------------------------- -bbc_mr4300_device::bbc_mr4300_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_mr4300_device::bbc_mr4300_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) @@ -131,12 +131,12 @@ bbc_mr4300_device::bbc_mr4300_device(const machine_config &mconfig, device_type { } -bbc_mr4300_device::bbc_mr4300_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_mr4300_device::bbc_mr4300_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_mr4300_device(mconfig, BBC_MR4300, tag, owner, clock) { } -bbc_mr4800_device::bbc_mr4800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_mr4800_device::bbc_mr4800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_mr4300_device(mconfig, BBC_MR4800, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/internal/peartree.h b/src/devices/bus/bbc/internal/peartree.h index 9f9ed683396..6b893fc3522 100644 --- a/src/devices/bus/bbc/internal/peartree.h +++ b/src/devices/bus/bbc/internal/peartree.h @@ -25,10 +25,10 @@ class bbc_mr3000_device : { public: // construction/destruction - bbc_mr3000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_mr3000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_mr3000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_mr3000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -51,7 +51,7 @@ class bbc_mr4200_device : public bbc_mr3000_device { public: // construction/destruction - bbc_mr4200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_mr4200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -70,10 +70,10 @@ class bbc_mr4300_device : { public: // construction/destruction - bbc_mr4300_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_mr4300_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_mr4300_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_mr4300_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -98,7 +98,7 @@ class bbc_mr4800_device : public bbc_mr4300_device { public: // construction/destruction - bbc_mr4800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_mr4800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/bbc/internal/ramamp.cpp b/src/devices/bus/bbc/internal/ramamp.cpp index 586159377aa..24c95856307 100644 --- a/src/devices/bus/bbc/internal/ramamp.cpp +++ b/src/devices/bus/bbc/internal/ramamp.cpp @@ -65,7 +65,7 @@ void bbc_ramamp_device::device_add_mconfig(machine_config &config) // bbc_ramamp_device - constructor //------------------------------------------------- -bbc_ramamp_device::bbc_ramamp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_ramamp_device::bbc_ramamp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_RAMAMP, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) diff --git a/src/devices/bus/bbc/internal/ramamp.h b/src/devices/bus/bbc/internal/ramamp.h index d8f9b62408b..39870217a06 100644 --- a/src/devices/bus/bbc/internal/ramamp.h +++ b/src/devices/bus/bbc/internal/ramamp.h @@ -25,7 +25,7 @@ class bbc_ramamp_device : { public: // construction/destruction - bbc_ramamp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_ramamp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/raven20.cpp b/src/devices/bus/bbc/internal/raven20.cpp index f6bb3efdb4b..86f371f259d 100644 --- a/src/devices/bus/bbc/internal/raven20.cpp +++ b/src/devices/bus/bbc/internal/raven20.cpp @@ -51,7 +51,7 @@ const tiny_rom_entry *bbc_raven20_device::device_rom_region() const // bbc_raven20_device - constructor //------------------------------------------------- -bbc_raven20_device::bbc_raven20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_raven20_device::bbc_raven20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_RAVEN20, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) { diff --git a/src/devices/bus/bbc/internal/raven20.h b/src/devices/bus/bbc/internal/raven20.h index 0e04137afa6..3962b280690 100644 --- a/src/devices/bus/bbc/internal/raven20.h +++ b/src/devices/bus/bbc/internal/raven20.h @@ -23,7 +23,7 @@ class bbc_raven20_device : { public: // construction/destruction - bbc_raven20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_raven20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/romex.cpp b/src/devices/bus/bbc/internal/romex.cpp index 9d7932db81f..60eeb3b8e49 100644 --- a/src/devices/bus/bbc/internal/romex.cpp +++ b/src/devices/bus/bbc/internal/romex.cpp @@ -53,7 +53,7 @@ void bbc_romex13_device::device_add_mconfig(machine_config &config) // bbc_romex13_device - constructor //------------------------------------------------- -bbc_romex13_device::bbc_romex13_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_romex13_device::bbc_romex13_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_ROMEX13, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) diff --git a/src/devices/bus/bbc/internal/romex.h b/src/devices/bus/bbc/internal/romex.h index b9542937ebf..8da974be33e 100644 --- a/src/devices/bus/bbc/internal/romex.h +++ b/src/devices/bus/bbc/internal/romex.h @@ -25,7 +25,7 @@ class bbc_romex13_device : { public: // construction/destruction - bbc_romex13_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_romex13_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/stl2m128.cpp b/src/devices/bus/bbc/internal/stl2m128.cpp index 46b595aedfa..dd1d6e14a8d 100644 --- a/src/devices/bus/bbc/internal/stl2m128.cpp +++ b/src/devices/bus/bbc/internal/stl2m128.cpp @@ -87,7 +87,7 @@ const tiny_rom_entry *bbc_stl2m128_device::device_rom_region() const // bbc_stl2m128_device - constructor //------------------------------------------------- -bbc_stl2m128_device::bbc_stl2m128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_stl2m128_device::bbc_stl2m128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_STL2M128, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) diff --git a/src/devices/bus/bbc/internal/stl2m128.h b/src/devices/bus/bbc/internal/stl2m128.h index 2c5f327ab19..bb61e166c2b 100644 --- a/src/devices/bus/bbc/internal/stl2m128.h +++ b/src/devices/bus/bbc/internal/stl2m128.h @@ -23,7 +23,7 @@ class bbc_stl2m128_device : { public: // construction/destruction - bbc_stl2m128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_stl2m128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/stl4m32.cpp b/src/devices/bus/bbc/internal/stl4m32.cpp index 5d3782c36ac..fb4703d5fdf 100644 --- a/src/devices/bus/bbc/internal/stl4m32.cpp +++ b/src/devices/bus/bbc/internal/stl4m32.cpp @@ -86,7 +86,7 @@ const tiny_rom_entry *bbc_stl4m32_device::device_rom_region() const // bbc_stl4m32_device - constructor //------------------------------------------------- -bbc_stl4m32_device::bbc_stl4m32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_stl4m32_device::bbc_stl4m32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_STL4M32, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) diff --git a/src/devices/bus/bbc/internal/stl4m32.h b/src/devices/bus/bbc/internal/stl4m32.h index ac939d6d4ff..f45d24876d5 100644 --- a/src/devices/bus/bbc/internal/stl4m32.h +++ b/src/devices/bus/bbc/internal/stl4m32.h @@ -25,7 +25,7 @@ class bbc_stl4m32_device : { public: // construction/destruction - bbc_stl4m32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_stl4m32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(clock_switch); diff --git a/src/devices/bus/bbc/internal/stlswr.cpp b/src/devices/bus/bbc/internal/stlswr.cpp index f4992197453..bdbf1c17d29 100644 --- a/src/devices/bus/bbc/internal/stlswr.cpp +++ b/src/devices/bus/bbc/internal/stlswr.cpp @@ -94,29 +94,29 @@ const tiny_rom_entry *bbc_stlswr_device::device_rom_region() const // bbc_stlswr_device - constructor //------------------------------------------------- -bbc_stlswr_device::bbc_stlswr_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_stlswr_device::bbc_stlswr_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) { } -bbc_stlswr16_device::bbc_stlswr16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_stlswr16_device::bbc_stlswr16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_stlswr_device(mconfig, BBC_STLSWR16, tag, owner, clock) { } -bbc_stlswr32_device::bbc_stlswr32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_stlswr32_device::bbc_stlswr32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_stlswr_device(mconfig, BBC_STLSWR32, tag, owner, clock) { } -bbc_stlswr64_device::bbc_stlswr64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_stlswr64_device::bbc_stlswr64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_stlswr_device(mconfig, BBC_STLSWR64, tag, owner, clock) { } -bbc_stlswr128_device::bbc_stlswr128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_stlswr128_device::bbc_stlswr128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_stlswr_device(mconfig, BBC_STLSWR128, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/internal/stlswr.h b/src/devices/bus/bbc/internal/stlswr.h index db7e263ce28..3ff46bfd349 100644 --- a/src/devices/bus/bbc/internal/stlswr.h +++ b/src/devices/bus/bbc/internal/stlswr.h @@ -25,10 +25,10 @@ class bbc_stlswr_device : { public: // construction/destruction - bbc_stlswr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_stlswr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_stlswr_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_stlswr_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -53,7 +53,7 @@ class bbc_stlswr16_device : public bbc_stlswr_device { public: // construction/destruction - bbc_stlswr16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_stlswr16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -65,7 +65,7 @@ class bbc_stlswr32_device : public bbc_stlswr_device { public: // construction/destruction - bbc_stlswr32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_stlswr32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -77,7 +77,7 @@ class bbc_stlswr64_device : public bbc_stlswr_device { public: // construction/destruction - bbc_stlswr64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_stlswr64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -89,7 +89,7 @@ class bbc_stlswr128_device : public bbc_stlswr_device { public: // construction/destruction - bbc_stlswr128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_stlswr128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/bbc/internal/we32kram.cpp b/src/devices/bus/bbc/internal/we32kram.cpp index 4e0e084e655..cfe6a252d24 100644 --- a/src/devices/bus/bbc/internal/we32kram.cpp +++ b/src/devices/bus/bbc/internal/we32kram.cpp @@ -56,7 +56,7 @@ const tiny_rom_entry *bbc_we32kram_device::device_rom_region() const // bbc_we32kram_device - constructor //------------------------------------------------- -bbc_we32kram_device::bbc_we32kram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_we32kram_device::bbc_we32kram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_WE32KRAM, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) { diff --git a/src/devices/bus/bbc/internal/we32kram.h b/src/devices/bus/bbc/internal/we32kram.h index aa10005292b..d5fc6a0a1f5 100644 --- a/src/devices/bus/bbc/internal/we32kram.h +++ b/src/devices/bus/bbc/internal/we32kram.h @@ -25,7 +25,7 @@ class bbc_we32kram_device : { public: // construction/destruction - bbc_we32kram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_we32kram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/werom.cpp b/src/devices/bus/bbc/internal/werom.cpp index bc38500dee8..90937325851 100644 --- a/src/devices/bus/bbc/internal/werom.cpp +++ b/src/devices/bus/bbc/internal/werom.cpp @@ -94,20 +94,20 @@ void bbc_we13rom_device::device_add_mconfig(machine_config &config) // bbc_werom_device - constructor //------------------------------------------------- -bbc_werom_device::bbc_werom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_werom_device::bbc_werom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) { } -bbc_we12rom_device::bbc_we12rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_we12rom_device::bbc_we12rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_werom_device(mconfig, BBC_WE12ROM, tag, owner, clock) , m_wp(*this, "wp") { } -bbc_we13rom_device::bbc_we13rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_we13rom_device::bbc_we13rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_werom_device(mconfig, BBC_WE13ROM, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/internal/werom.h b/src/devices/bus/bbc/internal/werom.h index 4e95ba120d8..87985297cf4 100644 --- a/src/devices/bus/bbc/internal/werom.h +++ b/src/devices/bus/bbc/internal/werom.h @@ -27,10 +27,10 @@ class bbc_werom_device : { public: // construction/destruction - bbc_werom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_werom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_werom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_werom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); optional_device_array<bbc_romslot_device, 16> m_rom; @@ -45,7 +45,7 @@ class bbc_we12rom_device : public bbc_werom_device { public: // construction/destruction - bbc_we12rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_we12rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -67,7 +67,7 @@ class bbc_we13rom_device : public bbc_werom_device { public: // construction/destruction - bbc_we13rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_we13rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/internal/weromram.cpp b/src/devices/bus/bbc/internal/weromram.cpp index ceb8be3e270..cf429706721 100644 --- a/src/devices/bus/bbc/internal/weromram.cpp +++ b/src/devices/bus/bbc/internal/weromram.cpp @@ -50,7 +50,7 @@ void bbc_weromram_device::device_add_mconfig(machine_config &config) // bbc_weromram_device - constructor //------------------------------------------------- -bbc_weromram_device::bbc_weromram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_weromram_device::bbc_weromram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_WEROMRAM, tag, owner, clock) , device_bbc_internal_interface(mconfig, *this) , m_rom(*this, "romslot%u", 0U) diff --git a/src/devices/bus/bbc/internal/weromram.h b/src/devices/bus/bbc/internal/weromram.h index b85c9d031ab..fa853944e51 100644 --- a/src/devices/bus/bbc/internal/weromram.h +++ b/src/devices/bus/bbc/internal/weromram.h @@ -25,7 +25,7 @@ class bbc_weromram_device : { public: // construction/destruction - bbc_weromram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_weromram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/joyport/joyport.cpp b/src/devices/bus/bbc/joyport/joyport.cpp index 59173030724..161b32a0a0d 100644 --- a/src/devices/bus/bbc/joyport/joyport.cpp +++ b/src/devices/bus/bbc/joyport/joyport.cpp @@ -40,7 +40,7 @@ device_bbc_joyport_interface::device_bbc_joyport_interface(const machine_config // bbcmc_joyport_slot_device - constructor //------------------------------------------------- -bbc_joyport_slot_device::bbc_joyport_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_joyport_slot_device::bbc_joyport_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_JOYPORT_SLOT, tag, owner, clock) , device_single_card_slot_interface(mconfig, *this) , m_device(nullptr) diff --git a/src/devices/bus/bbc/joyport/joyport.h b/src/devices/bus/bbc/joyport/joyport.h index 15d81243d84..94814633a34 100644 --- a/src/devices/bus/bbc/joyport/joyport.h +++ b/src/devices/bus/bbc/joyport/joyport.h @@ -55,7 +55,7 @@ public: set_fixed(false); } - bbc_joyport_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + bbc_joyport_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // callbacks auto cb1_handler() { return m_cb1_handler.bind(); } diff --git a/src/devices/bus/bbc/joyport/joystick.cpp b/src/devices/bus/bbc/joyport/joystick.cpp index 1f5a9f89c98..527c7668e10 100644 --- a/src/devices/bus/bbc/joyport/joystick.cpp +++ b/src/devices/bus/bbc/joyport/joystick.cpp @@ -48,7 +48,7 @@ ioport_constructor bbcmc_joystick_device::device_input_ports() const // bbcmc_joystick_device - constructor //------------------------------------------------- -bbcmc_joystick_device::bbcmc_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbcmc_joystick_device::bbcmc_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBCMC_JOYSTICK, tag, owner, clock) , device_bbc_joyport_interface(mconfig, *this) , m_joy(*this, "JOY") diff --git a/src/devices/bus/bbc/joyport/joystick.h b/src/devices/bus/bbc/joyport/joystick.h index b30ef3ae51c..50872e7f810 100644 --- a/src/devices/bus/bbc/joyport/joystick.h +++ b/src/devices/bus/bbc/joyport/joystick.h @@ -26,7 +26,7 @@ class bbcmc_joystick_device : { public: // construction/destruction - bbcmc_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbcmc_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/bbc/joyport/mouse.cpp b/src/devices/bus/bbc/joyport/mouse.cpp index 1cd91caeaa5..ae8fe92b348 100644 --- a/src/devices/bus/bbc/joyport/mouse.cpp +++ b/src/devices/bus/bbc/joyport/mouse.cpp @@ -59,7 +59,7 @@ ioport_constructor bbcmc_mouse_device::device_input_ports() const // bbcmc_mouse_device - constructor //------------------------------------------------- -bbcmc_mouse_device::bbcmc_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbcmc_mouse_device::bbcmc_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBCMC_MOUSE, tag, owner, clock) , device_bbc_joyport_interface(mconfig, *this) , m_mouse_x(*this, "mouse_x") diff --git a/src/devices/bus/bbc/joyport/mouse.h b/src/devices/bus/bbc/joyport/mouse.h index 0e2c6947104..6347d6bbb3f 100644 --- a/src/devices/bus/bbc/joyport/mouse.h +++ b/src/devices/bus/bbc/joyport/mouse.h @@ -25,7 +25,7 @@ class bbcmc_mouse_device : { public: // construction/destruction - bbcmc_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbcmc_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/modem/meup.cpp b/src/devices/bus/bbc/modem/meup.cpp index 128db2b0297..eb24a25e66c 100644 --- a/src/devices/bus/bbc/modem/meup.cpp +++ b/src/devices/bus/bbc/modem/meup.cpp @@ -45,7 +45,7 @@ void bbc_meup_device::device_add_mconfig(machine_config &config) // bbc_meup_device - constructor //------------------------------------------------- -bbc_meup_device::bbc_meup_device(const machine_config &mconfig, const char* tag, device_t* owner, uint32_t clock) +bbc_meup_device::bbc_meup_device(const machine_config &mconfig, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, BBC_MEUP, tag, owner, clock) , device_bbc_modem_interface(mconfig, *this) , m_via(*this, "via") diff --git a/src/devices/bus/bbc/modem/meup.h b/src/devices/bus/bbc/modem/meup.h index 95d0a536c50..4be0245071d 100644 --- a/src/devices/bus/bbc/modem/meup.h +++ b/src/devices/bus/bbc/modem/meup.h @@ -22,7 +22,7 @@ class bbc_meup_device: public device_t, public device_bbc_modem_interface { public: // construction/destruction - bbc_meup_device(const machine_config &mconfig, const char* tag, device_t* owner, uint32_t clock); + bbc_meup_device(const machine_config &mconfig, const char* tag, device_t* owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/modem/modem.cpp b/src/devices/bus/bbc/modem/modem.cpp index e3b4d164fac..43af8978c4b 100644 --- a/src/devices/bus/bbc/modem/modem.cpp +++ b/src/devices/bus/bbc/modem/modem.cpp @@ -41,7 +41,7 @@ device_bbc_modem_interface::device_bbc_modem_interface(const machine_config &mco // bbc_modem_slot_device - constructor //------------------------------------------------- -bbc_modem_slot_device::bbc_modem_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_modem_slot_device::bbc_modem_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_MODEM_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_bbc_modem_interface>(mconfig, *this) , m_card(nullptr) diff --git a/src/devices/bus/bbc/modem/modem.h b/src/devices/bus/bbc/modem/modem.h index 6c1e7840637..17d7076aa28 100644 --- a/src/devices/bus/bbc/modem/modem.h +++ b/src/devices/bus/bbc/modem/modem.h @@ -51,7 +51,7 @@ class bbc_modem_slot_device : public device_t, public device_single_card_slot_in public: // construction/destruction template <typename T> - bbc_modem_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&slot_options, const char *default_option) + bbc_modem_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&slot_options, const char *default_option) : bbc_modem_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -60,7 +60,7 @@ public: set_fixed(false); } - bbc_modem_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + bbc_modem_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // callbacks auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/bus/bbc/modem/scsiaiv.cpp b/src/devices/bus/bbc/modem/scsiaiv.cpp index 603b36c9a8a..c4c3e5243d5 100644 --- a/src/devices/bus/bbc/modem/scsiaiv.cpp +++ b/src/devices/bus/bbc/modem/scsiaiv.cpp @@ -54,19 +54,19 @@ void bbc_scsiaiv_device::device_add_mconfig(machine_config& config) // bbc_scsiaiv_device - constructor //------------------------------------------------- -bbc_scsiaiv_device::bbc_scsiaiv_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock) +bbc_scsiaiv_device::bbc_scsiaiv_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_modem_interface(mconfig, *this) , m_scsi(*this, "scsi:7:scsicb") { } -bbc_scsiaiv_device::bbc_scsiaiv_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +bbc_scsiaiv_device::bbc_scsiaiv_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : bbc_scsiaiv_device(mconfig, BBC_SCSIAIV, tag, owner, clock) { } -//bbc_vp415_device::bbc_vp415_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +//bbc_vp415_device::bbc_vp415_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) // : bbc_scsiaiv_device(mconfig, BBC_VP415, tag, owner, clock) //{ //} diff --git a/src/devices/bus/bbc/modem/scsiaiv.h b/src/devices/bus/bbc/modem/scsiaiv.h index 0b244bb71e3..8cbb8602d9b 100644 --- a/src/devices/bus/bbc/modem/scsiaiv.h +++ b/src/devices/bus/bbc/modem/scsiaiv.h @@ -24,13 +24,13 @@ class bbc_scsiaiv_device: { public: // construction/destruction - bbc_scsiaiv_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + bbc_scsiaiv_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(bsy_w); DECLARE_WRITE_LINE_MEMBER(req_w); protected: - bbc_scsiaiv_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock); + bbc_scsiaiv_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -55,7 +55,7 @@ private: //{ //public: // // construction/destruction -// bbc_vp415_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); +// bbc_vp415_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); // //protected: // // optional information overrides diff --git a/src/devices/bus/bbc/rom/datagem.cpp b/src/devices/bus/bbc/rom/datagem.cpp index 11f2cfdb631..d516d2d1487 100644 --- a/src/devices/bus/bbc/rom/datagem.cpp +++ b/src/devices/bus/bbc/rom/datagem.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(BBC_DATAGEM, bbc_datagem_device, "bbc_datagem", "Gemini DataG // bbc_datagem_device - constructor //------------------------------------------------- -bbc_datagem_device::bbc_datagem_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_datagem_device::bbc_datagem_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_DATAGEM, tag, owner, clock) , device_bbc_rom_interface(mconfig, *this) , m_bank(0) diff --git a/src/devices/bus/bbc/rom/datagem.h b/src/devices/bus/bbc/rom/datagem.h index 0d78f754e44..f5c1bb29dbf 100644 --- a/src/devices/bus/bbc/rom/datagem.h +++ b/src/devices/bus/bbc/rom/datagem.h @@ -25,7 +25,7 @@ class bbc_datagem_device : public device_t, { public: // construction/destruction - bbc_datagem_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_datagem_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/rom/dfs.cpp b/src/devices/bus/bbc/rom/dfs.cpp index 7395b31dae9..4dc8dd6bb0d 100644 --- a/src/devices/bus/bbc/rom/dfs.cpp +++ b/src/devices/bus/bbc/rom/dfs.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(BBC_DFSE00, bbc_dfse00_device, "bbc_dfse00", "BBC Micro E00 D // bbc_rom_device - constructor //------------------------------------------------- -bbc_dfse00_device::bbc_dfse00_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_dfse00_device::bbc_dfse00_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_DFSE00, tag, owner, clock) , device_bbc_rom_interface(mconfig, *this) { diff --git a/src/devices/bus/bbc/rom/dfs.h b/src/devices/bus/bbc/rom/dfs.h index 13d6d94d079..8f5824d1146 100644 --- a/src/devices/bus/bbc/rom/dfs.h +++ b/src/devices/bus/bbc/rom/dfs.h @@ -23,7 +23,7 @@ class bbc_dfse00_device : public device_t, public device_bbc_rom_interface { public: // construction/destruction - bbc_dfse00_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_dfse00_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/rom/genie.cpp b/src/devices/bus/bbc/rom/genie.cpp index 28b9b42644a..c3b1ef8afc0 100644 --- a/src/devices/bus/bbc/rom/genie.cpp +++ b/src/devices/bus/bbc/rom/genie.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(BBC_PMSGENIE, bbc_pmsgenie_device, "bbc_pmsgenie", "PMS Genie // bbc_palprom_device - constructor //------------------------------------------------- -bbc_pmsgenie_device::bbc_pmsgenie_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_pmsgenie_device::bbc_pmsgenie_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_PMSGENIE, tag, owner, clock) , device_bbc_rom_interface(mconfig, *this) , m_write_latch(0) diff --git a/src/devices/bus/bbc/rom/genie.h b/src/devices/bus/bbc/rom/genie.h index 82813b2b166..81ffb542e9b 100644 --- a/src/devices/bus/bbc/rom/genie.h +++ b/src/devices/bus/bbc/rom/genie.h @@ -25,7 +25,7 @@ class bbc_pmsgenie_device : public device_t, { public: // construction/destruction - bbc_pmsgenie_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_pmsgenie_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/rom/nvram.cpp b/src/devices/bus/bbc/rom/nvram.cpp index 0d24f30c8bd..686b2afcc6a 100644 --- a/src/devices/bus/bbc/rom/nvram.cpp +++ b/src/devices/bus/bbc/rom/nvram.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(BBC_NVRAM, bbc_nvram_device, "bbc_nvram", "BBC Micro Sideways // bbc_nvram_device - constructor //------------------------------------------------- -bbc_nvram_device::bbc_nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_nvram_device::bbc_nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_NVRAM, tag, owner, clock) , device_bbc_rom_interface(mconfig, *this) { diff --git a/src/devices/bus/bbc/rom/nvram.h b/src/devices/bus/bbc/rom/nvram.h index d10025c6acd..a9134c44ac1 100644 --- a/src/devices/bus/bbc/rom/nvram.h +++ b/src/devices/bus/bbc/rom/nvram.h @@ -24,7 +24,7 @@ class bbc_nvram_device : public device_t, { public: // construction/destruction - bbc_nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/rom/pal.cpp b/src/devices/bus/bbc/rom/pal.cpp index 51667f70955..80c838a1a4c 100644 --- a/src/devices/bus/bbc/rom/pal.cpp +++ b/src/devices/bus/bbc/rom/pal.cpp @@ -63,54 +63,54 @@ DEFINE_DEVICE_TYPE(BBC_PALMO2, bbc_palmo2_device, "bbc_palmo2", "Instant Mini Of // bbc_palprom_device - constructor //------------------------------------------------- -bbc_pal_device::bbc_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_pal_device::bbc_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_rom_interface(mconfig, *this) , m_bank(0) { } -bbc_cciword_device::bbc_cciword_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_cciword_device::bbc_cciword_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pal_device(mconfig, BBC_CCIWORD, tag, owner, clock) { } -bbc_ccibase_device::bbc_ccibase_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_ccibase_device::bbc_ccibase_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pal_device(mconfig, BBC_CCIBASE, tag, owner, clock) { } -bbc_ccispell_device::bbc_ccispell_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_ccispell_device::bbc_ccispell_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pal_device(mconfig, BBC_CCISPELL, tag, owner, clock) { } -bbc_palqst_device::bbc_palqst_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_palqst_device::bbc_palqst_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pal_device(mconfig, BBC_PALQST, tag, owner, clock) { } -bbc_palwap_device::bbc_palwap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_palwap_device::bbc_palwap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pal_device(mconfig, BBC_PALWAP, tag, owner, clock) { } -bbc_palted_device::bbc_palted_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_palted_device::bbc_palted_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pal_device(mconfig, BBC_PALTED, tag, owner, clock) { } -bbc_palabep_device::bbc_palabep_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_palabep_device::bbc_palabep_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pal_device(mconfig, BBC_PALABEP, tag, owner, clock) { } -bbc_palabe_device::bbc_palabe_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_palabe_device::bbc_palabe_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pal_device(mconfig, BBC_PALABE, tag, owner, clock) { } -bbc_palmo2_device::bbc_palmo2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_palmo2_device::bbc_palmo2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pal_device(mconfig, BBC_PALMO2, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/rom/pal.h b/src/devices/bus/bbc/rom/pal.h index 31c8dcd0d78..5fda03fd656 100644 --- a/src/devices/bus/bbc/rom/pal.h +++ b/src/devices/bus/bbc/rom/pal.h @@ -25,7 +25,7 @@ class bbc_pal_device : public device_t, { protected: // construction/destruction - bbc_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -42,7 +42,7 @@ class bbc_cciword_device : public bbc_pal_device { public: // construction/destruction - bbc_cciword_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_cciword_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_bbc_rom_interface overrides @@ -55,7 +55,7 @@ class bbc_ccibase_device : public bbc_pal_device { public: // construction/destruction - bbc_ccibase_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_ccibase_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_bbc_rom_interface overrides @@ -68,7 +68,7 @@ class bbc_ccispell_device : public bbc_pal_device { public: // construction/destruction - bbc_ccispell_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_ccispell_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_bbc_rom_interface overrides @@ -80,7 +80,7 @@ protected: class bbc_palqst_device : public bbc_pal_device { public: - bbc_palqst_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_palqst_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_bbc_rom_interface overrides @@ -92,7 +92,7 @@ protected: class bbc_palwap_device : public bbc_pal_device { public: - bbc_palwap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_palwap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_bbc_rom_interface overrides @@ -105,7 +105,7 @@ class bbc_palted_device : public bbc_pal_device { public: // construction/destruction - bbc_palted_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_palted_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_bbc_rom_interface overrides @@ -118,7 +118,7 @@ class bbc_palabep_device : public bbc_pal_device { public: // construction/destruction - bbc_palabep_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_palabep_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_bbc_rom_interface overrides @@ -131,7 +131,7 @@ class bbc_palabe_device : public bbc_pal_device { public: // construction/destruction - bbc_palabe_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_palabe_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_bbc_rom_interface overrides @@ -144,7 +144,7 @@ class bbc_palmo2_device : public bbc_pal_device { public: // construction/destruction - bbc_palmo2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_palmo2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_bbc_rom_interface overrides diff --git a/src/devices/bus/bbc/rom/ram.cpp b/src/devices/bus/bbc/rom/ram.cpp index bbe5d956006..d3cb0cea3b8 100644 --- a/src/devices/bus/bbc/rom/ram.cpp +++ b/src/devices/bus/bbc/rom/ram.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(BBC_RAM, bbc_ram_device, "bbc_ram", "BBC Micro Sideways RAM") // bbc_ram_device - constructor //------------------------------------------------- -bbc_ram_device::bbc_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_ram_device::bbc_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_RAM, tag, owner, clock) , device_bbc_rom_interface(mconfig, *this) { diff --git a/src/devices/bus/bbc/rom/ram.h b/src/devices/bus/bbc/rom/ram.h index 85267147a35..adb538fce2e 100644 --- a/src/devices/bus/bbc/rom/ram.h +++ b/src/devices/bus/bbc/rom/ram.h @@ -24,7 +24,7 @@ class bbc_ram_device : public device_t, { public: // construction/destruction - bbc_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/rom/rom.cpp b/src/devices/bus/bbc/rom/rom.cpp index f419998510b..09df9d47ba1 100644 --- a/src/devices/bus/bbc/rom/rom.cpp +++ b/src/devices/bus/bbc/rom/rom.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(BBC_ROM, bbc_rom_device, "bbc_rom", "BBC Micro Sideways ROM") // bbc_rom_device - constructor //------------------------------------------------- -bbc_rom_device::bbc_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_rom_device::bbc_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_ROM, tag, owner, clock) , device_bbc_rom_interface(mconfig, *this) { diff --git a/src/devices/bus/bbc/rom/rom.h b/src/devices/bus/bbc/rom/rom.h index 282e5471781..4405d3d313f 100644 --- a/src/devices/bus/bbc/rom/rom.h +++ b/src/devices/bus/bbc/rom/rom.h @@ -24,7 +24,7 @@ class bbc_rom_device : public device_t, { public: // construction/destruction - bbc_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/rom/rtc.cpp b/src/devices/bus/bbc/rom/rtc.cpp index 7d73c24b53e..14f58489a3c 100644 --- a/src/devices/bus/bbc/rom/rtc.cpp +++ b/src/devices/bus/bbc/rom/rtc.cpp @@ -34,7 +34,7 @@ void bbc_stlrtc_device::device_add_mconfig(machine_config &config) void bbc_pmsrtc_device::device_add_mconfig(machine_config &config) { /* Dallas DS1216 SmartWatch RAM */ - DS1315(config, m_rtc, 0); + DS1315(config, m_rtc); } //************************************************************************** @@ -45,14 +45,14 @@ void bbc_pmsrtc_device::device_add_mconfig(machine_config &config) // bbc_stlrtc_device - constructor //------------------------------------------------- -bbc_stlrtc_device::bbc_stlrtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_stlrtc_device::bbc_stlrtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_STLRTC, tag, owner, clock) , device_bbc_rom_interface(mconfig, *this) , m_rtc(*this, "rtc") { } -bbc_pmsrtc_device::bbc_pmsrtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_pmsrtc_device::bbc_pmsrtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_PMSRTC, tag, owner, clock) , device_bbc_rom_interface(mconfig, *this) , m_rtc(*this, "rtc") diff --git a/src/devices/bus/bbc/rom/rtc.h b/src/devices/bus/bbc/rom/rtc.h index d37b2174b9b..0cdb9819352 100644 --- a/src/devices/bus/bbc/rom/rtc.h +++ b/src/devices/bus/bbc/rom/rtc.h @@ -28,7 +28,7 @@ class bbc_stlrtc_device : public device_t, { public: // construction/destruction - bbc_stlrtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_stlrtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -50,7 +50,7 @@ class bbc_pmsrtc_device : public device_t, { public: // construction/destruction - bbc_pmsrtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_pmsrtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/rom/slot.cpp b/src/devices/bus/bbc/rom/slot.cpp index b7ea541bbc2..b015306c86a 100644 --- a/src/devices/bus/bbc/rom/slot.cpp +++ b/src/devices/bus/bbc/rom/slot.cpp @@ -82,7 +82,7 @@ void device_bbc_rom_interface::nvram_alloc(uint32_t size) //------------------------------------------------- // bbc_romslot_device - constructor //------------------------------------------------- -bbc_romslot_device::bbc_romslot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_romslot_device::bbc_romslot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_rom_image_interface(mconfig, *this) , device_single_card_slot_interface<device_bbc_rom_interface>(mconfig, *this) @@ -90,12 +90,12 @@ bbc_romslot_device::bbc_romslot_device(const machine_config &mconfig, device_typ { } -bbc_romslot16_device::bbc_romslot16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_romslot16_device::bbc_romslot16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_romslot_device(mconfig, BBC_ROMSLOT16, tag, owner, clock) { } -bbc_romslot32_device::bbc_romslot32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_romslot32_device::bbc_romslot32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_romslot_device(mconfig, BBC_ROMSLOT32, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/rom/slot.h b/src/devices/bus/bbc/rom/slot.h index 986d796dd0d..c0d6b87b831 100644 --- a/src/devices/bus/bbc/rom/slot.h +++ b/src/devices/bus/bbc/rom/slot.h @@ -53,7 +53,7 @@ public: protected: // construction/destruction - bbc_romslot_device(const machine_config &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock); + bbc_romslot_device(const machine_config &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -81,7 +81,7 @@ public: m_slot_size = 0x4000; } - bbc_romslot16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + bbc_romslot16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // ======================> bbc_romslot32_device @@ -101,7 +101,7 @@ public: m_slot_size = 0x8000; } - bbc_romslot32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + bbc_romslot32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; diff --git a/src/devices/bus/bbc/tube/tube.cpp b/src/devices/bus/bbc/tube/tube.cpp index 505b7a25030..0b833e38651 100644 --- a/src/devices/bus/bbc/tube/tube.cpp +++ b/src/devices/bus/bbc/tube/tube.cpp @@ -42,7 +42,7 @@ device_bbc_tube_interface::device_bbc_tube_interface(const machine_config &mconf // bbc_tube_slot_device - constructor //------------------------------------------------- -bbc_tube_slot_device::bbc_tube_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bbc_tube_slot_device::bbc_tube_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_TUBE_SLOT, tag, owner, clock), device_single_card_slot_interface<device_bbc_tube_interface>(mconfig, *this), m_card(nullptr), diff --git a/src/devices/bus/bbc/tube/tube.h b/src/devices/bus/bbc/tube/tube.h index 97c18ab0d34..400292366ae 100644 --- a/src/devices/bus/bbc/tube/tube.h +++ b/src/devices/bus/bbc/tube/tube.h @@ -62,7 +62,7 @@ public: set_insert_rom(true); } - bbc_tube_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + bbc_tube_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); void set_insert_rom(bool insert_rom) { m_insert_rom = insert_rom; } bool insert_rom() { return m_insert_rom; } diff --git a/src/devices/bus/bbc/tube/tube_32016.cpp b/src/devices/bus/bbc/tube/tube_32016.cpp index e62e3003998..781f84e55cd 100644 --- a/src/devices/bus/bbc/tube/tube_32016.cpp +++ b/src/devices/bus/bbc/tube/tube_32016.cpp @@ -199,7 +199,7 @@ ioport_constructor bbc_tube_32016_device::device_input_ports() const // bbc_tube_32016_device - constructor //------------------------------------------------- -bbc_tube_32016_device::bbc_tube_32016_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_32016_device::bbc_tube_32016_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -210,17 +210,17 @@ bbc_tube_32016_device::bbc_tube_32016_device(const machine_config &mconfig, devi { } -bbc_tube_32016_device::bbc_tube_32016_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_32016_device::bbc_tube_32016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_32016_device(mconfig, BBC_TUBE_32016, tag, owner, clock) { } -bbc_tube_16032_device::bbc_tube_16032_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_16032_device::bbc_tube_16032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_32016_device(mconfig, BBC_TUBE_16032, tag, owner, clock) { } -bbc_tube_32016l_device::bbc_tube_32016l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_32016l_device::bbc_tube_32016l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_32016_device(mconfig, BBC_TUBE_32016L, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/tube/tube_32016.h b/src/devices/bus/bbc/tube/tube_32016.h index 242b4eb773b..318f72c9d09 100644 --- a/src/devices/bus/bbc/tube/tube_32016.h +++ b/src/devices/bus/bbc/tube/tube_32016.h @@ -34,10 +34,10 @@ class bbc_tube_32016_device : { public: // construction/destruction - bbc_tube_32016_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_32016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_tube_32016_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_32016_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -68,7 +68,7 @@ protected: class bbc_tube_16032_device : public bbc_tube_32016_device { public: - bbc_tube_16032_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_16032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -80,7 +80,7 @@ protected: class bbc_tube_32016l_device : public bbc_tube_32016_device { public: - bbc_tube_32016l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_32016l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/bbc/tube/tube_6502.cpp b/src/devices/bus/bbc/tube/tube_6502.cpp index e7cc3157c90..b680b1eff41 100644 --- a/src/devices/bus/bbc/tube/tube_6502.cpp +++ b/src/devices/bus/bbc/tube/tube_6502.cpp @@ -200,7 +200,7 @@ const tiny_rom_entry *bbc_tube_65c102_device::device_rom_region() const // bbc_tube_6502_device - constructor //------------------------------------------------- -bbc_tube_6502_device::bbc_tube_6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_6502_device::bbc_tube_6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -211,17 +211,17 @@ bbc_tube_6502_device::bbc_tube_6502_device(const machine_config &mconfig, device { } -bbc_tube_6502_device::bbc_tube_6502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_6502_device::bbc_tube_6502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_6502_device(mconfig, BBC_TUBE_6502, tag, owner, clock) { } -bbc_tube_6502p_device::bbc_tube_6502p_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_6502p_device::bbc_tube_6502p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_6502_device(mconfig, BBC_TUBE_6502P, tag, owner, clock) { } -bbc_tube_6502e_device::bbc_tube_6502e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_6502e_device::bbc_tube_6502e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_6502_device(mconfig, BBC_TUBE_6502E, tag, owner, clock) , m_opcode_ind_y(false) , m_page(0) @@ -229,7 +229,7 @@ bbc_tube_6502e_device::bbc_tube_6502e_device(const machine_config &mconfig, cons { } -bbc_tube_65c102_device::bbc_tube_65c102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_65c102_device::bbc_tube_65c102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_6502_device(mconfig, BBC_TUBE_65C102, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/tube/tube_6502.h b/src/devices/bus/bbc/tube/tube_6502.h index a68e9c3f51e..b34aa903e8b 100644 --- a/src/devices/bus/bbc/tube/tube_6502.h +++ b/src/devices/bus/bbc/tube/tube_6502.h @@ -33,10 +33,10 @@ class bbc_tube_6502_device { public: // construction/destruction - bbc_tube_6502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_6502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_tube_6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -67,7 +67,7 @@ protected: class bbc_tube_6502p_device : public bbc_tube_6502_device { public: - bbc_tube_6502p_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_6502p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -82,7 +82,7 @@ private: class bbc_tube_6502e_device : public bbc_tube_6502_device { public: - bbc_tube_6502e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_6502e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -107,7 +107,7 @@ private: class bbc_tube_65c102_device : public bbc_tube_6502_device { public: - bbc_tube_65c102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_65c102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/bbc/tube/tube_80186.cpp b/src/devices/bus/bbc/tube/tube_80186.cpp index 07456c67a38..4b657a60b86 100644 --- a/src/devices/bus/bbc/tube/tube_80186.cpp +++ b/src/devices/bus/bbc/tube/tube_80186.cpp @@ -72,7 +72,7 @@ void bbc_tube_80186_device::device_add_mconfig(machine_config &config) m_i80186->tmrout0_handler().set_inputline(m_i80186, INPUT_LINE_HALT).invert(); m_i80186->tmrout1_handler().set_inputline(m_i80186, INPUT_LINE_NMI).invert(); - TUBE(config, m_ula, 0); + TUBE(config, m_ula); m_ula->pirq_handler().set(m_i80186, FUNC(i80186_cpu_device::int0_w)); m_ula->drq_handler().set(m_i80186, FUNC(i80186_cpu_device::drq0_w)); m_ula->prst_handler().set(FUNC(bbc_tube_80186_device::prst_w)); @@ -115,7 +115,7 @@ const tiny_rom_entry *bbc_tube_pcplus_device::device_rom_region() const // bbc_tube_80186_device - constructor //------------------------------------------------- -bbc_tube_80186_device::bbc_tube_80186_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_80186_device::bbc_tube_80186_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_i80186(*this, "i80186") @@ -125,12 +125,12 @@ bbc_tube_80186_device::bbc_tube_80186_device(const machine_config &mconfig, devi { } -bbc_tube_80186_device::bbc_tube_80186_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_80186_device::bbc_tube_80186_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_80186_device(mconfig, BBC_TUBE_80186, tag, owner, clock) { } -bbc_tube_pcplus_device::bbc_tube_pcplus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_pcplus_device::bbc_tube_pcplus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_80186_device(mconfig, BBC_TUBE_PCPLUS, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/tube/tube_80186.h b/src/devices/bus/bbc/tube/tube_80186.h index 448ef06cc7f..f7903ee2810 100644 --- a/src/devices/bus/bbc/tube/tube_80186.h +++ b/src/devices/bus/bbc/tube/tube_80186.h @@ -29,10 +29,10 @@ class bbc_tube_80186_device : { public: // construction/destruction - bbc_tube_80186_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_80186_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_tube_80186_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_80186_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -60,7 +60,7 @@ protected: class bbc_tube_pcplus_device : public bbc_tube_80186_device { public: - bbc_tube_pcplus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_pcplus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/tube/tube_80286.cpp b/src/devices/bus/bbc/tube/tube_80286.cpp index ffdfc0edb6f..863990a6bdb 100644 --- a/src/devices/bus/bbc/tube/tube_80286.cpp +++ b/src/devices/bus/bbc/tube/tube_80286.cpp @@ -94,7 +94,7 @@ const tiny_rom_entry *bbc_tube_80286_device::device_rom_region() const // bbc_tube_80286_device - constructor //------------------------------------------------- -bbc_tube_80286_device::bbc_tube_80286_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_80286_device::bbc_tube_80286_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_TUBE_80286, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_i80286(*this, "i80286") diff --git a/src/devices/bus/bbc/tube/tube_80286.h b/src/devices/bus/bbc/tube/tube_80286.h index 6ac75975fa7..eefef58de50 100644 --- a/src/devices/bus/bbc/tube/tube_80286.h +++ b/src/devices/bus/bbc/tube/tube_80286.h @@ -27,7 +27,7 @@ class bbc_tube_80286_device : { public: // construction/destruction - bbc_tube_80286_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_80286_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/tube/tube_a500.cpp b/src/devices/bus/bbc/tube/tube_a500.cpp index f9406f2d2f0..f2653db1099 100644 --- a/src/devices/bus/bbc/tube/tube_a500.cpp +++ b/src/devices/bus/bbc/tube/tube_a500.cpp @@ -114,7 +114,7 @@ const tiny_rom_entry *bbc_tube_a500_device::device_rom_region() const // bbc_tube_a500_device - constructor //------------------------------------------------- -bbc_tube_a500_device::bbc_tube_a500_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_a500_device::bbc_tube_a500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_TUBE_A500, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_maincpu(*this, "maincpu") diff --git a/src/devices/bus/bbc/tube/tube_a500.h b/src/devices/bus/bbc/tube/tube_a500.h index 31af8f227f1..f5f6af9658f 100644 --- a/src/devices/bus/bbc/tube/tube_a500.h +++ b/src/devices/bus/bbc/tube/tube_a500.h @@ -36,7 +36,7 @@ class bbc_tube_a500_device : { public: // construction/destruction - bbc_tube_a500_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_a500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/tube/tube_arm.cpp b/src/devices/bus/bbc/tube/tube_arm.cpp index c015871ffa5..dfc2c3f8760 100644 --- a/src/devices/bus/bbc/tube/tube_arm.cpp +++ b/src/devices/bus/bbc/tube/tube_arm.cpp @@ -85,7 +85,7 @@ const tiny_rom_entry *bbc_tube_arm_device::device_rom_region() const // bbc_tube_arm_device - constructor //------------------------------------------------- -bbc_tube_arm_device::bbc_tube_arm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_arm_device::bbc_tube_arm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_TUBE_ARM, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_maincpu(*this, "maincpu") diff --git a/src/devices/bus/bbc/tube/tube_arm.h b/src/devices/bus/bbc/tube/tube_arm.h index c84ddc97748..125228b5f03 100644 --- a/src/devices/bus/bbc/tube/tube_arm.h +++ b/src/devices/bus/bbc/tube/tube_arm.h @@ -27,7 +27,7 @@ class bbc_tube_arm_device : { public: // construction/destruction - bbc_tube_arm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_arm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/tube/tube_arm7.cpp b/src/devices/bus/bbc/tube/tube_arm7.cpp index e79b83ad997..f4ce41f2f05 100644 --- a/src/devices/bus/bbc/tube/tube_arm7.cpp +++ b/src/devices/bus/bbc/tube/tube_arm7.cpp @@ -87,7 +87,7 @@ const tiny_rom_entry *bbc_tube_arm7_device::device_rom_region() const // bbc_tube_arm7_device - constructor //------------------------------------------------- -bbc_tube_arm7_device::bbc_tube_arm7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_arm7_device::bbc_tube_arm7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_TUBE_ARM7, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_maincpu(*this, "maincpu") diff --git a/src/devices/bus/bbc/tube/tube_arm7.h b/src/devices/bus/bbc/tube/tube_arm7.h index e203c26388a..cd903e39598 100644 --- a/src/devices/bus/bbc/tube/tube_arm7.h +++ b/src/devices/bus/bbc/tube/tube_arm7.h @@ -44,7 +44,7 @@ class bbc_tube_arm7_device : public: // construction/destruction - bbc_tube_arm7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_arm7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/tube/tube_casper.cpp b/src/devices/bus/bbc/tube/tube_casper.cpp index ea2734159f9..b035b3e6f26 100644 --- a/src/devices/bus/bbc/tube/tube_casper.cpp +++ b/src/devices/bus/bbc/tube/tube_casper.cpp @@ -85,7 +85,7 @@ const tiny_rom_entry *bbc_tube_casper_device::device_rom_region() const // bbc_tube_casper_device - constructor //------------------------------------------------- -bbc_tube_casper_device::bbc_tube_casper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_casper_device::bbc_tube_casper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_TUBE_CASPER, tag, owner, clock), device_bbc_tube_interface(mconfig, *this), m_m68000(*this, "m68000"), diff --git a/src/devices/bus/bbc/tube/tube_casper.h b/src/devices/bus/bbc/tube/tube_casper.h index 5f4187c80a7..b9760d3b6c3 100644 --- a/src/devices/bus/bbc/tube/tube_casper.h +++ b/src/devices/bus/bbc/tube/tube_casper.h @@ -26,7 +26,7 @@ class bbc_tube_casper_device : { public: // construction/destruction - bbc_tube_casper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_casper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/tube/tube_cms6809.cpp b/src/devices/bus/bbc/tube/tube_cms6809.cpp index 43c86628f2a..c2d8a220da7 100644 --- a/src/devices/bus/bbc/tube/tube_cms6809.cpp +++ b/src/devices/bus/bbc/tube/tube_cms6809.cpp @@ -89,7 +89,7 @@ const tiny_rom_entry *bbc_tube_cms6809_device::device_rom_region() const // bbc_tube_cms6809_device - constructor //------------------------------------------------- -bbc_tube_cms6809_device::bbc_tube_cms6809_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_cms6809_device::bbc_tube_cms6809_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_TUBE_CMS6809, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_maincpu(*this, "maincpu") diff --git a/src/devices/bus/bbc/tube/tube_cms6809.h b/src/devices/bus/bbc/tube/tube_cms6809.h index 79336974246..0fac81f17ea 100644 --- a/src/devices/bus/bbc/tube/tube_cms6809.h +++ b/src/devices/bus/bbc/tube/tube_cms6809.h @@ -26,7 +26,7 @@ class bbc_tube_cms6809_device : { public: // construction/destruction - bbc_tube_cms6809_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_cms6809_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/tube/tube_rc6502.cpp b/src/devices/bus/bbc/tube/tube_rc6502.cpp index 7aeeee283a2..550755e72d3 100644 --- a/src/devices/bus/bbc/tube/tube_rc6502.cpp +++ b/src/devices/bus/bbc/tube/tube_rc6502.cpp @@ -175,7 +175,7 @@ const tiny_rom_entry *bbc_tube_rc65816_device::device_rom_region() const // bbc_tube_rc6502_device - constructor //------------------------------------------------- -bbc_tube_rc6502_device::bbc_tube_rc6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_rc6502_device::bbc_tube_rc6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -188,12 +188,12 @@ bbc_tube_rc6502_device::bbc_tube_rc6502_device(const machine_config &mconfig, de { } -bbc_tube_rc6502_device::bbc_tube_rc6502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_rc6502_device::bbc_tube_rc6502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_rc6502_device(mconfig, BBC_TUBE_RC6502, tag, owner, clock) { } -bbc_tube_rc65816_device::bbc_tube_rc65816_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_rc65816_device::bbc_tube_rc65816_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_rc6502_device(mconfig, BBC_TUBE_RC65816, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/tube/tube_rc6502.h b/src/devices/bus/bbc/tube/tube_rc6502.h index cc1e12d71c8..9e0e926d507 100644 --- a/src/devices/bus/bbc/tube/tube_rc6502.h +++ b/src/devices/bus/bbc/tube/tube_rc6502.h @@ -31,10 +31,10 @@ class bbc_tube_rc6502_device : { public: // construction/destruction - bbc_tube_rc6502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_rc6502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_tube_rc6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_rc6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -78,7 +78,7 @@ private: class bbc_tube_rc65816_device : public bbc_tube_rc6502_device { public: - bbc_tube_rc65816_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_rc65816_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/bbc/tube/tube_x25.cpp b/src/devices/bus/bbc/tube/tube_x25.cpp index 21e03217201..d68273edc06 100644 --- a/src/devices/bus/bbc/tube/tube_x25.cpp +++ b/src/devices/bus/bbc/tube/tube_x25.cpp @@ -135,7 +135,7 @@ const tiny_rom_entry *bbc_tube_x25_device::device_rom_region() const // bbc_tube_x25_device - constructor //------------------------------------------------- -bbc_tube_x25_device::bbc_tube_x25_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_x25_device::bbc_tube_x25_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_TUBE_X25, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_z80(*this, "z80_%u", 0) diff --git a/src/devices/bus/bbc/tube/tube_x25.h b/src/devices/bus/bbc/tube/tube_x25.h index 6e63c45bfa5..72bfd360ca5 100644 --- a/src/devices/bus/bbc/tube/tube_x25.h +++ b/src/devices/bus/bbc/tube/tube_x25.h @@ -30,7 +30,7 @@ class bbc_tube_x25_device : { public: // construction/destruction - bbc_tube_x25_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_x25_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::LAN; } diff --git a/src/devices/bus/bbc/tube/tube_z80.cpp b/src/devices/bus/bbc/tube/tube_z80.cpp index f273c2f37d4..0868335657f 100644 --- a/src/devices/bus/bbc/tube/tube_z80.cpp +++ b/src/devices/bus/bbc/tube/tube_z80.cpp @@ -108,7 +108,7 @@ const tiny_rom_entry *bbc_tube_z80w_device::device_rom_region() const // bbc_tube_z80_device - constructor //------------------------------------------------- -bbc_tube_z80_device::bbc_tube_z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_z80_device::bbc_tube_z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_z80(*this, "z80") @@ -118,12 +118,12 @@ bbc_tube_z80_device::bbc_tube_z80_device(const machine_config &mconfig, device_t { } -bbc_tube_z80_device::bbc_tube_z80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_z80_device::bbc_tube_z80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_z80_device(mconfig, BBC_TUBE_Z80, tag, owner, clock) { } -bbc_tube_z80w_device::bbc_tube_z80w_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_z80w_device::bbc_tube_z80w_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_z80_device(mconfig, BBC_TUBE_Z80W, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/tube/tube_z80.h b/src/devices/bus/bbc/tube/tube_z80.h index e878f61627d..ac8050ccd5c 100644 --- a/src/devices/bus/bbc/tube/tube_z80.h +++ b/src/devices/bus/bbc/tube/tube_z80.h @@ -28,10 +28,10 @@ class bbc_tube_z80_device : { public: // construction/destruction - bbc_tube_z80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_z80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_tube_z80_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock); + bbc_tube_z80_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -70,7 +70,7 @@ private: class bbc_tube_z80w_device : public bbc_tube_z80_device { public: - bbc_tube_z80w_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + bbc_tube_z80w_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/bbc/tube/tube_zep100.cpp b/src/devices/bus/bbc/tube/tube_zep100.cpp index 0d5b0d18948..7a066ed56a6 100644 --- a/src/devices/bus/bbc/tube/tube_zep100.cpp +++ b/src/devices/bus/bbc/tube/tube_zep100.cpp @@ -111,7 +111,7 @@ void bbc_tube_zep100_device::device_add_mconfig(machine_config &config) m_via->ca2_handler().set(m_ppi, FUNC(i8255_device::pc6_w)); m_via->irq_handler().set(DEVICE_SELF_OWNER, FUNC(bbc_tube_slot_device::irq_w)); - I8255A(config, m_ppi, 0); + I8255A(config, m_ppi); m_ppi->out_pa_callback().set(m_via, FUNC(via6522_device::write_pa)); m_ppi->in_pb_callback().set(FUNC(bbc_tube_zep100_device::ppi_pb_r)); m_ppi->out_pc_callback().set(FUNC(bbc_tube_zep100_device::ppi_pc_w)); @@ -152,7 +152,7 @@ const tiny_rom_entry *bbc_tube_zep100m_device::device_rom_region() const // bbc_tube_zep100_device - constructor //------------------------------------------------- -bbc_tube_zep100_device::bbc_tube_zep100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_zep100_device::bbc_tube_zep100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_tube_interface(mconfig, *this) , m_rom_enabled(true) @@ -164,22 +164,22 @@ bbc_tube_zep100_device::bbc_tube_zep100_device(const machine_config &mconfig, de { } -bbc_tube_zep100_device::bbc_tube_zep100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_zep100_device::bbc_tube_zep100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_zep100_device(mconfig, BBC_TUBE_ZEP100, tag, owner, clock) { } -bbc_tube_zep100l_device::bbc_tube_zep100l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_zep100l_device::bbc_tube_zep100l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_zep100_device(mconfig, BBC_TUBE_ZEP100L, tag, owner, clock) { } -bbc_tube_zep100w_device::bbc_tube_zep100w_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_zep100w_device::bbc_tube_zep100w_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_zep100_device(mconfig, BBC_TUBE_ZEP100W, tag, owner, clock) { } -bbc_tube_zep100m_device::bbc_tube_zep100m_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tube_zep100m_device::bbc_tube_zep100m_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_tube_zep100_device(mconfig, BBC_TUBE_ZEP100M, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/tube/tube_zep100.h b/src/devices/bus/bbc/tube/tube_zep100.h index a4f0dd58d92..1c5a292c551 100644 --- a/src/devices/bus/bbc/tube/tube_zep100.h +++ b/src/devices/bus/bbc/tube/tube_zep100.h @@ -29,10 +29,10 @@ class bbc_tube_zep100_device : { public: // construction/destruction - bbc_tube_zep100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_zep100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_tube_zep100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_zep100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -73,7 +73,7 @@ private: class bbc_tube_zep100l_device : public bbc_tube_zep100_device { public: - bbc_tube_zep100l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_zep100l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -82,7 +82,7 @@ protected: class bbc_tube_zep100w_device : public bbc_tube_zep100_device { public: - bbc_tube_zep100w_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_zep100w_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -91,7 +91,7 @@ protected: class bbc_tube_zep100m_device : public bbc_tube_zep100_device { public: - bbc_tube_zep100m_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tube_zep100m_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/bbc/userport/beebspch.cpp b/src/devices/bus/bbc/userport/beebspch.cpp index 728d8ae6658..666802ea546 100644 --- a/src/devices/bus/bbc/userport/beebspch.cpp +++ b/src/devices/bus/bbc/userport/beebspch.cpp @@ -47,7 +47,7 @@ const tiny_rom_entry *bbc_beebspch_device::device_rom_region() const void bbc_beebspch_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "mono").front_center(); - SP0256(config, m_nsp, 3120000); // TODO: generated by a LS269 + SP0256(config, m_nsp, XTAL::u(3120000)); // TODO: generated by a LS269 m_nsp->data_request_callback().set(FUNC(bbc_beebspch_device::cb1_w)); m_nsp->standby_callback().set(FUNC(bbc_beebspch_device::cb2_w)); m_nsp->add_route(ALL_OUTPUTS, "mono", 1.0); @@ -62,7 +62,7 @@ void bbc_beebspch_device::device_add_mconfig(machine_config &config) // bbc_beebspch_device - constructor //------------------------------------------------- -bbc_beebspch_device::bbc_beebspch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_beebspch_device::bbc_beebspch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_BEEBSPCH, tag, owner, clock) , device_bbc_userport_interface(mconfig, *this) , m_nsp(*this, "sp0256") @@ -88,11 +88,11 @@ void bbc_beebspch_device::pb_w(uint8_t data) { case 0x40: // intonation high - m_nsp->set_clock(3800000); // TODO: the exact frequency is unknown + m_nsp->set_clock(XTAL::u(3800000)); // TODO: the exact frequency is unknown break; case 0x80: // intonation low - m_nsp->set_clock(3500000); // CK / 4 ?? + m_nsp->set_clock(XTAL::u(3500000)); // CK / 4 ?? break; } diff --git a/src/devices/bus/bbc/userport/beebspch.h b/src/devices/bus/bbc/userport/beebspch.h index 79e6abf64ab..67a5bbb82bf 100644 --- a/src/devices/bus/bbc/userport/beebspch.h +++ b/src/devices/bus/bbc/userport/beebspch.h @@ -25,7 +25,7 @@ class bbc_beebspch_device : { public: // construction/destruction - bbc_beebspch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_beebspch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(cb1_w); DECLARE_WRITE_LINE_MEMBER(cb2_w); diff --git a/src/devices/bus/bbc/userport/cfa3000kbd.cpp b/src/devices/bus/bbc/userport/cfa3000kbd.cpp index 5b2d5586f56..36420596a12 100644 --- a/src/devices/bus/bbc/userport/cfa3000kbd.cpp +++ b/src/devices/bus/bbc/userport/cfa3000kbd.cpp @@ -83,7 +83,7 @@ ioport_constructor cfa3000_kbd_device::device_input_ports() const // cfa3000_kbd_device - constructor //------------------------------------------------- -cfa3000_kbd_device::cfa3000_kbd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cfa3000_kbd_device::cfa3000_kbd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CFA3000_KBD, tag, owner, clock), device_bbc_userport_interface(mconfig, *this), m_kbd(*this, "KBD.%u", 0) diff --git a/src/devices/bus/bbc/userport/cfa3000kbd.h b/src/devices/bus/bbc/userport/cfa3000kbd.h index ff9951399c8..7b4d66372ea 100644 --- a/src/devices/bus/bbc/userport/cfa3000kbd.h +++ b/src/devices/bus/bbc/userport/cfa3000kbd.h @@ -26,7 +26,7 @@ class cfa3000_kbd_device : { public: // construction/destruction - cfa3000_kbd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cfa3000_kbd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/userport/lcd.cpp b/src/devices/bus/bbc/userport/lcd.cpp index f5f92270ca9..b693b28957e 100644 --- a/src/devices/bus/bbc/userport/lcd.cpp +++ b/src/devices/bus/bbc/userport/lcd.cpp @@ -51,7 +51,7 @@ void bbc_lcd_device::device_add_mconfig(machine_config &config) // bbc_lcd_device - constructor //------------------------------------------------- -bbc_lcd_device::bbc_lcd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_lcd_device::bbc_lcd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_LCD, tag, owner, clock) , device_bbc_userport_interface(mconfig, *this) , m_lcdc(*this, "lcdc") diff --git a/src/devices/bus/bbc/userport/lcd.h b/src/devices/bus/bbc/userport/lcd.h index c4aecfbd00e..99d0fad96e6 100644 --- a/src/devices/bus/bbc/userport/lcd.h +++ b/src/devices/bus/bbc/userport/lcd.h @@ -28,7 +28,7 @@ class bbc_lcd_device : { public: // construction/destruction - bbc_lcd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_lcd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/userport/m4000.cpp b/src/devices/bus/bbc/userport/m4000.cpp index 910f2f8b3f1..e374b727c46 100644 --- a/src/devices/bus/bbc/userport/m4000.cpp +++ b/src/devices/bus/bbc/userport/m4000.cpp @@ -113,7 +113,7 @@ ioport_constructor bbc_m4000_device::device_input_ports() const // bbc_m4000_device - constructor //------------------------------------------------- -bbc_m4000_device::bbc_m4000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_m4000_device::bbc_m4000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_M4000, tag, owner, clock) , device_bbc_userport_interface(mconfig, *this) , m_kbd(*this, "KBLOCK_%u", 1) diff --git a/src/devices/bus/bbc/userport/m4000.h b/src/devices/bus/bbc/userport/m4000.h index df9c5e556cf..a04adb626a0 100644 --- a/src/devices/bus/bbc/userport/m4000.h +++ b/src/devices/bus/bbc/userport/m4000.h @@ -29,7 +29,7 @@ class bbc_m4000_device : { public: // construction/destruction - bbc_m4000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_m4000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/userport/palext.cpp b/src/devices/bus/bbc/userport/palext.cpp index dab527e478b..d44d5a8cfaa 100644 --- a/src/devices/bus/bbc/userport/palext.cpp +++ b/src/devices/bus/bbc/userport/palext.cpp @@ -51,7 +51,7 @@ const tiny_rom_entry* bbc_chameleon_device::device_rom_region() const // bbc_palext_device - constructor //------------------------------------------------- -bbc_palext_device::bbc_palext_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_palext_device::bbc_palext_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_userport_interface(mconfig, *this) , m_palette(*this, ":palette") @@ -59,12 +59,12 @@ bbc_palext_device::bbc_palext_device(const machine_config &mconfig, device_type { } -bbc_chameleon_device::bbc_chameleon_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_chameleon_device::bbc_chameleon_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_palext_device(mconfig, BBC_CHAMELEON, tag, owner, clock) { } -bbc_cpalette_device::bbc_cpalette_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_cpalette_device::bbc_cpalette_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_palext_device(mconfig, BBC_CPALETTE, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/userport/palext.h b/src/devices/bus/bbc/userport/palext.h index bca159103cb..6caa44793ca 100644 --- a/src/devices/bus/bbc/userport/palext.h +++ b/src/devices/bus/bbc/userport/palext.h @@ -27,7 +27,7 @@ class bbc_palext_device : { protected: // construction/destruction - bbc_palext_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_palext_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -45,7 +45,7 @@ class bbc_chameleon_device : public bbc_palext_device { public: // construction/destruction - bbc_chameleon_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_chameleon_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -63,7 +63,7 @@ public: static constexpr feature_type imperfect_features() { return feature::PALETTE; } // construction/destruction - bbc_cpalette_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_cpalette_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void pb_w(uint8_t data) override; diff --git a/src/devices/bus/bbc/userport/pointer.cpp b/src/devices/bus/bbc/userport/pointer.cpp index cff7c1570e2..1ae9fbde8ad 100644 --- a/src/devices/bus/bbc/userport/pointer.cpp +++ b/src/devices/bus/bbc/userport/pointer.cpp @@ -120,7 +120,7 @@ ioport_constructor bbc_tracker_device::device_input_ports() const // bbc_pointer_device - constructor //------------------------------------------------- -bbc_pointer_device::bbc_pointer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_pointer_device::bbc_pointer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_userport_interface(mconfig, *this) , m_pointer_x(*this, "POINTER_X") @@ -129,17 +129,17 @@ bbc_pointer_device::bbc_pointer_device(const machine_config &mconfig, device_typ { } -bbc_amxmouse_device::bbc_amxmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_amxmouse_device::bbc_amxmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pointer_device(mconfig, BBC_AMXMOUSE, tag, owner, clock) { } -bbc_m512mouse_device::bbc_m512mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_m512mouse_device::bbc_m512mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pointer_device(mconfig, BBC_M512MOUSE, tag, owner, clock) { } -bbc_tracker_device::bbc_tracker_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_tracker_device::bbc_tracker_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_pointer_device(mconfig, BBC_TRACKER, tag, owner, clock) { } diff --git a/src/devices/bus/bbc/userport/pointer.h b/src/devices/bus/bbc/userport/pointer.h index 865a9c91270..d903afbe331 100644 --- a/src/devices/bus/bbc/userport/pointer.h +++ b/src/devices/bus/bbc/userport/pointer.h @@ -24,7 +24,7 @@ class bbc_pointer_device : { protected: // construction/destruction - bbc_pointer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_pointer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -53,7 +53,7 @@ class bbc_amxmouse_device : public bbc_pointer_device { public: // construction/destruction - bbc_amxmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_amxmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t pb_r() override; @@ -68,7 +68,7 @@ class bbc_m512mouse_device : public bbc_pointer_device { public: // construction/destruction - bbc_m512mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_m512mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t pb_r() override; @@ -83,7 +83,7 @@ class bbc_tracker_device : public bbc_pointer_device { public: // construction/destruction - bbc_tracker_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_tracker_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t pb_r() override; diff --git a/src/devices/bus/bbc/userport/sdcard.cpp b/src/devices/bus/bbc/userport/sdcard.cpp index ccd5337d840..c6509f56f65 100644 --- a/src/devices/bus/bbc/userport/sdcard.cpp +++ b/src/devices/bus/bbc/userport/sdcard.cpp @@ -57,13 +57,13 @@ DEFINE_DEVICE_TYPE(BBC_SDCARDT, bbc_sdcardt_device, "bbc_sdcardt", "BBC Micro Tu void bbc_sdcard_device::device_add_mconfig(machine_config &config) { - SPI_SDCARD(config, m_sdcard, 0); + SPI_SDCARD(config, m_sdcard); m_sdcard->spi_miso_callback().set([this](int state) { m_slot->cb2_w(state); }); } void bbc_sdcardt_device::device_add_mconfig(machine_config &config) { - SPI_SDCARD(config, m_sdcard, 0); + SPI_SDCARD(config, m_sdcard); m_sdcard->spi_miso_callback().set([this](int state) { if (!m_turbo) m_slot->cb2_w(state); }); } @@ -76,19 +76,19 @@ void bbc_sdcardt_device::device_add_mconfig(machine_config &config) // bbc_sdcard_device - constructor //------------------------------------------------- -bbc_sdcard_device::bbc_sdcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bbc_sdcard_device::bbc_sdcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_bbc_userport_interface(mconfig, *this) , m_sdcard(*this, "sdcard") { } -bbc_sdcard_device::bbc_sdcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_sdcard_device::bbc_sdcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_sdcard_device(mconfig, BBC_SDCARD, tag, owner, clock) { } -bbc_sdcardt_device::bbc_sdcardt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_sdcardt_device::bbc_sdcardt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbc_sdcard_device(mconfig, BBC_SDCARDT, tag, owner, clock) , m_turbo(false) { diff --git a/src/devices/bus/bbc/userport/sdcard.h b/src/devices/bus/bbc/userport/sdcard.h index bfa86ad359b..07e5756974d 100644 --- a/src/devices/bus/bbc/userport/sdcard.h +++ b/src/devices/bus/bbc/userport/sdcard.h @@ -25,10 +25,10 @@ class bbc_sdcard_device : public device_t, public device_bbc_userport_interface { public: // construction/destruction - bbc_sdcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_sdcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bbc_sdcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bbc_sdcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -49,7 +49,7 @@ class bbc_sdcardt_device : public bbc_sdcard_device { public: // construction/destruction - bbc_sdcardt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_sdcardt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bbc/userport/userport.cpp b/src/devices/bus/bbc/userport/userport.cpp index 6bf5476db9c..71cc4782fe9 100644 --- a/src/devices/bus/bbc/userport/userport.cpp +++ b/src/devices/bus/bbc/userport/userport.cpp @@ -51,7 +51,7 @@ device_bbc_userport_interface::~device_bbc_userport_interface() // bbc_userport_slot_device - constructor //------------------------------------------------- -bbc_userport_slot_device::bbc_userport_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_userport_slot_device::bbc_userport_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_USERPORT_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_bbc_userport_interface>(mconfig, *this) , m_device(nullptr) diff --git a/src/devices/bus/bbc/userport/userport.h b/src/devices/bus/bbc/userport/userport.h index 29374eb9058..6785a9c4832 100644 --- a/src/devices/bus/bbc/userport/userport.h +++ b/src/devices/bus/bbc/userport/userport.h @@ -55,7 +55,7 @@ public: set_fixed(false); } - bbc_userport_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + bbc_userport_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // callbacks auto cb1_handler() { return m_cb1_handler.bind(); } diff --git a/src/devices/bus/bbc/userport/usersplit.cpp b/src/devices/bus/bbc/userport/usersplit.cpp index 520abaebdb9..5f9f3ca5608 100644 --- a/src/devices/bus/bbc/userport/usersplit.cpp +++ b/src/devices/bus/bbc/userport/usersplit.cpp @@ -64,7 +64,7 @@ void bbc_usersplit_device::device_add_mconfig(machine_config &config) // bbc_usersplit_device - constructor //------------------------------------------------- -bbc_usersplit_device::bbc_usersplit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_usersplit_device::bbc_usersplit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_USERSPLIT, tag, owner, clock) , device_bbc_userport_interface(mconfig, *this) , m_userport(*this, "userport%u", 1) diff --git a/src/devices/bus/bbc/userport/usersplit.h b/src/devices/bus/bbc/userport/usersplit.h index 27ce11a9fde..0c359a59fc9 100644 --- a/src/devices/bus/bbc/userport/usersplit.h +++ b/src/devices/bus/bbc/userport/usersplit.h @@ -26,7 +26,7 @@ class bbc_usersplit_device : { public: // construction/destruction - bbc_usersplit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_usersplit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(userport_changed) { m_selected = newval; } diff --git a/src/devices/bus/bbc/userport/voicebox.cpp b/src/devices/bus/bbc/userport/voicebox.cpp index c42d71a2456..8c726b659a5 100644 --- a/src/devices/bus/bbc/userport/voicebox.cpp +++ b/src/devices/bus/bbc/userport/voicebox.cpp @@ -40,7 +40,7 @@ const tiny_rom_entry *bbc_voicebox_device::device_rom_region() const void bbc_voicebox_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "mono").front_center(); - SP0256(config, m_nsp, 3120000); // TODO: unknown crystal + SP0256(config, m_nsp, XTAL::u(3120000)); // TODO: unknown crystal m_nsp->data_request_callback().set(DEVICE_SELF_OWNER, FUNC(bbc_userport_slot_device::cb1_w)).invert(); m_nsp->add_route(ALL_OUTPUTS, "mono", 1.0); } @@ -54,7 +54,7 @@ void bbc_voicebox_device::device_add_mconfig(machine_config &config) // bbc_voicebox_device - constructor //------------------------------------------------- -bbc_voicebox_device::bbc_voicebox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bbc_voicebox_device::bbc_voicebox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BBC_VOICEBOX, tag, owner, clock) , device_bbc_userport_interface(mconfig, *this) , m_nsp(*this, "sp0256") diff --git a/src/devices/bus/bbc/userport/voicebox.h b/src/devices/bus/bbc/userport/voicebox.h index 0f479e27c1d..33bc693d6a1 100644 --- a/src/devices/bus/bbc/userport/voicebox.h +++ b/src/devices/bus/bbc/userport/voicebox.h @@ -25,7 +25,7 @@ class bbc_voicebox_device : { public: // construction/destruction - bbc_voicebox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bbc_voicebox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/bml3/bml3bus.cpp b/src/devices/bus/bml3/bml3bus.cpp index 54e63ea70ec..a4c9973af8a 100644 --- a/src/devices/bus/bml3/bml3bus.cpp +++ b/src/devices/bus/bml3/bml3bus.cpp @@ -59,12 +59,12 @@ DEFINE_DEVICE_TYPE(BML3BUS_SLOT, bml3bus_slot_device, "bml3bus_slot", "Hitachi M //------------------------------------------------- // bml3bus_slot_device - constructor //------------------------------------------------- -bml3bus_slot_device::bml3bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bml3bus_slot_device::bml3bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bml3bus_slot_device(mconfig, BML3BUS_SLOT, tag, owner, clock) { } -bml3bus_slot_device::bml3bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +bml3bus_slot_device::bml3bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_single_card_slot_interface<device_bml3bus_card_interface>(mconfig, *this), m_bml3bus(*this, finder_base::DUMMY_TAG), @@ -97,12 +97,12 @@ DEFINE_DEVICE_TYPE(BML3BUS, bml3bus_device, "bml3bus", "Hitachi MB-6890 Bus") // bml3bus_device - constructor //------------------------------------------------- -bml3bus_device::bml3bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bml3bus_device::bml3bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bml3bus_device(mconfig, BML3BUS, tag, owner, clock) { } -bml3bus_device::bml3bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +bml3bus_device::bml3bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_space(*this, finder_base::DUMMY_TAG, -1, 8), m_out_nmi_cb(*this), diff --git a/src/devices/bus/bml3/bml3bus.h b/src/devices/bus/bml3/bml3bus.h index b3c36ed9c70..dd1eed49471 100644 --- a/src/devices/bus/bml3/bml3bus.h +++ b/src/devices/bus/bml3/bml3bus.h @@ -32,7 +32,7 @@ public: // construction/destruction template <typename T, typename U> bml3bus_slot_device(machine_config const &mconfig, const char *tag, device_t *owner, T &&nbtag, U &&opts, const char *dflt) - : bml3bus_slot_device(mconfig, tag, owner, (uint32_t)0) + : bml3bus_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -41,7 +41,7 @@ public: set_bml3bus_slot(std::forward<T>(nbtag), tag); } - bml3bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + bml3bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration template <typename T> @@ -52,7 +52,7 @@ public: } protected: - bml3bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bml3bus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -72,7 +72,7 @@ class bml3bus_device : public device_t friend class device_bml3bus_card_interface; public: // construction/destruction - bml3bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bml3bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration template <class Object> void set_space(Object &&tag, int spacenum) { m_space.set_tag(std::forward<Object>(tag), spacenum); } @@ -87,7 +87,7 @@ public: DECLARE_WRITE_LINE_MEMBER( firq_w ); protected: - bml3bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bml3bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/bml3/bml3kanji.cpp b/src/devices/bus/bml3/bml3kanji.cpp index 22bfe8d58a9..ac87e07d7ad 100644 --- a/src/devices/bus/bml3/bml3kanji.cpp +++ b/src/devices/bus/bml3/bml3kanji.cpp @@ -59,7 +59,7 @@ void bml3bus_kanji_device::bml3_kanji_w(offs_t offset, uint8_t data) // LIVE DEVICE //************************************************************************** -bml3bus_kanji_device::bml3bus_kanji_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bml3bus_kanji_device::bml3bus_kanji_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BML3BUS_KANJI, tag, owner, clock), device_bml3bus_card_interface(mconfig, *this), m_kanji_addr(0), m_rom(nullptr) { diff --git a/src/devices/bus/bml3/bml3kanji.h b/src/devices/bus/bml3/bml3kanji.h index 2ce54ed8230..2e00d6259c6 100644 --- a/src/devices/bus/bml3/bml3kanji.h +++ b/src/devices/bus/bml3/bml3kanji.h @@ -25,7 +25,7 @@ class bml3bus_kanji_device: { public: // construction/destruction - bml3bus_kanji_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bml3bus_kanji_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t bml3_kanji_r(offs_t offset); void bml3_kanji_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/bml3/bml3mp1802.cpp b/src/devices/bus/bml3/bml3mp1802.cpp index 61900cd020f..c0f66308c7a 100644 --- a/src/devices/bus/bml3/bml3mp1802.cpp +++ b/src/devices/bus/bml3/bml3mp1802.cpp @@ -110,7 +110,7 @@ void bml3bus_mp1802_device::bml3_mp1802_w(uint8_t data) // LIVE DEVICE //************************************************************************** -bml3bus_mp1802_device::bml3bus_mp1802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bml3bus_mp1802_device::bml3bus_mp1802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BML3BUS_MP1802, tag, owner, clock), device_bml3bus_card_interface(mconfig, *this), m_fdc(*this, "fdc"), diff --git a/src/devices/bus/bml3/bml3mp1802.h b/src/devices/bus/bml3/bml3mp1802.h index d1bbdad744b..f45206c968d 100644 --- a/src/devices/bus/bml3/bml3mp1802.h +++ b/src/devices/bus/bml3/bml3mp1802.h @@ -29,7 +29,7 @@ class bml3bus_mp1802_device: { public: // construction/destruction - bml3bus_mp1802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bml3bus_mp1802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t bml3_mp1802_r(); void bml3_mp1802_w(uint8_t data); diff --git a/src/devices/bus/bml3/bml3mp1805.cpp b/src/devices/bus/bml3/bml3mp1805.cpp index 78b58782d6e..ee14fc8724d 100644 --- a/src/devices/bus/bml3/bml3mp1805.cpp +++ b/src/devices/bus/bml3/bml3mp1805.cpp @@ -52,7 +52,7 @@ void bml3bus_mp1805_device::floppy_drives(device_slot_interface &device) void bml3bus_mp1805_device::device_add_mconfig(machine_config &config) { - MC6843(config, m_mc6843, 500000); + MC6843(config, m_mc6843, XTAL::u(500000)); m_mc6843->force_ready(); m_mc6843->irq().set(FUNC(bml3bus_mp1805_device::nmi_w)); @@ -131,7 +131,7 @@ void bml3bus_mp1805_device::bml3_mp1805_w(uint8_t data) // LIVE DEVICE //************************************************************************** -bml3bus_mp1805_device::bml3bus_mp1805_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bml3bus_mp1805_device::bml3bus_mp1805_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BML3BUS_MP1805, tag, owner, clock), device_bml3bus_card_interface(mconfig, *this), m_floppy(*this, "%u", 0U), diff --git a/src/devices/bus/bml3/bml3mp1805.h b/src/devices/bus/bml3/bml3mp1805.h index f3c4de448d3..2a8d0f6da03 100644 --- a/src/devices/bus/bml3/bml3mp1805.h +++ b/src/devices/bus/bml3/bml3mp1805.h @@ -28,7 +28,7 @@ class bml3bus_mp1805_device: { public: // construction/destruction - bml3bus_mp1805_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bml3bus_mp1805_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t bml3_mp1805_r(); void bml3_mp1805_w(uint8_t data); diff --git a/src/devices/bus/bml3/bml3rtc.cpp b/src/devices/bus/bml3/bml3rtc.cpp index 6fbe66f166e..da6cb024945 100644 --- a/src/devices/bus/bml3/bml3rtc.cpp +++ b/src/devices/bus/bml3/bml3rtc.cpp @@ -82,7 +82,7 @@ void bml3bus_rtc_device::bml3_rtc_w(offs_t offset, uint8_t data) // LIVE DEVICE //************************************************************************** -bml3bus_rtc_device::bml3bus_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bml3bus_rtc_device::bml3bus_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BML3BUS_RTC, tag, owner, clock) , device_bml3bus_card_interface(mconfig, *this) , m_rtc(*this, "rtc") diff --git a/src/devices/bus/bml3/bml3rtc.h b/src/devices/bus/bml3/bml3rtc.h index 16c6cbd0e9c..4a4d1d4514a 100644 --- a/src/devices/bus/bml3/bml3rtc.h +++ b/src/devices/bus/bml3/bml3rtc.h @@ -27,7 +27,7 @@ class bml3bus_rtc_device: { public: // construction/destruction - bml3bus_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bml3bus_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t bml3_rtc_r(offs_t offset); void bml3_rtc_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/bw2/exp.cpp b/src/devices/bus/bw2/exp.cpp index 030170d488c..01c07f72392 100644 --- a/src/devices/bus/bw2/exp.cpp +++ b/src/devices/bus/bw2/exp.cpp @@ -52,7 +52,7 @@ device_bw2_expansion_slot_interface::~device_bw2_expansion_slot_interface() // bw2_expansion_slot_device - constructor //------------------------------------------------- -bw2_expansion_slot_device::bw2_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bw2_expansion_slot_device::bw2_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BW2_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_bw2_expansion_slot_interface>(mconfig, *this), m_cart(nullptr) diff --git a/src/devices/bus/bw2/exp.h b/src/devices/bus/bw2/exp.h index 6c6acf11f9a..32f4e008fb2 100644 --- a/src/devices/bus/bw2/exp.h +++ b/src/devices/bus/bw2/exp.h @@ -56,7 +56,7 @@ class bw2_expansion_slot_device : public device_t, public: // construction/destruction template <typename T> - bw2_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) + bw2_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts, char const *dflt) : bw2_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -65,7 +65,7 @@ public: set_fixed(false); } - bw2_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bw2_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~bw2_expansion_slot_device(); // computer interface diff --git a/src/devices/bus/bw2/ramcard.cpp b/src/devices/bus/bw2/ramcard.cpp index 33d1fc147d9..80715655e20 100644 --- a/src/devices/bus/bw2/ramcard.cpp +++ b/src/devices/bus/bw2/ramcard.cpp @@ -47,7 +47,7 @@ const tiny_rom_entry *bw2_ramcard_device::device_rom_region() const // bw2_ramcard_device - constructor //------------------------------------------------- -bw2_ramcard_device::bw2_ramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bw2_ramcard_device::bw2_ramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BW2_RAMCARD, tag, owner, clock), device_bw2_expansion_slot_interface(mconfig, *this), m_rom(*this, "ramcard"), diff --git a/src/devices/bus/bw2/ramcard.h b/src/devices/bus/bw2/ramcard.h index f3cd95f38d4..4a6d49c2504 100644 --- a/src/devices/bus/bw2/ramcard.h +++ b/src/devices/bus/bw2/ramcard.h @@ -26,7 +26,7 @@ class bw2_ramcard_device : public device_t, { public: // construction/destruction - bw2_ramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bw2_ramcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/c64/16kb.cpp b/src/devices/bus/c64/16kb.cpp index 4b497f88591..a94bb9567f4 100644 --- a/src/devices/bus/c64/16kb.cpp +++ b/src/devices/bus/c64/16kb.cpp @@ -62,7 +62,7 @@ ioport_constructor c64_16kb_cartridge_device::device_input_ports() const // c64_16kb_cartridge_device - constructor //------------------------------------------------- -c64_16kb_cartridge_device::c64_16kb_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_16kb_cartridge_device::c64_16kb_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_16KB, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_sw1(*this, "SW1"), diff --git a/src/devices/bus/c64/16kb.h b/src/devices/bus/c64/16kb.h index d17e7636879..7ab351fae4d 100644 --- a/src/devices/bus/c64/16kb.h +++ b/src/devices/bus/c64/16kb.h @@ -28,7 +28,7 @@ class c64_16kb_cartridge_device : public device_t, public device_c64_expansion_c { public: // construction/destruction - c64_16kb_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_16kb_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/4dxh.cpp b/src/devices/bus/c64/4dxh.cpp index 4273388543b..e28c2967fb3 100644 --- a/src/devices/bus/c64/4dxh.cpp +++ b/src/devices/bus/c64/4dxh.cpp @@ -62,7 +62,7 @@ ioport_constructor c64_4dxh_device::device_input_ports() const // c64_4dxh_device - constructor //------------------------------------------------- -c64_4dxh_device::c64_4dxh_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_4dxh_device::c64_4dxh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_4DXH, tag, owner, clock), device_pet_user_port_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/4dxh.h b/src/devices/bus/c64/4dxh.h index 620228e4942..d1bbe17e6a6 100644 --- a/src/devices/bus/c64/4dxh.h +++ b/src/devices/bus/c64/4dxh.h @@ -26,7 +26,7 @@ class c64_4dxh_device : public device_t, public device_pet_user_port_interface { public: // construction/destruction - c64_4dxh_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_4dxh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/4ksa.cpp b/src/devices/bus/c64/4ksa.cpp index 39a86b6b17c..164297719bc 100644 --- a/src/devices/bus/c64/4ksa.cpp +++ b/src/devices/bus/c64/4ksa.cpp @@ -62,7 +62,7 @@ ioport_constructor c64_4ksa_device::device_input_ports() const // c64_4ksa_device - constructor //------------------------------------------------- -c64_4ksa_device::c64_4ksa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_4ksa_device::c64_4ksa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_4KSA, tag, owner, clock), device_pet_user_port_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/4ksa.h b/src/devices/bus/c64/4ksa.h index 6208ab201d2..d9f758a0a23 100644 --- a/src/devices/bus/c64/4ksa.h +++ b/src/devices/bus/c64/4ksa.h @@ -26,7 +26,7 @@ class c64_4ksa_device : public device_t, public device_pet_user_port_interface { public: // construction/destruction - c64_4ksa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_4ksa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/4tba.cpp b/src/devices/bus/c64/4tba.cpp index 4fc58cb0d49..1c7ae31f3fe 100644 --- a/src/devices/bus/c64/4tba.cpp +++ b/src/devices/bus/c64/4tba.cpp @@ -62,7 +62,7 @@ ioport_constructor c64_4tba_device::device_input_ports() const // c64_4tba_device - constructor //------------------------------------------------- -c64_4tba_device::c64_4tba_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_4tba_device::c64_4tba_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_4TBA, tag, owner, clock), device_pet_user_port_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/4tba.h b/src/devices/bus/c64/4tba.h index dc4f3b2186c..b18074e184f 100644 --- a/src/devices/bus/c64/4tba.h +++ b/src/devices/bus/c64/4tba.h @@ -26,7 +26,7 @@ class c64_4tba_device : public device_t, public device_pet_user_port_interface { public: // construction/destruction - c64_4tba_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_4tba_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/bn1541.cpp b/src/devices/bus/c64/bn1541.cpp index ffdf84b77d1..3e2f152ac70 100644 --- a/src/devices/bus/c64/bn1541.cpp +++ b/src/devices/bus/c64/bn1541.cpp @@ -61,7 +61,7 @@ device_c64_floppy_parallel_interface::~device_c64_floppy_parallel_interface() // c64_bn1541_device - constructor //------------------------------------------------- -c64_bn1541_device::c64_bn1541_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_bn1541_device::c64_bn1541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_BN1541, tag, owner, clock), device_pet_user_port_interface(mconfig, *this), device_c64_floppy_parallel_interface(mconfig, *this), m_parallel_output(0) diff --git a/src/devices/bus/c64/bn1541.h b/src/devices/bus/c64/bn1541.h index af6fedd7c97..08b29759ea3 100644 --- a/src/devices/bus/c64/bn1541.h +++ b/src/devices/bus/c64/bn1541.h @@ -47,7 +47,7 @@ class c64_bn1541_device : public device_t, { public: // construction/destruction - c64_bn1541_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_bn1541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/buscard.cpp b/src/devices/bus/c64/buscard.cpp index aef66ef022b..669eabd8bf4 100644 --- a/src/devices/bus/c64/buscard.cpp +++ b/src/devices/bus/c64/buscard.cpp @@ -222,7 +222,7 @@ WRITE_LINE_MEMBER( c64_buscard_device::busy_w ) void c64_buscard_device::device_add_mconfig(machine_config &config) { - I8255A(config, m_ppi, 0); + I8255A(config, m_ppi); m_ppi->in_pa_callback().set(FUNC(c64_buscard_device::ppi_pa_r)); m_ppi->out_pa_callback().set(FUNC(c64_buscard_device::ppi_pa_w)); m_ppi->in_pb_callback().set_constant(0xff); @@ -230,11 +230,11 @@ void c64_buscard_device::device_add_mconfig(machine_config &config) m_ppi->in_pc_callback().set(FUNC(c64_buscard_device::ppi_pc_r)); m_ppi->out_pc_callback().set(FUNC(c64_buscard_device::ppi_pc_w)); - DS75160A(config, m_ieee1, 0); + DS75160A(config, m_ieee1); m_ieee1->read_callback().set(IEEE488_TAG, FUNC(ieee488_device::dio_r)); m_ieee1->write_callback().set(IEEE488_TAG, FUNC(ieee488_device::host_dio_w)); - DS75161A(config, m_ieee2, 0); + DS75161A(config, m_ieee2); m_ieee2->in_ren().set(IEEE488_TAG, FUNC(ieee488_device::ren_r)); m_ieee2->in_ifc().set(IEEE488_TAG, FUNC(ieee488_device::ifc_r)); m_ieee2->in_ndac().set(IEEE488_TAG, FUNC(ieee488_device::ndac_r)); @@ -252,7 +252,7 @@ void c64_buscard_device::device_add_mconfig(machine_config &config) m_ieee2->out_atn().set(IEEE488_TAG, FUNC(ieee488_device::host_atn_w)); m_ieee2->out_srq().set(IEEE488_TAG, FUNC(ieee488_device::host_srq_w)); - IEEE488(config, m_bus, 0); + IEEE488(config, m_bus); ieee488_slot_device::add_cbm_defaults(config, nullptr); CENTRONICS(config, m_centronics, centronics_devices, nullptr); @@ -272,7 +272,7 @@ void c64_buscard_device::device_add_mconfig(machine_config &config) // c64_buscard_device - constructor //------------------------------------------------- -c64_buscard_device::c64_buscard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_buscard_device::c64_buscard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_BUSCARD, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_ppi(*this, "u2"), diff --git a/src/devices/bus/c64/buscard.h b/src/devices/bus/c64/buscard.h index 151598060ad..230a84e258f 100644 --- a/src/devices/bus/c64/buscard.h +++ b/src/devices/bus/c64/buscard.h @@ -32,7 +32,7 @@ class c64_buscard_device : public device_t, { public: // construction/destruction - c64_buscard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_buscard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/buscard2.cpp b/src/devices/bus/c64/buscard2.cpp index 65ee3b0ebb8..309a765cf33 100644 --- a/src/devices/bus/c64/buscard2.cpp +++ b/src/devices/bus/c64/buscard2.cpp @@ -105,11 +105,11 @@ WRITE_LINE_MEMBER( c64_buscard2_device::busy_w ) void c64_buscard2_device::device_add_mconfig(machine_config &config) { - RIOT6532(config, m_riot, 0); + RIOT6532(config, m_riot); - PIA6821(config, m_pia, 0); + PIA6821(config, m_pia); - IEEE488(config, m_bus, 0); + IEEE488(config, m_bus); ieee488_slot_device::add_cbm_defaults(config, nullptr); CENTRONICS(config, m_centronics, centronics_devices, nullptr); @@ -129,7 +129,7 @@ void c64_buscard2_device::device_add_mconfig(machine_config &config) // c64_buscard2_device - constructor //------------------------------------------------- -c64_buscard2_device::c64_buscard2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_buscard2_device::c64_buscard2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_BUSCARD2, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_riot(*this, "riot"), diff --git a/src/devices/bus/c64/buscard2.h b/src/devices/bus/c64/buscard2.h index e0250f03d03..8c235cfce1b 100644 --- a/src/devices/bus/c64/buscard2.h +++ b/src/devices/bus/c64/buscard2.h @@ -31,7 +31,7 @@ class c64_buscard2_device : public device_t, { public: // construction/destruction - c64_buscard2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_buscard2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/c128_comal80.cpp b/src/devices/bus/c64/c128_comal80.cpp index f1ce8c5c87a..c8e93c03b9c 100644 --- a/src/devices/bus/c64/c128_comal80.cpp +++ b/src/devices/bus/c64/c128_comal80.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C128_COMAL80, c128_comal80_cartridge_device, "c128_comal80", // c128_comal80_cartridge_device - constructor //------------------------------------------------- -c128_comal80_cartridge_device::c128_comal80_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c128_comal80_cartridge_device::c128_comal80_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C128_COMAL80, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/c128_comal80.h b/src/devices/bus/c64/c128_comal80.h index fe413f9bef6..06107e5c70e 100644 --- a/src/devices/bus/c64/c128_comal80.h +++ b/src/devices/bus/c64/c128_comal80.h @@ -27,7 +27,7 @@ class c128_comal80_cartridge_device : public device_t, { public: // construction/destruction - c128_comal80_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c128_comal80_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/c128_partner.cpp b/src/devices/bus/c64/c128_partner.cpp index 7c6cf1aea97..e9c3d6cb75e 100644 --- a/src/devices/bus/c64/c128_partner.cpp +++ b/src/devices/bus/c64/c128_partner.cpp @@ -77,7 +77,7 @@ ioport_constructor c128_partner_cartridge_device::device_input_ports() const // c128_partner_cartridge_device - constructor //------------------------------------------------- -c128_partner_cartridge_device::c128_partner_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c128_partner_cartridge_device::c128_partner_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C128_PARTNER, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_ram(*this, "ram", 0x2000, ENDIANNESS_LITTLE), diff --git a/src/devices/bus/c64/c128_partner.h b/src/devices/bus/c64/c128_partner.h index 3f91afbb0e9..587d0ccf42d 100644 --- a/src/devices/bus/c64/c128_partner.h +++ b/src/devices/bus/c64/c128_partner.h @@ -28,7 +28,7 @@ class c128_partner_cartridge_device : public device_t, { public: // construction/destruction - c128_partner_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c128_partner_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/comal80.cpp b/src/devices/bus/c64/comal80.cpp index 0ce6dcbfb5a..40a3f604ad6 100644 --- a/src/devices/bus/c64/comal80.cpp +++ b/src/devices/bus/c64/comal80.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_COMAL80, c64_comal80_cartridge_device, "c64_comal80", "C6 // c64_comal80_cartridge_device - constructor //------------------------------------------------- -c64_comal80_cartridge_device::c64_comal80_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_comal80_cartridge_device::c64_comal80_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_COMAL80, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/comal80.h b/src/devices/bus/c64/comal80.h index af0958a8940..1abe98fb26c 100644 --- a/src/devices/bus/c64/comal80.h +++ b/src/devices/bus/c64/comal80.h @@ -27,7 +27,7 @@ class c64_comal80_cartridge_device : public device_t, { public: // construction/destruction - c64_comal80_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_comal80_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/cpm.cpp b/src/devices/bus/c64/cpm.cpp index f60fe8bd506..99b8ad6bc3c 100644 --- a/src/devices/bus/c64/cpm.cpp +++ b/src/devices/bus/c64/cpm.cpp @@ -62,7 +62,7 @@ void c64_cpm_cartridge_device::z80_io(address_map &map) void c64_cpm_cartridge_device::device_add_mconfig(machine_config &config) { - Z80(config, m_maincpu, 3000000); + Z80(config, m_maincpu, XTAL::u(3000000)); m_maincpu->set_addrmap(AS_PROGRAM, &c64_cpm_cartridge_device::z80_mem); m_maincpu->set_addrmap(AS_IO, &c64_cpm_cartridge_device::z80_io); } @@ -122,7 +122,7 @@ inline void c64_cpm_cartridge_device::update_signals() // c64_cpm_cartridge_device - constructor //------------------------------------------------- -c64_cpm_cartridge_device::c64_cpm_cartridge_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +c64_cpm_cartridge_device::c64_cpm_cartridge_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_maincpu(*this, Z80_TAG), @@ -131,7 +131,7 @@ c64_cpm_cartridge_device::c64_cpm_cartridge_device(const machine_config& mconfig { } -c64_cpm_cartridge_device::c64_cpm_cartridge_device(const machine_config& mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_cpm_cartridge_device::c64_cpm_cartridge_device(const machine_config& mconfig, const char *tag, device_t *owner, const XTAL &clock) : c64_cpm_cartridge_device(mconfig, C64_CPM, tag, owner, clock) { } diff --git a/src/devices/bus/c64/cpm.h b/src/devices/bus/c64/cpm.h index c490d61aa58..e80ced0d8e4 100644 --- a/src/devices/bus/c64/cpm.h +++ b/src/devices/bus/c64/cpm.h @@ -27,10 +27,10 @@ class c64_cpm_cartridge_device : public device_t, { public: // construction/destruction - c64_cpm_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_cpm_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - c64_cpm_cartridge_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + c64_cpm_cartridge_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/c64/currah_speech.cpp b/src/devices/bus/c64/currah_speech.cpp index 0216e4c4ef5..8d807a4ba6f 100644 --- a/src/devices/bus/c64/currah_speech.cpp +++ b/src/devices/bus/c64/currah_speech.cpp @@ -106,7 +106,7 @@ const tiny_rom_entry *c64_currah_speech_cartridge_device::device_rom_region() co void c64_currah_speech_cartridge_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "mono").front_center(); - SP0256(config, m_nsp, 4000000); // ??? + SP0256(config, m_nsp, XTAL::u(4000000)); // ??? m_nsp->add_route(ALL_OUTPUTS, "mono", 1.00); } @@ -138,7 +138,7 @@ void c64_currah_speech_cartridge_device::set_osc1(int voice, int intonation) // c64_currah_speech_cartridge_device - constructor //------------------------------------------------- -c64_currah_speech_cartridge_device::c64_currah_speech_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_currah_speech_cartridge_device::c64_currah_speech_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_CURRAH_SPEECH, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_nsp(*this, "sp0256") diff --git a/src/devices/bus/c64/currah_speech.h b/src/devices/bus/c64/currah_speech.h index f856833f659..179967526de 100644 --- a/src/devices/bus/c64/currah_speech.h +++ b/src/devices/bus/c64/currah_speech.h @@ -28,7 +28,7 @@ class c64_currah_speech_cartridge_device : public device_t, { public: // construction/destruction - c64_currah_speech_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_currah_speech_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/dela_ep256.cpp b/src/devices/bus/c64/dela_ep256.cpp index d5052f914b2..dde8d788582 100644 --- a/src/devices/bus/c64/dela_ep256.cpp +++ b/src/devices/bus/c64/dela_ep256.cpp @@ -38,7 +38,7 @@ void c64_dela_ep256_cartridge_device::device_add_mconfig(machine_config &config) // c64_dela_ep256_cartridge_device - constructor //------------------------------------------------- -c64_dela_ep256_cartridge_device::c64_dela_ep256_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_dela_ep256_cartridge_device::c64_dela_ep256_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_DELA_EP256, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_eproms(*this, "rom%u", 1U) diff --git a/src/devices/bus/c64/dela_ep256.h b/src/devices/bus/c64/dela_ep256.h index bb6806f4d8e..1addc1e9fed 100644 --- a/src/devices/bus/c64/dela_ep256.h +++ b/src/devices/bus/c64/dela_ep256.h @@ -29,7 +29,7 @@ class c64_dela_ep256_cartridge_device : public device_t, { public: // construction/destruction - c64_dela_ep256_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_dela_ep256_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/dela_ep64.cpp b/src/devices/bus/c64/dela_ep64.cpp index 5798794f7eb..70592f3b571 100644 --- a/src/devices/bus/c64/dela_ep64.cpp +++ b/src/devices/bus/c64/dela_ep64.cpp @@ -37,7 +37,7 @@ void c64_dela_ep64_cartridge_device::device_add_mconfig(machine_config &config) // c64_dela_ep64_cartridge_device - constructor //------------------------------------------------- -c64_dela_ep64_cartridge_device::c64_dela_ep64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_dela_ep64_cartridge_device::c64_dela_ep64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_DELA_EP64, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_eprom1(*this, "eprom1"), diff --git a/src/devices/bus/c64/dela_ep64.h b/src/devices/bus/c64/dela_ep64.h index 95ac3440871..6aa026205ae 100644 --- a/src/devices/bus/c64/dela_ep64.h +++ b/src/devices/bus/c64/dela_ep64.h @@ -29,7 +29,7 @@ class c64_dela_ep64_cartridge_device : public device_t, { public: // construction/destruction - c64_dela_ep64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_dela_ep64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/dela_ep7x8.cpp b/src/devices/bus/c64/dela_ep7x8.cpp index 0c71555b880..8e2dd88387b 100644 --- a/src/devices/bus/c64/dela_ep7x8.cpp +++ b/src/devices/bus/c64/dela_ep7x8.cpp @@ -42,7 +42,7 @@ void c64_dela_ep7x8_cartridge_device::device_add_mconfig(machine_config &config) // c64_dela_ep7x8_cartridge_device - constructor //------------------------------------------------- -c64_dela_ep7x8_cartridge_device::c64_dela_ep7x8_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_dela_ep7x8_cartridge_device::c64_dela_ep7x8_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_DELA_EP7X8, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_eprom(*this, "rom%u", 1U) diff --git a/src/devices/bus/c64/dela_ep7x8.h b/src/devices/bus/c64/dela_ep7x8.h index 50e1b3af01e..a000175868d 100644 --- a/src/devices/bus/c64/dela_ep7x8.h +++ b/src/devices/bus/c64/dela_ep7x8.h @@ -29,7 +29,7 @@ class c64_dela_ep7x8_cartridge_device : public device_t, { public: // construction/destruction - c64_dela_ep7x8_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_dela_ep7x8_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/dinamic.cpp b/src/devices/bus/c64/dinamic.cpp index 13d37749335..89aac9ec324 100644 --- a/src/devices/bus/c64/dinamic.cpp +++ b/src/devices/bus/c64/dinamic.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_DINAMIC, c64_dinamic_cartridge_device, "c64_dinamic", "C6 // c64_dinamic_cartridge_device - constructor //------------------------------------------------- -c64_dinamic_cartridge_device::c64_dinamic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_dinamic_cartridge_device::c64_dinamic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_DINAMIC, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/dinamic.h b/src/devices/bus/c64/dinamic.h index e204964e4a1..f30c02386c9 100644 --- a/src/devices/bus/c64/dinamic.h +++ b/src/devices/bus/c64/dinamic.h @@ -27,7 +27,7 @@ class c64_dinamic_cartridge_device : public device_t, { public: // construction/destruction - c64_dinamic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_dinamic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/dqbb.cpp b/src/devices/bus/c64/dqbb.cpp index e08bfbd05b5..a4ed00fe8a6 100644 --- a/src/devices/bus/c64/dqbb.cpp +++ b/src/devices/bus/c64/dqbb.cpp @@ -36,7 +36,7 @@ DEFINE_DEVICE_TYPE(C64_DQBB, c64_dqbb_cartridge_device, "c64_dqbb", "C64 Double // c64_dqbb_cartridge_device - constructor //------------------------------------------------- -c64_dqbb_cartridge_device::c64_dqbb_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_dqbb_cartridge_device::c64_dqbb_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_DQBB, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/bus/c64/dqbb.h b/src/devices/bus/c64/dqbb.h index 9770793bdd0..57e64339257 100644 --- a/src/devices/bus/c64/dqbb.h +++ b/src/devices/bus/c64/dqbb.h @@ -28,7 +28,7 @@ class c64_dqbb_cartridge_device : public device_t, { public: // construction/destruction - c64_dqbb_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_dqbb_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/easy_calc_result.cpp b/src/devices/bus/c64/easy_calc_result.cpp index 123870d5d3e..3fd64c777f5 100644 --- a/src/devices/bus/c64/easy_calc_result.cpp +++ b/src/devices/bus/c64/easy_calc_result.cpp @@ -48,7 +48,7 @@ DEFINE_DEVICE_TYPE(C64_EASY_CALC_RESULT, c64_easy_calc_result_cartridge_device, // c64_easy_calc_result_cartridge_device - constructor //------------------------------------------------- -c64_easy_calc_result_cartridge_device::c64_easy_calc_result_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_easy_calc_result_cartridge_device::c64_easy_calc_result_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_EASY_CALC_RESULT, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) { diff --git a/src/devices/bus/c64/easy_calc_result.h b/src/devices/bus/c64/easy_calc_result.h index 2d945b7dea2..ec72a56ff73 100644 --- a/src/devices/bus/c64/easy_calc_result.h +++ b/src/devices/bus/c64/easy_calc_result.h @@ -27,7 +27,7 @@ class c64_easy_calc_result_cartridge_device : public device_t, { public: // construction/destruction - c64_easy_calc_result_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_easy_calc_result_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/easyflash.cpp b/src/devices/bus/c64/easyflash.cpp index eab9ff7930a..966ecc93d01 100644 --- a/src/devices/bus/c64/easyflash.cpp +++ b/src/devices/bus/c64/easyflash.cpp @@ -71,7 +71,7 @@ ioport_constructor c64_easyflash_cartridge_device::device_input_ports() const // c64_easyflash_cartridge_device - constructor //------------------------------------------------- -c64_easyflash_cartridge_device::c64_easyflash_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_easyflash_cartridge_device::c64_easyflash_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_EASYFLASH, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_flash_roml(*this, AM29F040_0_TAG), diff --git a/src/devices/bus/c64/easyflash.h b/src/devices/bus/c64/easyflash.h index 6c73a14838a..40c206e2b6c 100644 --- a/src/devices/bus/c64/easyflash.h +++ b/src/devices/bus/c64/easyflash.h @@ -28,7 +28,7 @@ class c64_easyflash_cartridge_device : public device_t, { public: // construction/destruction - c64_easyflash_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_easyflash_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/epyx_fast_load.cpp b/src/devices/bus/c64/epyx_fast_load.cpp index 21352ddef63..1098f868dfc 100644 --- a/src/devices/bus/c64/epyx_fast_load.cpp +++ b/src/devices/bus/c64/epyx_fast_load.cpp @@ -37,7 +37,7 @@ DEFINE_DEVICE_TYPE(C64_EPYX_FAST_LOAD, c64_epyx_fast_load_cartridge_device, "c64 // c64_epyx_fast_load_cartridge_device - constructor //------------------------------------------------- -c64_epyx_fast_load_cartridge_device::c64_epyx_fast_load_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_epyx_fast_load_cartridge_device::c64_epyx_fast_load_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_EPYX_FAST_LOAD, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_exrom_timer(nullptr) { diff --git a/src/devices/bus/c64/epyx_fast_load.h b/src/devices/bus/c64/epyx_fast_load.h index 8a2ebcaa9b0..8d13a81d508 100644 --- a/src/devices/bus/c64/epyx_fast_load.h +++ b/src/devices/bus/c64/epyx_fast_load.h @@ -27,7 +27,7 @@ class c64_epyx_fast_load_cartridge_device : public device_t, { public: // construction/destruction - c64_epyx_fast_load_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_epyx_fast_load_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/exos.cpp b/src/devices/bus/c64/exos.cpp index 13c5d972642..dbfe1fdca3a 100644 --- a/src/devices/bus/c64/exos.cpp +++ b/src/devices/bus/c64/exos.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_EXOS, c64_exos_cartridge_device, "c64_exos", "C64 ExOS ca // c64_exos_cartridge_device - constructor //------------------------------------------------- -c64_exos_cartridge_device::c64_exos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_exos_cartridge_device::c64_exos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_EXOS, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/exos.h b/src/devices/bus/c64/exos.h index 73b9b2699aa..e31f4fc5536 100644 --- a/src/devices/bus/c64/exos.h +++ b/src/devices/bus/c64/exos.h @@ -27,7 +27,7 @@ class c64_exos_cartridge_device : public device_t, { public: // construction/destruction - c64_exos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_exos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/exp.cpp b/src/devices/bus/c64/exp.cpp index 72d66ce6f30..5c0c5ae3e6a 100644 --- a/src/devices/bus/c64/exp.cpp +++ b/src/devices/bus/c64/exp.cpp @@ -56,7 +56,7 @@ device_c64_expansion_card_interface::~device_c64_expansion_card_interface() // c64_expansion_slot_device - constructor //------------------------------------------------- -c64_expansion_slot_device::c64_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_expansion_slot_device::c64_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_c64_expansion_card_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/c64/exp.h b/src/devices/bus/c64/exp.h index d5861b0c4a3..3607b1f11b9 100644 --- a/src/devices/bus/c64/exp.h +++ b/src/devices/bus/c64/exp.h @@ -56,7 +56,7 @@ class c64_expansion_slot_device : public device_t, public: // construction/destruction template <typename T> - c64_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + c64_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : c64_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -65,7 +65,7 @@ public: set_fixed(false); } - c64_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_callback() { return m_write_irq.bind(); } auto nmi_callback() { return m_write_nmi.bind(); } @@ -87,8 +87,8 @@ public: DECLARE_WRITE_LINE_MEMBER( nmi_w ) { m_write_nmi(state); } DECLARE_WRITE_LINE_MEMBER( dma_w ) { m_write_dma(state); } DECLARE_WRITE_LINE_MEMBER( reset_w ) { m_write_reset(state); } - int phi2() { return clock(); } - int dotclock() { return phi2() * 8; } + XTAL phi2() { return clock(); } + XTAL dotclock() { return phi2() * 8; } int hiram() { return m_hiram; } int loram() { return m_loram; } diff --git a/src/devices/bus/c64/fcc.cpp b/src/devices/bus/c64/fcc.cpp index 07ff8840e3a..6199968cc0a 100644 --- a/src/devices/bus/c64/fcc.cpp +++ b/src/devices/bus/c64/fcc.cpp @@ -78,7 +78,7 @@ ioport_constructor c64_final_chesscard_device::device_input_ports() const // c64_final_chesscard_device - constructor //------------------------------------------------- -c64_final_chesscard_device::c64_final_chesscard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_final_chesscard_device::c64_final_chesscard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_FCC, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/bus/c64/fcc.h b/src/devices/bus/c64/fcc.h index 33baea0707c..18dbd863f72 100644 --- a/src/devices/bus/c64/fcc.h +++ b/src/devices/bus/c64/fcc.h @@ -29,7 +29,7 @@ class c64_final_chesscard_device : public device_t, { public: // construction/destruction - c64_final_chesscard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_final_chesscard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/final.cpp b/src/devices/bus/c64/final.cpp index b11267b1f01..d7a40b39ff0 100644 --- a/src/devices/bus/c64/final.cpp +++ b/src/devices/bus/c64/final.cpp @@ -63,7 +63,7 @@ ioport_constructor c64_final_cartridge_device::device_input_ports() const // c64_final_cartridge_device - constructor //------------------------------------------------- -c64_final_cartridge_device::c64_final_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_final_cartridge_device::c64_final_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_FINAL, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/final.h b/src/devices/bus/c64/final.h index 6d59e737c02..11e18d56dee 100644 --- a/src/devices/bus/c64/final.h +++ b/src/devices/bus/c64/final.h @@ -27,7 +27,7 @@ class c64_final_cartridge_device : public device_t, { public: // construction/destruction - c64_final_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_final_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/final3.cpp b/src/devices/bus/c64/final3.cpp index 7df9d03042e..739e3e96c8f 100644 --- a/src/devices/bus/c64/final3.cpp +++ b/src/devices/bus/c64/final3.cpp @@ -64,7 +64,7 @@ ioport_constructor c64_final3_cartridge_device::device_input_ports() const // c64_final3_cartridge_device - constructor //------------------------------------------------- -c64_final3_cartridge_device::c64_final3_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_final3_cartridge_device::c64_final3_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_FINAL3, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0), m_hidden(0) { diff --git a/src/devices/bus/c64/final3.h b/src/devices/bus/c64/final3.h index 8b020482560..0f19ba580ef 100644 --- a/src/devices/bus/c64/final3.h +++ b/src/devices/bus/c64/final3.h @@ -27,7 +27,7 @@ class c64_final3_cartridge_device : public device_t, { public: // construction/destruction - c64_final3_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_final3_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/fun_play.cpp b/src/devices/bus/c64/fun_play.cpp index 2a211b21ab5..0c6a2430ee2 100644 --- a/src/devices/bus/c64/fun_play.cpp +++ b/src/devices/bus/c64/fun_play.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_FUN_PLAY, c64_fun_play_cartridge_device, "c64_fun_play", // c64_fun_play_cartridge_device - constructor //------------------------------------------------- -c64_fun_play_cartridge_device::c64_fun_play_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_fun_play_cartridge_device::c64_fun_play_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_FUN_PLAY, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/fun_play.h b/src/devices/bus/c64/fun_play.h index 6fc082164c6..1b43b5e5755 100644 --- a/src/devices/bus/c64/fun_play.h +++ b/src/devices/bus/c64/fun_play.h @@ -27,7 +27,7 @@ class c64_fun_play_cartridge_device : public device_t, { public: // construction/destruction - c64_fun_play_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_fun_play_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/geocable.cpp b/src/devices/bus/c64/geocable.cpp index e07734f987f..19ec7430bf6 100644 --- a/src/devices/bus/c64/geocable.cpp +++ b/src/devices/bus/c64/geocable.cpp @@ -46,7 +46,7 @@ void c64_geocable_device::device_add_mconfig(machine_config &config) // c64_geocable_device - constructor //------------------------------------------------- -c64_geocable_device::c64_geocable_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_geocable_device::c64_geocable_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_GEOCABLE, tag, owner, clock), device_pet_user_port_interface(mconfig, *this), m_centronics(*this, CENTRONICS_TAG) diff --git a/src/devices/bus/c64/geocable.h b/src/devices/bus/c64/geocable.h index 587a94ad80c..408fa0df991 100644 --- a/src/devices/bus/c64/geocable.h +++ b/src/devices/bus/c64/geocable.h @@ -27,7 +27,7 @@ class c64_geocable_device : public device_t, public device_pet_user_port_interfa { public: // construction/destruction - c64_geocable_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_geocable_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/georam.cpp b/src/devices/bus/c64/georam.cpp index 377bc10a391..19db7f3c66c 100644 --- a/src/devices/bus/c64/georam.cpp +++ b/src/devices/bus/c64/georam.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_GEORAM, c64_georam_cartridge_device, "c64_georam", "C64 G // c64_georam_cartridge_device - constructor //------------------------------------------------- -c64_georam_cartridge_device::c64_georam_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_georam_cartridge_device::c64_georam_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_GEORAM, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_ram(*this, "ram", 0x80000, ENDIANNESS_LITTLE), diff --git a/src/devices/bus/c64/georam.h b/src/devices/bus/c64/georam.h index 41b7fd82379..0a66f343b92 100644 --- a/src/devices/bus/c64/georam.h +++ b/src/devices/bus/c64/georam.h @@ -27,7 +27,7 @@ class c64_georam_cartridge_device : public device_t, { public: // construction/destruction - c64_georam_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_georam_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/ide64.cpp b/src/devices/bus/c64/ide64.cpp index 830f38c3993..5fa27a61e66 100644 --- a/src/devices/bus/c64/ide64.cpp +++ b/src/devices/bus/c64/ide64.cpp @@ -86,7 +86,7 @@ ioport_constructor c64_ide64_cartridge_device::device_input_ports() const // c64_ide64_cartridge_device - constructor //------------------------------------------------- -c64_ide64_cartridge_device::c64_ide64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_ide64_cartridge_device::c64_ide64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_IDE64, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_flash_rom(*this, AT29C010A_TAG), diff --git a/src/devices/bus/c64/ide64.h b/src/devices/bus/c64/ide64.h index 9438e3a1ed0..d0a7d113c2a 100644 --- a/src/devices/bus/c64/ide64.h +++ b/src/devices/bus/c64/ide64.h @@ -31,7 +31,7 @@ class c64_ide64_cartridge_device : public device_t, { public: // construction/destruction - c64_ide64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_ide64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/ieee488.cpp b/src/devices/bus/c64/ieee488.cpp index dc588dfc136..48288cb216c 100644 --- a/src/devices/bus/c64/ieee488.cpp +++ b/src/devices/bus/c64/ieee488.cpp @@ -143,7 +143,7 @@ void c64_ieee488_device::tpi_pc_w(uint8_t data) void c64_ieee488_device::device_add_mconfig(machine_config &config) { - TPI6525(config, m_tpi, 0); + TPI6525(config, m_tpi); m_tpi->in_pa_cb().set(FUNC(c64_ieee488_device::tpi_pa_r)); m_tpi->out_pa_cb().set(FUNC(c64_ieee488_device::tpi_pa_w)); m_tpi->in_pb_cb().set(m_bus, FUNC(ieee488_device::dio_r)); @@ -151,7 +151,7 @@ void c64_ieee488_device::device_add_mconfig(machine_config &config) m_tpi->in_pc_cb().set(FUNC(c64_ieee488_device::tpi_pc_r)); m_tpi->out_pc_cb().set(FUNC(c64_ieee488_device::tpi_pc_w)); - IEEE488(config, m_bus, 0); + IEEE488(config, m_bus); ieee488_slot_device::add_cbm_defaults(config, nullptr); C64_EXPANSION_SLOT(config, m_exp, DERIVED_CLOCK(1, 1), c64_expansion_cards, nullptr); @@ -168,7 +168,7 @@ void c64_ieee488_device::device_add_mconfig(machine_config &config) // c64_ieee488_device - constructor //------------------------------------------------- -c64_ieee488_device::c64_ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_ieee488_device::c64_ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_IEEE488, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_tpi(*this, MOS6525_TAG), diff --git a/src/devices/bus/c64/ieee488.h b/src/devices/bus/c64/ieee488.h index 60919029bf7..224ac1c5883 100644 --- a/src/devices/bus/c64/ieee488.h +++ b/src/devices/bus/c64/ieee488.h @@ -28,7 +28,7 @@ class c64_ieee488_device : public device_t, { public: // construction/destruction - c64_ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/kingsoft.cpp b/src/devices/bus/c64/kingsoft.cpp index 510032fb720..3e8be5a06b2 100644 --- a/src/devices/bus/c64/kingsoft.cpp +++ b/src/devices/bus/c64/kingsoft.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_KINGSOFT, c64_kingsoft_cartridge_device, "c64_kingsoft", // c64_kingsoft_cartridge_device - constructor //------------------------------------------------- -c64_kingsoft_cartridge_device::c64_kingsoft_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_kingsoft_cartridge_device::c64_kingsoft_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_KINGSOFT, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/kingsoft.h b/src/devices/bus/c64/kingsoft.h index 3a9fda45fef..afccc2e7363 100644 --- a/src/devices/bus/c64/kingsoft.h +++ b/src/devices/bus/c64/kingsoft.h @@ -27,7 +27,7 @@ class c64_kingsoft_cartridge_device : public device_t, { public: // construction/destruction - c64_kingsoft_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_kingsoft_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/mach5.cpp b/src/devices/bus/c64/mach5.cpp index ddd44407d3e..006cd6972eb 100644 --- a/src/devices/bus/c64/mach5.cpp +++ b/src/devices/bus/c64/mach5.cpp @@ -52,7 +52,7 @@ ioport_constructor c64_mach5_cartridge_device::device_input_ports() const // c64_mach5_cartridge_device - constructor //------------------------------------------------- -c64_mach5_cartridge_device::c64_mach5_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_mach5_cartridge_device::c64_mach5_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MACH5, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_s1(*this, "S1"), m_c128(false) diff --git a/src/devices/bus/c64/mach5.h b/src/devices/bus/c64/mach5.h index a49e1bec347..b532c0e253a 100644 --- a/src/devices/bus/c64/mach5.h +++ b/src/devices/bus/c64/mach5.h @@ -26,7 +26,7 @@ class c64_mach5_cartridge_device : public device_t, { public: // construction/destruction - c64_mach5_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_mach5_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/magic_desk.cpp b/src/devices/bus/c64/magic_desk.cpp index 2fe55681966..f1a140a6fe5 100644 --- a/src/devices/bus/c64/magic_desk.cpp +++ b/src/devices/bus/c64/magic_desk.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_MAGIC_DESK, c64_magic_desk_cartridge_device, "c64_magic_d // c64_magic_desk_cartridge_device - constructor //------------------------------------------------- -c64_magic_desk_cartridge_device::c64_magic_desk_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_magic_desk_cartridge_device::c64_magic_desk_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MAGIC_DESK, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/magic_desk.h b/src/devices/bus/c64/magic_desk.h index 75f76dee732..811c521e22e 100644 --- a/src/devices/bus/c64/magic_desk.h +++ b/src/devices/bus/c64/magic_desk.h @@ -27,7 +27,7 @@ class c64_magic_desk_cartridge_device : public device_t, { public: // construction/destruction - c64_magic_desk_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_magic_desk_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/magic_formel.cpp b/src/devices/bus/c64/magic_formel.cpp index 1e6c38d1685..5409307eb69 100644 --- a/src/devices/bus/c64/magic_formel.cpp +++ b/src/devices/bus/c64/magic_formel.cpp @@ -98,7 +98,7 @@ WRITE_LINE_MEMBER( c64_magic_formel_cartridge_device::pia_cb2_w ) void c64_magic_formel_cartridge_device::device_add_mconfig(machine_config &config) { - PIA6821(config, m_pia, 0); + PIA6821(config, m_pia); m_pia->writepa_handler().set(FUNC(c64_magic_formel_cartridge_device::pia_pa_w)); m_pia->writepb_handler().set(FUNC(c64_magic_formel_cartridge_device::pia_pb_w)); m_pia->cb2_handler().set(FUNC(c64_magic_formel_cartridge_device::pia_cb2_w)); @@ -153,7 +153,7 @@ ioport_constructor c64_magic_formel_cartridge_device::device_input_ports() const // c64_magic_formel_cartridge_device - constructor //------------------------------------------------- -c64_magic_formel_cartridge_device::c64_magic_formel_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_magic_formel_cartridge_device::c64_magic_formel_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MAGIC_FORMEL, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_pia(*this, MC6821_TAG), diff --git a/src/devices/bus/c64/magic_formel.h b/src/devices/bus/c64/magic_formel.h index ab16d4a0e34..aa6e35116b2 100644 --- a/src/devices/bus/c64/magic_formel.h +++ b/src/devices/bus/c64/magic_formel.h @@ -27,7 +27,7 @@ class c64_magic_formel_cartridge_device : public device_t, { public: // construction/destruction - c64_magic_formel_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_magic_formel_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER( freeze ); diff --git a/src/devices/bus/c64/magic_voice.cpp b/src/devices/bus/c64/magic_voice.cpp index faac3bc0a33..f6752526d69 100644 --- a/src/devices/bus/c64/magic_voice.cpp +++ b/src/devices/bus/c64/magic_voice.cpp @@ -221,7 +221,7 @@ WRITE_LINE_MEMBER( c64_magic_voice_cartridge_device::apd_w ) void c64_magic_voice_cartridge_device::device_add_mconfig(machine_config &config) { - TPI6525(config, m_tpi, 0); + TPI6525(config, m_tpi); m_tpi->out_irq_cb().set(FUNC(c64_magic_voice_cartridge_device::tpi_irq_w)); m_tpi->in_pa_cb().set(FUNC(c64_magic_voice_cartridge_device::tpi_pa_r)); m_tpi->out_pa_cb().set(FUNC(c64_magic_voice_cartridge_device::tpi_pa_w)); @@ -230,7 +230,7 @@ void c64_magic_voice_cartridge_device::device_add_mconfig(machine_config &config m_tpi->out_ca_cb().set(FUNC(c64_magic_voice_cartridge_device::tpi_ca_w)); m_tpi->out_cb_cb().set(FUNC(c64_magic_voice_cartridge_device::tpi_cb_w)); - CD40105(config, m_fifo, 0); + CD40105(config, m_fifo); m_fifo->in_ready_cb().set(m_tpi, FUNC(tpi6525_device::i3_w)); SPEAKER(config, "mono").front_center(); @@ -255,7 +255,7 @@ void c64_magic_voice_cartridge_device::device_add_mconfig(machine_config &config // c64_magic_voice_cartridge_device - constructor //------------------------------------------------- -c64_magic_voice_cartridge_device::c64_magic_voice_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_magic_voice_cartridge_device::c64_magic_voice_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MAGIC_VOICE, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_vslsi(*this, T6721A_TAG), diff --git a/src/devices/bus/c64/magic_voice.h b/src/devices/bus/c64/magic_voice.h index f6c4a4d138e..b55008f9614 100644 --- a/src/devices/bus/c64/magic_voice.h +++ b/src/devices/bus/c64/magic_voice.h @@ -29,7 +29,7 @@ class c64_magic_voice_cartridge_device : public device_t, { public: // construction/destruction - c64_magic_voice_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_magic_voice_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/midi_maplin.cpp b/src/devices/bus/c64/midi_maplin.cpp index adc8556a7bd..ae0a7d3f286 100644 --- a/src/devices/bus/c64/midi_maplin.cpp +++ b/src/devices/bus/c64/midi_maplin.cpp @@ -46,7 +46,7 @@ WRITE_LINE_MEMBER( c64_maplin_midi_cartridge_device::write_acia_clock ) void c64_maplin_midi_cartridge_device::device_add_mconfig(machine_config &config) { - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("mdout", FUNC(midi_port_device::write_txd)); m_acia->irq_handler().set(FUNC(c64_maplin_midi_cartridge_device::acia_irq_w)); @@ -54,7 +54,7 @@ void c64_maplin_midi_cartridge_device::device_add_mconfig(machine_config &config MIDI_PORT(config, "mdout", midiout_slot, "midiout"); - clock_device &acia_clock(CLOCK(config, "acia_clock", 31250*16)); + clock_device &acia_clock(CLOCK(config, "acia_clock", XTAL::u(31250*16))); acia_clock.signal_handler().set(FUNC(c64_maplin_midi_cartridge_device::write_acia_clock)); } @@ -68,7 +68,7 @@ void c64_maplin_midi_cartridge_device::device_add_mconfig(machine_config &config // c64_maplin_midi_cartridge_device - constructor //------------------------------------------------- -c64_maplin_midi_cartridge_device::c64_maplin_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_maplin_midi_cartridge_device::c64_maplin_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MIDI_MAPLIN, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_acia(*this, MC6850_TAG) diff --git a/src/devices/bus/c64/midi_maplin.h b/src/devices/bus/c64/midi_maplin.h index d0798d9217f..18e40b9207a 100644 --- a/src/devices/bus/c64/midi_maplin.h +++ b/src/devices/bus/c64/midi_maplin.h @@ -26,7 +26,7 @@ class c64_maplin_midi_cartridge_device : public device_t, public device_c64_expa { public: // construction/destruction - c64_maplin_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_maplin_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/midi_namesoft.cpp b/src/devices/bus/c64/midi_namesoft.cpp index d4e7c8b59ac..4aef9cf522b 100644 --- a/src/devices/bus/c64/midi_namesoft.cpp +++ b/src/devices/bus/c64/midi_namesoft.cpp @@ -46,7 +46,7 @@ WRITE_LINE_MEMBER( c64_namesoft_midi_cartridge_device::write_acia_clock ) void c64_namesoft_midi_cartridge_device::device_add_mconfig(machine_config &config) { - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("mdout", FUNC(midi_port_device::write_txd)); m_acia->irq_handler().set(FUNC(c64_namesoft_midi_cartridge_device::acia_irq_w)); @@ -54,7 +54,7 @@ void c64_namesoft_midi_cartridge_device::device_add_mconfig(machine_config &conf MIDI_PORT(config, "mdout", midiout_slot, "midiout"); - clock_device &acia_clock(CLOCK(config, "acia_clock", 31250*16)); + clock_device &acia_clock(CLOCK(config, "acia_clock", XTAL::u(31250*16))); acia_clock.signal_handler().set(FUNC(c64_namesoft_midi_cartridge_device::write_acia_clock)); } @@ -68,7 +68,7 @@ void c64_namesoft_midi_cartridge_device::device_add_mconfig(machine_config &conf // c64_namesoft_midi_cartridge_device - constructor //------------------------------------------------- -c64_namesoft_midi_cartridge_device::c64_namesoft_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_namesoft_midi_cartridge_device::c64_namesoft_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MIDI_NAMESOFT, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_acia(*this, MC6850_TAG) diff --git a/src/devices/bus/c64/midi_namesoft.h b/src/devices/bus/c64/midi_namesoft.h index d2183d271d0..3d66ff6b433 100644 --- a/src/devices/bus/c64/midi_namesoft.h +++ b/src/devices/bus/c64/midi_namesoft.h @@ -26,7 +26,7 @@ class c64_namesoft_midi_cartridge_device : public device_t, public device_c64_ex { public: // construction/destruction - c64_namesoft_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_namesoft_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/midi_passport.cpp b/src/devices/bus/c64/midi_passport.cpp index 05a3fbb1a36..1e98e2e9417 100644 --- a/src/devices/bus/c64/midi_passport.cpp +++ b/src/devices/bus/c64/midi_passport.cpp @@ -60,19 +60,19 @@ WRITE_LINE_MEMBER( c64_passport_midi_cartridge_device::write_acia_clock ) void c64_passport_midi_cartridge_device::device_add_mconfig(machine_config &config) { - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("mdout", FUNC(midi_port_device::write_txd)); m_acia->irq_handler().set(FUNC(c64_passport_midi_cartridge_device::acia_irq_w)); - PTM6840(config, m_ptm, 1021800); - m_ptm->set_external_clocks(1021800.0f, 1021800.0f, 1021800.0f); + PTM6840(config, m_ptm, XTAL::u(1021800)); + m_ptm->set_external_clocks(XTAL::u(1021800), XTAL::u(1021800), XTAL::u(1021800)); m_ptm->irq_callback().set(FUNC(c64_passport_midi_cartridge_device::ptm_irq_w)); MIDI_PORT(config, "mdin", midiin_slot, "midiin").rxd_handler().set(m_acia, FUNC(acia6850_device::write_rxd)); MIDI_PORT(config, "mdout", midiout_slot, "midiout"); - clock_device &acia_clock(CLOCK(config, "acia_clock", 31250*16)); // TODO: work out if the clock should come from the 6840 + clock_device &acia_clock(CLOCK(config, "acia_clock", XTAL::u(31250*16))); // TODO: work out if the clock should come from the 6840 acia_clock.signal_handler().set(FUNC(c64_passport_midi_cartridge_device::write_acia_clock)); } @@ -86,7 +86,7 @@ void c64_passport_midi_cartridge_device::device_add_mconfig(machine_config &conf // c64_passport_midi_cartridge_device - constructor //------------------------------------------------- -c64_passport_midi_cartridge_device::c64_passport_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_passport_midi_cartridge_device::c64_passport_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MIDI_PASSPORT, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_acia(*this, MC6850_TAG), diff --git a/src/devices/bus/c64/midi_passport.h b/src/devices/bus/c64/midi_passport.h index d6b4cf16eb7..77b4ccc9538 100644 --- a/src/devices/bus/c64/midi_passport.h +++ b/src/devices/bus/c64/midi_passport.h @@ -27,7 +27,7 @@ class c64_passport_midi_cartridge_device : public device_t, public device_c64_ex { public: // construction/destruction - c64_passport_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_passport_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/midi_sci.cpp b/src/devices/bus/c64/midi_sci.cpp index 14309ee5e7c..62d9fed4fd3 100644 --- a/src/devices/bus/c64/midi_sci.cpp +++ b/src/devices/bus/c64/midi_sci.cpp @@ -46,7 +46,7 @@ WRITE_LINE_MEMBER( c64_sequential_midi_cartridge_device::write_acia_clock ) void c64_sequential_midi_cartridge_device::device_add_mconfig(machine_config &config) { - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("mdout", FUNC(midi_port_device::write_txd)); m_acia->irq_handler().set(FUNC(c64_sequential_midi_cartridge_device::acia_irq_w)); @@ -54,7 +54,7 @@ void c64_sequential_midi_cartridge_device::device_add_mconfig(machine_config &co MIDI_PORT(config, "mdout", midiout_slot, "midiout"); - clock_device &acia_clock(CLOCK(config, "acia_clock", 31250*16)); + clock_device &acia_clock(CLOCK(config, "acia_clock", XTAL::u(31250*16))); acia_clock.signal_handler().set(FUNC(c64_sequential_midi_cartridge_device::write_acia_clock)); } @@ -68,7 +68,7 @@ void c64_sequential_midi_cartridge_device::device_add_mconfig(machine_config &co // c64_sequential_midi_cartridge_device - constructor //------------------------------------------------- -c64_sequential_midi_cartridge_device::c64_sequential_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_sequential_midi_cartridge_device::c64_sequential_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MIDI_SCI, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_acia(*this, MC6850_TAG) diff --git a/src/devices/bus/c64/midi_sci.h b/src/devices/bus/c64/midi_sci.h index 5ab0d8d45db..66a8623a489 100644 --- a/src/devices/bus/c64/midi_sci.h +++ b/src/devices/bus/c64/midi_sci.h @@ -26,7 +26,7 @@ class c64_sequential_midi_cartridge_device : public device_t, public device_c64_ { public: // construction/destruction - c64_sequential_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_sequential_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/midi_siel.cpp b/src/devices/bus/c64/midi_siel.cpp index eea7a4b333d..d2af8c262a5 100644 --- a/src/devices/bus/c64/midi_siel.cpp +++ b/src/devices/bus/c64/midi_siel.cpp @@ -46,7 +46,7 @@ WRITE_LINE_MEMBER( c64_siel_midi_cartridge_device::write_acia_clock ) void c64_siel_midi_cartridge_device::device_add_mconfig(machine_config &config) { - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("mdout", FUNC(midi_port_device::write_txd)); m_acia->irq_handler().set(FUNC(c64_siel_midi_cartridge_device::acia_irq_w)); @@ -54,7 +54,7 @@ void c64_siel_midi_cartridge_device::device_add_mconfig(machine_config &config) MIDI_PORT(config, "mdout", midiout_slot, "midiout"); - clock_device &acia_clock(CLOCK(config, "acia_clock", 31250*16)); + clock_device &acia_clock(CLOCK(config, "acia_clock", XTAL::u(31250*16))); acia_clock.signal_handler().set(FUNC(c64_siel_midi_cartridge_device::write_acia_clock)); } @@ -68,7 +68,7 @@ void c64_siel_midi_cartridge_device::device_add_mconfig(machine_config &config) // c64_siel_midi_cartridge_device - constructor //------------------------------------------------- -c64_siel_midi_cartridge_device::c64_siel_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_siel_midi_cartridge_device::c64_siel_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MIDI_SIEL, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_acia(*this, MC6850_TAG) diff --git a/src/devices/bus/c64/midi_siel.h b/src/devices/bus/c64/midi_siel.h index 412d1a224b7..5a84c250e66 100644 --- a/src/devices/bus/c64/midi_siel.h +++ b/src/devices/bus/c64/midi_siel.h @@ -26,7 +26,7 @@ class c64_siel_midi_cartridge_device : public device_t, public device_c64_expans { public: // construction/destruction - c64_siel_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_siel_midi_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/mikro_assembler.cpp b/src/devices/bus/c64/mikro_assembler.cpp index d6c02be7681..394cf04afcb 100644 --- a/src/devices/bus/c64/mikro_assembler.cpp +++ b/src/devices/bus/c64/mikro_assembler.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_MIKRO_ASSEMBLER, c64_mikro_assembler_cartridge_device, "c // c64_mikro_assembler_cartridge_device - constructor //------------------------------------------------- -c64_mikro_assembler_cartridge_device::c64_mikro_assembler_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_mikro_assembler_cartridge_device::c64_mikro_assembler_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MIKRO_ASSEMBLER, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/mikro_assembler.h b/src/devices/bus/c64/mikro_assembler.h index 754a91385d4..0abf97aabe4 100644 --- a/src/devices/bus/c64/mikro_assembler.h +++ b/src/devices/bus/c64/mikro_assembler.h @@ -27,7 +27,7 @@ class c64_mikro_assembler_cartridge_device : public device_t, { public: // construction/destruction - c64_mikro_assembler_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_mikro_assembler_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/multiscreen.cpp b/src/devices/bus/c64/multiscreen.cpp index 890c1a35799..63b6bca4d80 100644 --- a/src/devices/bus/c64/multiscreen.cpp +++ b/src/devices/bus/c64/multiscreen.cpp @@ -117,8 +117,8 @@ void c64_multiscreen_cartridge_device::device_add_mconfig(machine_config &config m6802_cpu_device &cpu(M6802(config, MC6802P_TAG, XTAL(4'000'000))); cpu.set_addrmap(AS_PROGRAM, &c64_multiscreen_cartridge_device::multiscreen_mem); - PIA6821(config, MC6821P_0_TAG, 0); - PIA6821(config, MC6821P_1_TAG, 0); + PIA6821(config, MC6821P_0_TAG); + PIA6821(config, MC6821P_1_TAG); } @@ -130,7 +130,7 @@ void c64_multiscreen_cartridge_device::device_add_mconfig(machine_config &config // c64_multiscreen_cartridge_device - constructor //------------------------------------------------- -c64_multiscreen_cartridge_device::c64_multiscreen_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_multiscreen_cartridge_device::c64_multiscreen_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MULTISCREEN, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) { diff --git a/src/devices/bus/c64/multiscreen.h b/src/devices/bus/c64/multiscreen.h index 619154d18c5..edc07af326a 100644 --- a/src/devices/bus/c64/multiscreen.h +++ b/src/devices/bus/c64/multiscreen.h @@ -29,7 +29,7 @@ class c64_multiscreen_cartridge_device : public device_t, { public: // construction/destruction - c64_multiscreen_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_multiscreen_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/music64.cpp b/src/devices/bus/c64/music64.cpp index 28fa6fc1539..1f8724e64d7 100644 --- a/src/devices/bus/c64/music64.cpp +++ b/src/devices/bus/c64/music64.cpp @@ -141,7 +141,7 @@ ioport_constructor c64_music64_cartridge_device::device_input_ports() const // c64_music64_cartridge_device - constructor //------------------------------------------------- -c64_music64_cartridge_device::c64_music64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_music64_cartridge_device::c64_music64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_MUSIC64, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_exp(*this, "exp"), diff --git a/src/devices/bus/c64/music64.h b/src/devices/bus/c64/music64.h index cf494c481b8..7b583e983aa 100644 --- a/src/devices/bus/c64/music64.h +++ b/src/devices/bus/c64/music64.h @@ -26,7 +26,7 @@ class c64_music64_cartridge_device : public device_t, { public: // construction/destruction - c64_music64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_music64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/neoram.cpp b/src/devices/bus/c64/neoram.cpp index c0f292da161..4d70792f337 100644 --- a/src/devices/bus/c64/neoram.cpp +++ b/src/devices/bus/c64/neoram.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_NEORAM, c64_neoram_cartridge_device, "c64_neoram", "C64 N // c64_neoram_cartridge_device - constructor //------------------------------------------------- -c64_neoram_cartridge_device::c64_neoram_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_neoram_cartridge_device::c64_neoram_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_NEORAM, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/bus/c64/neoram.h b/src/devices/bus/c64/neoram.h index d54e8e18cc4..63b4149c004 100644 --- a/src/devices/bus/c64/neoram.h +++ b/src/devices/bus/c64/neoram.h @@ -28,7 +28,7 @@ class c64_neoram_cartridge_device : public device_t, { public: // construction/destruction - c64_neoram_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_neoram_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/ocean.cpp b/src/devices/bus/c64/ocean.cpp index 3e134d9449b..dacb5513608 100644 --- a/src/devices/bus/c64/ocean.cpp +++ b/src/devices/bus/c64/ocean.cpp @@ -49,7 +49,7 @@ DEFINE_DEVICE_TYPE(C64_OCEAN, c64_ocean_cartridge_device, "c64_ocean", "C64 Ocea // c64_ocean_cartridge_device - constructor //------------------------------------------------- -c64_ocean_cartridge_device::c64_ocean_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_ocean_cartridge_device::c64_ocean_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_OCEAN, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/ocean.h b/src/devices/bus/c64/ocean.h index 9a78f5e21f9..752fe0eb087 100644 --- a/src/devices/bus/c64/ocean.h +++ b/src/devices/bus/c64/ocean.h @@ -27,7 +27,7 @@ class c64_ocean_cartridge_device : public device_t, { public: // construction/destruction - c64_ocean_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_ocean_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/pagefox.cpp b/src/devices/bus/c64/pagefox.cpp index e33bb4d3d7b..67580e00c2d 100644 --- a/src/devices/bus/c64/pagefox.cpp +++ b/src/devices/bus/c64/pagefox.cpp @@ -49,7 +49,7 @@ DEFINE_DEVICE_TYPE(C64_PAGEFOX, c64_pagefox_cartridge_device, "c64_pagefox", "C6 // c64_pagefox_cartridge_device - constructor //------------------------------------------------- -c64_pagefox_cartridge_device::c64_pagefox_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_pagefox_cartridge_device::c64_pagefox_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_PAGEFOX, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_ram(*this, "ram", 0x8000, ENDIANNESS_LITTLE), diff --git a/src/devices/bus/c64/pagefox.h b/src/devices/bus/c64/pagefox.h index b0295eb9d0d..f19f7d71653 100644 --- a/src/devices/bus/c64/pagefox.h +++ b/src/devices/bus/c64/pagefox.h @@ -27,7 +27,7 @@ class c64_pagefox_cartridge_device : public device_t, { public: // construction/destruction - c64_pagefox_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_pagefox_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/partner.cpp b/src/devices/bus/c64/partner.cpp index b77cf610d17..851224479b8 100644 --- a/src/devices/bus/c64/partner.cpp +++ b/src/devices/bus/c64/partner.cpp @@ -77,7 +77,7 @@ ioport_constructor c64_partner_cartridge_device::device_input_ports() const // c64_partner_cartridge_device - constructor //------------------------------------------------- -c64_partner_cartridge_device::c64_partner_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_partner_cartridge_device::c64_partner_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_PARTNER, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_ram(*this, "ram", 0x2000, ENDIANNESS_LITTLE), diff --git a/src/devices/bus/c64/partner.h b/src/devices/bus/c64/partner.h index 4dd71542571..be3aa3925b6 100644 --- a/src/devices/bus/c64/partner.h +++ b/src/devices/bus/c64/partner.h @@ -26,7 +26,7 @@ class c64_partner_cartridge_device : public device_t, { public: // construction/destruction - c64_partner_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_partner_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/prophet64.cpp b/src/devices/bus/c64/prophet64.cpp index ea5e16a3000..d4f2d4ff9cc 100644 --- a/src/devices/bus/c64/prophet64.cpp +++ b/src/devices/bus/c64/prophet64.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_PROPHET64, c64_prophet64_cartridge_device, "c64_prophet64 // c64_prophet64_cartridge_device - constructor //------------------------------------------------- -c64_prophet64_cartridge_device::c64_prophet64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_prophet64_cartridge_device::c64_prophet64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_PROPHET64, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/prophet64.h b/src/devices/bus/c64/prophet64.h index f58ba30b7b7..fc26e74ebab 100644 --- a/src/devices/bus/c64/prophet64.h +++ b/src/devices/bus/c64/prophet64.h @@ -26,7 +26,7 @@ class c64_prophet64_cartridge_device : public device_t, { public: // construction/destruction - c64_prophet64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_prophet64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/ps64.cpp b/src/devices/bus/c64/ps64.cpp index c14008b2c08..fcfd3f02422 100644 --- a/src/devices/bus/c64/ps64.cpp +++ b/src/devices/bus/c64/ps64.cpp @@ -67,7 +67,7 @@ DEFINE_DEVICE_TYPE(C64_PS64, c64_ps64_cartridge_device, "c64_ps64", "C64 PS-64") void c64_ps64_cartridge_device::device_add_mconfig(machine_config &config) { //SPEAKER(config, "speaker").front_center(); - //VOTRAX_SC02(config, SSI263_TAG, 2000000).add_route(ALL_OUTPUTS, "mono", 1.00); + //VOTRAX_SC02(config, SSI263_TAG, XTAL::u(2000000)).add_route(ALL_OUTPUTS, "mono", 1.00); } @@ -80,7 +80,7 @@ void c64_ps64_cartridge_device::device_add_mconfig(machine_config &config) // c64_ps64_cartridge_device - constructor //------------------------------------------------- -c64_ps64_cartridge_device::c64_ps64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_ps64_cartridge_device::c64_ps64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_PS64, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/ps64.h b/src/devices/bus/c64/ps64.h index 69a9c5b0110..1cb0d113031 100644 --- a/src/devices/bus/c64/ps64.h +++ b/src/devices/bus/c64/ps64.h @@ -28,7 +28,7 @@ class c64_ps64_cartridge_device : public device_t, { public: // construction/destruction - c64_ps64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_ps64_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/reu.cpp b/src/devices/bus/c64/reu.cpp index 0d24a1967fa..09c0cf82bba 100644 --- a/src/devices/bus/c64/reu.cpp +++ b/src/devices/bus/c64/reu.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(C64_REU1764, c64_reu1764_cartridge_device, "c64_1764reu", "17 void c64_reu_cartridge_device::device_add_mconfig(machine_config &config) { - MOS8726(config, m_dmac, 1000000); // dummy clock + MOS8726(config, m_dmac, XTAL::u(1000000)); // dummy clock GENERIC_SOCKET(config, m_eprom, generic_linear_slot, nullptr, "bin,rom"); } @@ -48,7 +48,7 @@ void c64_reu_cartridge_device::device_add_mconfig(machine_config &config) // c64_reu_cartridge_device - constructor //------------------------------------------------- -c64_reu_cartridge_device::c64_reu_cartridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant, int jp1, size_t ram_size) : +c64_reu_cartridge_device::c64_reu_cartridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant, int jp1, size_t ram_size) : device_t(mconfig, type, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_dmac(*this, MOS8726R1_TAG), @@ -60,13 +60,13 @@ c64_reu_cartridge_device::c64_reu_cartridge_device(const machine_config &mconfig { } -c64_reu1700_cartridge_device::c64_reu1700_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c64_reu1700_cartridge_device::c64_reu1700_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c64_reu_cartridge_device(mconfig, C64_REU1700, tag, owner, clock, TYPE_1700, 0, 128 * 1024) { } -c64_reu1750_cartridge_device::c64_reu1750_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c64_reu1750_cartridge_device::c64_reu1750_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c64_reu_cartridge_device(mconfig, C64_REU1750, tag, owner, clock, TYPE_1750, 1, 256 * 1024) { } -c64_reu1764_cartridge_device::c64_reu1764_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c64_reu1764_cartridge_device::c64_reu1764_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c64_reu_cartridge_device(mconfig, C64_REU1764, tag, owner, clock, TYPE_1764, 1, 512 * 1024) { } diff --git a/src/devices/bus/c64/reu.h b/src/devices/bus/c64/reu.h index eaa662f38a1..e2197b615d9 100644 --- a/src/devices/bus/c64/reu.h +++ b/src/devices/bus/c64/reu.h @@ -37,7 +37,7 @@ protected: }; // construction/destruction - c64_reu_cartridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant, int jp1, size_t ram_size); + c64_reu_cartridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant, int jp1, size_t ram_size); // device-level overrides virtual void device_start() override; @@ -66,7 +66,7 @@ class c64_reu1700_cartridge_device : public c64_reu_cartridge_device { public: // construction/destruction - c64_reu1700_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_reu1700_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -76,7 +76,7 @@ class c64_reu1750_cartridge_device : public c64_reu_cartridge_device { public: // construction/destruction - c64_reu1750_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_reu1750_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> c64_reu1700_cartridge_device @@ -85,7 +85,7 @@ class c64_reu1764_cartridge_device : public c64_reu_cartridge_device { public: // construction/destruction - c64_reu1764_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_reu1764_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/c64/rex.cpp b/src/devices/bus/c64/rex.cpp index 97fecd740af..3932cd419a2 100644 --- a/src/devices/bus/c64/rex.cpp +++ b/src/devices/bus/c64/rex.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_REX, c64_rex_cartridge_device, "c64_rex", "C64 Rex cartri // c64_rex_cartridge_device - constructor //------------------------------------------------- -c64_rex_cartridge_device::c64_rex_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_rex_cartridge_device::c64_rex_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_REX, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/rex.h b/src/devices/bus/c64/rex.h index cc0cccb52da..f7ab9abbe4b 100644 --- a/src/devices/bus/c64/rex.h +++ b/src/devices/bus/c64/rex.h @@ -27,7 +27,7 @@ class c64_rex_cartridge_device : public device_t, { public: // construction/destruction - c64_rex_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_rex_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/rex_ep256.cpp b/src/devices/bus/c64/rex_ep256.cpp index c482e4b2589..2868e1430aa 100644 --- a/src/devices/bus/c64/rex_ep256.cpp +++ b/src/devices/bus/c64/rex_ep256.cpp @@ -38,7 +38,7 @@ void c64_rex_ep256_cartridge_device::device_add_mconfig(machine_config &config) // c64_rex_ep256_cartridge_device - constructor //------------------------------------------------- -c64_rex_ep256_cartridge_device::c64_rex_ep256_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_rex_ep256_cartridge_device::c64_rex_ep256_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_REX_EP256, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_eproms(*this, "rom%u", 1U) diff --git a/src/devices/bus/c64/rex_ep256.h b/src/devices/bus/c64/rex_ep256.h index e06a2c71d17..b9c4d53808d 100644 --- a/src/devices/bus/c64/rex_ep256.h +++ b/src/devices/bus/c64/rex_ep256.h @@ -29,7 +29,7 @@ class c64_rex_ep256_cartridge_device : public device_t, { public: // construction/destruction - c64_rex_ep256_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_rex_ep256_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/ross.cpp b/src/devices/bus/c64/ross.cpp index e8703a33bcc..9e0e9c31580 100644 --- a/src/devices/bus/c64/ross.cpp +++ b/src/devices/bus/c64/ross.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_ROSS, c64_ross_cartridge_device, "c64_ross", "C64 Ross ca // c64_ross_cartridge_device - constructor //------------------------------------------------- -c64_ross_cartridge_device::c64_ross_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_ross_cartridge_device::c64_ross_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_ROSS, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) { diff --git a/src/devices/bus/c64/ross.h b/src/devices/bus/c64/ross.h index 97f2698fb6c..4374f044b2f 100644 --- a/src/devices/bus/c64/ross.h +++ b/src/devices/bus/c64/ross.h @@ -27,7 +27,7 @@ class c64_ross_cartridge_device : public device_t, { public: // construction/destruction - c64_ross_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_ross_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/sfx_sound_expander.cpp b/src/devices/bus/c64/sfx_sound_expander.cpp index a85b93bccbf..e392e5f6aac 100644 --- a/src/devices/bus/c64/sfx_sound_expander.cpp +++ b/src/devices/bus/c64/sfx_sound_expander.cpp @@ -173,7 +173,7 @@ inline offs_t c64_sfx_sound_expander_cartridge_device::get_offset(offs_t offset, // c64_sfx_sound_expander_cartridge_device - constructor //------------------------------------------------- -c64_sfx_sound_expander_cartridge_device::c64_sfx_sound_expander_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_sfx_sound_expander_cartridge_device::c64_sfx_sound_expander_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_SFX_SOUND_EXPANDER, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_opl(*this, YM3526_TAG), diff --git a/src/devices/bus/c64/sfx_sound_expander.h b/src/devices/bus/c64/sfx_sound_expander.h index 52e006ce686..174b4659149 100644 --- a/src/devices/bus/c64/sfx_sound_expander.h +++ b/src/devices/bus/c64/sfx_sound_expander.h @@ -27,7 +27,7 @@ class c64_sfx_sound_expander_cartridge_device : public device_t, { public: // construction/destruction - c64_sfx_sound_expander_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_sfx_sound_expander_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/silverrock.cpp b/src/devices/bus/c64/silverrock.cpp index f52efc569b6..7b411c2020a 100644 --- a/src/devices/bus/c64/silverrock.cpp +++ b/src/devices/bus/c64/silverrock.cpp @@ -60,7 +60,7 @@ DEFINE_DEVICE_TYPE(C64_SILVERROCK, c64_silverrock_cartridge_device, "c64_silverr // c64_silverrock_cartridge_device - constructor //------------------------------------------------- -c64_silverrock_cartridge_device::c64_silverrock_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_silverrock_cartridge_device::c64_silverrock_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_SILVERROCK, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) { diff --git a/src/devices/bus/c64/silverrock.h b/src/devices/bus/c64/silverrock.h index 3d9c4e015f2..e758dc18c1b 100644 --- a/src/devices/bus/c64/silverrock.h +++ b/src/devices/bus/c64/silverrock.h @@ -27,7 +27,7 @@ class c64_silverrock_cartridge_device : public device_t, { public: // construction/destruction - c64_silverrock_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_silverrock_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/simons_basic.cpp b/src/devices/bus/c64/simons_basic.cpp index 246e67b8b56..57e5a8774b5 100644 --- a/src/devices/bus/c64/simons_basic.cpp +++ b/src/devices/bus/c64/simons_basic.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_SIMONS_BASIC, c64_simons_basic_cartridge_device, "c64_sim // c64_simons_basic_cartridge_device - constructor //------------------------------------------------- -c64_simons_basic_cartridge_device::c64_simons_basic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_simons_basic_cartridge_device::c64_simons_basic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_SIMONS_BASIC, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/simons_basic.h b/src/devices/bus/c64/simons_basic.h index 63d2dfb5cb9..88639532062 100644 --- a/src/devices/bus/c64/simons_basic.h +++ b/src/devices/bus/c64/simons_basic.h @@ -27,7 +27,7 @@ class c64_simons_basic_cartridge_device : public device_t, { public: // construction/destruction - c64_simons_basic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_simons_basic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/speakeasy.cpp b/src/devices/bus/c64/speakeasy.cpp index 23caee3488f..1d85625d8b9 100644 --- a/src/devices/bus/c64/speakeasy.cpp +++ b/src/devices/bus/c64/speakeasy.cpp @@ -35,7 +35,7 @@ void c64_speakeasy_cartridge_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "mono").front_center(); - VOTRAX_SC01(config, m_votrax, 720000).add_route(ALL_OUTPUTS, "mono", 0.85); + VOTRAX_SC01(config, m_votrax, XTAL::u(720000)).add_route(ALL_OUTPUTS, "mono", 0.85); } @@ -48,7 +48,7 @@ void c64_speakeasy_cartridge_device::device_add_mconfig(machine_config &config) // c64_speakeasy_cartridge_device - constructor //------------------------------------------------- -c64_speakeasy_cartridge_device::c64_speakeasy_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_speakeasy_cartridge_device::c64_speakeasy_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_SPEAKEASY, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_votrax(*this, SC01A_TAG) diff --git a/src/devices/bus/c64/speakeasy.h b/src/devices/bus/c64/speakeasy.h index 0816e4caa2e..bf16973502f 100644 --- a/src/devices/bus/c64/speakeasy.h +++ b/src/devices/bus/c64/speakeasy.h @@ -26,7 +26,7 @@ class c64_speakeasy_cartridge_device : public device_t, public device_c64_expans { public: // construction/destruction - c64_speakeasy_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_speakeasy_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/stardos.cpp b/src/devices/bus/c64/stardos.cpp index 601ada2778c..c8436020b94 100644 --- a/src/devices/bus/c64/stardos.cpp +++ b/src/devices/bus/c64/stardos.cpp @@ -113,7 +113,7 @@ void c64_stardos_cartridge_device::charge_io2_capacitor() // c64_stardos_cartridge_device - constructor //------------------------------------------------- -c64_stardos_cartridge_device::c64_stardos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_stardos_cartridge_device::c64_stardos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_STARDOS, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_io1_charge(0), diff --git a/src/devices/bus/c64/stardos.h b/src/devices/bus/c64/stardos.h index 9be9f599957..606eb155a2a 100644 --- a/src/devices/bus/c64/stardos.h +++ b/src/devices/bus/c64/stardos.h @@ -28,7 +28,7 @@ class c64_stardos_cartridge_device : public device_t, { public: // construction/destruction - c64_stardos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_stardos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/std.cpp b/src/devices/bus/c64/std.cpp index 127f0bf235c..dd4ed8c2b5c 100644 --- a/src/devices/bus/c64/std.cpp +++ b/src/devices/bus/c64/std.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_STD, c64_standard_cartridge_device, "c64_standard", "C64 // c64_standard_cartridge_device - constructor //------------------------------------------------- -c64_standard_cartridge_device::c64_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_standard_cartridge_device::c64_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_STD, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/std.h b/src/devices/bus/c64/std.h index 391e9ac973f..edb034d2717 100644 --- a/src/devices/bus/c64/std.h +++ b/src/devices/bus/c64/std.h @@ -27,7 +27,7 @@ class c64_standard_cartridge_device : public device_t, { public: // construction/destruction - c64_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/structured_basic.cpp b/src/devices/bus/c64/structured_basic.cpp index e7773c772c0..951b997c38a 100644 --- a/src/devices/bus/c64/structured_basic.cpp +++ b/src/devices/bus/c64/structured_basic.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_STRUCTURED_BASIC, c64_structured_basic_cartridge_device, // c64_structured_basic_cartridge_device - constructor //------------------------------------------------- -c64_structured_basic_cartridge_device::c64_structured_basic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_structured_basic_cartridge_device::c64_structured_basic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_STRUCTURED_BASIC, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/structured_basic.h b/src/devices/bus/c64/structured_basic.h index 44d370cdb3f..3811455996c 100644 --- a/src/devices/bus/c64/structured_basic.h +++ b/src/devices/bus/c64/structured_basic.h @@ -27,7 +27,7 @@ class c64_structured_basic_cartridge_device : public device_t, { public: // construction/destruction - c64_structured_basic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_structured_basic_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/super_explode.cpp b/src/devices/bus/c64/super_explode.cpp index b01e2e25fba..336c0bf4bbe 100644 --- a/src/devices/bus/c64/super_explode.cpp +++ b/src/devices/bus/c64/super_explode.cpp @@ -37,7 +37,7 @@ DEFINE_DEVICE_TYPE(C64_SUPER_EXPLODE, c64_super_explode_cartridge_device, "c64_s // c64_super_explode_cartridge_device - constructor //------------------------------------------------- -c64_super_explode_cartridge_device::c64_super_explode_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_super_explode_cartridge_device::c64_super_explode_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_SUPER_EXPLODE, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0), m_exrom_timer(nullptr) { diff --git a/src/devices/bus/c64/super_explode.h b/src/devices/bus/c64/super_explode.h index b2cedd35c55..37c763ab194 100644 --- a/src/devices/bus/c64/super_explode.h +++ b/src/devices/bus/c64/super_explode.h @@ -27,7 +27,7 @@ class c64_super_explode_cartridge_device : public device_t, { public: // construction/destruction - c64_super_explode_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_super_explode_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/super_games.cpp b/src/devices/bus/c64/super_games.cpp index 610861c360e..f10f5e7b740 100644 --- a/src/devices/bus/c64/super_games.cpp +++ b/src/devices/bus/c64/super_games.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_SUPER_GAMES, c64_super_games_cartridge_device, "c64_super // c64_super_games_cartridge_device - constructor //------------------------------------------------- -c64_super_games_cartridge_device::c64_super_games_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_super_games_cartridge_device::c64_super_games_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_SUPER_GAMES, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/super_games.h b/src/devices/bus/c64/super_games.h index 11e4b44046a..eda47dcc195 100644 --- a/src/devices/bus/c64/super_games.h +++ b/src/devices/bus/c64/super_games.h @@ -27,7 +27,7 @@ class c64_super_games_cartridge_device : public device_t, { public: // construction/destruction - c64_super_games_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_super_games_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/supercpu.cpp b/src/devices/bus/c64/supercpu.cpp index e0fe2e2a1ea..c9aa032dfdd 100644 --- a/src/devices/bus/c64/supercpu.cpp +++ b/src/devices/bus/c64/supercpu.cpp @@ -63,7 +63,7 @@ void c64_supercpu_device::c64_supercpu_map(address_map &map) void c64_supercpu_device::device_add_mconfig(machine_config &config) { - G65816(config, m_maincpu, 1000000); + G65816(config, m_maincpu, XTAL::u(1000000)); m_maincpu->set_addrmap(AS_PROGRAM, &c64_supercpu_device::c64_supercpu_map); C64_EXPANSION_SLOT(config, m_exp, DERIVED_CLOCK(1, 1), c64_expansion_cards, nullptr); @@ -111,7 +111,7 @@ ioport_constructor c64_supercpu_device::device_input_ports() const // c64_supercpu_device - constructor //------------------------------------------------- -c64_supercpu_device::c64_supercpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_supercpu_device::c64_supercpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_SUPERCPU, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_maincpu(*this, G65816_TAG), diff --git a/src/devices/bus/c64/supercpu.h b/src/devices/bus/c64/supercpu.h index 73982328c31..ca82826bc37 100644 --- a/src/devices/bus/c64/supercpu.h +++ b/src/devices/bus/c64/supercpu.h @@ -27,7 +27,7 @@ class c64_supercpu_device : public device_t, { public: // construction/destruction - c64_supercpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_supercpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/sw8k.cpp b/src/devices/bus/c64/sw8k.cpp index 2f55b223797..037363364da 100644 --- a/src/devices/bus/c64/sw8k.cpp +++ b/src/devices/bus/c64/sw8k.cpp @@ -72,7 +72,7 @@ ioport_constructor c64_switchable_8k_cartridge_device::device_input_ports() cons // c64_switchable_8k_cartridge_device - constructor //------------------------------------------------- -c64_switchable_8k_cartridge_device::c64_switchable_8k_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_switchable_8k_cartridge_device::c64_switchable_8k_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_SW8K, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_sw(*this, "SW"), m_bank(0) diff --git a/src/devices/bus/c64/sw8k.h b/src/devices/bus/c64/sw8k.h index 186e96792d6..7fae40984f2 100644 --- a/src/devices/bus/c64/sw8k.h +++ b/src/devices/bus/c64/sw8k.h @@ -27,7 +27,7 @@ class c64_switchable_8k_cartridge_device : public device_t, { public: // construction/destruction - c64_switchable_8k_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_switchable_8k_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/swiftlink.cpp b/src/devices/bus/c64/swiftlink.cpp index 3855da85ca3..b89eb1d40e3 100644 --- a/src/devices/bus/c64/swiftlink.cpp +++ b/src/devices/bus/c64/swiftlink.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(C64_SWIFTLINK, c64_swiftlink_cartridge_device, "c64_swiftlink void c64_swiftlink_cartridge_device::device_add_mconfig(machine_config &config) { - MOS6551(config, m_acia, 0); + MOS6551(config, m_acia); m_acia->set_xtal(3.6864_MHz_XTAL); m_acia->irq_handler().set(FUNC(c64_swiftlink_cartridge_device::acia_irq_w)); m_acia->txd_handler().set(RS232_TAG, FUNC(rs232_port_device::write_txd)); @@ -90,7 +90,7 @@ ioport_constructor c64_swiftlink_cartridge_device::device_input_ports() const // c64_swiftlink_cartridge_device - constructor //------------------------------------------------- -c64_swiftlink_cartridge_device::c64_swiftlink_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_swiftlink_cartridge_device::c64_swiftlink_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_SWIFTLINK, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_acia(*this, MOS6551_TAG), diff --git a/src/devices/bus/c64/swiftlink.h b/src/devices/bus/c64/swiftlink.h index 409cfafa33a..63309c6e395 100644 --- a/src/devices/bus/c64/swiftlink.h +++ b/src/devices/bus/c64/swiftlink.h @@ -29,7 +29,7 @@ class c64_swiftlink_cartridge_device : public device_t, { public: // construction/destruction - c64_swiftlink_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_swiftlink_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/system3.cpp b/src/devices/bus/c64/system3.cpp index f02ef692b3b..26aa73719d4 100644 --- a/src/devices/bus/c64/system3.cpp +++ b/src/devices/bus/c64/system3.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_SYSTEM3, c64_system3_cartridge_device, "c64_system3", "C6 // c64_system3_cartridge_device - constructor //------------------------------------------------- -c64_system3_cartridge_device::c64_system3_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_system3_cartridge_device::c64_system3_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_SYSTEM3, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/system3.h b/src/devices/bus/c64/system3.h index 024798fc77e..43c2e151c86 100644 --- a/src/devices/bus/c64/system3.h +++ b/src/devices/bus/c64/system3.h @@ -27,7 +27,7 @@ class c64_system3_cartridge_device : public device_t, { public: // construction/destruction - c64_system3_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_system3_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/tdos.cpp b/src/devices/bus/c64/tdos.cpp index 5f8a9a4c456..47734a24368 100644 --- a/src/devices/bus/c64/tdos.cpp +++ b/src/devices/bus/c64/tdos.cpp @@ -193,7 +193,7 @@ ioport_constructor c64_tdos_cartridge_device::device_input_ports() const // c64_tdos_cartridge_device - constructor //------------------------------------------------- -c64_tdos_cartridge_device::c64_tdos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_tdos_cartridge_device::c64_tdos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_TDOS, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_ssda(*this, MC68A52P_TAG), diff --git a/src/devices/bus/c64/tdos.h b/src/devices/bus/c64/tdos.h index 49c1b07651c..d12420536ba 100644 --- a/src/devices/bus/c64/tdos.h +++ b/src/devices/bus/c64/tdos.h @@ -27,7 +27,7 @@ class c64_tdos_cartridge_device : public device_t, { public: // construction/destruction - c64_tdos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_tdos_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/turbo232.cpp b/src/devices/bus/c64/turbo232.cpp index f9113bed1c5..789a17e0717 100644 --- a/src/devices/bus/c64/turbo232.cpp +++ b/src/devices/bus/c64/turbo232.cpp @@ -39,7 +39,7 @@ DEFINE_DEVICE_TYPE(C64_TURBO232, c64_turbo232_cartridge_device, "c64_turbo232", void c64_turbo232_cartridge_device::device_add_mconfig(machine_config &config) { - MOS6551(config, m_acia, 0); + MOS6551(config, m_acia); m_acia->set_xtal(3.6864_MHz_XTAL); m_acia->irq_handler().set(FUNC(c64_turbo232_cartridge_device::acia_irq_w)); m_acia->txd_handler().set(RS232_TAG, FUNC(rs232_port_device::write_txd)); @@ -89,7 +89,7 @@ ioport_constructor c64_turbo232_cartridge_device::device_input_ports() const // c64_turbo232_cartridge_device - constructor //------------------------------------------------- -c64_turbo232_cartridge_device::c64_turbo232_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_turbo232_cartridge_device::c64_turbo232_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_TURBO232, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_acia(*this, MOS6551_TAG), diff --git a/src/devices/bus/c64/turbo232.h b/src/devices/bus/c64/turbo232.h index 4f5638f88fa..77bf4daa929 100644 --- a/src/devices/bus/c64/turbo232.h +++ b/src/devices/bus/c64/turbo232.h @@ -29,7 +29,7 @@ class c64_turbo232_cartridge_device : public device_t, { public: // construction/destruction - c64_turbo232_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_turbo232_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/vizastar.cpp b/src/devices/bus/c64/vizastar.cpp index 443c232bde7..ab154609b8f 100644 --- a/src/devices/bus/c64/vizastar.cpp +++ b/src/devices/bus/c64/vizastar.cpp @@ -59,7 +59,7 @@ DEFINE_DEVICE_TYPE(C64_VIZASTAR, c64_vizastar_cartridge_device, "c64_vizastar", // c64_vizastar_cartridge_device - constructor //------------------------------------------------- -c64_vizastar_cartridge_device::c64_vizastar_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_vizastar_cartridge_device::c64_vizastar_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_VIZASTAR, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/vizastar.h b/src/devices/bus/c64/vizastar.h index 26ec63cd46b..b1d98340aee 100644 --- a/src/devices/bus/c64/vizastar.h +++ b/src/devices/bus/c64/vizastar.h @@ -27,7 +27,7 @@ class c64_vizastar_cartridge_device : public device_t, { public: // construction/destruction - c64_vizastar_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_vizastar_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/vw64.cpp b/src/devices/bus/c64/vw64.cpp index 81a56e478b8..521b397e1a9 100644 --- a/src/devices/bus/c64/vw64.cpp +++ b/src/devices/bus/c64/vw64.cpp @@ -67,7 +67,7 @@ DEFINE_DEVICE_TYPE(C64_VW64, c64_vizawrite_cartridge_device, "c64_vizawrite", "V // c64_vizawrite_cartridge_device - constructor //------------------------------------------------- -c64_vizawrite_cartridge_device::c64_vizawrite_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_vizawrite_cartridge_device::c64_vizawrite_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_VW64, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_game_timer(nullptr) { diff --git a/src/devices/bus/c64/vw64.h b/src/devices/bus/c64/vw64.h index 00b94969413..4e88e8e5401 100644 --- a/src/devices/bus/c64/vw64.h +++ b/src/devices/bus/c64/vw64.h @@ -27,7 +27,7 @@ class c64_vizawrite_cartridge_device : public device_t, { public: // construction/destruction - c64_vizawrite_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_vizawrite_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/warp_speed.cpp b/src/devices/bus/c64/warp_speed.cpp index ff485c05277..a43f1e78796 100644 --- a/src/devices/bus/c64/warp_speed.cpp +++ b/src/devices/bus/c64/warp_speed.cpp @@ -86,7 +86,7 @@ ioport_constructor c64_warp_speed_cartridge_device::device_input_ports() const // c64_warp_speed_cartridge_device - constructor //------------------------------------------------- -c64_warp_speed_cartridge_device::c64_warp_speed_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_warp_speed_cartridge_device::c64_warp_speed_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_WARP_SPEED, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/warp_speed.h b/src/devices/bus/c64/warp_speed.h index d5c61f50f49..58385a85253 100644 --- a/src/devices/bus/c64/warp_speed.h +++ b/src/devices/bus/c64/warp_speed.h @@ -27,7 +27,7 @@ class c64_warp_speed_cartridge_device : public device_t, { public: // construction/destruction - c64_warp_speed_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_warp_speed_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/c64/westermann.cpp b/src/devices/bus/c64/westermann.cpp index 57a752c8fe2..134fc29f4a9 100644 --- a/src/devices/bus/c64/westermann.cpp +++ b/src/devices/bus/c64/westermann.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_WESTERMANN, c64_westermann_cartridge_device, "c64_westerm // c64_westermann_cartridge_device - constructor //------------------------------------------------- -c64_westermann_cartridge_device::c64_westermann_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_westermann_cartridge_device::c64_westermann_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_WESTERMANN, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/c64/westermann.h b/src/devices/bus/c64/westermann.h index 4b7b2e4389f..4ed2983a529 100644 --- a/src/devices/bus/c64/westermann.h +++ b/src/devices/bus/c64/westermann.h @@ -27,7 +27,7 @@ class c64_westermann_cartridge_device : public device_t, { public: // construction/destruction - c64_westermann_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_westermann_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/xl80.cpp b/src/devices/bus/c64/xl80.cpp index 3f467c7ade3..97053865531 100644 --- a/src/devices/bus/c64/xl80.cpp +++ b/src/devices/bus/c64/xl80.cpp @@ -151,7 +151,7 @@ void c64_xl80_device::device_add_mconfig(machine_config &config) // c64_xl80_device - constructor //------------------------------------------------- -c64_xl80_device::c64_xl80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_xl80_device::c64_xl80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_XL80, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_crtc(*this, HD46505SP_TAG), diff --git a/src/devices/bus/c64/xl80.h b/src/devices/bus/c64/xl80.h index 6d5ca071262..3131696503f 100644 --- a/src/devices/bus/c64/xl80.h +++ b/src/devices/bus/c64/xl80.h @@ -29,7 +29,7 @@ class c64_xl80_device : public device_t, { public: // construction/destruction - c64_xl80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_xl80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/z80videopak.cpp b/src/devices/bus/c64/z80videopak.cpp index fc6c3544b2c..26d7a7daf98 100644 --- a/src/devices/bus/c64/z80videopak.cpp +++ b/src/devices/bus/c64/z80videopak.cpp @@ -124,7 +124,7 @@ void c64_z80videopak_device::device_add_mconfig(machine_config &config) // c64_z80videopak_device - constructor //------------------------------------------------- -c64_z80videopak_device::c64_z80videopak_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +c64_z80videopak_device::c64_z80videopak_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : c64_cpm_cartridge_device(mconfig, C64_Z80VIDEOPAK, tag, owner, clock), m_crtc(*this, HD46505SP_TAG), m_palette(*this, "palette"), diff --git a/src/devices/bus/c64/z80videopak.h b/src/devices/bus/c64/z80videopak.h index 0e563518ca9..496df621094 100644 --- a/src/devices/bus/c64/z80videopak.h +++ b/src/devices/bus/c64/z80videopak.h @@ -28,7 +28,7 @@ class c64_z80videopak_device : public c64_cpm_cartridge_device { public: // construction/destruction - c64_z80videopak_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_z80videopak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/c64/zaxxon.cpp b/src/devices/bus/c64/zaxxon.cpp index d63b05da095..c8f3a2329ff 100644 --- a/src/devices/bus/c64/zaxxon.cpp +++ b/src/devices/bus/c64/zaxxon.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(C64_ZAXXON, c64_zaxxon_cartridge_device, "c64_zaxxon", "C64 Z // c64_zaxxon_cartridge_device - constructor //------------------------------------------------- -c64_zaxxon_cartridge_device::c64_zaxxon_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_zaxxon_cartridge_device::c64_zaxxon_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_ZAXXON, tag, owner, clock), device_c64_expansion_card_interface(mconfig, *this), m_bank(0) diff --git a/src/devices/bus/c64/zaxxon.h b/src/devices/bus/c64/zaxxon.h index 8e47d4caff7..ee33945b798 100644 --- a/src/devices/bus/c64/zaxxon.h +++ b/src/devices/bus/c64/zaxxon.h @@ -27,7 +27,7 @@ class c64_zaxxon_cartridge_device : public device_t, { public: // construction/destruction - c64_zaxxon_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_zaxxon_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cbm2/24k.cpp b/src/devices/bus/cbm2/24k.cpp index c56474c7be9..c5fccaf6d65 100644 --- a/src/devices/bus/cbm2/24k.cpp +++ b/src/devices/bus/cbm2/24k.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(CBM2_24K, cbm2_24k_cartridge_device, "cbm2_24k", "CBM-II 24K // cbm2_24k_cartridge_device - constructor //------------------------------------------------- -cbm2_24k_cartridge_device::cbm2_24k_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm2_24k_cartridge_device::cbm2_24k_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CBM2_24K, tag, owner, clock), device_cbm2_expansion_card_interface(mconfig, *this), m_ram(*this, "ram", 0x6000, ENDIANNESS_LITTLE) diff --git a/src/devices/bus/cbm2/24k.h b/src/devices/bus/cbm2/24k.h index 554ba721444..5450b3edf4d 100644 --- a/src/devices/bus/cbm2/24k.h +++ b/src/devices/bus/cbm2/24k.h @@ -26,7 +26,7 @@ class cbm2_24k_cartridge_device : public device_t, { public: // construction/destruction - cbm2_24k_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm2_24k_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cbm2/exp.cpp b/src/devices/bus/cbm2/exp.cpp index c43e540e181..c3879d2a627 100644 --- a/src/devices/bus/cbm2/exp.cpp +++ b/src/devices/bus/cbm2/exp.cpp @@ -60,7 +60,7 @@ device_cbm2_expansion_card_interface::~device_cbm2_expansion_card_interface() // cbm2_expansion_slot_device - constructor //------------------------------------------------- -cbm2_expansion_slot_device::cbm2_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm2_expansion_slot_device::cbm2_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CBM2_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_cbm2_expansion_card_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/cbm2/exp.h b/src/devices/bus/cbm2/exp.h index 19ed3d01dac..030be49ce06 100644 --- a/src/devices/bus/cbm2/exp.h +++ b/src/devices/bus/cbm2/exp.h @@ -48,7 +48,7 @@ class cbm2_expansion_slot_device : public device_t, public: // construction/destruction template <typename T> - cbm2_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) + cbm2_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts, char const *dflt) : cbm2_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -56,14 +56,14 @@ public: set_default_option(dflt); set_fixed(false); } - cbm2_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + cbm2_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // computer interface uint8_t read(offs_t offset, uint8_t data, int csbank1, int csbank2, int csbank3); void write(offs_t offset, uint8_t data, int csbank1, int csbank2, int csbank3); // cartridge interface - int phi2() { return clock(); } + XTAL phi2() { return clock(); } protected: // device-level overrides diff --git a/src/devices/bus/cbm2/hrg.cpp b/src/devices/bus/cbm2/hrg.cpp index 166e38e76b2..c635070cda0 100644 --- a/src/devices/bus/cbm2/hrg.cpp +++ b/src/devices/bus/cbm2/hrg.cpp @@ -97,7 +97,7 @@ void cbm2_hrg_a_device::device_add_mconfig(machine_config &config) screen.set_refresh_hz(25); PALETTE(config, "palette", palette_device::MONOCHROME); - EF9365(config, m_gdc, 1750000); + EF9365(config, m_gdc, XTAL::u(1750000)); m_gdc->set_screen(SCREEN_TAG); m_gdc->set_addrmap(0, &cbm2_hrg_a_device::hrg_a_map); m_gdc->set_palette_tag("palette"); @@ -114,7 +114,7 @@ void cbm2_hrg_b_device::device_add_mconfig(machine_config &config) screen.set_refresh_hz(50); PALETTE(config, "palette", palette_device::MONOCHROME); - EF9365(config, m_gdc, 1750000); //EF9366 + EF9365(config, m_gdc, XTAL::u(1750000)); //EF9366 m_gdc->set_screen(SCREEN_TAG); m_gdc->set_addrmap(0, &cbm2_hrg_b_device::hrg_b_map); m_gdc->set_palette_tag("palette"); @@ -132,7 +132,7 @@ void cbm2_hrg_b_device::device_add_mconfig(machine_config &config) // cbm2_hrg_device - constructor //------------------------------------------------- -cbm2_hrg_device::cbm2_hrg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +cbm2_hrg_device::cbm2_hrg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_cbm2_expansion_card_interface(mconfig, *this), m_gdc(*this, EF9366_TAG), @@ -140,12 +140,12 @@ cbm2_hrg_device::cbm2_hrg_device(const machine_config &mconfig, device_type type { } -cbm2_hrg_a_device::cbm2_hrg_a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm2_hrg_a_device::cbm2_hrg_a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cbm2_hrg_device(mconfig, CBM2_HRG_A, tag, owner, clock) { } -cbm2_hrg_b_device::cbm2_hrg_b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm2_hrg_b_device::cbm2_hrg_b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cbm2_hrg_device(mconfig, CBM2_HRG_B, tag, owner, clock) { } diff --git a/src/devices/bus/cbm2/hrg.h b/src/devices/bus/cbm2/hrg.h index 3b6a20c94e8..d1ba273ee14 100644 --- a/src/devices/bus/cbm2/hrg.h +++ b/src/devices/bus/cbm2/hrg.h @@ -31,7 +31,7 @@ public: protected: // construction/destruction - cbm2_hrg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cbm2_hrg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -54,7 +54,7 @@ class cbm2_hrg_a_device : public cbm2_hrg_device { public: // construction/destruction - cbm2_hrg_a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm2_hrg_a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -71,7 +71,7 @@ class cbm2_hrg_b_device : public cbm2_hrg_device { public: // construction/destruction - cbm2_hrg_b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm2_hrg_b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/cbm2/std.cpp b/src/devices/bus/cbm2/std.cpp index 51653c72755..5a1a3f51be4 100644 --- a/src/devices/bus/cbm2/std.cpp +++ b/src/devices/bus/cbm2/std.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(CBM2_STD, cbm2_standard_cartridge_device, "cbm2_standard", "C // cbm2_standard_cartridge_device - constructor //------------------------------------------------- -cbm2_standard_cartridge_device::cbm2_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm2_standard_cartridge_device::cbm2_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CBM2_STD, tag, owner, clock), device_cbm2_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/cbm2/std.h b/src/devices/bus/cbm2/std.h index ee941ca580a..209a2237444 100644 --- a/src/devices/bus/cbm2/std.h +++ b/src/devices/bus/cbm2/std.h @@ -26,7 +26,7 @@ class cbm2_standard_cartridge_device : public device_t, { public: // construction/destruction - cbm2_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm2_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cbm2/user.cpp b/src/devices/bus/cbm2/user.cpp index 5dc12567096..d9ca37c7b0f 100644 --- a/src/devices/bus/cbm2/user.cpp +++ b/src/devices/bus/cbm2/user.cpp @@ -43,7 +43,7 @@ device_cbm2_user_port_interface::device_cbm2_user_port_interface(const machine_c // cbm2_user_port_device - constructor //------------------------------------------------- -cbm2_user_port_device::cbm2_user_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm2_user_port_device::cbm2_user_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CBM2_USER_PORT, tag, owner, clock), device_single_card_slot_interface<device_cbm2_user_port_interface>(mconfig, *this), m_write_irq(*this), diff --git a/src/devices/bus/cbm2/user.h b/src/devices/bus/cbm2/user.h index 4a49807118d..7e236149539 100644 --- a/src/devices/bus/cbm2/user.h +++ b/src/devices/bus/cbm2/user.h @@ -73,14 +73,14 @@ public: // construction/destruction template <typename T> cbm2_user_port_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : cbm2_user_port_device(mconfig, tag, owner, 0) + : cbm2_user_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - cbm2_user_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm2_user_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto irq_callback() { return m_write_irq.bind(); } auto sp_callback() { return m_write_sp.bind(); } diff --git a/src/devices/bus/cbmiec/c1526.cpp b/src/devices/bus/cbmiec/c1526.cpp index 45e4540e236..1c6584a6368 100644 --- a/src/devices/bus/cbmiec/c1526.cpp +++ b/src/devices/bus/cbmiec/c1526.cpp @@ -151,7 +151,7 @@ ioport_constructor c4023_device::device_input_ports() const // c1526_device_base - constructor //------------------------------------------------- -c1526_device_base::c1526_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +c1526_device_base::c1526_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) { } @@ -161,7 +161,7 @@ c1526_device_base::c1526_device_base(const machine_config &mconfig, device_type // c1526_device - constructor //------------------------------------------------- -c1526_device::c1526_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c1526_device::c1526_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1526_device_base(mconfig, C1526, tag, owner, clock), device_cbm_iec_interface(mconfig, *this) { @@ -172,7 +172,7 @@ c1526_device::c1526_device(const machine_config &mconfig, const char *tag, devic // c4023_device - constructor //------------------------------------------------- -c4023_device::c4023_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c4023_device::c4023_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1526_device_base(mconfig, C4023, tag, owner, clock), device_ieee488_interface(mconfig, *this) { diff --git a/src/devices/bus/cbmiec/c1526.h b/src/devices/bus/cbmiec/c1526.h index d5042f283f1..40acefc91eb 100644 --- a/src/devices/bus/cbmiec/c1526.h +++ b/src/devices/bus/cbmiec/c1526.h @@ -27,7 +27,7 @@ class c1526_device_base : public device_t { protected: // construction/destruction - c1526_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + c1526_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -42,7 +42,7 @@ class c1526_device : public c1526_device_base, public device_cbm_iec_interface { public: // construction/destruction - c1526_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c1526_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -63,7 +63,7 @@ class c4023_device : public c1526_device_base, public device_ieee488_interface { public: // construction/destruction - c4023_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c4023_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/cbmiec/c1541.cpp b/src/devices/bus/cbmiec/c1541.cpp index a547fc6f208..1120ca40399 100644 --- a/src/devices/bus/cbmiec/c1541.cpp +++ b/src/devices/bus/cbmiec/c1541.cpp @@ -990,7 +990,7 @@ void c1541_device_base::device_add_mconfig(machine_config &config) m_ga->atn_callback().set(FUNC(c1541_device_base::atn_w)); m_ga->byte_callback().set(FUNC(c1541_device_base::byte_w)); - floppy_connector &connector(FLOPPY_CONNECTOR(config, C64H156_TAG":0", 0)); + floppy_connector &connector(FLOPPY_CONNECTOR(config, C64H156_TAG":0")); connector.option_add("525ssqd", ALPS_3255190X); connector.set_default_option("525ssqd"); connector.set_fixed(true); @@ -1025,7 +1025,7 @@ void c1541_prologic_dos_classic_device::device_add_mconfig(machine_config &confi m_maincpu->set_addrmap(AS_PROGRAM, &c1541_prologic_dos_classic_device::c1541pdc_mem); - PIA6821(config, m_pia, 0); + PIA6821(config, m_pia); m_pia->readpb_handler().set(FUNC(c1541_prologic_dos_classic_device::pia_pb_r)); m_pia->writepa_handler().set(FUNC(c1541_prologic_dos_classic_device::pia_pa_w)); m_pia->writepb_handler().set(FUNC(c1541_prologic_dos_classic_device::pia_pb_w)); @@ -1034,7 +1034,7 @@ void c1541_prologic_dos_classic_device::device_add_mconfig(machine_config &confi centronics_device ¢ronics(CENTRONICS(config, CENTRONICS_TAG, centronics_devices, "printer")); centronics.ack_handler().set(MC6821_TAG, FUNC(pia6821_device::ca1_w)); - output_latch_device ¢_data_out(OUTPUT_LATCH(config, "cent_data_out", 0)); + output_latch_device ¢_data_out(OUTPUT_LATCH(config, "cent_data_out")); centronics.set_output_latch(cent_data_out); } @@ -1089,7 +1089,7 @@ inline void c1541_device_base::set_iec_data() // c1541_device_base - constructor //------------------------------------------------- -c1541_device_base::c1541_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +c1541_device_base::c1541_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_cbm_iec_interface(mconfig, *this), device_c64_floppy_parallel_interface(mconfig, *this), @@ -1111,7 +1111,7 @@ c1541_device_base::c1541_device_base(const machine_config &mconfig, device_type // c1540_device - constructor //------------------------------------------------- -c1540_device::c1540_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +c1540_device::c1540_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, C1540, tag, owner, clock) { } @@ -1119,7 +1119,7 @@ c1540_device::c1540_device(const machine_config &mconfig, const char *tag, devic // c1541_device - constructor //------------------------------------------------- -c1541_device::c1541_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +c1541_device::c1541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, C1541, tag, owner, clock) { } @@ -1127,7 +1127,7 @@ c1541_device::c1541_device(const machine_config &mconfig, const char *tag, devic // c1541c_device - constructor //------------------------------------------------- -c1541c_device::c1541c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +c1541c_device::c1541c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, C1541C, tag, owner, clock) { } @@ -1135,7 +1135,7 @@ c1541c_device::c1541c_device(const machine_config &mconfig, const char *tag, dev // c1541ii_device - constructor //------------------------------------------------- -c1541ii_device::c1541ii_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +c1541ii_device::c1541ii_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, C1541II, tag, owner, clock) { } @@ -1143,7 +1143,7 @@ c1541ii_device::c1541ii_device(const machine_config &mconfig, const char *tag, d // sx1541_device - constructor //------------------------------------------------- -sx1541_device::sx1541_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sx1541_device::sx1541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, SX1541, tag, owner, clock) { } @@ -1151,7 +1151,7 @@ sx1541_device::sx1541_device(const machine_config &mconfig, const char *tag, dev // fsd1_device - constructor //------------------------------------------------- -fsd1_device::fsd1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +fsd1_device::fsd1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, FSD1, tag, owner, clock) { } @@ -1159,7 +1159,7 @@ fsd1_device::fsd1_device(const machine_config &mconfig, const char *tag, device_ // fsd2_device - constructor //------------------------------------------------- -fsd2_device::fsd2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +fsd2_device::fsd2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, FSD2, tag, owner, clock) { } @@ -1167,7 +1167,7 @@ fsd2_device::fsd2_device(const machine_config &mconfig, const char *tag, device_ // csd1_device - constructor //------------------------------------------------- -csd1_device::csd1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +csd1_device::csd1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, CSD1, tag, owner, clock) { } @@ -1175,7 +1175,7 @@ csd1_device::csd1_device(const machine_config &mconfig, const char *tag, device_ // c1541_dolphin_dos_device - constructor //------------------------------------------------- -c1541_dolphin_dos_device::c1541_dolphin_dos_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +c1541_dolphin_dos_device::c1541_dolphin_dos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, C1541_DOLPHIN_DOS, tag, owner, clock) { } @@ -1183,7 +1183,7 @@ c1541_dolphin_dos_device::c1541_dolphin_dos_device(const machine_config &mconfig // c1541_professional_dos_v1_device - constructor //------------------------------------------------- -c1541_professional_dos_v1_device::c1541_professional_dos_v1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +c1541_professional_dos_v1_device::c1541_professional_dos_v1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, C1541_PROFESSIONAL_DOS_V1, tag, owner, clock) { } @@ -1191,7 +1191,7 @@ c1541_professional_dos_v1_device::c1541_professional_dos_v1_device(const machine // c1541_prologic_dos_classic_device - constructor //------------------------------------------------- -c1541_prologic_dos_classic_device::c1541_prologic_dos_classic_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +c1541_prologic_dos_classic_device::c1541_prologic_dos_classic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, C1541_PROLOGIC_DOS_CLASSIC, tag, owner, clock), m_pia(*this, MC6821_TAG), m_cent_data_out(*this, "cent_data_out"), @@ -1204,7 +1204,7 @@ c1541_prologic_dos_classic_device::c1541_prologic_dos_classic_device(const machi // indus_gt_device - constructor //------------------------------------------------- -indus_gt_device::indus_gt_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +indus_gt_device::indus_gt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, INDUS_GT, tag, owner, clock) { } @@ -1212,7 +1212,7 @@ indus_gt_device::indus_gt_device(const machine_config &mconfig, const char *tag, // technica_device - constructor //------------------------------------------------- -technica_device::technica_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +technica_device::technica_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, TECHNICA, tag, owner, clock) { } @@ -1220,7 +1220,7 @@ technica_device::technica_device(const machine_config &mconfig, const char *tag, // blue_chip_device - constructor //------------------------------------------------- -blue_chip_device::blue_chip_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +blue_chip_device::blue_chip_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, BLUE_CHIP, tag, owner, clock) { } @@ -1228,7 +1228,7 @@ blue_chip_device::blue_chip_device(const machine_config &mconfig, const char *ta // commander_c2_device - constructor //------------------------------------------------- -commander_c2_device::commander_c2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +commander_c2_device::commander_c2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, COMMANDER_C2, tag, owner, clock) { } @@ -1236,7 +1236,7 @@ commander_c2_device::commander_c2_device(const machine_config &mconfig, const ch // enhancer_2000_device - constructor //------------------------------------------------- -enhancer_2000_device::enhancer_2000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +enhancer_2000_device::enhancer_2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, ENHANCER_2000, tag, owner, clock) { } @@ -1244,7 +1244,7 @@ enhancer_2000_device::enhancer_2000_device(const machine_config &mconfig, const // fd148_device - constructor //------------------------------------------------- -fd148_device::fd148_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +fd148_device::fd148_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, FD148, tag, owner, clock) { } @@ -1252,7 +1252,7 @@ fd148_device::fd148_device(const machine_config &mconfig, const char *tag, devic // msd_sd1_device - constructor //------------------------------------------------- -msd_sd1_device::msd_sd1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +msd_sd1_device::msd_sd1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, MSD_SD1, tag, owner, clock) { } @@ -1260,7 +1260,7 @@ msd_sd1_device::msd_sd1_device(const machine_config &mconfig, const char *tag, d // msd_sd2_device - constructor //------------------------------------------------- -msd_sd2_device::msd_sd2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +msd_sd2_device::msd_sd2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1541_device_base(mconfig, MSD_SD2, tag, owner, clock) { } diff --git a/src/devices/bus/cbmiec/c1541.h b/src/devices/bus/cbmiec/c1541.h index de79cc95f90..44fe91a16dd 100644 --- a/src/devices/bus/cbmiec/c1541.h +++ b/src/devices/bus/cbmiec/c1541.h @@ -33,7 +33,7 @@ class c1541_device_base : public device_t, { protected: // construction/destruction - c1541_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + c1541_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -103,7 +103,7 @@ class c1540_device : public c1541_device_base { public: // construction/destruction - c1540_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + c1540_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -117,7 +117,7 @@ class c1541_device : public c1541_device_base { public: // construction/destruction - c1541_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + c1541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -131,7 +131,7 @@ class c1541c_device : public c1541_device_base { public: // construction/destruction - c1541c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + c1541c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -149,7 +149,7 @@ class c1541ii_device : public c1541_device_base { public: // construction/destruction - c1541ii_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + c1541ii_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -163,7 +163,7 @@ class sx1541_device : public c1541_device_base { public: // construction/destruction - sx1541_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sx1541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -177,7 +177,7 @@ class fsd1_device : public c1541_device_base { public: // construction/destruction - fsd1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + fsd1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -191,7 +191,7 @@ class fsd2_device : public c1541_device_base { public: // construction/destruction - fsd2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + fsd2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -208,7 +208,7 @@ class csd1_device : public c1541_device_base { public: // construction/destruction - csd1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + csd1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -222,7 +222,7 @@ class c1541_dolphin_dos_device : public c1541_device_base { public: // construction/destruction - c1541_dolphin_dos_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + c1541_dolphin_dos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -237,7 +237,7 @@ class c1541_professional_dos_v1_device : public c1541_device_base { public: // construction/destruction - c1541_professional_dos_v1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + c1541_professional_dos_v1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -252,7 +252,7 @@ class c1541_prologic_dos_classic_device : public c1541_device_base { public: // construction/destruction - c1541_prologic_dos_classic_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + c1541_prologic_dos_classic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -282,7 +282,7 @@ class indus_gt_device : public c1541_device_base { public: // construction/destruction - indus_gt_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + indus_gt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -296,7 +296,7 @@ class technica_device : public c1541_device_base { public: // construction/destruction - technica_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + technica_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -310,7 +310,7 @@ class blue_chip_device : public c1541_device_base { public: // construction/destruction - blue_chip_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + blue_chip_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -324,7 +324,7 @@ class commander_c2_device : public c1541_device_base { public: // construction/destruction - commander_c2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + commander_c2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -338,7 +338,7 @@ class enhancer_2000_device : public c1541_device_base { public: // construction/destruction - enhancer_2000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + enhancer_2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -352,7 +352,7 @@ class fd148_device : public c1541_device_base { public: // construction/destruction - fd148_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + fd148_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -366,7 +366,7 @@ class msd_sd1_device : public c1541_device_base { public: // construction/destruction - msd_sd1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + msd_sd1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -380,7 +380,7 @@ class msd_sd2_device : public c1541_device_base { public: // construction/destruction - msd_sd2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + msd_sd2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/cbmiec/c1571.cpp b/src/devices/bus/cbmiec/c1571.cpp index f2d41120f5e..f12e0635c92 100644 --- a/src/devices/bus/cbmiec/c1571.cpp +++ b/src/devices/bus/cbmiec/c1571.cpp @@ -622,7 +622,7 @@ void c1571_device::add_base_mconfig(machine_config &config) C64H156(config, m_ga, 16_MHz_XTAL); m_ga->byte_callback().set(FUNC(c1571_device::byte_w)); - floppy_connector &connector(FLOPPY_CONNECTOR(config, C64H156_TAG":0", 0)); + floppy_connector &connector(FLOPPY_CONNECTOR(config, C64H156_TAG":0")); connector.option_add("525qd", FLOPPY_525_QD); connector.set_default_option("525qd"); connector.set_fixed(true); @@ -673,10 +673,10 @@ void mini_chief_device::device_add_mconfig(machine_config &config) m_maincpu->set_addrmap(AS_PROGRAM, &mini_chief_device::mini_chief_mem); - isa8_device &isa8(ISA8(config, ISA_BUS_TAG, 0)); + isa8_device &isa8(ISA8(config, ISA_BUS_TAG)); isa8.set_memspace(m_maincpu, AS_PROGRAM); isa8.set_iospace(m_maincpu, AS_PROGRAM); - ISA8_SLOT(config, "isa1", 0, ISA_BUS_TAG, mini_chief_isa8_cards, "wd1002a_wx1", false); + ISA8_SLOT(config, "isa1", ISA_BUS_TAG, mini_chief_isa8_cards, "wd1002a_wx1", false); } @@ -713,7 +713,7 @@ ioport_constructor c1571_device::device_input_ports() const // c1571_device - constructor //------------------------------------------------- -c1571_device::c1571_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +c1571_device::c1571_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_cbm_iec_interface(mconfig, *this), device_c64_floppy_parallel_interface(mconfig, *this), @@ -737,7 +737,7 @@ c1571_device::c1571_device(const machine_config &mconfig, device_type type, cons { } -c1571_device::c1571_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c1571_device::c1571_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1571_device(mconfig, C1571, tag, owner, clock) { } @@ -747,7 +747,7 @@ c1571_device::c1571_device(const machine_config &mconfig, const char *tag, devic // c1570_device - constructor //------------------------------------------------- -c1570_device::c1570_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c1570_device::c1570_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1571_device(mconfig, C1570, tag, owner, clock) { } @@ -757,7 +757,7 @@ c1570_device::c1570_device(const machine_config &mconfig, const char *tag, devic // c1571cr_device - constructor //------------------------------------------------- -c1571cr_device::c1571cr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c1571cr_device::c1571cr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1571_device(mconfig, C1571CR, tag, owner, clock) { } @@ -767,7 +767,7 @@ c1571cr_device::c1571cr_device(const machine_config &mconfig, const char *tag, d // mini_chief_device - constructor //------------------------------------------------- -mini_chief_device::mini_chief_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mini_chief_device::mini_chief_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1571_device(mconfig, MINI_CHIEF, tag, owner, clock) { } diff --git a/src/devices/bus/cbmiec/c1571.h b/src/devices/bus/cbmiec/c1571.h index 103da690a2c..c25433a4148 100644 --- a/src/devices/bus/cbmiec/c1571.h +++ b/src/devices/bus/cbmiec/c1571.h @@ -41,7 +41,7 @@ class c1571_device : public device_t, public device_cbm_iec_interface, public de { public: // construction/destruction - c1571_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c1571_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( via0_irq_w ); uint8_t via0_pa_r(); @@ -70,7 +70,7 @@ public: void c1571_mem(address_map &map); protected: - c1571_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + c1571_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -134,7 +134,7 @@ class c1570_device : public c1571_device { public: // construction/destruction - c1570_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c1570_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -149,7 +149,7 @@ class c1571cr_device : public c1571_device { public: // construction/destruction - c1571cr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c1571cr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -168,7 +168,7 @@ class mini_chief_device : public c1571_device { public: // construction/destruction - mini_chief_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mini_chief_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/cbmiec/c1581.cpp b/src/devices/bus/cbmiec/c1581.cpp index b139a272266..8a4a167a44b 100644 --- a/src/devices/bus/cbmiec/c1581.cpp +++ b/src/devices/bus/cbmiec/c1581.cpp @@ -320,7 +320,7 @@ ioport_constructor c1581_device::device_input_ports() const // c1581_device - constructor //------------------------------------------------- -c1581_device::c1581_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +c1581_device::c1581_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_cbm_iec_interface(mconfig, *this), m_maincpu(*this, M6502_TAG), @@ -337,7 +337,7 @@ c1581_device::c1581_device(const machine_config &mconfig, device_type type, cons { } -c1581_device::c1581_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c1581_device::c1581_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1581_device(mconfig, C1581, tag, owner, clock) { } @@ -347,7 +347,7 @@ c1581_device::c1581_device(const machine_config &mconfig, const char *tag, devic // c1563_device - constructor //------------------------------------------------- -c1563_device::c1563_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c1563_device::c1563_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c1581_device(mconfig, C1563, tag, owner, clock) { } diff --git a/src/devices/bus/cbmiec/c1581.h b/src/devices/bus/cbmiec/c1581.h index 1fef8579460..3fbe5615b3d 100644 --- a/src/devices/bus/cbmiec/c1581.h +++ b/src/devices/bus/cbmiec/c1581.h @@ -38,10 +38,10 @@ class c1581_device : public device_t, public device_cbm_iec_interface { public: // construction/destruction - c1581_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c1581_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - c1581_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + c1581_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -99,7 +99,7 @@ class c1563_device : public c1581_device { public: // construction/destruction - c1563_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c1563_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/cbmiec/c64_nl10.cpp b/src/devices/bus/cbmiec/c64_nl10.cpp index d4ed3467016..a287fec53ac 100644 --- a/src/devices/bus/cbmiec/c64_nl10.cpp +++ b/src/devices/bus/cbmiec/c64_nl10.cpp @@ -47,7 +47,7 @@ const tiny_rom_entry *c64_nl10_interface_device::device_rom_region() const // c64_nl10_interface_device - constructor //------------------------------------------------- -c64_nl10_interface_device::c64_nl10_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c64_nl10_interface_device::c64_nl10_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_NL10_INTERFACE, tag, owner, clock) , device_cbm_iec_interface(mconfig, *this) { diff --git a/src/devices/bus/cbmiec/c64_nl10.h b/src/devices/bus/cbmiec/c64_nl10.h index 68f9f135c91..9c38233050d 100644 --- a/src/devices/bus/cbmiec/c64_nl10.h +++ b/src/devices/bus/cbmiec/c64_nl10.h @@ -25,7 +25,7 @@ class c64_nl10_interface_device : public device_t, public device_cbm_iec_interfa { public: // construction/destruction - c64_nl10_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_nl10_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/cbmiec/cbmiec.cpp b/src/devices/bus/cbmiec/cbmiec.cpp index 03b9837779f..6415a4e203c 100644 --- a/src/devices/bus/cbmiec/cbmiec.cpp +++ b/src/devices/bus/cbmiec/cbmiec.cpp @@ -246,7 +246,7 @@ device_cbm_iec_interface::~device_cbm_iec_interface() // cbm_iec_slot_device - constructor //------------------------------------------------- -cbm_iec_slot_device::cbm_iec_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm_iec_slot_device::cbm_iec_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CBM_IEC_SLOT, tag, owner, clock), device_slot_interface(mconfig, *this), m_address(0) { @@ -281,7 +281,7 @@ void cbm_iec_slot_device::device_start() // cbm_iec_device - constructor //------------------------------------------------- -cbm_iec_device::cbm_iec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm_iec_device::cbm_iec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CBM_IEC, tag, owner, clock), m_write_srq(*this), m_write_atn(*this), diff --git a/src/devices/bus/cbmiec/cbmiec.h b/src/devices/bus/cbmiec/cbmiec.h index 0683a98b4f8..fe00416c9c3 100644 --- a/src/devices/bus/cbmiec/cbmiec.h +++ b/src/devices/bus/cbmiec/cbmiec.h @@ -39,7 +39,7 @@ class cbm_iec_device : public device_t { public: // construction/destruction - cbm_iec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm_iec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto srq_callback() { return m_write_srq.bind(); } auto atn_callback() { return m_write_atn.bind(); } @@ -124,7 +124,7 @@ public: // construction/destruction template <typename T> cbm_iec_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, int address, T &&opts, char const *dflt) - : cbm_iec_slot_device(mconfig, tag, owner, (uint32_t)0) + : cbm_iec_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -132,7 +132,7 @@ public: set_fixed(false); set_address(address); } - cbm_iec_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm_iec_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> static void add(machine_config &config, T &&_bus_tag, const char *_default_drive) { @@ -142,7 +142,7 @@ public: CBM_IEC_SLOT(config, "iec10", 10, cbm_iec_devices, nullptr); CBM_IEC_SLOT(config, "iec11", 11, cbm_iec_devices, nullptr); - CBM_IEC(config, std::forward<T>(_bus_tag), 0); + CBM_IEC(config, std::forward<T>(_bus_tag)); } void set_address(int address) { m_address = address; } diff --git a/src/devices/bus/cbmiec/cmdhd.cpp b/src/devices/bus/cbmiec/cmdhd.cpp index 104b0eb456e..e7badebec3b 100644 --- a/src/devices/bus/cbmiec/cmdhd.cpp +++ b/src/devices/bus/cbmiec/cmdhd.cpp @@ -75,12 +75,12 @@ void cmd_hd_device::mem_map(address_map &map) void cmd_hd_device::device_add_mconfig(machine_config &config) { - M6502(config, m_maincpu, 2000000); + M6502(config, m_maincpu, XTAL::u(2000000)); m_maincpu->set_addrmap(AS_PROGRAM, &cmd_hd_device::mem_map); - MOS6522(config, M6522_1_TAG, 2000000); - MOS6522(config, M6522_2_TAG, 2000000); - I8255A(config, I8255A_TAG, 0); + MOS6522(config, M6522_1_TAG, XTAL::u(2000000)); + MOS6522(config, M6522_2_TAG, XTAL::u(2000000)); + I8255A(config, I8255A_TAG); RTC72421(config, RTC72421A_TAG, XTAL(32'768)); SCSI_PORT(config, m_scsibus); @@ -97,7 +97,7 @@ void cmd_hd_device::device_add_mconfig(machine_config &config) // cmd_hd_device - constructor //------------------------------------------------- -cmd_hd_device::cmd_hd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cmd_hd_device::cmd_hd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CMD_HD, tag, owner, clock), device_cbm_iec_interface(mconfig, *this), m_maincpu(*this, M6502_TAG), diff --git a/src/devices/bus/cbmiec/cmdhd.h b/src/devices/bus/cbmiec/cmdhd.h index 8c6836f36bf..431d8582109 100644 --- a/src/devices/bus/cbmiec/cmdhd.h +++ b/src/devices/bus/cbmiec/cmdhd.h @@ -30,7 +30,7 @@ class cmd_hd_device : public device_t, public device_cbm_iec_interface { public: // construction/destruction - cmd_hd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cmd_hd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cbmiec/diag264_lb_iec.cpp b/src/devices/bus/cbmiec/diag264_lb_iec.cpp index 8852f997285..188488c6d7d 100644 --- a/src/devices/bus/cbmiec/diag264_lb_iec.cpp +++ b/src/devices/bus/cbmiec/diag264_lb_iec.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(DIAG264_SERIAL_LOOPBACK, diag264_serial_loopback_device, "dia // diag264_serial_loopback_device - constructor //------------------------------------------------- -diag264_serial_loopback_device::diag264_serial_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +diag264_serial_loopback_device::diag264_serial_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DIAG264_SERIAL_LOOPBACK, tag, owner, clock) , device_cbm_iec_interface(mconfig, *this) { diff --git a/src/devices/bus/cbmiec/diag264_lb_iec.h b/src/devices/bus/cbmiec/diag264_lb_iec.h index 6611fee413d..3d7faf9a2a8 100644 --- a/src/devices/bus/cbmiec/diag264_lb_iec.h +++ b/src/devices/bus/cbmiec/diag264_lb_iec.h @@ -26,7 +26,7 @@ class diag264_serial_loopback_device : public device_t, { public: // construction/destruction - diag264_serial_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + diag264_serial_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cbmiec/fd2000.cpp b/src/devices/bus/cbmiec/fd2000.cpp index 34e06d70dbf..912bf9c78ec 100644 --- a/src/devices/bus/cbmiec/fd2000.cpp +++ b/src/devices/bus/cbmiec/fd2000.cpp @@ -251,12 +251,12 @@ void fd4000_device::device_add_mconfig(machine_config &config) // fd2000_device - constructor //------------------------------------------------- -fd2000_device::fd2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fd2000_device::fd2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : fd2000_device(mconfig, FD2000, tag, owner, clock) { } -fd2000_device::fd2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +fd2000_device::fd2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_cbm_iec_interface(mconfig, *this) , m_maincpu(*this, G65SC02PI2_TAG) @@ -270,7 +270,7 @@ fd2000_device::fd2000_device(const machine_config &mconfig, device_type type, co // fd4000_device - constructor //------------------------------------------------- -fd4000_device::fd4000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fd4000_device::fd4000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : fd2000_device(mconfig, FD4000, tag, owner, clock) { m_maincpu.set_tag(*this, R65C02P4_TAG); diff --git a/src/devices/bus/cbmiec/fd2000.h b/src/devices/bus/cbmiec/fd2000.h index 0b247405e7e..b7ddd71bab4 100644 --- a/src/devices/bus/cbmiec/fd2000.h +++ b/src/devices/bus/cbmiec/fd2000.h @@ -31,7 +31,7 @@ class fd2000_device : public device_t, { public: // construction/destruction - fd2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t via_pa_r(); void via_pa_w(uint8_t data); @@ -41,7 +41,7 @@ public: //static void floppy_formats(format_registration &fr); protected: - fd2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + fd2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -74,7 +74,7 @@ class fd4000_device : public fd2000_device { public: // construction/destruction - fd4000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd4000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/cbmiec/interpod.cpp b/src/devices/bus/cbmiec/interpod.cpp index c5479a30b18..9e5fec201a4 100644 --- a/src/devices/bus/cbmiec/interpod.cpp +++ b/src/devices/bus/cbmiec/interpod.cpp @@ -125,14 +125,14 @@ void cbm_interpod_device::interpod_mem(address_map &map) void cbm_interpod_device::device_add_mconfig(machine_config &config) { - M6502(config, m_maincpu, 1000000); + M6502(config, m_maincpu, XTAL::u(1000000)); m_maincpu->set_addrmap(AS_PROGRAM, &cbm_interpod_device::interpod_mem); - MOS6522(config, m_via, 1000000); + MOS6522(config, m_via, XTAL::u(1000000)); - MOS6532_NEW(config, m_riot, 1000000); + MOS6532_NEW(config, m_riot, XTAL::u(1000000)); - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); ieee488_device::add_cbm_devices(config, nullptr); @@ -149,7 +149,7 @@ void cbm_interpod_device::device_add_mconfig(machine_config &config) // cbm_interpod_device - constructor //------------------------------------------------- -cbm_interpod_device::cbm_interpod_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm_interpod_device::cbm_interpod_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CBM_INTERPOD, tag, owner, clock), device_cbm_iec_interface(mconfig, *this), m_maincpu(*this, R6502_TAG), diff --git a/src/devices/bus/cbmiec/interpod.h b/src/devices/bus/cbmiec/interpod.h index 823ab0c64e7..1b3debfce6f 100644 --- a/src/devices/bus/cbmiec/interpod.h +++ b/src/devices/bus/cbmiec/interpod.h @@ -32,7 +32,7 @@ class cbm_interpod_device : public device_t, { public: // construction/destruction - cbm_interpod_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm_interpod_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cbmiec/serialbox.cpp b/src/devices/bus/cbmiec/serialbox.cpp index 9d9dcc114cf..a3e5e5ba2f1 100644 --- a/src/devices/bus/cbmiec/serialbox.cpp +++ b/src/devices/bus/cbmiec/serialbox.cpp @@ -85,7 +85,7 @@ void cbm_serial_box_device::device_add_mconfig(machine_config &config) // cbm_serial_box_device - constructor //------------------------------------------------- -cbm_serial_box_device::cbm_serial_box_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cbm_serial_box_device::cbm_serial_box_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CBM_SERIAL_BOX, tag, owner, clock), device_cbm_iec_interface(mconfig, *this), m_maincpu(*this, M6502_TAG) diff --git a/src/devices/bus/cbmiec/serialbox.h b/src/devices/bus/cbmiec/serialbox.h index 16cb099e247..53a3613dd7f 100644 --- a/src/devices/bus/cbmiec/serialbox.h +++ b/src/devices/bus/cbmiec/serialbox.h @@ -26,7 +26,7 @@ class cbm_serial_box_device : public device_t, public device_cbm_iec_interface { public: // construction/destruction - cbm_serial_box_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm_serial_box_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cbmiec/vic1515.cpp b/src/devices/bus/cbmiec/vic1515.cpp index 5accd8b6858..959a7ee5dcf 100644 --- a/src/devices/bus/cbmiec/vic1515.cpp +++ b/src/devices/bus/cbmiec/vic1515.cpp @@ -101,7 +101,7 @@ ioport_constructor vic1515_device::device_input_ports() const // vic1515_device - constructor //------------------------------------------------- -vic1515_device::vic1515_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vic1515_device::vic1515_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC1515, tag, owner, clock), device_cbm_iec_interface(mconfig, *this) { diff --git a/src/devices/bus/cbmiec/vic1515.h b/src/devices/bus/cbmiec/vic1515.h index 1b84636e6d3..0b8c9b5eeb1 100644 --- a/src/devices/bus/cbmiec/vic1515.h +++ b/src/devices/bus/cbmiec/vic1515.h @@ -26,7 +26,7 @@ class vic1515_device : public device_t, public device_cbm_iec_interface { public: // construction/destruction - vic1515_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic1515_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cbmiec/vic1520.cpp b/src/devices/bus/cbmiec/vic1520.cpp index c77175fb83b..7d5f028956a 100644 --- a/src/devices/bus/cbmiec/vic1520.cpp +++ b/src/devices/bus/cbmiec/vic1520.cpp @@ -112,7 +112,7 @@ ioport_constructor vic1520_device::device_input_ports() const // vic1520_device - constructor //------------------------------------------------- -vic1520_device::vic1520_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +vic1520_device::vic1520_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC1520, tag, owner, clock) , device_cbm_iec_interface(mconfig, *this) , m_mcu(*this, "mcu") diff --git a/src/devices/bus/cbmiec/vic1520.h b/src/devices/bus/cbmiec/vic1520.h index 37659c19942..4348613cf92 100644 --- a/src/devices/bus/cbmiec/vic1520.h +++ b/src/devices/bus/cbmiec/vic1520.h @@ -26,7 +26,7 @@ class vic1520_device : public device_t, public device_cbm_iec_interface { public: // construction/destruction - vic1520_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + vic1520_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cbus/mpu_pc98.cpp b/src/devices/bus/cbus/mpu_pc98.cpp index 2ba192d4b0d..815f2f9591f 100644 --- a/src/devices/bus/cbus/mpu_pc98.cpp +++ b/src/devices/bus/cbus/mpu_pc98.cpp @@ -54,7 +54,7 @@ void mpu_pc98_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -mpu_pc98_device::mpu_pc98_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpu_pc98_device::mpu_pc98_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MPU_PC98, tag, owner, clock) , m_bus(*this, DEVICE_SELF_OWNER) , m_mpu401(*this, MPU_CORE_TAG) diff --git a/src/devices/bus/cbus/mpu_pc98.h b/src/devices/bus/cbus/mpu_pc98.h index 798f8b8f11e..b8bb6e735ff 100644 --- a/src/devices/bus/cbus/mpu_pc98.h +++ b/src/devices/bus/cbus/mpu_pc98.h @@ -18,7 +18,7 @@ class mpu_pc98_device : public device_t { public: // construction/destruction - mpu_pc98_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpu_pc98_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cbus/pc9801_118.cpp b/src/devices/bus/cbus/pc9801_118.cpp index 403a23b4658..0a6ac5ee9a2 100644 --- a/src/devices/bus/cbus/pc9801_118.cpp +++ b/src/devices/bus/cbus/pc9801_118.cpp @@ -148,7 +148,7 @@ const tiny_rom_entry *pc9801_118_device::device_rom_region() const // pc9801_118_device - constructor //------------------------------------------------- -pc9801_118_device::pc9801_118_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc9801_118_device::pc9801_118_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc9801_snd_device(mconfig, PC9801_118, tag, owner, clock), m_bus(*this, DEVICE_SELF_OWNER), m_opn3(*this, "opn3") diff --git a/src/devices/bus/cbus/pc9801_118.h b/src/devices/bus/cbus/pc9801_118.h index 94ac3bfe24c..3a92996cd02 100644 --- a/src/devices/bus/cbus/pc9801_118.h +++ b/src/devices/bus/cbus/pc9801_118.h @@ -26,7 +26,7 @@ class pc9801_118_device : public pc9801_snd_device { public: // construction/destruction - pc9801_118_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc9801_118_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type imperfect_features() { return feature::SOUND; } diff --git a/src/devices/bus/cbus/pc9801_26.cpp b/src/devices/bus/cbus/pc9801_26.cpp index 8f8b15740bd..6283d2cc9f4 100644 --- a/src/devices/bus/cbus/pc9801_26.cpp +++ b/src/devices/bus/cbus/pc9801_26.cpp @@ -115,7 +115,7 @@ ioport_constructor pc9801_26_device::device_input_ports() const // pc9801_26_device - constructor //------------------------------------------------- -pc9801_26_device::pc9801_26_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc9801_26_device::pc9801_26_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc9801_snd_device(mconfig, PC9801_26, tag, owner, clock) , m_bus(*this, DEVICE_SELF_OWNER) , m_opn(*this, "opn") diff --git a/src/devices/bus/cbus/pc9801_26.h b/src/devices/bus/cbus/pc9801_26.h index 80cd57a20cd..fdb67619200 100644 --- a/src/devices/bus/cbus/pc9801_26.h +++ b/src/devices/bus/cbus/pc9801_26.h @@ -25,7 +25,7 @@ class pc9801_26_device : public pc9801_snd_device { public: // construction/destruction - pc9801_26_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc9801_26_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t opn_r(offs_t offset); void opn_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/cbus/pc9801_55.cpp b/src/devices/bus/cbus/pc9801_55.cpp index 879ad2f1a66..44e17b63c60 100644 --- a/src/devices/bus/cbus/pc9801_55.cpp +++ b/src/devices/bus/cbus/pc9801_55.cpp @@ -144,7 +144,7 @@ ioport_constructor pc9801_55_device::device_input_ports() const // pc9801_55u_device - constructor //------------------------------------------------- -pc9801_55_device::pc9801_55_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pc9801_55_device::pc9801_55_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_bus(*this, DEVICE_SELF_OWNER) , m_scsi_bus(*this, "scsi") @@ -152,13 +152,13 @@ pc9801_55_device::pc9801_55_device(const machine_config &mconfig, device_type ty { } -pc9801_55u_device::pc9801_55u_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc9801_55u_device::pc9801_55u_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc9801_55_device(mconfig, PC9801_55U, tag, owner, clock) { } -pc9801_55l_device::pc9801_55l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc9801_55l_device::pc9801_55l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc9801_55_device(mconfig, PC9801_55L, tag, owner, clock) { diff --git a/src/devices/bus/cbus/pc9801_55.h b/src/devices/bus/cbus/pc9801_55.h index b74c754c2b8..212e4501b26 100644 --- a/src/devices/bus/cbus/pc9801_55.h +++ b/src/devices/bus/cbus/pc9801_55.h @@ -26,8 +26,8 @@ class pc9801_55_device : public device_t { public: // construction/destruction - //pc9801_55_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - pc9801_55_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + //pc9801_55_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); + pc9801_55_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } @@ -55,7 +55,7 @@ private: class pc9801_55u_device : public pc9801_55_device { public: - pc9801_55u_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc9801_55u_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: virtual const tiny_rom_entry *device_rom_region() const override; @@ -65,7 +65,7 @@ private: class pc9801_55l_device : public pc9801_55_device { public: - pc9801_55l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc9801_55l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/cbus/pc9801_86.cpp b/src/devices/bus/cbus/pc9801_86.cpp index 740906357c5..dd11ad30fd7 100644 --- a/src/devices/bus/cbus/pc9801_86.cpp +++ b/src/devices/bus/cbus/pc9801_86.cpp @@ -89,8 +89,8 @@ void pc9801_86_device::pc9801_86_config(machine_config &config) m_opna->add_route(1, "lspeaker", 1.00); m_opna->add_route(2, "rspeaker", 1.00); - DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_ldac, 0).add_route(ALL_OUTPUTS, "lspeaker", 1.0); // burr brown pcm61p - DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_rdac, 0).add_route(ALL_OUTPUTS, "rspeaker", 1.0); // burr brown pcm61p + DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_ldac).add_route(ALL_OUTPUTS, "lspeaker", 1.0); // burr brown pcm61p + DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_rdac).add_route(ALL_OUTPUTS, "rspeaker", 1.0); // burr brown pcm61p } void pc9801_86_device::device_add_mconfig(machine_config &config) @@ -178,7 +178,7 @@ ioport_constructor pc9801_86_device::device_input_ports() const // pc9801_86_device - constructor //------------------------------------------------- -pc9801_86_device::pc9801_86_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pc9801_86_device::pc9801_86_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : pc9801_snd_device(mconfig, type, tag, owner, clock) , m_bus(*this, DEVICE_SELF_OWNER) , m_opna(*this, "opna") @@ -188,7 +188,7 @@ pc9801_86_device::pc9801_86_device(const machine_config &mconfig, device_type ty { } -pc9801_86_device::pc9801_86_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc9801_86_device::pc9801_86_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc9801_86_device(mconfig, PC9801_86, tag, owner, clock) { @@ -445,7 +445,7 @@ const tiny_rom_entry *pc9801_speakboard_device::device_rom_region() const return ROM_NAME( pc9801_spb ); } -pc9801_speakboard_device::pc9801_speakboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc9801_speakboard_device::pc9801_speakboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc9801_86_device(mconfig, PC9801_SPEAKBOARD, tag, owner, clock) , m_opna_slave(*this, "opna_slave") { @@ -505,7 +505,7 @@ void pc9801_speakboard_device::opna_slave_w(offs_t offset, u8 data) DEFINE_DEVICE_TYPE(OTOMICHAN_KAI, otomichan_kai_device, "pc98_otomichan_kai", "MAD Factory Otomi-chan Kai") // 音美(おとみ)ちゃん改 -otomichan_kai_device::otomichan_kai_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +otomichan_kai_device::otomichan_kai_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc9801_86_device(mconfig, OTOMICHAN_KAI, tag, owner, clock) , m_opn2c(*this, "opn2c") { diff --git a/src/devices/bus/cbus/pc9801_86.h b/src/devices/bus/cbus/pc9801_86.h index 7903f11e0b9..e5f8399d94c 100644 --- a/src/devices/bus/cbus/pc9801_86.h +++ b/src/devices/bus/cbus/pc9801_86.h @@ -26,8 +26,8 @@ class pc9801_86_device : public pc9801_snd_device { public: // construction/destruction - pc9801_86_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - pc9801_86_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pc9801_86_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); + pc9801_86_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(sound_irq); @@ -77,7 +77,7 @@ class pc9801_speakboard_device : public pc9801_86_device { public: // construction/destruction - pc9801_speakboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc9801_speakboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type imperfect_features() { return feature::SOUND; } @@ -98,7 +98,7 @@ class otomichan_kai_device : public pc9801_86_device { public: // construction/destruction - otomichan_kai_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + otomichan_kai_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type imperfect_features() { return feature::SOUND; } diff --git a/src/devices/bus/cbus/pc9801_amd98.cpp b/src/devices/bus/cbus/pc9801_amd98.cpp index 5b4d66bbdff..a6461f65319 100644 --- a/src/devices/bus/cbus/pc9801_amd98.cpp +++ b/src/devices/bus/cbus/pc9801_amd98.cpp @@ -47,17 +47,17 @@ void pc9801_amd98_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - AY8910(config, m_ay1, 1'996'800); + AY8910(config, m_ay1, XTAL::u(1'996'800)); m_ay1->port_a_read_callback().set_ioport("OPN_PA1"); m_ay1->port_b_write_callback().set(FUNC(pc9801_amd98_device::ay3_address_w)); m_ay1->add_route(ALL_OUTPUTS, "lspeaker", 0.50); - AY8910(config, m_ay2, 1'996'800); + AY8910(config, m_ay2, XTAL::u(1'996'800)); m_ay2->port_a_read_callback().set_ioport("OPN_PA2"); m_ay2->port_b_write_callback().set(FUNC(pc9801_amd98_device::ay3_data_latch_w)); m_ay2->add_route(ALL_OUTPUTS, "rspeaker", 0.50); - AY8910(config, m_ay3, 1'996'800); + AY8910(config, m_ay3, XTAL::u(1'996'800)); m_ay3->add_route(ALL_OUTPUTS, "lspeaker", 0.25); m_ay3->add_route(ALL_OUTPUTS, "rspeaker", 0.25); } @@ -100,7 +100,7 @@ ioport_constructor pc9801_amd98_device::device_input_ports() const // pc9801_amd98_device - constructor //------------------------------------------------- -pc9801_amd98_device::pc9801_amd98_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc9801_amd98_device::pc9801_amd98_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC9801_AMD98, tag, owner, clock) , m_bus(*this, DEVICE_SELF_OWNER) , m_ay1(*this, "ay1") diff --git a/src/devices/bus/cbus/pc9801_amd98.h b/src/devices/bus/cbus/pc9801_amd98.h index f26246c768b..fbc74a2dba4 100644 --- a/src/devices/bus/cbus/pc9801_amd98.h +++ b/src/devices/bus/cbus/pc9801_amd98.h @@ -24,7 +24,7 @@ class pc9801_amd98_device : public device_t { public: // construction/destruction - pc9801_amd98_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc9801_amd98_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type imperfect_features() { return feature::SOUND; } diff --git a/src/devices/bus/cbus/pc9801_cbus.cpp b/src/devices/bus/cbus/pc9801_cbus.cpp index 9077d8cc4ea..aabc8d8a7d6 100644 --- a/src/devices/bus/cbus/pc9801_cbus.cpp +++ b/src/devices/bus/cbus/pc9801_cbus.cpp @@ -65,7 +65,7 @@ device_pc9801cbus_card_interface::~device_pc9801cbus_card_interface() // pc9801_slot_device - constructor //------------------------------------------------- -pc9801_slot_device::pc9801_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pc9801_slot_device::pc9801_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC9801CBUS_SLOT, tag, owner, clock), device_slot_interface(mconfig, *this), m_memspace(*this, finder_base::DUMMY_TAG, -1), diff --git a/src/devices/bus/cbus/pc9801_cbus.h b/src/devices/bus/cbus/pc9801_cbus.h index ab7085dfa86..9a0bf3fe367 100644 --- a/src/devices/bus/cbus/pc9801_cbus.h +++ b/src/devices/bus/cbus/pc9801_cbus.h @@ -93,14 +93,14 @@ public: // construction/destruction template <typename T> pc9801_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : pc9801_slot_device(mconfig, tag, owner, (uint32_t)0) + : pc9801_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - pc9801_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc9801_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_memspace(T &&tag, int spacenum) { m_memspace.set_tag(std::forward<T>(tag), spacenum); } template <typename T> void set_iospace(T &&tag, int spacenum) { m_iospace.set_tag(std::forward<T>(tag), spacenum); } diff --git a/src/devices/bus/cbus/pc9801_snd.cpp b/src/devices/bus/cbus/pc9801_snd.cpp index 3a33cfe6757..8c173c47500 100644 --- a/src/devices/bus/cbus/pc9801_snd.cpp +++ b/src/devices/bus/cbus/pc9801_snd.cpp @@ -10,7 +10,7 @@ #include "emu.h" #include "pc9801_snd.h" -pc9801_snd_device::pc9801_snd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pc9801_snd_device::pc9801_snd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/bus/cbus/pc9801_snd.h b/src/devices/bus/cbus/pc9801_snd.h index 0c9c694a4e3..63190b94832 100644 --- a/src/devices/bus/cbus/pc9801_snd.h +++ b/src/devices/bus/cbus/pc9801_snd.h @@ -15,7 +15,7 @@ class pc9801_snd_device : public device_t { public: - pc9801_snd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pc9801_snd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); protected: u8 opn_porta_r(); diff --git a/src/devices/bus/centronics/chessmec.cpp b/src/devices/bus/centronics/chessmec.cpp index fb30a7253b7..25fb4acdf69 100644 --- a/src/devices/bus/centronics/chessmec.cpp +++ b/src/devices/bus/centronics/chessmec.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(CENTRONICS_CHESSMEC, centronics_chessmec_device, "centronics_ // constructor //------------------------------------------------- -centronics_chessmec_device::centronics_chessmec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +centronics_chessmec_device::centronics_chessmec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CENTRONICS_CHESSMEC, tag, owner, clock), device_centronics_peripheral_interface(mconfig, *this), m_chessm(*this, "chessm") @@ -32,5 +32,5 @@ centronics_chessmec_device::centronics_chessmec_device(const machine_config &mco void centronics_chessmec_device::device_add_mconfig(machine_config &config) { - CHESSMACHINE(config, m_chessm, 15'000'000).data_out().set(FUNC(centronics_chessmec_device::output_busy)); + CHESSMACHINE(config, m_chessm, XTAL::u(15'000'000)).data_out().set(FUNC(centronics_chessmec_device::output_busy)); } diff --git a/src/devices/bus/centronics/chessmec.h b/src/devices/bus/centronics/chessmec.h index 07bbd8970c3..726a79b07dd 100644 --- a/src/devices/bus/centronics/chessmec.h +++ b/src/devices/bus/centronics/chessmec.h @@ -20,7 +20,7 @@ class centronics_chessmec_device : public device_t, { public: // construction/destruction - centronics_chessmec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + centronics_chessmec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/centronics/comxpl80.cpp b/src/devices/bus/centronics/comxpl80.cpp index 65646f0d290..f22556ed915 100644 --- a/src/devices/bus/centronics/comxpl80.cpp +++ b/src/devices/bus/centronics/comxpl80.cpp @@ -65,7 +65,7 @@ const tiny_rom_entry *comx_pl80_device::device_rom_region() const void comx_pl80_device::device_add_mconfig(machine_config &config) { #if 0 - m6805_device &cx005(M6805(config, CX005_TAG, 4000000)); // CX005: some kind of MC6805/MC68HC05 clone + m6805_device &cx005(M6805(config, CX005_TAG, XTAL::u(4000000))); // CX005: some kind of MC6805/MC68HC05 clone cx005.set_disable(); #endif } @@ -113,7 +113,7 @@ ioport_constructor comx_pl80_device::device_input_ports() const // comx_pl80_device - constructor //------------------------------------------------- -comx_pl80_device::comx_pl80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +comx_pl80_device::comx_pl80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMX_PL80, tag, owner, clock), device_centronics_peripheral_interface(mconfig, *this), m_plotter(*this, "gfx1"), diff --git a/src/devices/bus/centronics/comxpl80.h b/src/devices/bus/centronics/comxpl80.h index f64a31da6d0..ffb727a8879 100644 --- a/src/devices/bus/centronics/comxpl80.h +++ b/src/devices/bus/centronics/comxpl80.h @@ -26,7 +26,7 @@ class comx_pl80_device : public device_t, { public: // construction/destruction - comx_pl80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + comx_pl80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/centronics/covox.cpp b/src/devices/bus/centronics/covox.cpp index d37d96ce958..12b9a89cb2f 100644 --- a/src/devices/bus/centronics/covox.cpp +++ b/src/devices/bus/centronics/covox.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(CENTRONICS_COVOX, centronics_covox_device, "covox", "Covox Sp // centronics_covox_device - constructor //------------------------------------------------- -centronics_covox_device::centronics_covox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +centronics_covox_device::centronics_covox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CENTRONICS_COVOX, tag, owner, clock), device_centronics_peripheral_interface( mconfig, *this ), m_dac(*this, "dac"), @@ -41,7 +41,7 @@ void centronics_covox_device::device_add_mconfig(machine_config &config) { /* sound hardware */ SPEAKER(config, "speaker").front_center(); - DAC_8BIT_R2R(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.5); // unknown DAC + DAC_8BIT_R2R(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.5); // unknown DAC } void centronics_covox_device::device_start() @@ -70,7 +70,7 @@ DEFINE_DEVICE_TYPE(CENTRONICS_COVOX_STEREO, centronics_covox_stereo_device, "cov // centronics_covox_stereo_device - constructor //------------------------------------------------- -centronics_covox_stereo_device::centronics_covox_stereo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +centronics_covox_stereo_device::centronics_covox_stereo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CENTRONICS_COVOX_STEREO, tag, owner, clock), device_centronics_peripheral_interface( mconfig, *this ), m_ldac(*this, "ldac"), @@ -90,8 +90,8 @@ void centronics_covox_stereo_device::device_add_mconfig(machine_config &config) /* sound hardware */ SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - DAC_8BIT_R2R(config, m_ldac, 0).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // unknown DAC - DAC_8BIT_R2R(config, m_rdac, 0).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // unknown DAC + DAC_8BIT_R2R(config, m_ldac).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // unknown DAC + DAC_8BIT_R2R(config, m_rdac).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // unknown DAC } void centronics_covox_stereo_device::device_start() diff --git a/src/devices/bus/centronics/covox.h b/src/devices/bus/centronics/covox.h index da6ed1063aa..1c83edb0c87 100644 --- a/src/devices/bus/centronics/covox.h +++ b/src/devices/bus/centronics/covox.h @@ -21,7 +21,7 @@ class centronics_covox_device : public device_t, { public: // construction/destruction - centronics_covox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + centronics_covox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -57,7 +57,7 @@ class centronics_covox_stereo_device : public device_t, { public: // construction/destruction - centronics_covox_stereo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + centronics_covox_stereo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/centronics/ctronics.cpp b/src/devices/bus/centronics/ctronics.cpp index 81812bc37f6..9cea2dd0b9e 100644 --- a/src/devices/bus/centronics/ctronics.cpp +++ b/src/devices/bus/centronics/ctronics.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(CENTRONICS, centronics_device, "centronics", "Centronics") -centronics_device::centronics_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +centronics_device::centronics_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CENTRONICS, tag, owner, clock), device_slot_interface(mconfig, *this), m_strobe_handler(*this), diff --git a/src/devices/bus/centronics/ctronics.h b/src/devices/bus/centronics/ctronics.h index 44de7930cc8..ebfc7ebe831 100644 --- a/src/devices/bus/centronics/ctronics.h +++ b/src/devices/bus/centronics/ctronics.h @@ -25,14 +25,14 @@ class centronics_device : public device_t, public device_slot_interface public: template <typename T> centronics_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : centronics_device(mconfig, tag, owner, 0) + : centronics_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - centronics_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + centronics_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto strobe_handler() { return m_strobe_handler.bind(); } diff --git a/src/devices/bus/centronics/digiblst.cpp b/src/devices/bus/centronics/digiblst.cpp index 3b66d35b9df..4ddce59f843 100644 --- a/src/devices/bus/centronics/digiblst.cpp +++ b/src/devices/bus/centronics/digiblst.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(CENTRONICS_DIGIBLASTER, centronics_digiblaster_device, "cpcdi // centronics_digiblaster_device - constructor //------------------------------------------------- -centronics_digiblaster_device::centronics_digiblaster_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +centronics_digiblaster_device::centronics_digiblaster_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CENTRONICS_DIGIBLASTER, tag, owner, clock), device_centronics_peripheral_interface( mconfig, *this ), m_dac(*this, "dac"), @@ -41,7 +41,7 @@ void centronics_digiblaster_device::device_add_mconfig(machine_config &config) { /* sound hardware */ SPEAKER(config, "speaker").front_center(); - DAC_8BIT_R2R(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.5); // unknown DAC + DAC_8BIT_R2R(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.5); // unknown DAC } void centronics_digiblaster_device::device_start() diff --git a/src/devices/bus/centronics/digiblst.h b/src/devices/bus/centronics/digiblst.h index 00a8246b802..a506c6930d8 100644 --- a/src/devices/bus/centronics/digiblst.h +++ b/src/devices/bus/centronics/digiblst.h @@ -27,7 +27,7 @@ class centronics_digiblaster_device : public device_t, { public: // construction/destruction - centronics_digiblaster_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + centronics_digiblaster_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/centronics/dsjoy.cpp b/src/devices/bus/centronics/dsjoy.cpp index a9209c264f8..55030b71094 100644 --- a/src/devices/bus/centronics/dsjoy.cpp +++ b/src/devices/bus/centronics/dsjoy.cpp @@ -6,7 +6,7 @@ DEFINE_DEVICE_TYPE(DEMPA_SHINBUNSHA_JOYSTICK, dempa_shinbunsha_joystick_device, "dempa_shinbunsha_joystick", "Dempa Shinbunsha Joystick") -dempa_shinbunsha_joystick_device::dempa_shinbunsha_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dempa_shinbunsha_joystick_device::dempa_shinbunsha_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DEMPA_SHINBUNSHA_JOYSTICK, tag, owner, clock), device_centronics_peripheral_interface( mconfig, *this ), m_lptjoy(*this, "lptjoy"), diff --git a/src/devices/bus/centronics/dsjoy.h b/src/devices/bus/centronics/dsjoy.h index bcb91afceed..14095017c62 100644 --- a/src/devices/bus/centronics/dsjoy.h +++ b/src/devices/bus/centronics/dsjoy.h @@ -18,7 +18,7 @@ class dempa_shinbunsha_joystick_device : public device_t, { public: // construction/destruction - dempa_shinbunsha_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dempa_shinbunsha_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/centronics/epson_ex800.cpp b/src/devices/bus/centronics/epson_ex800.cpp index e7af6cfc65b..6326bdd0422 100644 --- a/src/devices/bus/centronics/epson_ex800.cpp +++ b/src/devices/bus/centronics/epson_ex800.cpp @@ -218,7 +218,7 @@ void epson_ex800_device::ex800_mem(address_map &map) void epson_ex800_device::device_add_mconfig(machine_config &config) { /* basic machine hardware */ - upd7810_device &upd(UPD7810(config, m_maincpu, 12000000)); // 12 MHz? + upd7810_device &upd(UPD7810(config, m_maincpu, XTAL::u(12000000))); // 12 MHz? upd.set_addrmap(AS_PROGRAM, &epson_ex800_device::ex800_mem); upd.pa_in_cb().set(FUNC(epson_ex800_device::porta_r)); upd.pa_out_cb().set(FUNC(epson_ex800_device::porta_w)); @@ -231,7 +231,7 @@ void epson_ex800_device::device_add_mconfig(machine_config &config) /* audio hardware */ SPEAKER(config, "mono").front_center(); - BEEP(config, m_beeper, 4000); // measured at 4000 Hz */ + BEEP(config, m_beeper, XTAL::u(4000)); // measured at 4000 Hz */ m_beeper->add_route(ALL_OUTPUTS, "mono", 1.0); } @@ -342,7 +342,7 @@ ioport_constructor epson_ex800_device::device_input_ports() const // epson_ex800_device - constructor //------------------------------------------------- -epson_ex800_device::epson_ex800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +epson_ex800_device::epson_ex800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EPSON_EX800, tag, owner, clock), device_centronics_peripheral_interface(mconfig, *this), m_maincpu(*this, "maincpu"), diff --git a/src/devices/bus/centronics/epson_ex800.h b/src/devices/bus/centronics/epson_ex800.h index 4c60b8cc847..0f8ae4bd0ff 100644 --- a/src/devices/bus/centronics/epson_ex800.h +++ b/src/devices/bus/centronics/epson_ex800.h @@ -27,7 +27,7 @@ class epson_ex800_device : public device_t, public device_centronics_peripheral { public: // construction/destruction - epson_ex800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + epson_ex800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(online_switch); diff --git a/src/devices/bus/centronics/epson_lx800.cpp b/src/devices/bus/centronics/epson_lx800.cpp index 3733c92cb2b..acb70a8fb38 100644 --- a/src/devices/bus/centronics/epson_lx800.cpp +++ b/src/devices/bus/centronics/epson_lx800.cpp @@ -89,11 +89,11 @@ void epson_lx800_device::device_add_mconfig(machine_config &config) /* audio hardware */ SPEAKER(config, "mono").front_center(); - BEEP(config, m_beep, 4000); // ? + BEEP(config, m_beep, XTAL::u(4000)); // ? m_beep->add_route(ALL_OUTPUTS, "mono", 0.05); /* gate array */ - e05a03_device &ic3b(E05A03(config, "ic3b", 0)); + e05a03_device &ic3b(E05A03(config, "ic3b")); ic3b.pe_lp_wr_callback().set_output("paperout_led"); ic3b.reso_wr_callback().set(FUNC(epson_lx800_device::reset_w)); ic3b.pe_wr_callback().set(FUNC(epson_lx800_device::centronics_pe_w)); @@ -176,12 +176,12 @@ ioport_constructor epson_lx800_device::device_input_ports() const // epson_lx800_device - constructor //------------------------------------------------- -epson_lx800_device::epson_lx800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +epson_lx800_device::epson_lx800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : epson_lx800_device(mconfig, EPSON_LX800, tag, owner, clock) { } -epson_lx800_device::epson_lx800_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +epson_lx800_device::epson_lx800_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_centronics_peripheral_interface(mconfig, *this), m_maincpu(*this, "maincpu"), diff --git a/src/devices/bus/centronics/epson_lx800.h b/src/devices/bus/centronics/epson_lx800.h index c6534f3d62f..e45a6217248 100644 --- a/src/devices/bus/centronics/epson_lx800.h +++ b/src/devices/bus/centronics/epson_lx800.h @@ -28,10 +28,10 @@ class epson_lx800_device : public device_t, public device_centronics_peripheral { public: // construction/destruction - epson_lx800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + epson_lx800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - epson_lx800_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + epson_lx800_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/centronics/epson_lx810l.cpp b/src/devices/bus/centronics/epson_lx810l.cpp index 24f9b90c50f..39611d2e367 100644 --- a/src/devices/bus/centronics/epson_lx810l.cpp +++ b/src/devices/bus/centronics/epson_lx810l.cpp @@ -144,10 +144,10 @@ void epson_lx810l_device::device_add_mconfig(machine_config &config) /* audio hardware */ SPEAKER(config, "speaker").front_center(); - DAC_1BIT(config, "dac", 0).add_route(ALL_OUTPUTS, "speaker", 0.25); + DAC_1BIT(config, "dac").add_route(ALL_OUTPUTS, "speaker", 0.25); /* gate array */ - e05a30_device &e05a30(E05A30(config, m_e05a30, 0)); + e05a30_device &e05a30(E05A30(config, m_e05a30)); e05a30.printhead().set(FUNC(epson_lx810l_device::printhead)); e05a30.pf_stepper().set(FUNC(epson_lx810l_device::pf_stepper)); e05a30.cr_stepper().set(FUNC(epson_lx810l_device::cr_stepper)); @@ -284,12 +284,12 @@ INPUT_CHANGED_MEMBER(epson_lx810l_device::reset_printer) // epson_lx810l_device - constructor //------------------------------------------------- -epson_lx810l_device::epson_lx810l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +epson_lx810l_device::epson_lx810l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : epson_lx810l_device(mconfig, EPSON_LX810L, tag, owner, clock) { } -epson_lx810l_device::epson_lx810l_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +epson_lx810l_device::epson_lx810l_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_centronics_peripheral_interface(mconfig, *this), m_maincpu(*this, "maincpu"), @@ -315,7 +315,7 @@ epson_lx810l_device::epson_lx810l_device(const machine_config &mconfig, device_t { } -epson_ap2000_device::epson_ap2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +epson_ap2000_device::epson_ap2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : epson_lx810l_device(mconfig, EPSON_AP2000, tag, owner, clock) { } diff --git a/src/devices/bus/centronics/epson_lx810l.h b/src/devices/bus/centronics/epson_lx810l.h index 1b5581a606b..96b4f3f04a5 100644 --- a/src/devices/bus/centronics/epson_lx810l.h +++ b/src/devices/bus/centronics/epson_lx810l.h @@ -31,7 +31,7 @@ class epson_lx810l_device : public device_t, public device_centronics_peripheral { public: // construction/destruction - epson_lx810l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + epson_lx810l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); /* Centronics stuff */ virtual DECLARE_WRITE_LINE_MEMBER( input_strobe ) override { m_e05a30->centronics_input_strobe(state); } @@ -52,7 +52,7 @@ public: DECLARE_INPUT_CHANGED_MEMBER(reset_printer); protected: - epson_lx810l_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + epson_lx810l_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -152,7 +152,7 @@ class epson_ap2000_device : public epson_lx810l_device { public: // construction/destruction - epson_ap2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + epson_ap2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/centronics/nec_p72.cpp b/src/devices/bus/centronics/nec_p72.cpp index fe03bb93d34..1804167bcee 100644 --- a/src/devices/bus/centronics/nec_p72.cpp +++ b/src/devices/bus/centronics/nec_p72.cpp @@ -73,12 +73,12 @@ void nec_p72_device::device_start() // nec_p72_device - constructor //------------------------------------------------- -nec_p72_device::nec_p72_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nec_p72_device::nec_p72_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nec_p72_device(mconfig, NEC_P72, tag, owner, clock) { } -nec_p72_device::nec_p72_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nec_p72_device::nec_p72_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_centronics_peripheral_interface(mconfig, *this), m_maincpu(*this, "maincpu") diff --git a/src/devices/bus/centronics/nec_p72.h b/src/devices/bus/centronics/nec_p72.h index f7ba6d59a73..0d92555f61e 100644 --- a/src/devices/bus/centronics/nec_p72.h +++ b/src/devices/bus/centronics/nec_p72.h @@ -20,10 +20,10 @@ class nec_p72_device : public device_t, { public: // construction/destruction - nec_p72_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nec_p72_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nec_p72_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nec_p72_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/centronics/printer.cpp b/src/devices/bus/centronics/printer.cpp index b1b136cfc66..c5f749dd811 100644 --- a/src/devices/bus/centronics/printer.cpp +++ b/src/devices/bus/centronics/printer.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(CENTRONICS_PRINTER, centronics_printer_device, "centronics_pr // centronics_printer_device - constructor //------------------------------------------------- -centronics_printer_device::centronics_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +centronics_printer_device::centronics_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CENTRONICS_PRINTER, tag, owner, clock), device_centronics_peripheral_interface( mconfig, *this ), m_strobe(0), @@ -34,7 +34,7 @@ centronics_printer_device::centronics_printer_device(const machine_config &mconf void centronics_printer_device::device_add_mconfig(machine_config &config) { - PRINTER(config, m_printer, 0); + PRINTER(config, m_printer); m_printer->online_callback().set(FUNC(centronics_printer_device::printer_online)); } diff --git a/src/devices/bus/centronics/printer.h b/src/devices/bus/centronics/printer.h index e959959be0c..4e2e4511122 100644 --- a/src/devices/bus/centronics/printer.h +++ b/src/devices/bus/centronics/printer.h @@ -15,7 +15,7 @@ class centronics_printer_device : public device_t, { public: // construction/destruction - centronics_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + centronics_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER( input_strobe ) override; virtual DECLARE_WRITE_LINE_MEMBER( input_data0 ) override { if (state) m_data |= 0x01; else m_data &= ~0x01; } diff --git a/src/devices/bus/centronics/samdac.cpp b/src/devices/bus/centronics/samdac.cpp index 01b18963e44..7586116100e 100644 --- a/src/devices/bus/centronics/samdac.cpp +++ b/src/devices/bus/centronics/samdac.cpp @@ -26,8 +26,8 @@ void centronics_samdac_device::device_add_mconfig(machine_config &config) SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - DAC_8BIT_R2R(config, m_dac[0], 0).add_route(ALL_OUTPUTS, "lspeaker", 0.5); - DAC_8BIT_R2R(config, m_dac[1], 0).add_route(ALL_OUTPUTS, "rspeaker", 0.5); + DAC_8BIT_R2R(config, m_dac[0]).add_route(ALL_OUTPUTS, "lspeaker", 0.5); + DAC_8BIT_R2R(config, m_dac[1]).add_route(ALL_OUTPUTS, "rspeaker", 0.5); } @@ -39,7 +39,7 @@ void centronics_samdac_device::device_add_mconfig(machine_config &config) // centronics_samdac_device - constructor //------------------------------------------------- -centronics_samdac_device::centronics_samdac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +centronics_samdac_device::centronics_samdac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CENTRONICS_SAMDAC, tag, owner, clock), device_centronics_peripheral_interface(mconfig, *this), m_dac(*this, "dac%u", 0U), diff --git a/src/devices/bus/centronics/samdac.h b/src/devices/bus/centronics/samdac.h index 79cd654e267..31ea00257ec 100644 --- a/src/devices/bus/centronics/samdac.h +++ b/src/devices/bus/centronics/samdac.h @@ -25,7 +25,7 @@ class centronics_samdac_device : public device_t, public device_centronics_perip { public: // construction/destruction - centronics_samdac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + centronics_samdac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from centronics port virtual DECLARE_WRITE_LINE_MEMBER( input_strobe ) override; diff --git a/src/devices/bus/centronics/smartboard.cpp b/src/devices/bus/centronics/smartboard.cpp index 8afcfbf68f7..200184abac7 100644 --- a/src/devices/bus/centronics/smartboard.cpp +++ b/src/devices/bus/centronics/smartboard.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(CENTRONICS_SMARTBOARD, centronics_smartboard_device, "centron // constructor //------------------------------------------------- -centronics_smartboard_device::centronics_smartboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +centronics_smartboard_device::centronics_smartboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CENTRONICS_SMARTBOARD, tag, owner, clock), device_centronics_peripheral_interface(mconfig, *this), m_smartboard(*this, "smartboard") diff --git a/src/devices/bus/centronics/smartboard.h b/src/devices/bus/centronics/smartboard.h index 4988086b11f..050bd67ba57 100644 --- a/src/devices/bus/centronics/smartboard.h +++ b/src/devices/bus/centronics/smartboard.h @@ -20,7 +20,7 @@ class centronics_smartboard_device : public device_t, { public: // construction/destruction - centronics_smartboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + centronics_smartboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/centronics/spjoy.cpp b/src/devices/bus/centronics/spjoy.cpp index dc032c35031..6302f3c5182 100644 --- a/src/devices/bus/centronics/spjoy.cpp +++ b/src/devices/bus/centronics/spjoy.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(SERIAL_PORT_JOYSTICK, serial_port_joystick_device, "spjoy", "The Serial Port/Vertical Twist Joystick Interface") -serial_port_joystick_device::serial_port_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +serial_port_joystick_device::serial_port_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SERIAL_PORT_JOYSTICK, tag, owner, clock) , device_centronics_peripheral_interface( mconfig, *this ) , m_joy(*this, "joy_p%u", 1U) diff --git a/src/devices/bus/centronics/spjoy.h b/src/devices/bus/centronics/spjoy.h index d13f2f90555..0cbc434cf94 100644 --- a/src/devices/bus/centronics/spjoy.h +++ b/src/devices/bus/centronics/spjoy.h @@ -18,7 +18,7 @@ class serial_port_joystick_device : public device_t, { public: // construction/destruction - serial_port_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + serial_port_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/cgenie/expansion/expansion.cpp b/src/devices/bus/cgenie/expansion/expansion.cpp index d35d75401bd..c29f56a5c59 100644 --- a/src/devices/bus/cgenie/expansion/expansion.cpp +++ b/src/devices/bus/cgenie/expansion/expansion.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(CG_EXP_SLOT, cg_exp_slot_device, "cg_exp_slot", "Colour Genie // cg_exp - constructor //------------------------------------------------- -cg_exp_slot_device::cg_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cg_exp_slot_device::cg_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CG_EXP_SLOT, tag, owner, clock), device_single_card_slot_interface<device_cg_exp_interface>(mconfig, *this), m_program(*this, finder_base::DUMMY_TAG, -1), diff --git a/src/devices/bus/cgenie/expansion/expansion.h b/src/devices/bus/cgenie/expansion/expansion.h index 5d128128fa8..e063f6defa8 100644 --- a/src/devices/bus/cgenie/expansion/expansion.h +++ b/src/devices/bus/cgenie/expansion/expansion.h @@ -54,14 +54,14 @@ class cg_exp_slot_device : public device_t, public device_single_card_slot_inter public: // construction/destruction cg_exp_slot_device(machine_config const &mconfig, char const *tag, device_t *owner) - : cg_exp_slot_device(mconfig, tag, owner, (uint32_t)0) + : cg_exp_slot_device(mconfig, tag, owner, XTAL()) { option_reset(); cg_exp_slot_carts(*this); set_default_option(nullptr); set_fixed(false); } - cg_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cg_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~cg_exp_slot_device(); template <typename T> void set_program_space(T &&tag, int spacenum) { m_program.set_tag(std::forward<T>(tag), spacenum); } diff --git a/src/devices/bus/cgenie/expansion/floppy.cpp b/src/devices/bus/cgenie/expansion/floppy.cpp index a97c3d46e66..c54eac55f71 100644 --- a/src/devices/bus/cgenie/expansion/floppy.cpp +++ b/src/devices/bus/cgenie/expansion/floppy.cpp @@ -113,7 +113,7 @@ void cgenie_fdc_device::device_add_mconfig(machine_config &config) // cgenie_fdc_device - constructor //------------------------------------------------- -cgenie_fdc_device::cgenie_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cgenie_fdc_device::cgenie_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CGENIE_FDC, tag, owner, clock), device_cg_exp_interface(mconfig, *this), m_fdc(*this, "wd2793"), diff --git a/src/devices/bus/cgenie/expansion/floppy.h b/src/devices/bus/cgenie/expansion/floppy.h index ca64b39f0d7..fb7a48776d0 100644 --- a/src/devices/bus/cgenie/expansion/floppy.h +++ b/src/devices/bus/cgenie/expansion/floppy.h @@ -28,7 +28,7 @@ class cgenie_fdc_device : public device_t, public device_cg_exp_interface { public: // construction/destruction - cgenie_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cgenie_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/cgenie/parallel/joystick.cpp b/src/devices/bus/cgenie/parallel/joystick.cpp index 2be4d5280b5..9fabe060244 100644 --- a/src/devices/bus/cgenie/parallel/joystick.cpp +++ b/src/devices/bus/cgenie/parallel/joystick.cpp @@ -93,7 +93,7 @@ ioport_constructor cgenie_joystick_device::device_input_ports() const // cgenie_joystick_device - constructor //------------------------------------------------- -cgenie_joystick_device::cgenie_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cgenie_joystick_device::cgenie_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CGENIE_JOYSTICK, tag, owner, clock), device_cg_parallel_interface(mconfig, *this), m_joy(*this, "JOY.%u", 0), diff --git a/src/devices/bus/cgenie/parallel/joystick.h b/src/devices/bus/cgenie/parallel/joystick.h index 6a4025ada9f..2f7b9871bd2 100644 --- a/src/devices/bus/cgenie/parallel/joystick.h +++ b/src/devices/bus/cgenie/parallel/joystick.h @@ -24,7 +24,7 @@ class cgenie_joystick_device : public device_t, public device_cg_parallel_interf { public: // construction/destruction - cgenie_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cgenie_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/cgenie/parallel/parallel.cpp b/src/devices/bus/cgenie/parallel/parallel.cpp index 2d08f27a1e5..8a9d7567ae7 100644 --- a/src/devices/bus/cgenie/parallel/parallel.cpp +++ b/src/devices/bus/cgenie/parallel/parallel.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(CG_PARALLEL_SLOT, cg_parallel_slot_device, "cg_parallel_slot" // cg_parallel_slot_device - constructor //------------------------------------------------- -cg_parallel_slot_device::cg_parallel_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cg_parallel_slot_device::cg_parallel_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CG_PARALLEL_SLOT, tag, owner, clock), device_single_card_slot_interface<device_cg_parallel_interface>(mconfig, *this), m_cart(nullptr) diff --git a/src/devices/bus/cgenie/parallel/parallel.h b/src/devices/bus/cgenie/parallel/parallel.h index 74fb8b7a50b..8027ad76eb4 100644 --- a/src/devices/bus/cgenie/parallel/parallel.h +++ b/src/devices/bus/cgenie/parallel/parallel.h @@ -38,14 +38,14 @@ class cg_parallel_slot_device : public device_t, public device_single_card_slot_ public: // construction/destruction cg_parallel_slot_device(machine_config const &mconfig, char const *tag, device_t *owner) - : cg_parallel_slot_device(mconfig, tag, owner, (uint32_t)0) + : cg_parallel_slot_device(mconfig, tag, owner, XTAL()) { option_reset(); cg_parallel_slot_carts(*this); set_default_option(nullptr); set_fixed(false); } - cg_parallel_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cg_parallel_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~cg_parallel_slot_device(); // IOA diff --git a/src/devices/bus/cgenie/parallel/printer.cpp b/src/devices/bus/cgenie/parallel/printer.cpp index 9a3e9df5dc4..c8816ea3fec 100644 --- a/src/devices/bus/cgenie/parallel/printer.cpp +++ b/src/devices/bus/cgenie/parallel/printer.cpp @@ -48,7 +48,7 @@ void cgenie_printer_device::device_add_mconfig(machine_config &config) // cgenie_printer_device - constructor //------------------------------------------------- -cgenie_printer_device::cgenie_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cgenie_printer_device::cgenie_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CGENIE_PRINTER, tag, owner, clock), device_cg_parallel_interface(mconfig, *this), m_centronics(*this, "centronics"), diff --git a/src/devices/bus/cgenie/parallel/printer.h b/src/devices/bus/cgenie/parallel/printer.h index 6da59e68ea0..ea3c34802d3 100644 --- a/src/devices/bus/cgenie/parallel/printer.h +++ b/src/devices/bus/cgenie/parallel/printer.h @@ -25,7 +25,7 @@ class cgenie_printer_device : public device_t, public device_cg_parallel_interfa { public: // construction/destruction - cgenie_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cgenie_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/chanf/rom.cpp b/src/devices/bus/chanf/rom.cpp index ab4b1a83750..f1d494f8822 100644 --- a/src/devices/bus/chanf/rom.cpp +++ b/src/devices/bus/chanf/rom.cpp @@ -31,39 +31,39 @@ DEFINE_DEVICE_TYPE(CHANF_ROM_MULTI_OLD, chanf_multi_old_device, "chanf_multi DEFINE_DEVICE_TYPE(CHANF_ROM_MULTI_FINAL, chanf_multi_final_device, "chanf_multi_fin", "Channel F Multigame (Final Version) Cart") -chanf_rom_device::chanf_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +chanf_rom_device::chanf_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_channelf_cart_interface(mconfig, *this) , m_addr_latch(0), m_addr(0), m_read_write(0), m_data0(0) { } -chanf_rom_device::chanf_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +chanf_rom_device::chanf_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : chanf_rom_device(mconfig, CHANF_ROM_STD, tag, owner, clock) { } -chanf_maze_device::chanf_maze_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +chanf_maze_device::chanf_maze_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : chanf_rom_device(mconfig, CHANF_ROM_MAZE, tag, owner, clock) { } -chanf_hangman_device::chanf_hangman_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +chanf_hangman_device::chanf_hangman_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : chanf_rom_device(mconfig, CHANF_ROM_HANGMAN, tag, owner, clock) { } -chanf_chess_device::chanf_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +chanf_chess_device::chanf_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : chanf_rom_device(mconfig, CHANF_ROM_CHESS, tag, owner, clock) { } -chanf_multi_old_device::chanf_multi_old_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +chanf_multi_old_device::chanf_multi_old_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : chanf_rom_device(mconfig, CHANF_ROM_MULTI_OLD, tag, owner, clock), m_base_bank(0) { } -chanf_multi_final_device::chanf_multi_final_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +chanf_multi_final_device::chanf_multi_final_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : chanf_rom_device(mconfig, CHANF_ROM_MULTI_FINAL, tag, owner, clock), m_base_bank(0), m_half_bank(0) { } diff --git a/src/devices/bus/chanf/rom.h b/src/devices/bus/chanf/rom.h index 76221811881..2abaac50320 100644 --- a/src/devices/bus/chanf/rom.h +++ b/src/devices/bus/chanf/rom.h @@ -13,7 +13,7 @@ class chanf_rom_device : public device_t, { public: // construction/destruction - chanf_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + chanf_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override {} @@ -28,7 +28,7 @@ public: virtual uint8_t read_rom(offs_t offset) override; protected: - chanf_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + chanf_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // used for RAM chip in Hangman & Maze uint8_t m_latch[2]; // PORT A & PORT B @@ -42,7 +42,7 @@ class chanf_maze_device : public chanf_rom_device { public: // construction/destruction - chanf_maze_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + chanf_maze_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -60,7 +60,7 @@ class chanf_hangman_device : public chanf_rom_device { public: // construction/destruction - chanf_hangman_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + chanf_hangman_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -78,7 +78,7 @@ class chanf_chess_device : public chanf_rom_device { public: // construction/destruction - chanf_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + chanf_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_ram(offs_t offset) override { return common_read_3853(offset); } @@ -92,7 +92,7 @@ class chanf_multi_old_device : public chanf_rom_device { public: // construction/destruction - chanf_multi_old_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + chanf_multi_old_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -115,7 +115,7 @@ class chanf_multi_final_device : public chanf_rom_device { public: // construction/destruction - chanf_multi_final_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + chanf_multi_final_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/chanf/slot.cpp b/src/devices/bus/chanf/slot.cpp index e13dd1d0d82..0a9f2992920 100644 --- a/src/devices/bus/chanf/slot.cpp +++ b/src/devices/bus/chanf/slot.cpp @@ -71,7 +71,7 @@ void device_channelf_cart_interface::ram_alloc(uint32_t size) //------------------------------------------------- // channelf_cart_slot_device - constructor //------------------------------------------------- -channelf_cart_slot_device::channelf_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +channelf_cart_slot_device::channelf_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CHANF_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_channelf_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/chanf/slot.h b/src/devices/bus/chanf/slot.h index afad1a76065..3fdcd91c479 100644 --- a/src/devices/bus/chanf/slot.h +++ b/src/devices/bus/chanf/slot.h @@ -66,7 +66,7 @@ public: // construction/destruction template <typename T> channelf_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : channelf_cart_slot_device(mconfig, tag, owner, 0) + : channelf_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -74,7 +74,7 @@ public: set_fixed(false); } - channelf_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + channelf_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~channelf_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/coco/coco_dcmodem.cpp b/src/devices/bus/coco/coco_dcmodem.cpp index fc26e61fb1f..611821a23ad 100644 --- a/src/devices/bus/coco/coco_dcmodem.cpp +++ b/src/devices/bus/coco/coco_dcmodem.cpp @@ -37,7 +37,7 @@ namespace { public: // construction/destruction - coco_dc_modem_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + coco_dc_modem_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_DCMODEM, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_uart(*this, UART_TAG) @@ -92,7 +92,7 @@ namespace void coco_dc_modem_device::device_add_mconfig(machine_config &config) { - MOS6551(config, m_uart, 0); + MOS6551(config, m_uart); m_uart->set_xtal(1.8432_MHz_XTAL); m_uart->irq_handler().set(FUNC(coco_dc_modem_device::uart_irq_w)); m_uart->txd_handler().set(PORT_TAG, FUNC(rs232_port_device::write_txd)); diff --git a/src/devices/bus/coco/coco_dwsock.cpp b/src/devices/bus/coco/coco_dwsock.cpp index b72783eed8d..3a1b794fb04 100644 --- a/src/devices/bus/coco/coco_dwsock.cpp +++ b/src/devices/bus/coco/coco_dwsock.cpp @@ -62,7 +62,7 @@ INPUT_CHANGED_MEMBER(beckerport_device::drivewire_port_changed) // beckerport_device - constructor / destructor //------------------------------------------------- -beckerport_device::beckerport_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +beckerport_device::beckerport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_DWSOCK, tag, owner, clock) , m_hostname(nullptr), m_dwconfigport(*this, DRIVEWIRE_PORT_TAG), m_dwtcpport(0) { diff --git a/src/devices/bus/coco/coco_dwsock.h b/src/devices/bus/coco/coco_dwsock.h index 6cbcc106488..d608d56fb9d 100644 --- a/src/devices/bus/coco/coco_dwsock.h +++ b/src/devices/bus/coco/coco_dwsock.h @@ -24,7 +24,7 @@ class beckerport_device : public device_t { public: - beckerport_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + beckerport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~beckerport_device(); // optional information overrides diff --git a/src/devices/bus/coco/coco_fdc.cpp b/src/devices/bus/coco/coco_fdc.cpp index 94d83954d59..d02ed33c06f 100644 --- a/src/devices/bus/coco/coco_fdc.cpp +++ b/src/devices/bus/coco/coco_fdc.cpp @@ -117,7 +117,7 @@ class coco_fdc_device_base : public coco_family_fdc_device_base { protected: // construction/destruction - coco_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + coco_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); enum class rtc_type { @@ -202,7 +202,7 @@ void coco_fdc_device_base::device_add_mconfig(machine_config &config) MSM6242(config, m_disto_msm6242, 32.768_kHz_XTAL); - DS1315(config, CLOUD9_TAG, 0); + DS1315(config, CLOUD9_TAG); RAM(config, "cachebuffer").set_default_size("256").set_default_value(0); } @@ -264,7 +264,7 @@ memory_region *coco_family_fdc_device_base::get_cart_memregion() // coco_fdc_device_base - constructor //------------------------------------------------- -coco_fdc_device_base::coco_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +coco_fdc_device_base::coco_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : coco_family_fdc_device_base(mconfig, type, tag, owner, clock) , m_wd17xx(*this, WD_TAG) , m_ds1315(*this, CLOUD9_TAG) @@ -639,7 +639,7 @@ namespace { public: // construction/destruction - coco_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + coco_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_fdc_device_base(mconfig, COCO_FDC, tag, owner, clock) { } @@ -676,7 +676,7 @@ namespace { public: // construction/destruction - coco_fdc_v11_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + coco_fdc_v11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_fdc_device_base(mconfig, COCO_FDC_V11, tag, owner, clock) { } @@ -711,7 +711,7 @@ namespace { public: // construction/destruction - coco3_hdb1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + coco3_hdb1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_fdc_device_base(mconfig, COCO3_HDB1, tag, owner, clock) { } @@ -745,7 +745,7 @@ namespace { public: // construction/destruction - coco2_hdb1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + coco2_hdb1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_fdc_device_base(mconfig, COCO2_HDB1, tag, owner, clock) { } @@ -781,7 +781,7 @@ namespace { public: // construction/destruction - cp450_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + cp450_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_fdc_device_base(mconfig, CP450_FDC, tag, owner, clock) { } @@ -815,7 +815,7 @@ namespace { public: // construction/destruction - cd6809_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + cd6809_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_fdc_device_base(mconfig, CD6809_FDC, tag, owner, clock) { } diff --git a/src/devices/bus/coco/coco_fdc.h b/src/devices/bus/coco/coco_fdc.h index 786d30c2f68..0851238f5cd 100644 --- a/src/devices/bus/coco/coco_fdc.h +++ b/src/devices/bus/coco/coco_fdc.h @@ -33,7 +33,7 @@ public: protected: // construction/destruction - coco_family_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) + coco_family_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_cococart_interface(mconfig, *this) { diff --git a/src/devices/bus/coco/coco_gmc.cpp b/src/devices/bus/coco/coco_gmc.cpp index 122450ace26..b801224e527 100644 --- a/src/devices/bus/coco/coco_gmc.cpp +++ b/src/devices/bus/coco/coco_gmc.cpp @@ -38,7 +38,7 @@ namespace { public: // construction/destruction - coco_pak_gmc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_pak_gmc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; protected: @@ -68,7 +68,7 @@ DEFINE_DEVICE_TYPE_PRIVATE(COCO_PAK_GMC, device_cococart_interface, coco_pak_gmc // coco_pak_device - constructor //------------------------------------------------- -coco_pak_gmc_device::coco_pak_gmc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_pak_gmc_device::coco_pak_gmc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_pak_banked_device(mconfig, COCO_PAK_GMC, tag, owner, clock) , m_psg(*this, SN76489AN_TAG) { diff --git a/src/devices/bus/coco/coco_ide.cpp b/src/devices/bus/coco/coco_ide.cpp index 0d261e2be3b..3d3b99780b0 100644 --- a/src/devices/bus/coco/coco_ide.cpp +++ b/src/devices/bus/coco/coco_ide.cpp @@ -47,7 +47,7 @@ ioport_constructor coco_ide_device::device_input_ports() const // coco_ide_device - constructor //------------------------------------------------- -coco_ide_device::coco_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_ide_device::coco_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_IDE, tag, owner, clock) , device_cococart_interface(mconfig, *this ) , m_ata(*this, "ata") diff --git a/src/devices/bus/coco/coco_ide.h b/src/devices/bus/coco/coco_ide.h index 465a4b0b8f6..fcbae3f3fe7 100644 --- a/src/devices/bus/coco/coco_ide.h +++ b/src/devices/bus/coco/coco_ide.h @@ -22,7 +22,7 @@ class coco_ide_device : { public: // construction/destruction - coco_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/coco/coco_max.cpp b/src/devices/bus/coco/coco_max.cpp index 611e4aad39f..948dfa37a8f 100644 --- a/src/devices/bus/coco/coco_max.cpp +++ b/src/devices/bus/coco/coco_max.cpp @@ -47,7 +47,7 @@ namespace { public: // construction/destruction - coco_pak_max_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_pak_max_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -80,7 +80,7 @@ DEFINE_DEVICE_TYPE_PRIVATE(COCO_PAK_MAX, device_cococart_interface, coco_pak_max // coco_pak_device - constructor //------------------------------------------------- -coco_pak_max_device::coco_pak_max_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_pak_max_device::coco_pak_max_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_PAK_MAX, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_mouse_x(*this, COCOMAX_X_TAG) diff --git a/src/devices/bus/coco/coco_midi.cpp b/src/devices/bus/coco/coco_midi.cpp index 0e6e38b839b..b803edcae0b 100644 --- a/src/devices/bus/coco/coco_midi.cpp +++ b/src/devices/bus/coco/coco_midi.cpp @@ -26,10 +26,10 @@ class coco_midi_device : { public: // construction/destruction - coco_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - coco_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + coco_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; // optional information overrides @@ -45,14 +45,14 @@ class dragon_midi_device : public coco_midi_device { public: // construction/destruction - dragon_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dragon_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - dragon_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + dragon_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; }; -coco_midi_device::coco_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +coco_midi_device::coco_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_cococart_interface(mconfig, *this ) , m_acia(*this, "mc6850") @@ -60,7 +60,7 @@ coco_midi_device::coco_midi_device(const machine_config &mconfig, device_type ty { } -coco_midi_device::coco_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_midi_device::coco_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_midi_device(mconfig, COCO_MIDI, tag, owner, clock) { } @@ -76,7 +76,7 @@ void coco_midi_device::device_add_mconfig(machine_config &config) MIDI_PORT(config, m_mdthru, midiout_slot, "midiout"); MIDI_PORT(config, "mdout", midiout_slot, "midiout"); - clock_device &acia_clock(CLOCK(config, "acia_clock", 31250*16)); + clock_device &acia_clock(CLOCK(config, "acia_clock", XTAL::u(31250*16))); acia_clock.signal_handler().set(m_acia, FUNC(acia6850_device::write_txc)); acia_clock.signal_handler().append(m_acia, FUNC(acia6850_device::write_rxc)); } @@ -93,12 +93,12 @@ WRITE_LINE_MEMBER(coco_midi_device::acia_irq_w) set_line_value(line::CART, state == 0); } -dragon_midi_device::dragon_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +dragon_midi_device::dragon_midi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : coco_midi_device(mconfig, type, tag, owner, clock) { } -dragon_midi_device::dragon_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dragon_midi_device::dragon_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dragon_midi_device(mconfig, DRAGON_MIDI, tag, owner, clock) { } diff --git a/src/devices/bus/coco/coco_multi.cpp b/src/devices/bus/coco/coco_multi.cpp index 2061c905b3f..860daf0c9da 100644 --- a/src/devices/bus/coco/coco_multi.cpp +++ b/src/devices/bus/coco/coco_multi.cpp @@ -96,12 +96,12 @@ namespace { public: // construction/destruction - coco_multipak_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_multipak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); INPUT_CHANGED_MEMBER( switch_changed ); protected: - coco_multipak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + coco_multipak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -152,7 +152,7 @@ class dragon_multipak_device : public coco_multipak_device { public: // construction/destruction - dragon_multipak_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dragon_multipak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -264,19 +264,19 @@ ioport_constructor coco_multipak_device::device_input_ports() const // coco_multipak_device - constructor //------------------------------------------------- -coco_multipak_device::coco_multipak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +coco_multipak_device::coco_multipak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_slots(*this, "slot%u", 1), m_select(0), m_block(0) { } -coco_multipak_device::coco_multipak_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_multipak_device::coco_multipak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_multipak_device(mconfig, COCO_MULTIPAK, tag, owner, clock) { } -dragon_multipak_device::dragon_multipak_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dragon_multipak_device::dragon_multipak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_multipak_device(mconfig, DRAGON_MULTIPAK, tag, owner, clock) { } diff --git a/src/devices/bus/coco/coco_orch90.cpp b/src/devices/bus/coco/coco_orch90.cpp index 7d149f36a26..0f1f02b126f 100644 --- a/src/devices/bus/coco/coco_orch90.cpp +++ b/src/devices/bus/coco/coco_orch90.cpp @@ -57,7 +57,7 @@ namespace { public: // construction/destruction - coco_orch90_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + coco_orch90_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_ORCH90, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_eprom(*this, "eprom") @@ -118,8 +118,8 @@ namespace { SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - DAC_8BIT_R2R(config, m_ldac, 0).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // ls374.ic5 + r7 (8x20k) + r9 (8x10k) - DAC_8BIT_R2R(config, m_rdac, 0).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // ls374.ic4 + r6 (8x20k) + r8 (8x10k) + DAC_8BIT_R2R(config, m_ldac).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // ls374.ic5 + r7 (8x20k) + r9 (8x10k) + DAC_8BIT_R2R(config, m_rdac).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // ls374.ic4 + r6 (8x20k) + r8 (8x10k) } //------------------------------------------------- diff --git a/src/devices/bus/coco/coco_pak.cpp b/src/devices/bus/coco/coco_pak.cpp index b01698633eb..72561d2a93c 100644 --- a/src/devices/bus/coco/coco_pak.cpp +++ b/src/devices/bus/coco/coco_pak.cpp @@ -55,14 +55,14 @@ DEFINE_DEVICE_TYPE(COCO_PAK, coco_pak_device, "cocopak", "CoCo Program PAK") //------------------------------------------------- // coco_pak_device - constructor //------------------------------------------------- -coco_pak_device::coco_pak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +coco_pak_device::coco_pak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_cart(nullptr), m_eprom(*this, CARTSLOT_TAG), m_autostart(*this, CART_AUTOSTART_TAG) { } -coco_pak_device::coco_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_pak_device::coco_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_pak_device(mconfig, COCO_PAK, tag, owner, clock) { } @@ -171,12 +171,12 @@ DEFINE_DEVICE_TYPE(COCO_PAK_BANKED, coco_pak_banked_device, "cocopak_banked", "C // coco_pak_device - constructor //------------------------------------------------- -coco_pak_banked_device::coco_pak_banked_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +coco_pak_banked_device::coco_pak_banked_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : coco_pak_device(mconfig, type, tag, owner, clock) , m_pos(0) { } -coco_pak_banked_device::coco_pak_banked_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_pak_banked_device::coco_pak_banked_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_pak_banked_device(mconfig, COCO_PAK_BANKED, tag, owner, clock) { } diff --git a/src/devices/bus/coco/coco_pak.h b/src/devices/bus/coco/coco_pak.h index 2add297bbc6..7787c57f39d 100644 --- a/src/devices/bus/coco/coco_pak.h +++ b/src/devices/bus/coco/coco_pak.h @@ -19,7 +19,7 @@ class coco_pak_device : { public: // construction/destruction - coco_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -30,7 +30,7 @@ public: virtual memory_region *get_cart_memregion() override; protected: - coco_pak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + coco_pak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -50,10 +50,10 @@ class coco_pak_banked_device : public coco_pak_device { public: // construction/destruction - coco_pak_banked_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_pak_banked_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - coco_pak_banked_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + coco_pak_banked_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/coco/coco_psg.cpp b/src/devices/bus/coco/coco_psg.cpp index 5f3d84c98da..ade232da48f 100644 --- a/src/devices/bus/coco/coco_psg.cpp +++ b/src/devices/bus/coco/coco_psg.cpp @@ -104,7 +104,7 @@ void coco_psg_device::device_add_mconfig(machine_config &config) // coco_psg_device - constructor //------------------------------------------------- -coco_psg_device::coco_psg_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_psg_device::coco_psg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_PSG, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_psg(*this, "psg") diff --git a/src/devices/bus/coco/coco_psg.h b/src/devices/bus/coco/coco_psg.h index 34c344c26e7..83bd13a86c1 100644 --- a/src/devices/bus/coco/coco_psg.h +++ b/src/devices/bus/coco/coco_psg.h @@ -22,7 +22,7 @@ class coco_psg_device : { public: // construction/destruction - coco_psg_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_psg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/coco/coco_ram.cpp b/src/devices/bus/coco/coco_ram.cpp index 885cc55a34d..5d227acd528 100644 --- a/src/devices/bus/coco/coco_ram.cpp +++ b/src/devices/bus/coco/coco_ram.cpp @@ -41,7 +41,7 @@ namespace { public: // construction/destruction - coco_pak_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_pak_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; protected: @@ -71,7 +71,7 @@ DEFINE_DEVICE_TYPE_PRIVATE(COCO_PAK_RAM, device_cococart_interface, coco_pak_ram // coco_pak_device - constructor //------------------------------------------------- -coco_pak_ram_device::coco_pak_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_pak_ram_device::coco_pak_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_PAK_RAM, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_staticram(*this, STATICRAM_TAG) diff --git a/src/devices/bus/coco/coco_rs232.cpp b/src/devices/bus/coco/coco_rs232.cpp index 90f7c6f7be7..326f4547bd7 100644 --- a/src/devices/bus/coco/coco_rs232.cpp +++ b/src/devices/bus/coco/coco_rs232.cpp @@ -36,7 +36,7 @@ namespace { public: // construction/destruction - coco_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + coco_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_RS232, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_eprom(*this, "eprom") @@ -90,7 +90,7 @@ IMPLEMENTATION void coco_rs232_device::device_add_mconfig(machine_config &config) { - MOS6551(config, m_uart, 0); + MOS6551(config, m_uart); m_uart->set_xtal(1.8432_MHz_XTAL); m_uart->irq_handler().set(FUNC(coco_rs232_device::uart_irq_w)); m_uart->txd_handler().set(PORT_TAG, FUNC(rs232_port_device::write_txd)); diff --git a/src/devices/bus/coco/coco_ssc.cpp b/src/devices/bus/coco/coco_ssc.cpp index 7c8d497a224..b2890fa4349 100644 --- a/src/devices/bus/coco/coco_ssc.cpp +++ b/src/devices/bus/coco/coco_ssc.cpp @@ -85,7 +85,7 @@ namespace { public: // construction/destruction - coco_ssc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_ssc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -126,7 +126,7 @@ namespace public device_sound_interface { public: - cocossc_sac_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cocossc_sac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~cocossc_sac_device() { } bool sound_activity_circuit_output(); @@ -200,7 +200,7 @@ ROM_END // coco_ssc_device - constructor //------------------------------------------------- -coco_ssc_device::coco_ssc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_ssc_device::coco_ssc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_SSC, tag, owner, clock), device_cococart_interface(mconfig, *this ), m_tms7040(*this, PIC_TAG), @@ -475,7 +475,7 @@ void coco_ssc_device::ssc_port_d_w(u8 data) // cocossc_sac_device - constructor //------------------------------------------------- -cocossc_sac_device::cocossc_sac_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cocossc_sac_device::cocossc_sac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCOSSC_SAC, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/bus/coco/coco_stecomp.cpp b/src/devices/bus/coco/coco_stecomp.cpp index 412f4e3f865..ef277c55e9a 100644 --- a/src/devices/bus/coco/coco_stecomp.cpp +++ b/src/devices/bus/coco/coco_stecomp.cpp @@ -35,7 +35,7 @@ namespace { public: // construction/destruction - coco_stereo_composer_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + coco_stereo_composer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_STEREO_COMPOSER, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_pia(*this, "sc_pia") @@ -70,10 +70,10 @@ namespace { SPEAKER(config, "sc_lspeaker").front_left(); SPEAKER(config, "sc_rspeaker").front_right(); - DAC_8BIT_R2R(config, m_ldac, 0).add_route(ALL_OUTPUTS, "sc_lspeaker", 0.5); - DAC_8BIT_R2R(config, m_rdac, 0).add_route(ALL_OUTPUTS, "sc_rspeaker", 0.5); + DAC_8BIT_R2R(config, m_ldac).add_route(ALL_OUTPUTS, "sc_lspeaker", 0.5); + DAC_8BIT_R2R(config, m_rdac).add_route(ALL_OUTPUTS, "sc_rspeaker", 0.5); - pia6821_device &pia(PIA6821(config, "sc_pia", 0)); + pia6821_device &pia(PIA6821(config, "sc_pia")); pia.writepa_handler().set("sc_ldac", FUNC(dac_byte_interface::data_w)); pia.writepb_handler().set("sc_rdac", FUNC(dac_byte_interface::data_w)); } diff --git a/src/devices/bus/coco/coco_sym12.cpp b/src/devices/bus/coco/coco_sym12.cpp index 1edbb27fccc..75ebe8ba3da 100644 --- a/src/devices/bus/coco/coco_sym12.cpp +++ b/src/devices/bus/coco/coco_sym12.cpp @@ -36,7 +36,7 @@ namespace { public: // construction/destruction - coco_symphony_twelve_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + coco_symphony_twelve_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_SYM12, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_pia(*this, "s12_pia") @@ -72,7 +72,7 @@ namespace void coco_symphony_twelve_device::device_add_mconfig(machine_config &config) { - pia6821_device &pia(PIA6821(config, "s12_pia", 0)); + pia6821_device &pia(PIA6821(config, "s12_pia")); pia.writepa_handler().set(*this, FUNC(coco_symphony_twelve_device::write_porta)); pia.readpa_handler().set(*this, FUNC(coco_symphony_twelve_device::read_porta)); pia.writepb_handler().set(*this, FUNC(coco_symphony_twelve_device::write_portb)); diff --git a/src/devices/bus/coco/coco_t4426.cpp b/src/devices/bus/coco/coco_t4426.cpp index bf236f5b7b8..219f31cedf2 100644 --- a/src/devices/bus/coco/coco_t4426.cpp +++ b/src/devices/bus/coco/coco_t4426.cpp @@ -95,7 +95,7 @@ namespace { public: // construction/destruction - coco_t4426_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_t4426_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; @@ -117,7 +117,7 @@ namespace DECLARE_WRITE_LINE_MEMBER (write_f13_clock){ write_acia_clocks(mc14411_device::TIMER_F13, state); } DECLARE_WRITE_LINE_MEMBER (write_f15_clock){ write_acia_clocks(mc14411_device::TIMER_F15, state); } protected: - coco_t4426_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + coco_t4426_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -151,10 +151,10 @@ namespace void coco_t4426_device::device_add_mconfig(machine_config &config) { - PIA6821(config, m_pia, 0); + PIA6821(config, m_pia); m_pia->writepa_handler().set(FUNC(coco_t4426_device::pia_A_w)); - ACIA6850(config, m_uart, 0); + ACIA6850(config, m_uart); m_uart->txd_handler().set(SERIAL_TAG, FUNC(rs232_port_device::write_txd)); m_uart->rts_handler().set(SERIAL_TAG, FUNC(rs232_port_device::write_rts)); @@ -236,7 +236,7 @@ DEFINE_DEVICE_TYPE_PRIVATE(COCO_T4426, device_cococart_interface, coco_t4426_dev // coco_t4426_device - constructor //------------------------------------------------- -coco_t4426_device::coco_t4426_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +coco_t4426_device::coco_t4426_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_cart(nullptr) @@ -251,7 +251,7 @@ coco_t4426_device::coco_t4426_device(const machine_config &mconfig, device_type { } -coco_t4426_device::coco_t4426_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_t4426_device::coco_t4426_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_t4426_device(mconfig, COCO_T4426, tag, owner, clock) { } diff --git a/src/devices/bus/coco/coco_wpk.cpp b/src/devices/bus/coco/coco_wpk.cpp index e2750428227..69d36d8be8c 100644 --- a/src/devices/bus/coco/coco_wpk.cpp +++ b/src/devices/bus/coco/coco_wpk.cpp @@ -44,7 +44,7 @@ DEFINE_DEVICE_TYPE(COCO_WPKRS, coco_wpkrs_device, "coco_wpkrs", "CoCo WordPak RS // coco_wpk_device - constructor //------------------------------------------------- -coco_wpk_device::coco_wpk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +coco_wpk_device::coco_wpk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_cococart_interface(mconfig, *this ) , m_crtc(*this, "crtc") @@ -54,17 +54,17 @@ coco_wpk_device::coco_wpk_device(const machine_config &mconfig, device_type type { } -coco_wpk_device::coco_wpk_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_wpk_device::coco_wpk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_wpk_device(mconfig, COCO_WPK, tag, owner, clock) { } -coco_wpk2_device::coco_wpk2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_wpk2_device::coco_wpk2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_wpk_device(mconfig, COCO_WPK2, tag, owner, clock) { } -coco_wpkrs_device::coco_wpkrs_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_wpkrs_device::coco_wpkrs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : coco_wpk_device(mconfig, COCO_WPKRS, tag, owner, clock) { } diff --git a/src/devices/bus/coco/coco_wpk.h b/src/devices/bus/coco/coco_wpk.h index 33db6c4be73..8c9fdfc121d 100644 --- a/src/devices/bus/coco/coco_wpk.h +++ b/src/devices/bus/coco/coco_wpk.h @@ -24,11 +24,11 @@ public: static constexpr feature_type imperfect_features() { return feature::GRAPHICS; } // construction/destruction - coco_wpk_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_wpk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // construction/destruction - coco_wpk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + coco_wpk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -58,7 +58,7 @@ class coco_wpk2_device : public coco_wpk_device { public: // construction/destruction - coco_wpk2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + coco_wpk2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -76,7 +76,7 @@ class coco_wpkrs_device : public coco_wpk_device { public: // construction/destruction - coco_wpkrs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + coco_wpkrs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/coco/coco_wpk2p.cpp b/src/devices/bus/coco/coco_wpk2p.cpp index 62fb2504bf7..25009d8b9a9 100644 --- a/src/devices/bus/coco/coco_wpk2p.cpp +++ b/src/devices/bus/coco/coco_wpk2p.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(COCO_WPK2P, coco_wpk2p_device, "coco_wpk2p", "CoCo WordPak 2+ // coco_wpk2p_device - constructor //------------------------------------------------- -coco_wpk2p_device::coco_wpk2p_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +coco_wpk2p_device::coco_wpk2p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCO_WPK2P, tag, owner, clock) , device_cococart_interface(mconfig, *this ) , m_v9958(*this, "v9958") diff --git a/src/devices/bus/coco/coco_wpk2p.h b/src/devices/bus/coco/coco_wpk2p.h index f6c3debc766..87da0b44e32 100644 --- a/src/devices/bus/coco/coco_wpk2p.h +++ b/src/devices/bus/coco/coco_wpk2p.h @@ -21,7 +21,7 @@ class coco_wpk2p_device : { public: // construction/destruction - coco_wpk2p_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + coco_wpk2p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/coco/cococart.cpp b/src/devices/bus/coco/cococart.cpp index ec387378fb8..737f6203e53 100644 --- a/src/devices/bus/coco/cococart.cpp +++ b/src/devices/bus/coco/cococart.cpp @@ -123,7 +123,7 @@ ALLOW_SAVE_TYPE(cococart_slot_device::line_value); //------------------------------------------------- // cococart_slot_device - constructor //------------------------------------------------- -cococart_slot_device::cococart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +cococart_slot_device::cococart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COCOCART_SLOT, tag, owner, clock), device_single_card_slot_interface<device_cococart_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/coco/cococart.h b/src/devices/bus/coco/cococart.h index b686ac0748d..33ee3f2d9df 100644 --- a/src/devices/bus/coco/cococart.h +++ b/src/devices/bus/coco/cococart.h @@ -53,7 +53,7 @@ public: // construction/destruction template <typename T> - cococart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&opts, const char *dflt) + cococart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : cococart_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -61,7 +61,7 @@ public: set_default_option(dflt); set_fixed(false); } - cococart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cococart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto cart_callback() { return m_cart_callback.bind(); } auto nmi_callback() { return m_nmi_callback.bind(); } diff --git a/src/devices/bus/coco/dragon_amtor.cpp b/src/devices/bus/coco/dragon_amtor.cpp index 7ce51671153..5eff8fd2842 100644 --- a/src/devices/bus/coco/dragon_amtor.cpp +++ b/src/devices/bus/coco/dragon_amtor.cpp @@ -53,7 +53,7 @@ INPUT_PORTS_END // dragon_amtor_device - constructor //------------------------------------------------- -dragon_amtor_device::dragon_amtor_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dragon_amtor_device::dragon_amtor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DRAGON_AMTOR, tag, owner, clock) , device_cococart_interface(mconfig, *this) , m_eprom(*this, "eprom") diff --git a/src/devices/bus/coco/dragon_amtor.h b/src/devices/bus/coco/dragon_amtor.h index 3d6e73fc40a..931d2388921 100644 --- a/src/devices/bus/coco/dragon_amtor.h +++ b/src/devices/bus/coco/dragon_amtor.h @@ -19,7 +19,7 @@ class dragon_amtor_device : { public: // construction/destruction - dragon_amtor_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dragon_amtor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/coco/dragon_claw.cpp b/src/devices/bus/coco/dragon_claw.cpp index a4c00b0f71a..affcfeaa40b 100644 --- a/src/devices/bus/coco/dragon_claw.cpp +++ b/src/devices/bus/coco/dragon_claw.cpp @@ -59,7 +59,7 @@ ioport_constructor dragon_claw_device::device_input_ports() const // dragon_claw_device - constructor //------------------------------------------------- -dragon_claw_device::dragon_claw_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dragon_claw_device::dragon_claw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DRAGON_CLAW, tag, owner, clock) , device_cococart_interface(mconfig, *this ) , m_via(*this, "via") diff --git a/src/devices/bus/coco/dragon_claw.h b/src/devices/bus/coco/dragon_claw.h index 9743b5b0b3c..f31dcc6e12f 100644 --- a/src/devices/bus/coco/dragon_claw.h +++ b/src/devices/bus/coco/dragon_claw.h @@ -22,7 +22,7 @@ class dragon_claw_device : { public: // construction/destruction - dragon_claw_device(const machine_config& mconfig, const char* tag, device_t* owner, u32 clock); + dragon_claw_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/coco/dragon_fdc.cpp b/src/devices/bus/coco/dragon_fdc.cpp index 5a70433e559..611a48ab091 100644 --- a/src/devices/bus/coco/dragon_fdc.cpp +++ b/src/devices/bus/coco/dragon_fdc.cpp @@ -96,7 +96,7 @@ namespace { protected: // construction/destruction - dragon_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + dragon_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual u8 cts_read(offs_t offset) override; @@ -118,7 +118,7 @@ namespace { protected: // construction/destruction - premier_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + premier_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual u8 cts_read(offs_t offset) override; @@ -178,7 +178,7 @@ void premier_fdc_device_base::device_add_mconfig(machine_config &config) //------------------------------------------------- // dragon_fdc_device_base - constructor //------------------------------------------------- -dragon_fdc_device_base::dragon_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +dragon_fdc_device_base::dragon_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : coco_family_fdc_device_base(mconfig, type, tag, owner, clock) , m_wd2797(*this, "wd2797") , m_floppies(*this, "wd2797:%u", 0) @@ -186,7 +186,7 @@ dragon_fdc_device_base::dragon_fdc_device_base(const machine_config &mconfig, de } -premier_fdc_device_base::premier_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +premier_fdc_device_base::premier_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : coco_family_fdc_device_base(mconfig, type, tag, owner, clock) , m_wd2791(*this, "wd2791") , m_floppies(*this, "wd2791:%u", 0) @@ -395,7 +395,7 @@ namespace { public: // construction/destruction - dragon_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + dragon_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dragon_fdc_device_base(mconfig, DRAGON_FDC, tag, owner, clock) { } @@ -427,7 +427,7 @@ namespace { public: // construction/destruction - premier_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + premier_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : premier_fdc_device_base(mconfig, PREMIER_FDC, tag, owner, clock) { } @@ -459,7 +459,7 @@ namespace { public: // construction/destruction - sdtandy_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + sdtandy_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dragon_fdc_device_base(mconfig, SDTANDY_FDC, tag, owner, clock) { } diff --git a/src/devices/bus/coco/dragon_jcbsnd.cpp b/src/devices/bus/coco/dragon_jcbsnd.cpp index fc5b8390f89..cf91ddc46cd 100644 --- a/src/devices/bus/coco/dragon_jcbsnd.cpp +++ b/src/devices/bus/coco/dragon_jcbsnd.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(DRAGON_JCBSND, dragon_jcbsnd_device, "dragon_jcbsnd", "Dragon // dragon_jcbsnd_device - constructor //------------------------------------------------- -dragon_jcbsnd_device::dragon_jcbsnd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dragon_jcbsnd_device::dragon_jcbsnd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DRAGON_JCBSND, tag, owner, clock) , device_cococart_interface(mconfig, *this ) , m_eprom(*this, "eprom") diff --git a/src/devices/bus/coco/dragon_jcbsnd.h b/src/devices/bus/coco/dragon_jcbsnd.h index 6ded5d6c601..9e13ff7b483 100644 --- a/src/devices/bus/coco/dragon_jcbsnd.h +++ b/src/devices/bus/coco/dragon_jcbsnd.h @@ -20,7 +20,7 @@ class dragon_jcbsnd_device : { public: // construction/destruction - dragon_jcbsnd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dragon_jcbsnd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/coco/dragon_jcbspch.cpp b/src/devices/bus/coco/dragon_jcbspch.cpp index a82d122d275..94445a29e90 100644 --- a/src/devices/bus/coco/dragon_jcbspch.cpp +++ b/src/devices/bus/coco/dragon_jcbspch.cpp @@ -41,7 +41,7 @@ DEFINE_DEVICE_TYPE(DRAGON_JCBSPCH, dragon_jcbspch_device, "dragon_jcbspch", "Dra // dragon_jcbspch_device - constructor //------------------------------------------------- -dragon_jcbspch_device::dragon_jcbspch_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dragon_jcbspch_device::dragon_jcbspch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DRAGON_JCBSPCH, tag, owner, clock) , device_cococart_interface(mconfig, *this ) , m_eprom(*this, "eprom") @@ -83,7 +83,7 @@ memory_region *dragon_jcbspch_device::get_cart_memregion() void dragon_jcbspch_device::device_add_mconfig(machine_config &config) { - PIA6821(config, m_pia, 0); + PIA6821(config, m_pia); m_pia->writepb_handler().set(m_nsp, FUNC(sp0256_device::ald_w)).mask(0x3f); m_pia->cb2_handler().set(FUNC(dragon_jcbspch_device::pia_cb2_w)); m_pia->irqb_handler().set(FUNC(dragon_jcbspch_device::nmi_w)); diff --git a/src/devices/bus/coco/dragon_jcbspch.h b/src/devices/bus/coco/dragon_jcbspch.h index e8761dec2d8..51187678623 100644 --- a/src/devices/bus/coco/dragon_jcbspch.h +++ b/src/devices/bus/coco/dragon_jcbspch.h @@ -21,7 +21,7 @@ class dragon_jcbspch_device : { public: // construction/destruction - dragon_jcbspch_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dragon_jcbspch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/coco/dragon_msx2.cpp b/src/devices/bus/coco/dragon_msx2.cpp index a8da5565991..2b8f2195f88 100644 --- a/src/devices/bus/coco/dragon_msx2.cpp +++ b/src/devices/bus/coco/dragon_msx2.cpp @@ -63,7 +63,7 @@ ioport_constructor dragon_msx2_device::device_input_ports() const // dragon_msx2_device - constructor //------------------------------------------------- -dragon_msx2_device::dragon_msx2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dragon_msx2_device::dragon_msx2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DRAGON_MSX2, tag, owner, clock) , device_cococart_interface(mconfig, *this ) , m_ym2413(*this, "ym2413") diff --git a/src/devices/bus/coco/dragon_msx2.h b/src/devices/bus/coco/dragon_msx2.h index 3eb1fcaa64b..cee2edd73cd 100644 --- a/src/devices/bus/coco/dragon_msx2.h +++ b/src/devices/bus/coco/dragon_msx2.h @@ -23,7 +23,7 @@ class dragon_msx2_device : { public: // construction/destruction - dragon_msx2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dragon_msx2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/coco/dragon_serial.cpp b/src/devices/bus/coco/dragon_serial.cpp index 8967bed816c..d018abeec09 100644 --- a/src/devices/bus/coco/dragon_serial.cpp +++ b/src/devices/bus/coco/dragon_serial.cpp @@ -43,7 +43,7 @@ DEFINE_DEVICE_TYPE(DRAGON_SERIAL, dragon_serial_device, "dragon_serial", "Dragon // dragon_serial_device - constructor //------------------------------------------------- -dragon_serial_device::dragon_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dragon_serial_device::dragon_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DRAGON_SERIAL, tag, owner, clock) , device_cococart_interface(mconfig, *this ) , m_eprom(*this, "eprom") @@ -84,7 +84,7 @@ memory_region *dragon_serial_device::get_cart_memregion() void dragon_serial_device::device_add_mconfig(machine_config &config) { - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("rs232", FUNC(rs232_port_device::write_txd)); m_acia->rts_handler().set("rs232", FUNC(rs232_port_device::write_rts)); m_acia->irq_handler().set([this](int state) { set_line_value(line::NMI, state); }); diff --git a/src/devices/bus/coco/dragon_serial.h b/src/devices/bus/coco/dragon_serial.h index 7f33a61de67..3d162c75e78 100644 --- a/src/devices/bus/coco/dragon_serial.h +++ b/src/devices/bus/coco/dragon_serial.h @@ -20,7 +20,7 @@ class dragon_serial_device : { public: // construction/destruction - dragon_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dragon_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type imperfect_features() { return feature::COMMS; } diff --git a/src/devices/bus/coco/dragon_sprites.cpp b/src/devices/bus/coco/dragon_sprites.cpp index a33d9648715..55bfb59ed68 100644 --- a/src/devices/bus/coco/dragon_sprites.cpp +++ b/src/devices/bus/coco/dragon_sprites.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(DRAGON_SPRITES, dragon_sprites_device, "dragon_sprites", "Dra // dragon_sprites_device - constructor //------------------------------------------------- -dragon_sprites_device::dragon_sprites_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dragon_sprites_device::dragon_sprites_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DRAGON_SPRITES, tag, owner, clock) , device_cococart_interface(mconfig, *this ) , m_eprom(*this, "eprom") diff --git a/src/devices/bus/coco/dragon_sprites.h b/src/devices/bus/coco/dragon_sprites.h index 1236912396e..e5b221c1ebf 100644 --- a/src/devices/bus/coco/dragon_sprites.h +++ b/src/devices/bus/coco/dragon_sprites.h @@ -21,7 +21,7 @@ class dragon_sprites_device : { public: // construction/destruction - dragon_sprites_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dragon_sprites_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/coleco/cartridge/exp.cpp b/src/devices/bus/coleco/cartridge/exp.cpp index 6a73d73efb6..534d7afa753 100644 --- a/src/devices/bus/coleco/cartridge/exp.cpp +++ b/src/devices/bus/coleco/cartridge/exp.cpp @@ -53,7 +53,7 @@ void device_colecovision_cartridge_interface::rom_alloc(size_t size) // colecovision_cartridge_slot_device - constructor //------------------------------------------------- -colecovision_cartridge_slot_device::colecovision_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +colecovision_cartridge_slot_device::colecovision_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COLECOVISION_CARTRIDGE_SLOT, tag, owner, clock), device_single_card_slot_interface<device_colecovision_cartridge_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/coleco/cartridge/exp.h b/src/devices/bus/coleco/cartridge/exp.h index 5e7eaa252d2..8b663c76e97 100644 --- a/src/devices/bus/coleco/cartridge/exp.h +++ b/src/devices/bus/coleco/cartridge/exp.h @@ -55,14 +55,14 @@ public: // construction/destruction template <typename T> colecovision_cartridge_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : colecovision_cartridge_slot_device(mconfig, tag, owner, (uint32_t)0) + : colecovision_cartridge_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - colecovision_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + colecovision_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // computer interface uint8_t bd_r(offs_t offset, uint8_t data, int _8000, int _a000, int _c000, int _e000); diff --git a/src/devices/bus/coleco/cartridge/megacart.cpp b/src/devices/bus/coleco/cartridge/megacart.cpp index 68b84af653b..48cc7045fad 100644 --- a/src/devices/bus/coleco/cartridge/megacart.cpp +++ b/src/devices/bus/coleco/cartridge/megacart.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(COLECOVISION_MEGACART, colecovision_megacart_cartridge_device // colecovision_megacart_cartridge_device - constructor //------------------------------------------------- -colecovision_megacart_cartridge_device::colecovision_megacart_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +colecovision_megacart_cartridge_device::colecovision_megacart_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COLECOVISION_MEGACART, tag, owner, clock), device_colecovision_cartridge_interface(mconfig, *this), m_bankcount(0), diff --git a/src/devices/bus/coleco/cartridge/megacart.h b/src/devices/bus/coleco/cartridge/megacart.h index 6a0b73f5124..747033c8e61 100644 --- a/src/devices/bus/coleco/cartridge/megacart.h +++ b/src/devices/bus/coleco/cartridge/megacart.h @@ -26,7 +26,7 @@ class colecovision_megacart_cartridge_device : public device_t, { public: // construction/destruction - colecovision_megacart_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + colecovision_megacart_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/coleco/cartridge/std.cpp b/src/devices/bus/coleco/cartridge/std.cpp index 24bb815834e..b6f155ed28b 100644 --- a/src/devices/bus/coleco/cartridge/std.cpp +++ b/src/devices/bus/coleco/cartridge/std.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(COLECOVISION_STANDARD, colecovision_standard_cartridge_device // colecovision_standard_cartridge_device - constructor //------------------------------------------------- -colecovision_standard_cartridge_device::colecovision_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +colecovision_standard_cartridge_device::colecovision_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COLECOVISION_STANDARD, tag, owner, clock), device_colecovision_cartridge_interface(mconfig, *this) { diff --git a/src/devices/bus/coleco/cartridge/std.h b/src/devices/bus/coleco/cartridge/std.h index 6e0c5206ada..c4b3a44553d 100644 --- a/src/devices/bus/coleco/cartridge/std.h +++ b/src/devices/bus/coleco/cartridge/std.h @@ -26,7 +26,7 @@ class colecovision_standard_cartridge_device : public device_t, { public: // construction/destruction - colecovision_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + colecovision_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/coleco/cartridge/xin1.cpp b/src/devices/bus/coleco/cartridge/xin1.cpp index 954c4a6e483..1548f0699b6 100644 --- a/src/devices/bus/coleco/cartridge/xin1.cpp +++ b/src/devices/bus/coleco/cartridge/xin1.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(COLECOVISION_XIN1, colecovision_xin1_cartridge_device, "colec // colecovision_xin1_cartridge_device - constructor //------------------------------------------------- -colecovision_xin1_cartridge_device::colecovision_xin1_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +colecovision_xin1_cartridge_device::colecovision_xin1_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COLECOVISION_XIN1, tag, owner, clock), device_colecovision_cartridge_interface(mconfig, *this), m_current_offset(0) diff --git a/src/devices/bus/coleco/cartridge/xin1.h b/src/devices/bus/coleco/cartridge/xin1.h index 0e8a7813c9f..624984e270a 100644 --- a/src/devices/bus/coleco/cartridge/xin1.h +++ b/src/devices/bus/coleco/cartridge/xin1.h @@ -26,7 +26,7 @@ class colecovision_xin1_cartridge_device : public device_t, { public: // construction/destruction - colecovision_xin1_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + colecovision_xin1_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/coleco/controller/ctrl.cpp b/src/devices/bus/coleco/controller/ctrl.cpp index 80b5968eb03..2ea1081a57e 100644 --- a/src/devices/bus/coleco/controller/ctrl.cpp +++ b/src/devices/bus/coleco/controller/ctrl.cpp @@ -45,7 +45,7 @@ device_colecovision_control_port_interface::device_colecovision_control_port_int // colecovision_control_port_device - constructor //------------------------------------------------- -colecovision_control_port_device::colecovision_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +colecovision_control_port_device::colecovision_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COLECOVISION_CONTROL_PORT, tag, owner, clock), device_single_card_slot_interface<device_colecovision_control_port_interface>(mconfig, *this), m_device(nullptr), diff --git a/src/devices/bus/coleco/controller/ctrl.h b/src/devices/bus/coleco/controller/ctrl.h index 3d87a19b355..2fbcc097f1f 100644 --- a/src/devices/bus/coleco/controller/ctrl.h +++ b/src/devices/bus/coleco/controller/ctrl.h @@ -50,14 +50,14 @@ public: // construction/destruction template <typename T> colecovision_control_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : colecovision_control_port_device(mconfig, tag, owner, (uint32_t)0) + : colecovision_control_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - colecovision_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + colecovision_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // static configuration helpers auto irq() { return m_write_irq.bind(); } diff --git a/src/devices/bus/coleco/controller/hand.cpp b/src/devices/bus/coleco/controller/hand.cpp index d5e4d72b6bc..6364e80f2f0 100644 --- a/src/devices/bus/coleco/controller/hand.cpp +++ b/src/devices/bus/coleco/controller/hand.cpp @@ -90,7 +90,7 @@ ioport_constructor coleco_hand_controller_device::device_input_ports() const // coleco_hand_controller_device - constructor //------------------------------------------------- -coleco_hand_controller_device::coleco_hand_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +coleco_hand_controller_device::coleco_hand_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COLECO_HAND_CONTROLLER, tag, owner, clock), device_colecovision_control_port_interface(mconfig, *this), m_io_common0(*this, "COMMON0"), diff --git a/src/devices/bus/coleco/controller/hand.h b/src/devices/bus/coleco/controller/hand.h index f65ad709106..9da3eb76f55 100644 --- a/src/devices/bus/coleco/controller/hand.h +++ b/src/devices/bus/coleco/controller/hand.h @@ -26,7 +26,7 @@ class coleco_hand_controller_device : public device_t, { public: // construction/destruction - coleco_hand_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + coleco_hand_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/coleco/controller/sac.cpp b/src/devices/bus/coleco/controller/sac.cpp index 7621897c78d..525ce109a22 100644 --- a/src/devices/bus/coleco/controller/sac.cpp +++ b/src/devices/bus/coleco/controller/sac.cpp @@ -102,7 +102,7 @@ ioport_constructor coleco_super_action_controller_device::device_input_ports() c // coleco_super_action_controller_device - constructor //------------------------------------------------- -coleco_super_action_controller_device::coleco_super_action_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +coleco_super_action_controller_device::coleco_super_action_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COLECO_SUPER_ACTION_CONTROLLER, tag, owner, clock), device_colecovision_control_port_interface(mconfig, *this), m_io_common0(*this, "COMMON0"), diff --git a/src/devices/bus/coleco/controller/sac.h b/src/devices/bus/coleco/controller/sac.h index 20078e33ef7..fc231ede99a 100644 --- a/src/devices/bus/coleco/controller/sac.h +++ b/src/devices/bus/coleco/controller/sac.h @@ -26,7 +26,7 @@ class coleco_super_action_controller_device : public device_t, { public: // construction/destruction - coleco_super_action_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + coleco_super_action_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/compis/graphics.cpp b/src/devices/bus/compis/graphics.cpp index ad9291dee65..7662d7ec2b4 100644 --- a/src/devices/bus/compis/graphics.cpp +++ b/src/devices/bus/compis/graphics.cpp @@ -38,7 +38,7 @@ device_compis_graphics_card_interface::device_compis_graphics_card_interface(con // compis_graphics_slot_device - constructor //------------------------------------------------- -compis_graphics_slot_device::compis_graphics_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +compis_graphics_slot_device::compis_graphics_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMPIS_GRAPHICS_SLOT, tag, owner, clock), device_single_card_slot_interface<device_compis_graphics_card_interface>(mconfig, *this), m_write_dma_request(*this), diff --git a/src/devices/bus/compis/graphics.h b/src/devices/bus/compis/graphics.h index 3f0c8e41cb9..964ea83ae64 100644 --- a/src/devices/bus/compis/graphics.h +++ b/src/devices/bus/compis/graphics.h @@ -50,7 +50,7 @@ class compis_graphics_slot_device : public device_t, public device_single_card_s public: // construction/destruction template <typename T> - compis_graphics_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) + compis_graphics_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts, char const *dflt) : compis_graphics_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -58,7 +58,7 @@ public: set_default_option(dflt); set_fixed(false); } - compis_graphics_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + compis_graphics_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto drq() { return m_write_dma_request.bind(); } diff --git a/src/devices/bus/compis/hrg.cpp b/src/devices/bus/compis/hrg.cpp index 9fcd130bec0..492253550fe 100644 --- a/src/devices/bus/compis/hrg.cpp +++ b/src/devices/bus/compis/hrg.cpp @@ -87,7 +87,7 @@ void compis_hrg_device::device_add_mconfig(machine_config &config) screen.set_visarea(0, 640-1, 0, 400-1); screen.set_screen_update(UPD7220_TAG, FUNC(upd7220_device::screen_update)); - UPD7220(config, m_crtc, 2252500); // unknown clock + UPD7220(config, m_crtc, XTAL::u(2252500)); // unknown clock m_crtc->set_addrmap(0, &compis_hrg_device::hrg_map); m_crtc->set_display_pixels(FUNC(compis_hrg_device::display_pixels)); m_crtc->set_screen(SCREEN_TAG); @@ -123,7 +123,7 @@ void compis_uhrg_device::device_add_mconfig(machine_config &config) // compis_hrg_device - constructor //------------------------------------------------- -compis_hrg_device::compis_hrg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +compis_hrg_device::compis_hrg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_compis_graphics_card_interface(mconfig, *this), m_crtc(*this, UPD7220_TAG), @@ -132,12 +132,12 @@ compis_hrg_device::compis_hrg_device(const machine_config &mconfig, device_type { } -compis_hrg_device::compis_hrg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +compis_hrg_device::compis_hrg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : compis_hrg_device(mconfig, COMPIS_HRG, tag, owner, clock) { } -compis_uhrg_device::compis_uhrg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +compis_uhrg_device::compis_uhrg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : compis_hrg_device(mconfig, COMPIS_UHRG, tag, owner, clock) { } diff --git a/src/devices/bus/compis/hrg.h b/src/devices/bus/compis/hrg.h index 98ef784df14..e9129983011 100644 --- a/src/devices/bus/compis/hrg.h +++ b/src/devices/bus/compis/hrg.h @@ -28,10 +28,10 @@ class compis_hrg_device : public device_t, { public: // construction/destruction - compis_hrg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + compis_hrg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - compis_hrg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + compis_hrg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -63,7 +63,7 @@ class compis_uhrg_device : public compis_hrg_device { public: // construction/destruction - compis_uhrg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + compis_uhrg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/compucolor/floppy.cpp b/src/devices/bus/compucolor/floppy.cpp index 9c8a33870c1..28928d9da4c 100644 --- a/src/devices/bus/compucolor/floppy.cpp +++ b/src/devices/bus/compucolor/floppy.cpp @@ -79,7 +79,7 @@ device_compucolor_floppy_port_interface::device_compucolor_floppy_port_interface // compucolor_floppy_port_device - constructor //------------------------------------------------- -compucolor_floppy_port_device::compucolor_floppy_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +compucolor_floppy_port_device::compucolor_floppy_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rs232_port_device(mconfig, COMPUCOLOR_FLOPPY_PORT, tag, owner, clock), m_dev(nullptr) { } @@ -89,7 +89,7 @@ compucolor_floppy_port_device::compucolor_floppy_port_device(const machine_confi // compucolor_floppy_device - constructor //------------------------------------------------- -compucolor_floppy_device::compucolor_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +compucolor_floppy_device::compucolor_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMPUCOLOR_FLOPPY, tag, owner, clock) , device_compucolor_floppy_port_interface(mconfig, *this) , m_floppy(*this, "floppy") diff --git a/src/devices/bus/compucolor/floppy.h b/src/devices/bus/compucolor/floppy.h index 66247ac9601..53ecfae9582 100644 --- a/src/devices/bus/compucolor/floppy.h +++ b/src/devices/bus/compucolor/floppy.h @@ -41,14 +41,14 @@ class compucolor_floppy_port_device : public rs232_port_device public: template <typename T> compucolor_floppy_port_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : rs232_port_device(mconfig, tag, owner, 0) + : rs232_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - compucolor_floppy_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + compucolor_floppy_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( rw_w ) { if (m_dev) m_dev->rw_w(state); } void stepper_w(uint8_t data) { if (m_dev) m_dev->stepper_w(data); } @@ -70,7 +70,7 @@ class compucolor_floppy_device : public device_t, public device_compucolor_flopp { public: // construction/destruction - compucolor_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + compucolor_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/comx35/clm.cpp b/src/devices/bus/comx35/clm.cpp index d32b4a694f8..70920c4d70b 100644 --- a/src/devices/bus/comx35/clm.cpp +++ b/src/devices/bus/comx35/clm.cpp @@ -165,7 +165,7 @@ void comx_clm_device::device_add_mconfig(machine_config &config) // comx_clm_device - constructor //------------------------------------------------- -comx_clm_device::comx_clm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +comx_clm_device::comx_clm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMX_CLM, tag, owner, clock), device_comx_expansion_card_interface(mconfig, *this), device_gfx_interface(mconfig, *this, nullptr, "palette"), diff --git a/src/devices/bus/comx35/clm.h b/src/devices/bus/comx35/clm.h index de86ff28b7f..61052edf06e 100644 --- a/src/devices/bus/comx35/clm.h +++ b/src/devices/bus/comx35/clm.h @@ -29,7 +29,7 @@ class comx_clm_device : public device_t, { public: // construction/destruction - comx_clm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + comx_clm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/comx35/eprom.cpp b/src/devices/bus/comx35/eprom.cpp index 0267d7c5b62..7eb4ca1481f 100644 --- a/src/devices/bus/comx35/eprom.cpp +++ b/src/devices/bus/comx35/eprom.cpp @@ -57,7 +57,7 @@ const tiny_rom_entry *comx_epr_device::device_rom_region() const // comx_epr_device - constructor //------------------------------------------------- -comx_epr_device::comx_epr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +comx_epr_device::comx_epr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMX_EPR, tag, owner, clock), device_comx_expansion_card_interface(mconfig, *this), m_rom(*this, "f800"), diff --git a/src/devices/bus/comx35/eprom.h b/src/devices/bus/comx35/eprom.h index 90f57e52d3d..de8fb88f812 100644 --- a/src/devices/bus/comx35/eprom.h +++ b/src/devices/bus/comx35/eprom.h @@ -26,7 +26,7 @@ class comx_epr_device : public device_t, { public: // construction/destruction - comx_epr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + comx_epr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/comx35/exp.cpp b/src/devices/bus/comx35/exp.cpp index 9c5095e5fd1..f69dbad5db4 100644 --- a/src/devices/bus/comx35/exp.cpp +++ b/src/devices/bus/comx35/exp.cpp @@ -43,7 +43,7 @@ device_comx_expansion_card_interface::device_comx_expansion_card_interface(const // comx_expansion_slot_device - constructor //------------------------------------------------- -comx_expansion_slot_device::comx_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +comx_expansion_slot_device::comx_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMX_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_comx_expansion_card_interface>(mconfig, *this), m_write_irq(*this), m_card(nullptr) diff --git a/src/devices/bus/comx35/exp.h b/src/devices/bus/comx35/exp.h index 8f99edae4fd..ea13f30a2ac 100644 --- a/src/devices/bus/comx35/exp.h +++ b/src/devices/bus/comx35/exp.h @@ -47,8 +47,8 @@ class comx_expansion_slot_device : public device_t, public device_single_card_sl public: // construction/destruction template <typename T> - comx_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) - : comx_expansion_slot_device(mconfig, tag, owner, clock) + comx_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) + : comx_expansion_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -56,7 +56,7 @@ public: set_fixed(false); } - comx_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + comx_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto irq_callback() { return m_write_irq.bind(); } diff --git a/src/devices/bus/comx35/expbox.cpp b/src/devices/bus/comx35/expbox.cpp index 65c945274f1..b511cbe4dbb 100644 --- a/src/devices/bus/comx35/expbox.cpp +++ b/src/devices/bus/comx35/expbox.cpp @@ -116,7 +116,7 @@ void comx_eb_device::device_add_mconfig(machine_config &config) // comx_eb_device - constructor //------------------------------------------------- -comx_eb_device::comx_eb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +comx_eb_device::comx_eb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMX_EB, tag, owner, clock), device_comx_expansion_card_interface(mconfig, *this), m_rom(*this, "e000"), diff --git a/src/devices/bus/comx35/expbox.h b/src/devices/bus/comx35/expbox.h index c4c89b4f2bc..c49b26992ee 100644 --- a/src/devices/bus/comx35/expbox.h +++ b/src/devices/bus/comx35/expbox.h @@ -34,7 +34,7 @@ class comx_eb_device : public device_t, { public: // construction/destruction - comx_eb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + comx_eb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/comx35/fdc.cpp b/src/devices/bus/comx35/fdc.cpp index 077de3e2c4d..a4e86aa12b4 100644 --- a/src/devices/bus/comx35/fdc.cpp +++ b/src/devices/bus/comx35/fdc.cpp @@ -116,7 +116,7 @@ void comx_fd_device::device_add_mconfig(machine_config &config) // comx_fd_device - constructor //------------------------------------------------- -comx_fd_device::comx_fd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +comx_fd_device::comx_fd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMX_FD, tag, owner, clock), device_comx_expansion_card_interface(mconfig, *this), m_fdc(*this, WD1770_TAG), diff --git a/src/devices/bus/comx35/fdc.h b/src/devices/bus/comx35/fdc.h index 6f2b5ea60bd..a424376d093 100644 --- a/src/devices/bus/comx35/fdc.h +++ b/src/devices/bus/comx35/fdc.h @@ -29,7 +29,7 @@ class comx_fd_device : public device_t, { public: // construction/destruction - comx_fd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + comx_fd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/comx35/joycard.cpp b/src/devices/bus/comx35/joycard.cpp index e76f20a5be8..40844d9b4dd 100644 --- a/src/devices/bus/comx35/joycard.cpp +++ b/src/devices/bus/comx35/joycard.cpp @@ -67,7 +67,7 @@ ioport_constructor comx_joy_device::device_input_ports() const // comx_joy_device - constructor //------------------------------------------------- -comx_joy_device::comx_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +comx_joy_device::comx_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMX_JOY, tag, owner, clock), device_comx_expansion_card_interface(mconfig, *this), m_joy1(*this, "JOY1"), diff --git a/src/devices/bus/comx35/joycard.h b/src/devices/bus/comx35/joycard.h index 92c41431961..81e11722a70 100644 --- a/src/devices/bus/comx35/joycard.h +++ b/src/devices/bus/comx35/joycard.h @@ -26,7 +26,7 @@ class comx_joy_device : public device_t, { public: // construction/destruction - comx_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + comx_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/comx35/printer.cpp b/src/devices/bus/comx35/printer.cpp index 6858d687c0b..e475bcb9e32 100644 --- a/src/devices/bus/comx35/printer.cpp +++ b/src/devices/bus/comx35/printer.cpp @@ -79,7 +79,7 @@ void comx_prn_device::device_add_mconfig(machine_config &config) // comx_prn_device - constructor //------------------------------------------------- -comx_prn_device::comx_prn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +comx_prn_device::comx_prn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMX_PRN, tag, owner, clock), device_comx_expansion_card_interface(mconfig, *this), m_centronics(*this, CENTRONICS_TAG), diff --git a/src/devices/bus/comx35/printer.h b/src/devices/bus/comx35/printer.h index 1ffa3f66046..3aef84ee373 100644 --- a/src/devices/bus/comx35/printer.h +++ b/src/devices/bus/comx35/printer.h @@ -27,7 +27,7 @@ class comx_prn_device : public device_t, public device_comx_expansion_card_inter { public: // construction/destruction - comx_prn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + comx_prn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/comx35/ram.cpp b/src/devices/bus/comx35/ram.cpp index 0f11dfdb194..c091c8c872c 100644 --- a/src/devices/bus/comx35/ram.cpp +++ b/src/devices/bus/comx35/ram.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(COMX_RAM, comx_ram_device, "comx_ram", "COMX-35 RAM Card") // comx_ram_device - constructor //------------------------------------------------- -comx_ram_device::comx_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +comx_ram_device::comx_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMX_RAM, tag, owner, clock), device_comx_expansion_card_interface(mconfig, *this), m_ram(*this, "ram", RAM_SIZE, ENDIANNESS_LITTLE), diff --git a/src/devices/bus/comx35/ram.h b/src/devices/bus/comx35/ram.h index 8ab8703d195..ab8b0b66adf 100644 --- a/src/devices/bus/comx35/ram.h +++ b/src/devices/bus/comx35/ram.h @@ -26,7 +26,7 @@ class comx_ram_device : public device_t, { public: // construction/destruction - comx_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + comx_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/comx35/thermal.cpp b/src/devices/bus/comx35/thermal.cpp index badd1beb8c1..65e1f23ab95 100644 --- a/src/devices/bus/comx35/thermal.cpp +++ b/src/devices/bus/comx35/thermal.cpp @@ -52,7 +52,7 @@ const tiny_rom_entry *comx_thm_device::device_rom_region() const // comx_thm_device - constructor //------------------------------------------------- -comx_thm_device::comx_thm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +comx_thm_device::comx_thm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMX_THM, tag, owner, clock), device_comx_expansion_card_interface(mconfig, *this), m_rom(*this, "c000") diff --git a/src/devices/bus/comx35/thermal.h b/src/devices/bus/comx35/thermal.h index 645f6bf0213..5a91d2a1d62 100644 --- a/src/devices/bus/comx35/thermal.h +++ b/src/devices/bus/comx35/thermal.h @@ -26,7 +26,7 @@ class comx_thm_device : public device_t, { public: // construction/destruction - comx_thm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + comx_thm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/cpc/amdrum.cpp b/src/devices/bus/cpc/amdrum.cpp index 26345f48bc9..f0d32d84896 100644 --- a/src/devices/bus/cpc/amdrum.cpp +++ b/src/devices/bus/cpc/amdrum.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(CPC_AMDRUM, cpc_amdrum_device, "cpc_amdrum", "Amdrum") void cpc_amdrum_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "speaker").front_center(); - ZN428E(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.5); + ZN428E(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.5); // no pass-through } @@ -31,7 +31,7 @@ void cpc_amdrum_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -cpc_amdrum_device::cpc_amdrum_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_amdrum_device::cpc_amdrum_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_AMDRUM, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), diff --git a/src/devices/bus/cpc/amdrum.h b/src/devices/bus/cpc/amdrum.h index 44fede8af4f..019c253e072 100644 --- a/src/devices/bus/cpc/amdrum.h +++ b/src/devices/bus/cpc/amdrum.h @@ -25,7 +25,7 @@ class cpc_amdrum_device : public device_t, { public: // construction/destruction - cpc_amdrum_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_amdrum_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void dac_w(uint8_t data); diff --git a/src/devices/bus/cpc/brunword4.cpp b/src/devices/bus/cpc/brunword4.cpp index c28433b281a..e02fb99009b 100644 --- a/src/devices/bus/cpc/brunword4.cpp +++ b/src/devices/bus/cpc/brunword4.cpp @@ -63,7 +63,7 @@ const tiny_rom_entry *cpc_brunword4_device::device_rom_region() const return ROM_NAME( cpc_brunword4 ); } -cpc_brunword4_device::cpc_brunword4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_brunword4_device::cpc_brunword4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_BRUNWORD_MK4, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), m_rombank_active(false), m_bank_sel(0) diff --git a/src/devices/bus/cpc/brunword4.h b/src/devices/bus/cpc/brunword4.h index c2e93f2a51d..99a7ec20bee 100644 --- a/src/devices/bus/cpc/brunword4.h +++ b/src/devices/bus/cpc/brunword4.h @@ -17,7 +17,7 @@ class cpc_brunword4_device : public device_t, { public: // construction/destruction - cpc_brunword4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_brunword4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/cpc/cpc_pds.cpp b/src/devices/bus/cpc/cpc_pds.cpp index 411b0b6e575..9200f0eff75 100644 --- a/src/devices/bus/cpc/cpc_pds.cpp +++ b/src/devices/bus/cpc/cpc_pds.cpp @@ -29,7 +29,7 @@ void cpc_pds_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -cpc_pds_device::cpc_pds_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_pds_device::cpc_pds_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_PDS, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), diff --git a/src/devices/bus/cpc/cpc_pds.h b/src/devices/bus/cpc/cpc_pds.h index c2d7e68b6fd..764d9b80651 100644 --- a/src/devices/bus/cpc/cpc_pds.h +++ b/src/devices/bus/cpc/cpc_pds.h @@ -34,7 +34,7 @@ class cpc_pds_device : public device_t, { public: // construction/destruction - cpc_pds_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_pds_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t pio_r(offs_t offset); void pio_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/cpc/cpc_rom.cpp b/src/devices/bus/cpc/cpc_rom.cpp index 014d4600858..74a2bf0fb09 100644 --- a/src/devices/bus/cpc/cpc_rom.cpp +++ b/src/devices/bus/cpc/cpc_rom.cpp @@ -20,14 +20,14 @@ void cpc_exp_cards(device_slot_interface &device); // device machine config void cpc_rom_device::device_add_mconfig(machine_config &config) { - CPC_ROMSLOT(config, m_rom[0], 0); - CPC_ROMSLOT(config, m_rom[1], 0); - CPC_ROMSLOT(config, m_rom[2], 0); - CPC_ROMSLOT(config, m_rom[3], 0); - CPC_ROMSLOT(config, m_rom[4], 0); - CPC_ROMSLOT(config, m_rom[5], 0); - CPC_ROMSLOT(config, m_rom[6], 0); - CPC_ROMSLOT(config, m_rom[7], 0); + CPC_ROMSLOT(config, m_rom[0]); + CPC_ROMSLOT(config, m_rom[1]); + CPC_ROMSLOT(config, m_rom[2]); + CPC_ROMSLOT(config, m_rom[3]); + CPC_ROMSLOT(config, m_rom[4]); + CPC_ROMSLOT(config, m_rom[5]); + CPC_ROMSLOT(config, m_rom[6]); + CPC_ROMSLOT(config, m_rom[7]); // pass-through cpc_expansion_slot_device &exp(CPC_EXPANSION_SLOT(config, "exp", DERIVED_CLOCK(1, 1), cpc_exp_cards, nullptr)); @@ -41,7 +41,7 @@ void cpc_rom_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -cpc_rom_device::cpc_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_rom_device::cpc_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_ROM, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_rom(*this, "rom%u", 1) @@ -74,7 +74,7 @@ DEFINE_DEVICE_TYPE(CPC_ROMSLOT, cpc_rom_image_device, "cpc_rom_image", "CPC ROM // cpc_rom_image_device - constructor //------------------------------------------------- -cpc_rom_image_device::cpc_rom_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cpc_rom_image_device::cpc_rom_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_ROMSLOT, tag, owner, clock) , device_rom_image_interface(mconfig, *this) , m_base(nullptr) diff --git a/src/devices/bus/cpc/cpc_rom.h b/src/devices/bus/cpc/cpc_rom.h index a9932dd57a8..08311ba9f94 100644 --- a/src/devices/bus/cpc/cpc_rom.h +++ b/src/devices/bus/cpc/cpc_rom.h @@ -22,7 +22,7 @@ class cpc_rom_image_device : public device_t, public device_rom_image_interface { public: // construction/destruction - cpc_rom_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_rom_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~cpc_rom_image_device(); // image-level overrides @@ -55,7 +55,7 @@ class cpc_rom_device : public device_t, { public: // construction/destruction - cpc_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t* base(uint8_t slot) { if(slot >=1 && slot <= 8) return m_rom[slot]->base(); else return nullptr; } diff --git a/src/devices/bus/cpc/cpc_rs232.cpp b/src/devices/bus/cpc/cpc_rs232.cpp index 4e387f9ab85..4c1f9e39b23 100644 --- a/src/devices/bus/cpc/cpc_rs232.cpp +++ b/src/devices/bus/cpc/cpc_rs232.cpp @@ -35,7 +35,7 @@ ROM_END // device machine config void cpc_rs232_device::device_add_mconfig(machine_config &config) { - PIT8253(config, m_pit, 0); + PIT8253(config, m_pit); m_pit->set_clk<0>(2000000); m_pit->set_clk<1>(2000000); m_pit->set_clk<2>(2000000); @@ -76,12 +76,12 @@ const tiny_rom_entry *cpc_ams_rs232_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -cpc_rs232_device::cpc_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_rs232_device::cpc_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpc_rs232_device(mconfig, CPC_RS232, tag, owner, clock) { } -cpc_rs232_device::cpc_rs232_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +cpc_rs232_device::cpc_rs232_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_pit(*this,"pit"), @@ -91,7 +91,7 @@ cpc_rs232_device::cpc_rs232_device(const machine_config &mconfig, device_type ty { } -cpc_ams_rs232_device::cpc_ams_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_ams_rs232_device::cpc_ams_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpc_rs232_device(mconfig, CPC_RS232_AMS, tag, owner, clock) { } diff --git a/src/devices/bus/cpc/cpc_rs232.h b/src/devices/bus/cpc/cpc_rs232.h index fabbbd2001b..1605e4af5e2 100644 --- a/src/devices/bus/cpc/cpc_rs232.h +++ b/src/devices/bus/cpc/cpc_rs232.h @@ -20,7 +20,7 @@ class cpc_rs232_device : public device_t, public device_cpc_expansion_card_inter { public: // construction/destruction - cpc_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t dart_r(offs_t offset); void dart_w(offs_t offset, uint8_t data); @@ -28,7 +28,7 @@ public: void pit_w(offs_t offset, uint8_t data); protected: - cpc_rs232_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cpc_rs232_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -54,7 +54,7 @@ class cpc_ams_rs232_device : public cpc_rs232_device { public: // construction/destruction - cpc_ams_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_ams_rs232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/cpc/cpc_ssa1.cpp b/src/devices/bus/cpc/cpc_ssa1.cpp index 40cfcccf0da..d67e4dd13d5 100644 --- a/src/devices/bus/cpc/cpc_ssa1.cpp +++ b/src/devices/bus/cpc/cpc_ssa1.cpp @@ -150,7 +150,7 @@ void cpc_dkspeech_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -cpc_ssa1_device::cpc_ssa1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_ssa1_device::cpc_ssa1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_SSA1, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), m_rom(nullptr), m_lrq(1), m_sby(0), @@ -158,7 +158,7 @@ cpc_ssa1_device::cpc_ssa1_device(const machine_config &mconfig, const char *tag, { } -cpc_dkspeech_device::cpc_dkspeech_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_dkspeech_device::cpc_dkspeech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_DKSPEECH, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), m_rom(nullptr), m_lrq(1), m_sby(0), diff --git a/src/devices/bus/cpc/cpc_ssa1.h b/src/devices/bus/cpc/cpc_ssa1.h index 7157d9a0475..88ad17757d3 100644 --- a/src/devices/bus/cpc/cpc_ssa1.h +++ b/src/devices/bus/cpc/cpc_ssa1.h @@ -54,7 +54,7 @@ class cpc_ssa1_device : public device_t, { public: // construction/destruction - cpc_ssa1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_ssa1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_lrq(uint8_t state) { m_lrq = state; } uint8_t get_lrq() { return m_lrq; } @@ -91,7 +91,7 @@ class cpc_dkspeech_device : public device_t, { public: // construction/destruction - cpc_dkspeech_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_dkspeech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_lrq(uint8_t state) { m_lrq = state; } uint8_t get_lrq() { return m_lrq; } diff --git a/src/devices/bus/cpc/cpcexp.cpp b/src/devices/bus/cpc/cpcexp.cpp index a8e1420f22d..daf1d7c0f7f 100644 --- a/src/devices/bus/cpc/cpcexp.cpp +++ b/src/devices/bus/cpc/cpcexp.cpp @@ -41,7 +41,7 @@ device_cpc_expansion_card_interface::~device_cpc_expansion_card_interface() // LIVE DEVICE //************************************************************************** -cpc_expansion_slot_device::cpc_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cpc_expansion_slot_device::cpc_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_EXPANSION_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_cpc_expansion_card_interface>(mconfig, *this) , m_cpu(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/bus/cpc/cpcexp.h b/src/devices/bus/cpc/cpcexp.h index 6793a116e6e..036119c9b27 100644 --- a/src/devices/bus/cpc/cpcexp.h +++ b/src/devices/bus/cpc/cpcexp.h @@ -92,9 +92,9 @@ class cpc_expansion_slot_device : public device_t, public device_single_card_slo { public: // construction/destruction - cpc_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> - cpc_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + cpc_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : cpc_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); diff --git a/src/devices/bus/cpc/ddi1.cpp b/src/devices/bus/cpc/ddi1.cpp index 7deaa49eabd..6a3cef24130 100644 --- a/src/devices/bus/cpc/ddi1.cpp +++ b/src/devices/bus/cpc/ddi1.cpp @@ -58,7 +58,7 @@ void cpc_ddi1_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -cpc_ddi1_device::cpc_ddi1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_ddi1_device::cpc_ddi1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_DDI1, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), m_fdc(*this,"upd765"), diff --git a/src/devices/bus/cpc/ddi1.h b/src/devices/bus/cpc/ddi1.h index ab25ce454d3..a763b54f587 100644 --- a/src/devices/bus/cpc/ddi1.h +++ b/src/devices/bus/cpc/ddi1.h @@ -21,7 +21,7 @@ class cpc_ddi1_device : public device_t, public device_cpc_expansion_card_interf { public: // construction/destruction - cpc_ddi1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_ddi1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void motor_w(offs_t offset, uint8_t data); void fdc_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/cpc/doubler.cpp b/src/devices/bus/cpc/doubler.cpp index 3a30f6b5449..007c3682bf9 100644 --- a/src/devices/bus/cpc/doubler.cpp +++ b/src/devices/bus/cpc/doubler.cpp @@ -31,7 +31,7 @@ void cpc_doubler_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -cpc_doubler_device::cpc_doubler_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_doubler_device::cpc_doubler_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_DOUBLER, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), m_tape(*this,"doubler_tape") diff --git a/src/devices/bus/cpc/doubler.h b/src/devices/bus/cpc/doubler.h index 13e3370dd99..a99ed8483bb 100644 --- a/src/devices/bus/cpc/doubler.h +++ b/src/devices/bus/cpc/doubler.h @@ -22,7 +22,7 @@ class cpc_doubler_device : public device_t, { public: // construction/destruction - cpc_doubler_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_doubler_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t ext_tape_r(); diff --git a/src/devices/bus/cpc/hd20.cpp b/src/devices/bus/cpc/hd20.cpp index 81fa6d90c43..7ec59cf5eb8 100644 --- a/src/devices/bus/cpc/hd20.cpp +++ b/src/devices/bus/cpc/hd20.cpp @@ -43,7 +43,7 @@ const tiny_rom_entry *cpc_hd20_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -cpc_hd20_device::cpc_hd20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_hd20_device::cpc_hd20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_HD20, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), m_hdc(*this, "hdc") diff --git a/src/devices/bus/cpc/hd20.h b/src/devices/bus/cpc/hd20.h index 684f7c90901..5272f9d9a45 100644 --- a/src/devices/bus/cpc/hd20.h +++ b/src/devices/bus/cpc/hd20.h @@ -24,7 +24,7 @@ class cpc_hd20_device : public device_t, { public: // construction/destruction - cpc_hd20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_hd20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t hdc_r(offs_t offset); void hdc_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/cpc/magicsound.cpp b/src/devices/bus/cpc/magicsound.cpp index 194791f4a38..13fa79a3126 100644 --- a/src/devices/bus/cpc/magicsound.cpp +++ b/src/devices/bus/cpc/magicsound.cpp @@ -41,7 +41,7 @@ void al_magicsound_device::device_add_mconfig(machine_config &config) // According to the schematics, the clock is from the clock pin on the expansion port (4MHz), and // passes through an inverter to each CLK pin on both timers. This seems to be too fast. // Timer outputs to SAM0/1/2/3 are sample clocks for each sound channel, D/A0 is the low bit of the channel select. - PIT8254(config, m_timer1, 0); + PIT8254(config, m_timer1); m_timer1->set_clk<0>(4000000); m_timer1->out_handler<0>().set(FUNC(al_magicsound_device::sam0_w)); m_timer1->set_clk<1>(4000000); @@ -49,7 +49,7 @@ void al_magicsound_device::device_add_mconfig(machine_config &config) m_timer1->set_clk<2>(4000000); m_timer1->out_handler<2>().set(FUNC(al_magicsound_device::sam2_w)); - PIT8254(config, m_timer2, 0); + PIT8254(config, m_timer2); m_timer2->set_clk<0>(4000000); m_timer2->out_handler<0>().set(FUNC(al_magicsound_device::sam3_w)); m_timer2->set_clk<1>(4000000); @@ -57,7 +57,7 @@ void al_magicsound_device::device_add_mconfig(machine_config &config) m_timer2->set_clk<2>(4000000); SPEAKER(config, "speaker").front_center(); - DAC_8BIT_R2R(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.5); // unknown DAC + DAC_8BIT_R2R(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.5); // unknown DAC // no pass-through(?) } @@ -66,7 +66,7 @@ void al_magicsound_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -al_magicsound_device::al_magicsound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +al_magicsound_device::al_magicsound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AL_MAGICSOUND, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), m_dac(*this,"dac"), diff --git a/src/devices/bus/cpc/magicsound.h b/src/devices/bus/cpc/magicsound.h index e40b6230d41..f3d1ba22cf0 100644 --- a/src/devices/bus/cpc/magicsound.h +++ b/src/devices/bus/cpc/magicsound.h @@ -39,7 +39,7 @@ class al_magicsound_device : public device_t, { public: // construction/destruction - al_magicsound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + al_magicsound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t dmac_r(offs_t offset); void dmac_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/cpc/mface2.cpp b/src/devices/bus/cpc/mface2.cpp index 831a895b439..e28d110dec9 100644 --- a/src/devices/bus/cpc/mface2.cpp +++ b/src/devices/bus/cpc/mface2.cpp @@ -307,7 +307,7 @@ ioport_constructor cpc_multiface2_device::device_input_ports() const // LIVE DEVICE //************************************************************************** -cpc_multiface2_device::cpc_multiface2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_multiface2_device::cpc_multiface2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_MFACE2, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), m_multiface_ram(nullptr), m_multiface_flags(0), m_romdis(0) diff --git a/src/devices/bus/cpc/mface2.h b/src/devices/bus/cpc/mface2.h index ba230b917c6..c0258e363db 100644 --- a/src/devices/bus/cpc/mface2.h +++ b/src/devices/bus/cpc/mface2.h @@ -37,7 +37,7 @@ class cpc_multiface2_device : public device_t, { public: // construction/destruction - cpc_multiface2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_multiface2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); int multiface_hardware_enabled(); void multiface_rethink_memory(); diff --git a/src/devices/bus/cpc/musicmachine.cpp b/src/devices/bus/cpc/musicmachine.cpp index a02be0c70b7..2c8e5de8691 100644 --- a/src/devices/bus/cpc/musicmachine.cpp +++ b/src/devices/bus/cpc/musicmachine.cpp @@ -25,11 +25,11 @@ void cpc_musicmachine_device::device_add_mconfig(machine_config &config) m_acia->irq_handler().set(DEVICE_SELF_OWNER, FUNC(cpc_expansion_slot_device::nmi_w)); MIDI_PORT(config, "mdin", midiin_slot, "midiin").rxd_handler().set(m_acia, FUNC(acia6850_device::write_rxd)); MIDI_PORT(config, "mdout", midiout_slot, "midiout"); - clock_device &acia_clock(CLOCK(config, "acia_clock", 31250*16)); + clock_device &acia_clock(CLOCK(config, "acia_clock", XTAL::u(31250*16))); acia_clock.signal_handler().set(FUNC(cpc_musicmachine_device::write_acia_clock)); SPEAKER(config, "speaker").front_center(); - ZN429E(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.2); + ZN429E(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.2); // no pass-through } @@ -38,7 +38,7 @@ void cpc_musicmachine_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -cpc_musicmachine_device::cpc_musicmachine_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_musicmachine_device::cpc_musicmachine_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_MUSICMACHINE, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), diff --git a/src/devices/bus/cpc/musicmachine.h b/src/devices/bus/cpc/musicmachine.h index 57c1b6f5273..dd10cf894cc 100644 --- a/src/devices/bus/cpc/musicmachine.h +++ b/src/devices/bus/cpc/musicmachine.h @@ -21,7 +21,7 @@ class cpc_musicmachine_device : public device_t, { public: // construction/destruction - cpc_musicmachine_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_musicmachine_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void dac_w(uint8_t data); uint8_t acia_r(offs_t offset); diff --git a/src/devices/bus/cpc/playcity.cpp b/src/devices/bus/cpc/playcity.cpp index c6abaeed14e..397a26b8d70 100644 --- a/src/devices/bus/cpc/playcity.cpp +++ b/src/devices/bus/cpc/playcity.cpp @@ -50,7 +50,7 @@ void cpc_playcity_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -cpc_playcity_device::cpc_playcity_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_playcity_device::cpc_playcity_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_PLAYCITY, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), diff --git a/src/devices/bus/cpc/playcity.h b/src/devices/bus/cpc/playcity.h index 5dd8459e986..c148bf44b83 100644 --- a/src/devices/bus/cpc/playcity.h +++ b/src/devices/bus/cpc/playcity.h @@ -28,7 +28,7 @@ class cpc_playcity_device : public device_t, public device_cpc_expansion_card_in { public: // construction/destruction - cpc_playcity_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_playcity_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t ctc_r(offs_t offset); void ctc_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/cpc/smartwatch.cpp b/src/devices/bus/cpc/smartwatch.cpp index a58b30f2c0a..651fd62731d 100644 --- a/src/devices/bus/cpc/smartwatch.cpp +++ b/src/devices/bus/cpc/smartwatch.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(CPC_SMARTWATCH, cpc_smartwatch_device, "cpc_smartwatch", "Dob void cpc_smartwatch_device::device_add_mconfig(machine_config &config) { - DS1315(config, m_rtc, 0); + DS1315(config, m_rtc); // no pass-through (?) } @@ -40,7 +40,7 @@ const tiny_rom_entry *cpc_smartwatch_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -cpc_smartwatch_device::cpc_smartwatch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_smartwatch_device::cpc_smartwatch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_SMARTWATCH, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), m_rtc(*this,"rtc"), m_bank(nullptr) diff --git a/src/devices/bus/cpc/smartwatch.h b/src/devices/bus/cpc/smartwatch.h index 8e3f08a1e00..86a3f3d6cbd 100644 --- a/src/devices/bus/cpc/smartwatch.h +++ b/src/devices/bus/cpc/smartwatch.h @@ -21,7 +21,7 @@ class cpc_smartwatch_device : public device_t, public device_cpc_expansion_card_ { public: // construction/destruction - cpc_smartwatch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_smartwatch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t rtc_w(offs_t offset); uint8_t rtc_r(); diff --git a/src/devices/bus/cpc/symbfac2.cpp b/src/devices/bus/cpc/symbfac2.cpp index bffadf99f2a..d28b06070d0 100644 --- a/src/devices/bus/cpc/symbfac2.cpp +++ b/src/devices/bus/cpc/symbfac2.cpp @@ -68,7 +68,7 @@ ioport_constructor cpc_symbiface2_device::device_input_ports() const // LIVE DEVICE //************************************************************************** -cpc_symbiface2_device::cpc_symbiface2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_symbiface2_device::cpc_symbiface2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_SYMBIFACE2, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), diff --git a/src/devices/bus/cpc/symbfac2.h b/src/devices/bus/cpc/symbfac2.h index 4bc59e8a5e6..f031d639b0f 100644 --- a/src/devices/bus/cpc/symbfac2.h +++ b/src/devices/bus/cpc/symbfac2.h @@ -21,7 +21,7 @@ class cpc_symbiface2_device : public device_t, { public: // construction/destruction - cpc_symbiface2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_symbiface2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t ide_cs0_r(offs_t offset); void ide_cs0_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/cpc/transtape.cpp b/src/devices/bus/cpc/transtape.cpp index 115b8463dc7..f2e47013460 100644 --- a/src/devices/bus/cpc/transtape.cpp +++ b/src/devices/bus/cpc/transtape.cpp @@ -42,7 +42,7 @@ ioport_constructor cpc_transtape_device::device_input_ports() const // LIVE DEVICE //************************************************************************** -cpc_transtape_device::cpc_transtape_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cpc_transtape_device::cpc_transtape_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPC_TRANSTAPE, tag, owner, clock), device_cpc_expansion_card_interface(mconfig, *this), m_slot(nullptr), m_space(nullptr), m_ram(nullptr), diff --git a/src/devices/bus/cpc/transtape.h b/src/devices/bus/cpc/transtape.h index 451c3b1bd2a..71545661fa2 100644 --- a/src/devices/bus/cpc/transtape.h +++ b/src/devices/bus/cpc/transtape.h @@ -19,7 +19,7 @@ class cpc_transtape_device : public device_t, { public: // construction/destruction - cpc_transtape_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cpc_transtape_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/crvision/rom.cpp b/src/devices/bus/crvision/rom.cpp index f4aac5393d8..9b639ca45ad 100644 --- a/src/devices/bus/crvision/rom.cpp +++ b/src/devices/bus/crvision/rom.cpp @@ -26,43 +26,43 @@ DEFINE_DEVICE_TYPE(CRVISION_ROM_16K, crvision_rom16k_device, "crvision_16k", "Cr DEFINE_DEVICE_TYPE(CRVISION_ROM_18K, crvision_rom18k_device, "crvision_18k", "CreatiVision 18K Carts") -crvision_rom_device::crvision_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +crvision_rom_device::crvision_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_crvision_cart_interface(mconfig, *this) { } -crvision_rom_device::crvision_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crvision_rom_device::crvision_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : crvision_rom_device(mconfig, CRVISION_ROM_4K, tag, owner, clock) { } -crvision_rom6k_device::crvision_rom6k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crvision_rom6k_device::crvision_rom6k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : crvision_rom_device(mconfig, CRVISION_ROM_6K, tag, owner, clock) { } -crvision_rom8k_device::crvision_rom8k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crvision_rom8k_device::crvision_rom8k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : crvision_rom_device(mconfig, CRVISION_ROM_8K, tag, owner, clock) { } -crvision_rom10k_device::crvision_rom10k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crvision_rom10k_device::crvision_rom10k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : crvision_rom_device(mconfig, CRVISION_ROM_10K, tag, owner, clock) { } -crvision_rom12k_device::crvision_rom12k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crvision_rom12k_device::crvision_rom12k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : crvision_rom_device(mconfig, CRVISION_ROM_12K, tag, owner, clock) { } -crvision_rom16k_device::crvision_rom16k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crvision_rom16k_device::crvision_rom16k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : crvision_rom_device(mconfig, CRVISION_ROM_16K, tag, owner, clock) { } -crvision_rom18k_device::crvision_rom18k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crvision_rom18k_device::crvision_rom18k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : crvision_rom_device(mconfig, CRVISION_ROM_18K, tag, owner, clock) { } diff --git a/src/devices/bus/crvision/rom.h b/src/devices/bus/crvision/rom.h index ffb07e8c601..8a1dffb4490 100644 --- a/src/devices/bus/crvision/rom.h +++ b/src/devices/bus/crvision/rom.h @@ -15,13 +15,13 @@ class crvision_rom_device : public device_t, { public: // construction/destruction - crvision_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crvision_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom80(offs_t offset) override; protected: - crvision_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + crvision_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override {} @@ -34,7 +34,7 @@ class crvision_rom6k_device : public crvision_rom_device { public: // construction/destruction - crvision_rom6k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crvision_rom6k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom80(offs_t offset) override; @@ -46,7 +46,7 @@ class crvision_rom8k_device : public crvision_rom_device { public: // construction/destruction - crvision_rom8k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crvision_rom8k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom80(offs_t offset) override; @@ -58,7 +58,7 @@ class crvision_rom10k_device : public crvision_rom_device { public: // construction/destruction - crvision_rom10k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crvision_rom10k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom40(offs_t offset) override; @@ -71,7 +71,7 @@ class crvision_rom12k_device : public crvision_rom_device { public: // construction/destruction - crvision_rom12k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crvision_rom12k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom40(offs_t offset) override; @@ -84,7 +84,7 @@ class crvision_rom16k_device : public crvision_rom_device { public: // construction/destruction - crvision_rom16k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crvision_rom16k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom80(offs_t offset) override; @@ -96,7 +96,7 @@ class crvision_rom18k_device : public crvision_rom_device { public: // construction/destruction - crvision_rom18k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crvision_rom18k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom40(offs_t offset) override; diff --git a/src/devices/bus/crvision/slot.cpp b/src/devices/bus/crvision/slot.cpp index 616ad6173b4..1a9950b640b 100644 --- a/src/devices/bus/crvision/slot.cpp +++ b/src/devices/bus/crvision/slot.cpp @@ -61,7 +61,7 @@ void device_crvision_cart_interface::rom_alloc(uint32_t size) //------------------------------------------------- // crvision_cart_slot_device - constructor //------------------------------------------------- -crvision_cart_slot_device::crvision_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +crvision_cart_slot_device::crvision_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CRVISION_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_crvision_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/crvision/slot.h b/src/devices/bus/crvision/slot.h index 41f86b117ae..9515b943f57 100644 --- a/src/devices/bus/crvision/slot.h +++ b/src/devices/bus/crvision/slot.h @@ -60,14 +60,14 @@ public: // construction/destruction template <typename T> crvision_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : crvision_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : crvision_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - crvision_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crvision_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~crvision_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/dmv/dmvbus.cpp b/src/devices/bus/dmv/dmvbus.cpp index 3b828de41a1..b26090d4639 100644 --- a/src/devices/bus/dmv/dmvbus.cpp +++ b/src/devices/bus/dmv/dmvbus.cpp @@ -196,7 +196,7 @@ device_dmvslot_interface::~device_dmvslot_interface() //------------------------------------------------- // dmvcart_slot_device - constructor //------------------------------------------------- -dmvcart_slot_device::dmvcart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dmvcart_slot_device::dmvcart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DMVCART_SLOT, tag, owner, clock), device_single_card_slot_interface<device_dmvslot_interface>(mconfig, *this), m_prog_read_cb(*this), diff --git a/src/devices/bus/dmv/dmvbus.h b/src/devices/bus/dmv/dmvbus.h index 24c55fdb512..84bd7ee93f8 100644 --- a/src/devices/bus/dmv/dmvbus.h +++ b/src/devices/bus/dmv/dmvbus.h @@ -28,14 +28,14 @@ public: // construction/destruction template <typename T> dmvcart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : dmvcart_slot_device(mconfig, tag, owner, (uint32_t)0) + : dmvcart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - dmvcart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmvcart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~dmvcart_slot_device(); auto prog_read() { return m_prog_read_cb.bind(); } diff --git a/src/devices/bus/dmv/k012.cpp b/src/devices/bus/dmv/k012.cpp index 21f5f4e5e8d..bcc651a73ea 100644 --- a/src/devices/bus/dmv/k012.cpp +++ b/src/devices/bus/dmv/k012.cpp @@ -40,12 +40,12 @@ DEFINE_DEVICE_TYPE(DMV_C3282, dmv_c3282_device, "dmv_c3282", "C3282 External HD // dmv_k012_device - constructor //------------------------------------------------- -dmv_k012_device::dmv_k012_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k012_device::dmv_k012_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_k012_device(mconfig, DMV_K012, tag, owner, clock) { } -dmv_k012_device::dmv_k012_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +dmv_k012_device::dmv_k012_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_dmvslot_interface( mconfig, *this ) , m_hdc(*this, "hdc") @@ -57,7 +57,7 @@ dmv_k012_device::dmv_k012_device(const machine_config &mconfig, device_type type // dmv_c3282_device - constructor //------------------------------------------------- -dmv_c3282_device::dmv_c3282_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_c3282_device::dmv_c3282_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_k012_device(mconfig, DMV_C3282, tag, owner, clock) { } @@ -97,10 +97,10 @@ void dmv_k012_device::device_add_mconfig(machine_config &config) m_hdc->intrq_wr_callback().set(FUNC(dmv_k012_device::out_int)); // default drive is 10MB (306,4,17) - HARDDISK(config, "hdc:0", 0); - HARDDISK(config, "hdc:1", 0); - HARDDISK(config, "hdc:2", 0); - HARDDISK(config, "hdc:3", 0); + HARDDISK(config, "hdc:0"); + HARDDISK(config, "hdc:1"); + HARDDISK(config, "hdc:2"); + HARDDISK(config, "hdc:3"); } void dmv_k012_device::io_read(int ifsel, offs_t offset, uint8_t &data) diff --git a/src/devices/bus/dmv/k012.h b/src/devices/bus/dmv/k012.h index b450b5f125b..4c04dfecd0c 100644 --- a/src/devices/bus/dmv/k012.h +++ b/src/devices/bus/dmv/k012.h @@ -21,10 +21,10 @@ class dmv_k012_device : { public: // construction/destruction - dmv_k012_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k012_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - dmv_k012_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dmv_k012_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -53,7 +53,7 @@ class dmv_c3282_device : { public: // construction/destruction - dmv_c3282_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_c3282_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/dmv/k210.cpp b/src/devices/bus/dmv/k210.cpp index 90f39e5bf0e..6803a8cb4b9 100644 --- a/src/devices/bus/dmv/k210.cpp +++ b/src/devices/bus/dmv/k210.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(DMV_K210, dmv_k210_device, "dmv_k210", "K210 Centronics") // dmv_k210_device - constructor //------------------------------------------------- -dmv_k210_device::dmv_k210_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k210_device::dmv_k210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DMV_K210, tag, owner, clock) , device_dmvslot_interface(mconfig, *this) , m_ppi(*this, "ppi8255") @@ -79,7 +79,7 @@ TIMER_CALLBACK_MEMBER(dmv_k210_device::strobe_tick) void dmv_k210_device::device_add_mconfig(machine_config &config) { - I8255(config, m_ppi, 0); + I8255(config, m_ppi); m_ppi->in_pa_callback().set(FUNC(dmv_k210_device::porta_r)); m_ppi->in_pb_callback().set(FUNC(dmv_k210_device::portb_r)); m_ppi->in_pc_callback().set(FUNC(dmv_k210_device::portc_r)); diff --git a/src/devices/bus/dmv/k210.h b/src/devices/bus/dmv/k210.h index d49673b2415..04dfb4377d8 100644 --- a/src/devices/bus/dmv/k210.h +++ b/src/devices/bus/dmv/k210.h @@ -22,7 +22,7 @@ class dmv_k210_device : { public: // construction/destruction - dmv_k210_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/dmv/k220.cpp b/src/devices/bus/dmv/k220.cpp index 64df90c21d8..c5f42fdd04a 100644 --- a/src/devices/bus/dmv/k220.cpp +++ b/src/devices/bus/dmv/k220.cpp @@ -120,7 +120,7 @@ DEFINE_DEVICE_TYPE(DMV_K220, dmv_k220_device, "dmv_k220", "K220 diagnostic") // dmv_k220_device - constructor //------------------------------------------------- -dmv_k220_device::dmv_k220_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k220_device::dmv_k220_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DMV_K220, tag, owner, clock) , device_dmvslot_interface(mconfig, *this) , m_pit(*this, "pit8253") @@ -172,7 +172,7 @@ void dmv_k220_device::device_add_mconfig(machine_config &config) m_ppi->in_pb_callback().set_ioport("SWITCH"); m_ppi->out_pc_callback().set(FUNC(dmv_k220_device::portc_w)); - PIT8253(config, m_pit, 0); + PIT8253(config, m_pit); m_pit->set_clk<0>(XTAL(1'000'000)); // CLK1 m_pit->out_handler<0>().set(FUNC(dmv_k220_device::write_out0)); m_pit->out_handler<1>().set(FUNC(dmv_k220_device::write_out1)); diff --git a/src/devices/bus/dmv/k220.h b/src/devices/bus/dmv/k220.h index b58777df15e..6efa7a33308 100644 --- a/src/devices/bus/dmv/k220.h +++ b/src/devices/bus/dmv/k220.h @@ -22,7 +22,7 @@ class dmv_k220_device : { public: // construction/destruction - dmv_k220_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k220_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/dmv/k230.cpp b/src/devices/bus/dmv/k230.cpp index 82d6e24f7d2..8d2a14ebd9d 100644 --- a/src/devices/bus/dmv/k230.cpp +++ b/src/devices/bus/dmv/k230.cpp @@ -90,12 +90,12 @@ DEFINE_DEVICE_TYPE(DMV_K235, dmv_k235_device, "dmv_k235", "K235 8088 with interr // dmv_k230_device - constructor //------------------------------------------------- -dmv_k230_device::dmv_k230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k230_device::dmv_k230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_k230_device(mconfig, DMV_K230, tag, owner, clock) { } -dmv_k230_device::dmv_k230_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +dmv_k230_device::dmv_k230_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_dmvslot_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -109,7 +109,7 @@ dmv_k230_device::dmv_k230_device(const machine_config &mconfig, device_type type // dmv_k231_device - constructor //------------------------------------------------- -dmv_k231_device::dmv_k231_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k231_device::dmv_k231_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_k230_device(mconfig, DMV_K231, tag, owner, clock) { } @@ -118,7 +118,7 @@ dmv_k231_device::dmv_k231_device(const machine_config &mconfig, const char *tag, // dmv_k234_device - constructor //------------------------------------------------- -dmv_k234_device::dmv_k234_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k234_device::dmv_k234_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_k230_device(mconfig, DMV_K234, tag, owner, clock), m_snr(0) { } @@ -127,7 +127,7 @@ dmv_k234_device::dmv_k234_device(const machine_config &mconfig, const char *tag, // dmv_k235_device - constructor //------------------------------------------------- -dmv_k235_device::dmv_k235_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k235_device::dmv_k235_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_k230_device(mconfig, DMV_K235, tag, owner, clock), m_pic(*this, "pic8259"), m_dsw(*this, "DSW") { } @@ -193,7 +193,7 @@ void dmv_k235_device::device_add_mconfig(machine_config &config) m_maincpu->set_addrmap(AS_IO, &dmv_k235_device::k235_io); m_maincpu->set_irq_acknowledge_callback("pic8259", FUNC(pic8259_device::inta_cb)); - PIC8259(config, m_pic, 0); + PIC8259(config, m_pic); m_pic->out_int_callback().set_inputline(m_maincpu, 0); } diff --git a/src/devices/bus/dmv/k230.h b/src/devices/bus/dmv/k230.h index c260ad70504..7c6367c3dcc 100644 --- a/src/devices/bus/dmv/k230.h +++ b/src/devices/bus/dmv/k230.h @@ -29,10 +29,10 @@ class dmv_k230_device : { public: // construction/destruction - dmv_k230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - dmv_k230_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dmv_k230_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -72,7 +72,7 @@ class dmv_k231_device : { public: // construction/destruction - dmv_k231_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k231_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -86,7 +86,7 @@ class dmv_k234_device : { public: // construction/destruction - dmv_k234_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k234_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -118,7 +118,7 @@ class dmv_k235_device : { public: // construction/destruction - dmv_k235_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k235_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/dmv/k233.cpp b/src/devices/bus/dmv/k233.cpp index 5873aec8d5c..bb42565083d 100644 --- a/src/devices/bus/dmv/k233.cpp +++ b/src/devices/bus/dmv/k233.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(DMV_K233, dmv_k233_device, "dmv_k233", "K233 16K Shared RAM") // dmv_k233_device - constructor //------------------------------------------------- -dmv_k233_device::dmv_k233_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k233_device::dmv_k233_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DMV_K233, tag, owner, clock) , device_dmvslot_interface(mconfig, *this) , m_enabled(false) diff --git a/src/devices/bus/dmv/k233.h b/src/devices/bus/dmv/k233.h index 8f4c9302136..63767459446 100644 --- a/src/devices/bus/dmv/k233.h +++ b/src/devices/bus/dmv/k233.h @@ -20,7 +20,7 @@ class dmv_k233_device : { public: // construction/destruction - dmv_k233_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k233_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/dmv/k801.cpp b/src/devices/bus/dmv/k801.cpp index 4465a45227b..4eb4756d008 100644 --- a/src/devices/bus/dmv/k801.cpp +++ b/src/devices/bus/dmv/k801.cpp @@ -76,12 +76,12 @@ DEFINE_DEVICE_TYPE(DMV_K213, dmv_k213_device, "dmv_k213", "K213 RS-232 Plotter I // dmv_k801_device - constructor //------------------------------------------------- -dmv_k801_device::dmv_k801_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k801_device::dmv_k801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_k801_device(mconfig, DMV_K801, tag, owner, clock) { } -dmv_k801_device::dmv_k801_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +dmv_k801_device::dmv_k801_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_dmvslot_interface( mconfig, *this ), m_pci(*this, "pci"), @@ -94,13 +94,13 @@ dmv_k801_device::dmv_k801_device(const machine_config &mconfig, device_type type // dmv_k211_device - constructor //------------------------------------------------- -dmv_k211_device::dmv_k211_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k211_device::dmv_k211_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_k211_device(mconfig, DMV_K211, tag, owner, clock) { } -dmv_k211_device::dmv_k211_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +dmv_k211_device::dmv_k211_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : dmv_k801_device(mconfig, type, tag, owner, clock) { } @@ -109,7 +109,7 @@ dmv_k211_device::dmv_k211_device(const machine_config &mconfig, device_type type // dmv_k212_device - constructor //------------------------------------------------- -dmv_k212_device::dmv_k212_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k212_device::dmv_k212_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_k211_device(mconfig, DMV_K212, tag, owner, clock) { } @@ -118,7 +118,7 @@ dmv_k212_device::dmv_k212_device(const machine_config &mconfig, const char *tag, // dmv_k213_device - constructor //------------------------------------------------- -dmv_k213_device::dmv_k213_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k213_device::dmv_k213_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_k211_device(mconfig, DMV_K213, tag, owner, clock) { } diff --git a/src/devices/bus/dmv/k801.h b/src/devices/bus/dmv/k801.h index 41f72aaacf8..d842bbf3208 100644 --- a/src/devices/bus/dmv/k801.h +++ b/src/devices/bus/dmv/k801.h @@ -23,10 +23,10 @@ class dmv_k801_device : { public: // construction/destruction - dmv_k801_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - dmv_k801_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dmv_k801_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -58,10 +58,10 @@ class dmv_k211_device : { public: // construction/destruction - dmv_k211_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k211_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - dmv_k211_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dmv_k211_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; @@ -79,7 +79,7 @@ class dmv_k212_device : { public: // construction/destruction - dmv_k212_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k212_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -94,7 +94,7 @@ class dmv_k213_device : { public: // construction/destruction - dmv_k213_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k213_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/dmv/k803.cpp b/src/devices/bus/dmv/k803.cpp index d2a72f22441..11be88cc159 100644 --- a/src/devices/bus/dmv/k803.cpp +++ b/src/devices/bus/dmv/k803.cpp @@ -45,7 +45,7 @@ DEFINE_DEVICE_TYPE(DMV_K803, dmv_k803_device, "dmv_k803", "K803 RTC") // dmv_k803_device - constructor //------------------------------------------------- -dmv_k803_device::dmv_k803_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dmv_k803_device::dmv_k803_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DMV_K803, tag, owner, clock), device_dmvslot_interface( mconfig, *this ), m_rtc(*this, "rtc"), diff --git a/src/devices/bus/dmv/k803.h b/src/devices/bus/dmv/k803.h index 60a8cd91ced..1771373e985 100644 --- a/src/devices/bus/dmv/k803.h +++ b/src/devices/bus/dmv/k803.h @@ -21,7 +21,7 @@ class dmv_k803_device : { public: // construction/destruction - dmv_k803_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k803_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/dmv/k806.cpp b/src/devices/bus/dmv/k806.cpp index 89802ca43bd..1fb6a8478dd 100644 --- a/src/devices/bus/dmv/k806.cpp +++ b/src/devices/bus/dmv/k806.cpp @@ -63,7 +63,7 @@ DEFINE_DEVICE_TYPE(DMV_K806, dmv_k806_device, "dmv_k806", "K806 mouse") // dmv_k806_device - constructor //------------------------------------------------- -dmv_k806_device::dmv_k806_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k806_device::dmv_k806_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DMV_K806, tag, owner, clock) , device_dmvslot_interface( mconfig, *this ) , m_mcu(*this, "mcu") @@ -116,7 +116,7 @@ void dmv_k806_device::device_add_mconfig(machine_config &config) m_mcu->p2_out_cb().set(FUNC(dmv_k806_device::port2_w)); m_mcu->t1_in_cb().set(FUNC(dmv_k806_device::portt1_r)); - TIMER(config, "mouse_timer", 0).configure_periodic(FUNC(dmv_k806_device::mouse_timer), attotime::from_hz(1000)); + TIMER(config, "mouse_timer").configure_periodic(FUNC(dmv_k806_device::mouse_timer), attotime::from_hz(1000)); } //------------------------------------------------- diff --git a/src/devices/bus/dmv/k806.h b/src/devices/bus/dmv/k806.h index 8c7c3618f69..c2649af0888 100644 --- a/src/devices/bus/dmv/k806.h +++ b/src/devices/bus/dmv/k806.h @@ -24,7 +24,7 @@ class dmv_k806_device : { public: // construction/destruction - dmv_k806_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k806_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/dmv/ram.cpp b/src/devices/bus/dmv/ram.cpp index 3538ba6ed41..dff22460e30 100644 --- a/src/devices/bus/dmv/ram.cpp +++ b/src/devices/bus/dmv/ram.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(DMV_K208, dmv_k208_device, "dmv_k208", "K208 448K RAM expansi // dmv_ram_device_base - constructor //------------------------------------------------- -dmv_ram_device_base::dmv_ram_device_base(const machine_config &mconfig, device_type type, uint32_t size, const char *tag, device_t *owner, uint32_t clock) +dmv_ram_device_base::dmv_ram_device_base(const machine_config &mconfig, device_type type, uint32_t size, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_dmvslot_interface(mconfig, *this) , m_ram(nullptr) @@ -45,7 +45,7 @@ dmv_ram_device_base::dmv_ram_device_base(const machine_config &mconfig, device_t // dmv_k200_device - constructor //------------------------------------------------- -dmv_k200_device::dmv_k200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k200_device::dmv_k200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_ram_device_base(mconfig, DMV_K200, 1, tag, owner, clock) { } @@ -54,7 +54,7 @@ dmv_k200_device::dmv_k200_device(const machine_config &mconfig, const char *tag, // dmv_k202_device - constructor //------------------------------------------------- -dmv_k202_device::dmv_k202_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k202_device::dmv_k202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_ram_device_base(mconfig, DMV_K202, 3, tag, owner, clock) { } @@ -63,7 +63,7 @@ dmv_k202_device::dmv_k202_device(const machine_config &mconfig, const char *tag, // dmv_k208_device - constructor //------------------------------------------------- -dmv_k208_device::dmv_k208_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmv_k208_device::dmv_k208_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmv_ram_device_base(mconfig, DMV_K208, 7, tag, owner, clock) { } diff --git a/src/devices/bus/dmv/ram.h b/src/devices/bus/dmv/ram.h index 79cc9c3ea92..d54811fa12a 100644 --- a/src/devices/bus/dmv/ram.h +++ b/src/devices/bus/dmv/ram.h @@ -20,7 +20,7 @@ class dmv_ram_device_base : { protected: // construction/destruction - dmv_ram_device_base(const machine_config &mconfig, device_type type, uint32_t size, const char *tag, device_t *owner, uint32_t clock); + dmv_ram_device_base(const machine_config &mconfig, device_type type, uint32_t size, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -39,7 +39,7 @@ class dmv_k200_device : public dmv_ram_device_base { public: // construction/destruction - dmv_k200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -47,7 +47,7 @@ class dmv_k202_device : public dmv_ram_device_base { public: // construction/destruction - dmv_k202_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -55,7 +55,7 @@ class dmv_k208_device : public dmv_ram_device_base { public: // construction/destruction - dmv_k208_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmv_k208_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/ecbbus/ecbbus.cpp b/src/devices/bus/ecbbus/ecbbus.cpp index 5eaeda9f284..1881f6b9848 100644 --- a/src/devices/bus/ecbbus/ecbbus.cpp +++ b/src/devices/bus/ecbbus/ecbbus.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(ECBBUS_SLOT, ecbbus_slot_device, "ecbbus_slot", "ECB bus slot // ecbbus_slot_device - constructor //------------------------------------------------- -ecbbus_slot_device::ecbbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ecbbus_slot_device::ecbbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ECBBUS_SLOT, tag, owner, clock), device_single_card_slot_interface<device_ecbbus_card_interface>(mconfig, *this), m_bus(*this, finder_base::DUMMY_TAG), @@ -81,7 +81,7 @@ device_ecbbus_card_interface::device_ecbbus_card_interface(const machine_config // ecbbus_device - constructor //------------------------------------------------- -ecbbus_device::ecbbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ecbbus_device::ecbbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ECBBUS, tag, owner, clock), m_write_irq(*this), m_write_nmi(*this) diff --git a/src/devices/bus/ecbbus/ecbbus.h b/src/devices/bus/ecbbus/ecbbus.h index bee5201a2fc..6e7ad6fcc29 100644 --- a/src/devices/bus/ecbbus/ecbbus.h +++ b/src/devices/bus/ecbbus/ecbbus.h @@ -65,7 +65,7 @@ public: // construction/destruction template <typename T, typename U> ecbbus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bustag, int num, U &&opts, char const *dflt) - : ecbbus_slot_device(mconfig, tag, owner, 0) + : ecbbus_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -74,7 +74,7 @@ public: set_ecbbus_slot(std::forward<T>(bustag), num); } - ecbbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ecbbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // device-level overrides virtual void device_start() override; @@ -103,7 +103,7 @@ class ecbbus_device : public device_t { public: // construction/destruction - ecbbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ecbbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto irq_wr_callback() { return m_write_irq.bind(); } auto nmi_wr_callback() { return m_write_nmi.bind(); } diff --git a/src/devices/bus/ecbbus/grip.cpp b/src/devices/bus/ecbbus/grip.cpp index 6de51191cd5..e0a8ea195c0 100644 --- a/src/devices/bus/ecbbus/grip.cpp +++ b/src/devices/bus/ecbbus/grip.cpp @@ -459,7 +459,7 @@ void ecb_grip21_device::device_add_mconfig(machine_config &config) output_latch_device ¢_data_out(OUTPUT_LATCH(config, "cent_data_out")); m_centronics->set_output_latch(cent_data_out); - generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, "keyboard", 0)); + generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, "keyboard")); keyboard.set_keyboard_callback(FUNC(ecb_grip21_device::kb_w)); } @@ -558,7 +558,7 @@ ioport_constructor ecb_grip21_device::device_input_ports() const // ecb_grip21_device - constructor //------------------------------------------------- -ecb_grip21_device::ecb_grip21_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ecb_grip21_device::ecb_grip21_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ECB_GRIP21, tag, owner, clock), device_ecbbus_card_interface(mconfig, *this), m_ppi(*this, I8255A_TAG), diff --git a/src/devices/bus/ecbbus/grip.h b/src/devices/bus/ecbbus/grip.h index 024a820e4e3..f77ffa9968b 100644 --- a/src/devices/bus/ecbbus/grip.h +++ b/src/devices/bus/ecbbus/grip.h @@ -35,7 +35,7 @@ class ecb_grip21_device : public device_t, public device_ecbbus_card_interface { public: // construction/destruction - ecb_grip21_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ecb_grip21_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/econet/e01.cpp b/src/devices/bus/econet/e01.cpp index 256e545c702..168aa239cd1 100644 --- a/src/devices/bus/econet/e01.cpp +++ b/src/devices/bus/econet/e01.cpp @@ -78,7 +78,7 @@ DEFINE_DEVICE_TYPE(ECONET_E01, econet_e01_device, "econet_e01", "Acorn FileStore E01") DEFINE_DEVICE_TYPE(ECONET_E01S, econet_e01s_device, "econet_e01s", "Acorn FileStore E01S") -econet_e01s_device::econet_e01s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +econet_e01s_device::econet_e01s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : econet_e01_device(mconfig, ECONET_E01S, tag, owner, clock, TYPE_E01S) { } @@ -253,7 +253,7 @@ void econet_e01_device::device_add_mconfig(machine_config &config) via.writepa_handler().set("cent_data_out", FUNC(output_latch_device::write)); via.irq_handler().set(FUNC(econet_e01_device::via_irq_w)); - MC6854(config, m_adlc, 0); + MC6854(config, m_adlc); m_adlc->out_irq_cb().set(FUNC(econet_e01_device::adlc_irq_w)); m_adlc->out_txd_cb().set(FUNC(econet_e01_device::econet_data_w)); @@ -380,13 +380,13 @@ inline void econet_e01_device::hdc_irq_enable(int enabled) // econet_e01_device - constructor //------------------------------------------------- -econet_e01_device::econet_e01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +econet_e01_device::econet_e01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : econet_e01_device(mconfig, ECONET_E01, tag, owner, clock, TYPE_E01) { } -econet_e01_device::econet_e01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int variant) +econet_e01_device::econet_e01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int variant) : device_t(mconfig, type, tag, owner, clock) , device_econet_interface(mconfig, *this) , m_maincpu(*this, R65C102_TAG) diff --git a/src/devices/bus/econet/e01.h b/src/devices/bus/econet/e01.h index 695e18c47cd..4bcdab699be 100644 --- a/src/devices/bus/econet/e01.h +++ b/src/devices/bus/econet/e01.h @@ -30,7 +30,7 @@ class econet_e01_device : public device_t, { public: // construction/destruction - econet_e01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + econet_e01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: enum @@ -39,7 +39,7 @@ protected: TYPE_E01S }; - econet_e01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int variant); + econet_e01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int variant); // device-level overrides virtual void device_start() override; @@ -132,7 +132,7 @@ class econet_e01s_device : public econet_e01_device { public: // construction/destruction - econet_e01s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + econet_e01s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/econet/econet.cpp b/src/devices/bus/econet/econet.cpp index e9afc9c0d49..7ec6552dcef 100644 --- a/src/devices/bus/econet/econet.cpp +++ b/src/devices/bus/econet/econet.cpp @@ -54,7 +54,7 @@ device_econet_interface::device_econet_interface(const machine_config &mconfig, // econet_slot_device - constructor //------------------------------------------------- -econet_slot_device::econet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +econet_slot_device::econet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ECONET_SLOT, tag, owner, clock), device_slot_interface(mconfig, *this), m_address(0), m_econet(*this, finder_base::DUMMY_TAG) @@ -183,7 +183,7 @@ inline int econet_device::get_signal(int signal) // econet_device - constructor //------------------------------------------------- -econet_device::econet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +econet_device::econet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ECONET, tag, owner, clock), m_write_clk(*this), m_write_data(*this) diff --git a/src/devices/bus/econet/econet.h b/src/devices/bus/econet/econet.h index 1aab9da8095..6f6ff3a5e35 100644 --- a/src/devices/bus/econet/econet.h +++ b/src/devices/bus/econet/econet.h @@ -26,7 +26,7 @@ class econet_device : public device_t { public: // construction/destruction - econet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + econet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto clk_wr_callback() { return m_write_clk.bind(); } auto data_wr_callback() { return m_write_data.bind(); } @@ -86,11 +86,11 @@ class econet_slot_device : public device_t, { public: // construction/destruction - econet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + econet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T, typename U> econet_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&econet_tag, U &&devs) - : econet_slot_device(mconfig, tag, owner, 0U) + : econet_slot_device(mconfig, tag, owner) { set_econet_tag(std::forward<T>(econet_tag)); devs(*this); diff --git a/src/devices/bus/einstein/pipe/pipe.cpp b/src/devices/bus/einstein/pipe/pipe.cpp index f54092e9587..868e56dcf7a 100644 --- a/src/devices/bus/einstein/pipe/pipe.cpp +++ b/src/devices/bus/einstein/pipe/pipe.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(TATUNG_PIPE, tatung_pipe_device, "tatung_pipe", "Tatung Pipe // tatung_pipe_device - constructor //------------------------------------------------- -tatung_pipe_device::tatung_pipe_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tatung_pipe_device::tatung_pipe_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TATUNG_PIPE, tag, owner, clock), device_single_card_slot_interface<device_tatung_pipe_interface>(mconfig, *this), m_program(*this, finder_base::DUMMY_TAG, -1), diff --git a/src/devices/bus/einstein/pipe/pipe.h b/src/devices/bus/einstein/pipe/pipe.h index 7b2a2fdcbad..2897b582818 100644 --- a/src/devices/bus/einstein/pipe/pipe.h +++ b/src/devices/bus/einstein/pipe/pipe.h @@ -56,9 +56,9 @@ class tatung_pipe_device : public device_t, public device_single_card_slot_inter friend class device_tatung_pipe_interface; public: // construction/destruction - tatung_pipe_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tatung_pipe_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> - tatung_pipe_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + tatung_pipe_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : tatung_pipe_device(mconfig, tag, owner, clock) { option_reset(); diff --git a/src/devices/bus/einstein/pipe/silicon_disc.cpp b/src/devices/bus/einstein/pipe/silicon_disc.cpp index c0a29f304bd..3f70488551a 100644 --- a/src/devices/bus/einstein/pipe/silicon_disc.cpp +++ b/src/devices/bus/einstein/pipe/silicon_disc.cpp @@ -49,7 +49,7 @@ const tiny_rom_entry *einstein_silicon_disc_device::device_rom_region() const // einstein_silicon_disc_device - constructor //------------------------------------------------- -einstein_silicon_disc_device::einstein_silicon_disc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +einstein_silicon_disc_device::einstein_silicon_disc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EINSTEIN_SILICON_DISC, tag, owner, clock), device_tatung_pipe_interface(mconfig, *this), m_rom(*this, "rom"), diff --git a/src/devices/bus/einstein/pipe/silicon_disc.h b/src/devices/bus/einstein/pipe/silicon_disc.h index c80ef0ed88c..48b5485cb77 100644 --- a/src/devices/bus/einstein/pipe/silicon_disc.h +++ b/src/devices/bus/einstein/pipe/silicon_disc.h @@ -26,7 +26,7 @@ class einstein_silicon_disc_device : public device_t, public device_tatung_pipe_ { public: // construction/destruction - einstein_silicon_disc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + einstein_silicon_disc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/einstein/pipe/speculator.cpp b/src/devices/bus/einstein/pipe/speculator.cpp index e99d3978cb4..4a05436724c 100644 --- a/src/devices/bus/einstein/pipe/speculator.cpp +++ b/src/devices/bus/einstein/pipe/speculator.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(EINSTEIN_SPECULATOR, einstein_speculator_device, "einstein_sp void einstein_speculator_device::device_add_mconfig(machine_config &config) { - TTL74123(config, m_ic5a, 0); + TTL74123(config, m_ic5a); m_ic5a->set_connection_type(TTL74123_NOT_GROUNDED_NO_DIODE); m_ic5a->set_resistor_value(RES_K(47)); m_ic5a->set_capacitor_value(CAP_P(560)); @@ -36,7 +36,7 @@ void einstein_speculator_device::device_add_mconfig(machine_config &config) m_ic5a->set_clear_pin_value(0); m_ic5a->out_cb().set(FUNC(einstein_speculator_device::ic5a_q_w)); - TTL74123(config, m_ic5b, 0); + TTL74123(config, m_ic5b); m_ic5b->set_connection_type(TTL74123_NOT_GROUNDED_NO_DIODE); m_ic5b->set_resistor_value(RES_K(47)); m_ic5b->set_capacitor_value(CAP_P(560)); @@ -64,7 +64,7 @@ void einstein_speculator_device::device_add_mconfig(machine_config &config) // einstein_speculator_device - constructor //------------------------------------------------- -einstein_speculator_device::einstein_speculator_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +einstein_speculator_device::einstein_speculator_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EINSTEIN_SPECULATOR, tag, owner, clock), device_tatung_pipe_interface(mconfig, *this), m_ic5a(*this, "ic5a"), m_ic5b(*this, "ic5b"), diff --git a/src/devices/bus/einstein/pipe/speculator.h b/src/devices/bus/einstein/pipe/speculator.h index c66b2e0122e..54159838878 100644 --- a/src/devices/bus/einstein/pipe/speculator.h +++ b/src/devices/bus/einstein/pipe/speculator.h @@ -30,7 +30,7 @@ class einstein_speculator_device : public device_t, public device_tatung_pipe_in { public: // construction/destruction - einstein_speculator_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + einstein_speculator_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void int_w(int state) override; diff --git a/src/devices/bus/einstein/pipe/tk02.cpp b/src/devices/bus/einstein/pipe/tk02.cpp index 74cd880e151..668426f458b 100644 --- a/src/devices/bus/einstein/pipe/tk02.cpp +++ b/src/devices/bus/einstein/pipe/tk02.cpp @@ -126,7 +126,7 @@ void tk02_device::device_add_mconfig(machine_config &config) // tk02_device - constructor //------------------------------------------------- -tk02_device::tk02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tk02_device::tk02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TK02_80COL, tag, owner, clock), device_tatung_pipe_interface(mconfig, *this), m_pipe(*this, "pipe"), diff --git a/src/devices/bus/einstein/pipe/tk02.h b/src/devices/bus/einstein/pipe/tk02.h index 3834585ed2a..aaccafb48c0 100644 --- a/src/devices/bus/einstein/pipe/tk02.h +++ b/src/devices/bus/einstein/pipe/tk02.h @@ -26,7 +26,7 @@ class tk02_device : public device_t, public device_tatung_pipe_interface { public: // construction/destruction - tk02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tk02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/einstein/userport/mouse.cpp b/src/devices/bus/einstein/userport/mouse.cpp index 945bff5d37c..e0613d4f1e5 100644 --- a/src/devices/bus/einstein/userport/mouse.cpp +++ b/src/devices/bus/einstein/userport/mouse.cpp @@ -48,7 +48,7 @@ ioport_constructor einstein_mouse_device::device_input_ports() const // einstein_speech_device - constructor //------------------------------------------------- -einstein_mouse_device::einstein_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +einstein_mouse_device::einstein_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EINSTEIN_MOUSE, tag, owner, clock), device_einstein_userport_interface(mconfig, *this), m_mouse_b(*this, "mouse_b"), diff --git a/src/devices/bus/einstein/userport/mouse.h b/src/devices/bus/einstein/userport/mouse.h index dad8200d06b..8ec38ae4004 100644 --- a/src/devices/bus/einstein/userport/mouse.h +++ b/src/devices/bus/einstein/userport/mouse.h @@ -24,7 +24,7 @@ class einstein_mouse_device : public device_t, public device_einstein_userport_i { public: // construction/destruction - einstein_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + einstein_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/einstein/userport/speech.cpp b/src/devices/bus/einstein/userport/speech.cpp index 435423f9f82..3a822109d49 100644 --- a/src/devices/bus/einstein/userport/speech.cpp +++ b/src/devices/bus/einstein/userport/speech.cpp @@ -40,7 +40,7 @@ const tiny_rom_entry *einstein_speech_device::device_rom_region() const void einstein_speech_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "mono").front_center(); - SP0256(config, m_sp0256, 3120000); // ??? + SP0256(config, m_sp0256, XTAL::u(3120000)); // ??? m_sp0256->add_route(ALL_OUTPUTS, "mono", 1.00); } @@ -53,7 +53,7 @@ void einstein_speech_device::device_add_mconfig(machine_config &config) // einstein_speech_device - constructor //------------------------------------------------- -einstein_speech_device::einstein_speech_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +einstein_speech_device::einstein_speech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EINSTEIN_SPEECH, tag, owner, clock), device_einstein_userport_interface(mconfig, *this), m_sp0256(*this, "sp0256") diff --git a/src/devices/bus/einstein/userport/speech.h b/src/devices/bus/einstein/userport/speech.h index 4c62b24e842..494e5e5d54d 100644 --- a/src/devices/bus/einstein/userport/speech.h +++ b/src/devices/bus/einstein/userport/speech.h @@ -25,7 +25,7 @@ class einstein_speech_device : public device_t, public device_einstein_userport_ { public: // construction/destruction - einstein_speech_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + einstein_speech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/einstein/userport/userport.cpp b/src/devices/bus/einstein/userport/userport.cpp index e2fdd06acd2..ce1ebcc4b97 100644 --- a/src/devices/bus/einstein/userport/userport.cpp +++ b/src/devices/bus/einstein/userport/userport.cpp @@ -29,12 +29,16 @@ DEFINE_DEVICE_TYPE(EINSTEIN_USERPORT, einstein_userport_device, "einstein_userpo // einstein_userport_device - constructor //------------------------------------------------- -einstein_userport_device::einstein_userport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +einstein_userport_device::einstein_userport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EINSTEIN_USERPORT, tag, owner, clock), device_single_card_slot_interface<device_einstein_userport_interface>(mconfig, *this), m_card(nullptr), m_bstb_handler(*this) { + option_reset(); + einstein_userport_cards(*this); + set_default_option(nullptr); + set_fixed(false); } //------------------------------------------------- diff --git a/src/devices/bus/einstein/userport/userport.h b/src/devices/bus/einstein/userport/userport.h index d543f14d7c6..fde4e708cfb 100644 --- a/src/devices/bus/einstein/userport/userport.h +++ b/src/devices/bus/einstein/userport/userport.h @@ -36,16 +36,7 @@ class einstein_userport_device : public device_t, public device_single_card_slot { public: // construction/destruction - einstein_userport_device(machine_config const &mconfig, char const *tag, device_t *owner) - : einstein_userport_device(mconfig, tag, owner, (uint32_t)0) - { - option_reset(); - einstein_userport_cards(*this); - set_default_option(nullptr); - set_fixed(false); - } - - einstein_userport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + einstein_userport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~einstein_userport_device(); // callbacks diff --git a/src/devices/bus/ekara/rom.cpp b/src/devices/bus/ekara/rom.cpp index f4458c63efd..b22b0482b29 100644 --- a/src/devices/bus/ekara/rom.cpp +++ b/src/devices/bus/ekara/rom.cpp @@ -17,56 +17,56 @@ DEFINE_DEVICE_TYPE(EKARA_ROM_I2C_24LC02_GC0010, ekara_rom_i2c_24lc02_gc0010_d DEFINE_DEVICE_TYPE(EKARA_ROM_I2C_24LC08_EVIO, ekara_rom_i2c_24lc08_evio_device, "ekara_rom_i2c_24lc08_evio", "EKARA Cartridge with I2C 24LC08 (evio direct access)") -ekara_rom_plain_device::ekara_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +ekara_rom_plain_device::ekara_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_ekara_cart_interface(mconfig, *this) { } -ekara_rom_plain_device::ekara_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ekara_rom_plain_device::ekara_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ekara_rom_plain_device(mconfig, EKARA_ROM_PLAIN, tag, owner, clock) { } -ekara_rom_i2c_base_device::ekara_rom_i2c_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +ekara_rom_i2c_base_device::ekara_rom_i2c_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ekara_rom_plain_device(mconfig, type, tag, owner, clock), m_i2cmem(*this, "i2cmem") { m_buscontrol[0] = m_buscontrol[1] = m_buscontrol[2] = 0x00; } -ekara_rom_i2c_base_device::ekara_rom_i2c_base_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ekara_rom_i2c_base_device::ekara_rom_i2c_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ekara_rom_i2c_base_device(mconfig, EKARA_ROM_I2C_BASE, tag, owner, clock) { } -ekara_rom_i2c_24c08_epitch_device::ekara_rom_i2c_24c08_epitch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ekara_rom_i2c_24c08_epitch_device::ekara_rom_i2c_24c08_epitch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ekara_rom_i2c_base_device(mconfig, EKARA_ROM_I2C_24C08_EPITCH, tag, owner, clock) { } -ekara_rom_i2c_24lc04_device::ekara_rom_i2c_24lc04_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ekara_rom_i2c_24lc04_device::ekara_rom_i2c_24lc04_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ekara_rom_i2c_base_device(mconfig, EKARA_ROM_I2C_24LC04, tag, owner, clock) { } -ekara_rom_i2c_24lc02_device::ekara_rom_i2c_24lc02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ekara_rom_i2c_24lc02_device::ekara_rom_i2c_24lc02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ekara_rom_i2c_base_device(mconfig, EKARA_ROM_I2C_24LC02, tag, owner, clock) { } -ekara_rom_i2c_24lc02_gc0010_device::ekara_rom_i2c_24lc02_gc0010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ekara_rom_i2c_24lc02_gc0010_device::ekara_rom_i2c_24lc02_gc0010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ekara_rom_i2c_24lc02_gc0010_device(mconfig, EKARA_ROM_I2C_24LC02_GC0010, tag, owner, clock) { } -ekara_rom_i2c_24lc02_gc0010_device::ekara_rom_i2c_24lc02_gc0010_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +ekara_rom_i2c_24lc02_gc0010_device::ekara_rom_i2c_24lc02_gc0010_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ekara_rom_i2c_base_device(mconfig, type, tag, owner, clock) { } -ekara_rom_i2c_24lc08_evio_device::ekara_rom_i2c_24lc08_evio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ekara_rom_i2c_24lc08_evio_device::ekara_rom_i2c_24lc08_evio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ekara_rom_i2c_24lc02_gc0010_device(mconfig, EKARA_ROM_I2C_24LC08_EVIO, tag, owner, clock) { } @@ -159,21 +159,21 @@ bool ekara_rom_i2c_24c08_epitch_device::is_write_access_not_rom(void) void ekara_rom_i2c_24c08_epitch_device::device_add_mconfig(machine_config &config) { - I2C_24C08(config, "i2cmem", 0); + I2C_24C08(config, "i2cmem"); } // i2c 24lc04 void ekara_rom_i2c_24lc04_device::device_add_mconfig(machine_config &config) { - I2C_24C04(config, "i2cmem", 0); // 24LC04 + I2C_24C04(config, "i2cmem"); // 24LC04 } // i2c 24lc02 void ekara_rom_i2c_24lc02_device::device_add_mconfig(machine_config &config) { - I2C_24C02(config, "i2cmem", 0); // 24LC02 + I2C_24C02(config, "i2cmem"); // 24LC02 } // i2c 24lc02 with direct IO port access @@ -217,7 +217,7 @@ READ_LINE_MEMBER(ekara_rom_i2c_24lc02_gc0010_device::read_sda ) void ekara_rom_i2c_24lc02_gc0010_device::device_add_mconfig(machine_config &config) { - I2C_24C02(config, "i2cmem", 0); // 24LC02 + I2C_24C02(config, "i2cmem"); // 24LC02 } diff --git a/src/devices/bus/ekara/rom.h b/src/devices/bus/ekara/rom.h index 890136f26ef..9c24f497ba5 100644 --- a/src/devices/bus/ekara/rom.h +++ b/src/devices/bus/ekara/rom.h @@ -15,7 +15,7 @@ class ekara_rom_plain_device : public device_t, { public: // construction/destruction - ekara_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ekara_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -28,7 +28,7 @@ public: virtual void write_rom(offs_t offset, uint8_t data); protected: - ekara_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ekara_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -41,10 +41,10 @@ class ekara_rom_i2c_base_device : public ekara_rom_plain_device { public: // construction/destruction - ekara_rom_i2c_base_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ekara_rom_i2c_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - ekara_rom_i2c_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ekara_rom_i2c_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; @@ -70,7 +70,7 @@ class ekara_rom_i2c_24c08_epitch_device : public ekara_rom_i2c_base_device { public: // construction/destruction - ekara_rom_i2c_24c08_epitch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ekara_rom_i2c_24c08_epitch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual bool is_read_access_not_rom(void) override; @@ -86,7 +86,7 @@ class ekara_rom_i2c_24lc04_device : public ekara_rom_i2c_base_device { public: // construction/destruction - ekara_rom_i2c_24lc04_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ekara_rom_i2c_24lc04_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -98,7 +98,7 @@ class ekara_rom_i2c_24lc02_device : public ekara_rom_i2c_base_device { public: // construction/destruction - ekara_rom_i2c_24lc02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ekara_rom_i2c_24lc02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -111,7 +111,7 @@ class ekara_rom_i2c_24lc02_gc0010_device : public ekara_rom_i2c_base_device { public: // construction/destruction - ekara_rom_i2c_24lc02_gc0010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ekara_rom_i2c_24lc02_gc0010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: ekara_rom_i2c_24lc02_gc0010_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); diff --git a/src/devices/bus/ekara/slot.cpp b/src/devices/bus/ekara/slot.cpp index 2cd33594edb..4cc6b43f95f 100644 --- a/src/devices/bus/ekara/slot.cpp +++ b/src/devices/bus/ekara/slot.cpp @@ -54,7 +54,7 @@ void device_ekara_cart_interface::rom_alloc(uint32_t size) //------------------------------------------------- // ekara_cart_slot_device - constructor //------------------------------------------------- -ekara_cart_slot_device::ekara_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ekara_cart_slot_device::ekara_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EKARA_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_ekara_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/ekara/slot.h b/src/devices/bus/ekara/slot.h index 29cdc7f81de..37d5df75155 100644 --- a/src/devices/bus/ekara/slot.h +++ b/src/devices/bus/ekara/slot.h @@ -66,10 +66,10 @@ class ekara_cart_slot_device : public device_t, { public: // construction/destruction - ekara_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ekara_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> - ekara_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + ekara_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : ekara_cart_slot_device(mconfig, tag, owner, clock) { option_reset(); diff --git a/src/devices/bus/electron/cart/abr.cpp b/src/devices/bus/electron/cart/abr.cpp index 0c82ca65782..af1e4fbd3ab 100644 --- a/src/devices/bus/electron/cart/abr.cpp +++ b/src/devices/bus/electron/cart/abr.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(ELECTRON_ABR, electron_abr_device, "electron_abr", "Electron // electron_abr_device - constructor //------------------------------------------------- -electron_abr_device::electron_abr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_abr_device::electron_abr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_ABR, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) { diff --git a/src/devices/bus/electron/cart/abr.h b/src/devices/bus/electron/cart/abr.h index 3ef92c95a8d..d7c1fc6649f 100644 --- a/src/devices/bus/electron/cart/abr.h +++ b/src/devices/bus/electron/cart/abr.h @@ -25,7 +25,7 @@ class electron_abr_device : public device_t, { public: // construction/destruction - electron_abr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_abr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/ap34.cpp b/src/devices/bus/electron/cart/ap34.cpp index ecb3b9da30c..5f4d4659ab7 100644 --- a/src/devices/bus/electron/cart/ap34.cpp +++ b/src/devices/bus/electron/cart/ap34.cpp @@ -61,7 +61,7 @@ void electron_ap34_device::device_add_mconfig(machine_config &config) // electron_ap34_device - constructor //------------------------------------------------- -electron_ap34_device::electron_ap34_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_ap34_device::electron_ap34_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_AP34, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_fdc(*this, "fdc") diff --git a/src/devices/bus/electron/cart/ap34.h b/src/devices/bus/electron/cart/ap34.h index ac84e7cd58f..3c3f762d7b8 100644 --- a/src/devices/bus/electron/cart/ap34.h +++ b/src/devices/bus/electron/cart/ap34.h @@ -26,7 +26,7 @@ class electron_ap34_device : { public: // construction/destruction - electron_ap34_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_ap34_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/ap5.cpp b/src/devices/bus/electron/cart/ap5.cpp index 90c4188d7b1..6862015154d 100644 --- a/src/devices/bus/electron/cart/ap5.cpp +++ b/src/devices/bus/electron/cart/ap5.cpp @@ -63,7 +63,7 @@ void electron_ap5_device::device_add_mconfig(machine_config &config) // electron_ap5_device - constructor //------------------------------------------------- -electron_ap5_device::electron_ap5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_ap5_device::electron_ap5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_AP5, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_irqs(*this, "irqs") diff --git a/src/devices/bus/electron/cart/ap5.h b/src/devices/bus/electron/cart/ap5.h index 9e69c775c63..f1b23f4c0f2 100644 --- a/src/devices/bus/electron/cart/ap5.h +++ b/src/devices/bus/electron/cart/ap5.h @@ -28,7 +28,7 @@ class electron_ap5_device : { public: // construction/destruction - electron_ap5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_ap5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/aqr.cpp b/src/devices/bus/electron/cart/aqr.cpp index 8be0176efc4..ba7a411078a 100644 --- a/src/devices/bus/electron/cart/aqr.cpp +++ b/src/devices/bus/electron/cart/aqr.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(ELECTRON_AQR, electron_aqr_device, "electron_aqr", "Electron // electron_aqr_device - constructor //------------------------------------------------- -electron_aqr_device::electron_aqr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_aqr_device::electron_aqr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_AQR, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_page_register(0) diff --git a/src/devices/bus/electron/cart/aqr.h b/src/devices/bus/electron/cart/aqr.h index 820f967b5cf..c267415e030 100644 --- a/src/devices/bus/electron/cart/aqr.h +++ b/src/devices/bus/electron/cart/aqr.h @@ -25,7 +25,7 @@ class electron_aqr_device : public device_t, { public: // construction/destruction - electron_aqr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_aqr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/click.cpp b/src/devices/bus/electron/cart/click.cpp index 46bb123c9e4..4dfd48592ba 100644 --- a/src/devices/bus/electron/cart/click.cpp +++ b/src/devices/bus/electron/cart/click.cpp @@ -57,7 +57,7 @@ ioport_constructor electron_click_device::device_input_ports() const // electron_click_device - constructor //------------------------------------------------- -electron_click_device::electron_click_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_click_device::electron_click_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_CLICK, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_rtc(*this, "rtc") diff --git a/src/devices/bus/electron/cart/click.h b/src/devices/bus/electron/cart/click.h index cb7dd114687..4ddcd6c7ab7 100644 --- a/src/devices/bus/electron/cart/click.h +++ b/src/devices/bus/electron/cart/click.h @@ -28,7 +28,7 @@ class electron_click_device : public device_t, { public: // construction/destruction - electron_click_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_click_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(click_button); diff --git a/src/devices/bus/electron/cart/cumana.cpp b/src/devices/bus/electron/cart/cumana.cpp index 9b854871e59..68782806942 100644 --- a/src/devices/bus/electron/cart/cumana.cpp +++ b/src/devices/bus/electron/cart/cumana.cpp @@ -67,7 +67,7 @@ void electron_cumana_device::device_add_mconfig(machine_config &config) // electron_cumana_device - constructor //------------------------------------------------- -electron_cumana_device::electron_cumana_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_cumana_device::electron_cumana_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_CUMANA, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_fdc(*this, "fdc") diff --git a/src/devices/bus/electron/cart/cumana.h b/src/devices/bus/electron/cart/cumana.h index 2dce4bbc78c..5672952f7d7 100644 --- a/src/devices/bus/electron/cart/cumana.h +++ b/src/devices/bus/electron/cart/cumana.h @@ -27,7 +27,7 @@ class electron_cumana_device : { public: // construction/destruction - electron_cumana_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_cumana_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/elksdp1.cpp b/src/devices/bus/electron/cart/elksdp1.cpp index c2baf7e7801..241d073c27f 100644 --- a/src/devices/bus/electron/cart/elksdp1.cpp +++ b/src/devices/bus/electron/cart/elksdp1.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(ELECTRON_ELKSDP1, electron_elksdp1_device, "electron_elksdp1" void electron_elksdp1_device::device_add_mconfig(machine_config &config) { - SPI_SDCARD(config, m_sdcard, 0); + SPI_SDCARD(config, m_sdcard); m_sdcard->spi_miso_callback().set([this](int state) { m_in_bit = state; }); } @@ -38,7 +38,7 @@ void electron_elksdp1_device::device_add_mconfig(machine_config &config) // electron_elksdp1_device - constructor //------------------------------------------------- -electron_elksdp1_device::electron_elksdp1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_elksdp1_device::electron_elksdp1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_ELKSDP1, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_sdcard(*this, "sdcard") diff --git a/src/devices/bus/electron/cart/elksdp1.h b/src/devices/bus/electron/cart/elksdp1.h index d0f606591ec..61267e4a990 100644 --- a/src/devices/bus/electron/cart/elksdp1.h +++ b/src/devices/bus/electron/cart/elksdp1.h @@ -21,7 +21,7 @@ class electron_elksdp1_device : public device_t, public device_electron_cart_int { public: // construction/destruction - electron_elksdp1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_elksdp1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/mgc.cpp b/src/devices/bus/electron/cart/mgc.cpp index 5f80559c47a..99f8bedb560 100644 --- a/src/devices/bus/electron/cart/mgc.cpp +++ b/src/devices/bus/electron/cart/mgc.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(ELECTRON_MGC, electron_mgc_device, "electron_mgc", "Electron // electron_mgc_device - constructor //------------------------------------------------- -electron_mgc_device::electron_mgc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_mgc_device::electron_mgc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_MGC, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_page_latch(0) diff --git a/src/devices/bus/electron/cart/mgc.h b/src/devices/bus/electron/cart/mgc.h index bf23aa34391..f089b6fb0c2 100644 --- a/src/devices/bus/electron/cart/mgc.h +++ b/src/devices/bus/electron/cart/mgc.h @@ -25,7 +25,7 @@ class electron_mgc_device : public device_t, { public: // construction/destruction - electron_mgc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_mgc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/peg400.cpp b/src/devices/bus/electron/cart/peg400.cpp index cba69099613..a685516d67d 100644 --- a/src/devices/bus/electron/cart/peg400.cpp +++ b/src/devices/bus/electron/cart/peg400.cpp @@ -60,7 +60,7 @@ void electron_peg400_device::device_add_mconfig(machine_config &config) // electron_peg400_device - constructor //------------------------------------------------- -electron_peg400_device::electron_peg400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_peg400_device::electron_peg400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_PEG400, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_fdc(*this, "fdc") diff --git a/src/devices/bus/electron/cart/peg400.h b/src/devices/bus/electron/cart/peg400.h index 141cc1fe02f..95418380c12 100644 --- a/src/devices/bus/electron/cart/peg400.h +++ b/src/devices/bus/electron/cart/peg400.h @@ -24,7 +24,7 @@ class electron_peg400_device : { public: // construction/destruction - electron_peg400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_peg400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/romp144.cpp b/src/devices/bus/electron/cart/romp144.cpp index 8bdeab7cc34..57ba5066ca4 100644 --- a/src/devices/bus/electron/cart/romp144.cpp +++ b/src/devices/bus/electron/cart/romp144.cpp @@ -49,7 +49,7 @@ void electron_romp144_device::device_add_mconfig(machine_config &config) // electron_romp144_device - constructor //------------------------------------------------- -electron_romp144_device::electron_romp144_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_romp144_device::electron_romp144_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_ROMP144, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_romslot(*this, "rom%u", 7) diff --git a/src/devices/bus/electron/cart/romp144.h b/src/devices/bus/electron/cart/romp144.h index 45916a3ab38..240788191c3 100644 --- a/src/devices/bus/electron/cart/romp144.h +++ b/src/devices/bus/electron/cart/romp144.h @@ -23,7 +23,7 @@ class electron_romp144_device : { public: // construction/destruction - electron_romp144_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_romp144_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/rs423.cpp b/src/devices/bus/electron/cart/rs423.cpp index 68838a4cae2..746b27900d7 100644 --- a/src/devices/bus/electron/cart/rs423.cpp +++ b/src/devices/bus/electron/cart/rs423.cpp @@ -43,7 +43,7 @@ void electron_rs423_device::device_add_mconfig(machine_config &config) // electron_rs423_device - constructor //------------------------------------------------- -electron_rs423_device::electron_rs423_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_rs423_device::electron_rs423_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_RS423, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_duart(*this, "duart") diff --git a/src/devices/bus/electron/cart/rs423.h b/src/devices/bus/electron/cart/rs423.h index 0068b9c701e..9fc582cd68d 100644 --- a/src/devices/bus/electron/cart/rs423.h +++ b/src/devices/bus/electron/cart/rs423.h @@ -22,7 +22,7 @@ class electron_rs423_device : { public: // construction/destruction - electron_rs423_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_rs423_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/slot.cpp b/src/devices/bus/electron/cart/slot.cpp index bcdff13233d..9268c2d5d03 100644 --- a/src/devices/bus/electron/cart/slot.cpp +++ b/src/devices/bus/electron/cart/slot.cpp @@ -89,7 +89,7 @@ void device_electron_cart_interface::nvram_alloc(uint32_t size) //------------------------------------------------- // electron_cartslot_device - constructor //------------------------------------------------- -electron_cartslot_device::electron_cartslot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +electron_cartslot_device::electron_cartslot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_electron_cart_interface>(mconfig, *this), @@ -99,7 +99,7 @@ electron_cartslot_device::electron_cartslot_device(const machine_config &mconfig { } -electron_cartslot_device::electron_cartslot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +electron_cartslot_device::electron_cartslot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : electron_cartslot_device(mconfig, ELECTRON_CARTSLOT, tag, owner, clock) { } diff --git a/src/devices/bus/electron/cart/slot.h b/src/devices/bus/electron/cart/slot.h index b71da09d5ae..a03b6ca63eb 100644 --- a/src/devices/bus/electron/cart/slot.h +++ b/src/devices/bus/electron/cart/slot.h @@ -121,7 +121,7 @@ class electron_cartslot_device : public device_t, public: // construction/destruction template <typename T> - electron_cartslot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&slot_options, const char *default_option) + electron_cartslot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&slot_options, const char *default_option) : electron_cartslot_device(mconfig, tag, owner, clock) { option_reset(); @@ -130,7 +130,7 @@ public: set_fixed(false); } - electron_cartslot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_cartslot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto irq_handler() { return m_irq_handler.bind(); } @@ -158,7 +158,7 @@ public: DECLARE_WRITE_LINE_MEMBER(nmi_w) { m_nmi_handler(state); } protected: - electron_cartslot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + electron_cartslot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/electron/cart/sndexp.cpp b/src/devices/bus/electron/cart/sndexp.cpp index 9ca096adbfd..fa587549f7b 100644 --- a/src/devices/bus/electron/cart/sndexp.cpp +++ b/src/devices/bus/electron/cart/sndexp.cpp @@ -60,7 +60,7 @@ ioport_constructor electron_sndexp_device::device_input_ports() const // electron_sndexp_device - constructor //------------------------------------------------- -electron_sndexp_device::electron_sndexp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_sndexp_device::electron_sndexp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_SNDEXP, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_sn(*this, "sn76489") diff --git a/src/devices/bus/electron/cart/sndexp.h b/src/devices/bus/electron/cart/sndexp.h index f222185aa5f..1eb70a91c0a 100644 --- a/src/devices/bus/electron/cart/sndexp.h +++ b/src/devices/bus/electron/cart/sndexp.h @@ -22,7 +22,7 @@ class electron_sndexp_device : { public: // construction/destruction - electron_sndexp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_sndexp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/sndexp3.cpp b/src/devices/bus/electron/cart/sndexp3.cpp index f39fb90c414..925dfb1346f 100644 --- a/src/devices/bus/electron/cart/sndexp3.cpp +++ b/src/devices/bus/electron/cart/sndexp3.cpp @@ -39,7 +39,7 @@ void electron_sndexp3_device::device_add_mconfig(machine_config &config) // electron_sndexp3_device - constructor //------------------------------------------------- -electron_sndexp3_device::electron_sndexp3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_sndexp3_device::electron_sndexp3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_SNDEXP3, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_sn(*this, "sn76489") diff --git a/src/devices/bus/electron/cart/sndexp3.h b/src/devices/bus/electron/cart/sndexp3.h index 95d437b63e2..455ea7a9a66 100644 --- a/src/devices/bus/electron/cart/sndexp3.h +++ b/src/devices/bus/electron/cart/sndexp3.h @@ -22,7 +22,7 @@ class electron_sndexp3_device : { public: // construction/destruction - electron_sndexp3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_sndexp3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/sp64.cpp b/src/devices/bus/electron/cart/sp64.cpp index 9b5d497999e..3b811207a72 100644 --- a/src/devices/bus/electron/cart/sp64.cpp +++ b/src/devices/bus/electron/cart/sp64.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(ELECTRON_SP64, electron_sp64_device, "electron_sp64", "Slogge // electron_sp64_device - constructor //------------------------------------------------- -electron_sp64_device::electron_sp64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_sp64_device::electron_sp64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_SP64, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_page_register(0) diff --git a/src/devices/bus/electron/cart/sp64.h b/src/devices/bus/electron/cart/sp64.h index 68954fc9d30..2466621ad47 100644 --- a/src/devices/bus/electron/cart/sp64.h +++ b/src/devices/bus/electron/cart/sp64.h @@ -25,7 +25,7 @@ class electron_sp64_device : public device_t, { public: // construction/destruction - electron_sp64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_sp64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/std.cpp b/src/devices/bus/electron/cart/std.cpp index f2b7333f347..6bbad0f3f78 100644 --- a/src/devices/bus/electron/cart/std.cpp +++ b/src/devices/bus/electron/cart/std.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(ELECTRON_STDCART, electron_stdcart_device, "electron_stdcart" // electron_stdcart_device - constructor //------------------------------------------------- -electron_stdcart_device::electron_stdcart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_stdcart_device::electron_stdcart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_STDCART, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) { diff --git a/src/devices/bus/electron/cart/std.h b/src/devices/bus/electron/cart/std.h index 3fc9cefbcd9..dae32559841 100644 --- a/src/devices/bus/electron/cart/std.h +++ b/src/devices/bus/electron/cart/std.h @@ -24,7 +24,7 @@ class electron_stdcart_device : public device_t, { public: // construction/destruction - electron_stdcart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_stdcart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/stlefs.cpp b/src/devices/bus/electron/cart/stlefs.cpp index 462ead401d1..0f1932976c4 100644 --- a/src/devices/bus/electron/cart/stlefs.cpp +++ b/src/devices/bus/electron/cart/stlefs.cpp @@ -70,7 +70,7 @@ void electron_stlefs_device::device_add_mconfig(machine_config &config) // electron_stlefs_device - constructor //------------------------------------------------- -electron_stlefs_device::electron_stlefs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_stlefs_device::electron_stlefs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_STLEFS, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_irqs(*this, "irqs") diff --git a/src/devices/bus/electron/cart/stlefs.h b/src/devices/bus/electron/cart/stlefs.h index 2ff8e53ea87..2b0e33214d3 100644 --- a/src/devices/bus/electron/cart/stlefs.h +++ b/src/devices/bus/electron/cart/stlefs.h @@ -28,7 +28,7 @@ class electron_stlefs_device : { public: // construction/destruction - electron_stlefs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_stlefs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/cart/tube.cpp b/src/devices/bus/electron/cart/tube.cpp index 02dcd00275d..e4cea6d5a49 100644 --- a/src/devices/bus/electron/cart/tube.cpp +++ b/src/devices/bus/electron/cart/tube.cpp @@ -37,7 +37,7 @@ void electron_tube_device::device_add_mconfig(machine_config &config) // electron_tube_device - constructor //------------------------------------------------- -electron_tube_device::electron_tube_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_tube_device::electron_tube_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_TUBE, tag, owner, clock) , device_electron_cart_interface(mconfig, *this) , m_tube(*this, "tube") diff --git a/src/devices/bus/electron/cart/tube.h b/src/devices/bus/electron/cart/tube.h index 1d239ef5215..579c68fbdc0 100644 --- a/src/devices/bus/electron/cart/tube.h +++ b/src/devices/bus/electron/cart/tube.h @@ -22,7 +22,7 @@ class electron_tube_device : { public: // construction/destruction - electron_tube_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_tube_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/elksd128.cpp b/src/devices/bus/electron/elksd128.cpp index 302144bb343..12179d61ba3 100644 --- a/src/devices/bus/electron/elksd128.cpp +++ b/src/devices/bus/electron/elksd128.cpp @@ -57,7 +57,7 @@ ROM_END void electron_elksd128_device::device_add_mconfig(machine_config &config) { - SPI_SDCARD(config, m_sdcard, 0); + SPI_SDCARD(config, m_sdcard); m_sdcard->spi_miso_callback().set([this](int state) { m_in_bit = state; }); } @@ -78,7 +78,7 @@ const tiny_rom_entry *electron_elksd128_device::device_rom_region() const // electron_elksd128_device - constructor //------------------------------------------------- -electron_elksd128_device::electron_elksd128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_elksd128_device::electron_elksd128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_ELKSD128, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_flash(*this, "flash") diff --git a/src/devices/bus/electron/elksd128.h b/src/devices/bus/electron/elksd128.h index 48ff1375ea9..bde97f588a7 100644 --- a/src/devices/bus/electron/elksd128.h +++ b/src/devices/bus/electron/elksd128.h @@ -24,7 +24,7 @@ class electron_elksd128_device: { public: // construction/destruction - electron_elksd128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_elksd128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/elksd64.cpp b/src/devices/bus/electron/elksd64.cpp index c76c9a8c685..030fc3732f0 100644 --- a/src/devices/bus/electron/elksd64.cpp +++ b/src/devices/bus/electron/elksd64.cpp @@ -38,7 +38,7 @@ ROM_END void electron_elksd64_device::device_add_mconfig(machine_config &config) { - SPI_SDCARD(config, m_sdcard, 0); + SPI_SDCARD(config, m_sdcard); m_sdcard->spi_miso_callback().set([this](int state) { m_status = state << 7; }); } @@ -59,7 +59,7 @@ const tiny_rom_entry *electron_elksd64_device::device_rom_region() const // electron_elksd64_device - constructor //------------------------------------------------- -electron_elksd64_device::electron_elksd64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_elksd64_device::electron_elksd64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_ELKSD64, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_flash(*this, "flash") diff --git a/src/devices/bus/electron/elksd64.h b/src/devices/bus/electron/elksd64.h index d21b9595fc0..093eaf34a5b 100644 --- a/src/devices/bus/electron/elksd64.h +++ b/src/devices/bus/electron/elksd64.h @@ -24,7 +24,7 @@ class electron_elksd64_device: { public: // construction/destruction - electron_elksd64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_elksd64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/exp.cpp b/src/devices/bus/electron/exp.cpp index 6e9b1c6a2e4..097111bcb28 100644 --- a/src/devices/bus/electron/exp.cpp +++ b/src/devices/bus/electron/exp.cpp @@ -40,7 +40,7 @@ device_electron_expansion_interface::device_electron_expansion_interface(const m // electron_expansion_slot_device - constructor //------------------------------------------------- -electron_expansion_slot_device::electron_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +electron_expansion_slot_device::electron_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_electron_expansion_interface>(mconfig, *this), m_card(nullptr), diff --git a/src/devices/bus/electron/exp.h b/src/devices/bus/electron/exp.h index ea0c435a4be..b1895f62cac 100644 --- a/src/devices/bus/electron/exp.h +++ b/src/devices/bus/electron/exp.h @@ -103,7 +103,7 @@ class electron_expansion_slot_device : public device_t, public device_single_car public: // construction/destruction template <typename T> - electron_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + electron_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : electron_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -111,7 +111,7 @@ public: set_default_option(dflt); set_fixed(false); } - electron_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/bus/electron/fbjoy.cpp b/src/devices/bus/electron/fbjoy.cpp index e5a4042cfeb..19012c64572 100644 --- a/src/devices/bus/electron/fbjoy.cpp +++ b/src/devices/bus/electron/fbjoy.cpp @@ -46,7 +46,7 @@ ioport_constructor electron_fbjoy_device::device_input_ports() const // electron_fbjoy_device - constructor //------------------------------------------------- -electron_fbjoy_device::electron_fbjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_fbjoy_device::electron_fbjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_FBJOY, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_joy(*this, "JOY") diff --git a/src/devices/bus/electron/fbjoy.h b/src/devices/bus/electron/fbjoy.h index d9faaa6cd15..4ea31227377 100644 --- a/src/devices/bus/electron/fbjoy.h +++ b/src/devices/bus/electron/fbjoy.h @@ -28,7 +28,7 @@ class electron_fbjoy_device : { public: // construction/destruction - electron_fbjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_fbjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/electron/fbprint.cpp b/src/devices/bus/electron/fbprint.cpp index 00bb056db75..6952e78144d 100644 --- a/src/devices/bus/electron/fbprint.cpp +++ b/src/devices/bus/electron/fbprint.cpp @@ -39,7 +39,7 @@ void electron_fbprint_device::device_add_mconfig(machine_config &config) // electron_fbprint_device - constructor //------------------------------------------------- -electron_fbprint_device::electron_fbprint_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_fbprint_device::electron_fbprint_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_FBPRINT, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_centronics(*this, "centronics") diff --git a/src/devices/bus/electron/fbprint.h b/src/devices/bus/electron/fbprint.h index f279e216943..4cb598ae6cb 100644 --- a/src/devices/bus/electron/fbprint.h +++ b/src/devices/bus/electron/fbprint.h @@ -24,7 +24,7 @@ class electron_fbprint_device: { public: // construction/destruction - electron_fbprint_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_fbprint_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/m2105.cpp b/src/devices/bus/electron/m2105.cpp index 35ba1e40e13..9c40e47482d 100644 --- a/src/devices/bus/electron/m2105.cpp +++ b/src/devices/bus/electron/m2105.cpp @@ -116,7 +116,7 @@ void electron_m2105_device::device_add_mconfig(machine_config &config) TMS6100(config, "tms6100", 640000/4); - tms5220_device &tms(TMS5220(config, "tms5220", 640000)); + tms5220_device &tms(TMS5220(config, "tms5220", XTAL::u(640000))); tms.ready_cb().set(m_via[0], FUNC(via6522_device::write_ca1)); tms.ready_cb().append(m_via[0], FUNC(via6522_device::write_pb2)); tms.irq_cb().set(m_via[0], FUNC(via6522_device::write_ca2)); @@ -144,7 +144,7 @@ const tiny_rom_entry *electron_m2105_device::device_rom_region() const // electron_m2105_device - constructor //------------------------------------------------- -electron_m2105_device::electron_m2105_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_m2105_device::electron_m2105_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_M2105, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_exp_rom(*this, "exp_rom") diff --git a/src/devices/bus/electron/m2105.h b/src/devices/bus/electron/m2105.h index 07c5ffc35c4..d0afe533562 100644 --- a/src/devices/bus/electron/m2105.h +++ b/src/devices/bus/electron/m2105.h @@ -32,7 +32,7 @@ class electron_m2105_device: { public: // construction/destruction - electron_m2105_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_m2105_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/electron/mc68k.cpp b/src/devices/bus/electron/mc68k.cpp index 06e39350977..8650430fc51 100644 --- a/src/devices/bus/electron/mc68k.cpp +++ b/src/devices/bus/electron/mc68k.cpp @@ -92,14 +92,14 @@ void electron_mc68k_device::device_add_mconfig(machine_config &config) RAM(config, m_ram).set_default_size("256K").set_extra_options("64K,128K,192K"); - PIA6821(config, m_pia[0], 0); + PIA6821(config, m_pia[0]); m_pia[0]->writepb_handler().set(m_pia[1], FUNC(pia6821_device::set_a_input)); m_pia[0]->ca2_handler().set(m_pia[1], FUNC(pia6821_device::cb1_w)); m_pia[0]->cb2_handler().set(m_pia[1], FUNC(pia6821_device::ca1_w)); m_pia[0]->irqa_handler().set("irq_ipl0", FUNC(input_merger_device::in_w<0>)); m_pia[0]->irqb_handler().set("irq_ipl0", FUNC(input_merger_device::in_w<1>)); - PIA6821(config, m_pia[1], 0); + PIA6821(config, m_pia[1]); m_pia[1]->writepb_handler().set(m_pia[0], FUNC(pia6821_device::set_a_input)); m_pia[1]->ca2_handler().set(m_pia[0], FUNC(pia6821_device::cb1_w)); m_pia[1]->cb2_handler().set(m_pia[0], FUNC(pia6821_device::ca1_w)); @@ -109,7 +109,7 @@ void electron_mc68k_device::device_add_mconfig(machine_config &config) via6522_device &via(MOS6522(config, "via", 10_MHz_XTAL / 10)); via.irq_handler().set("irq_ipl1", FUNC(input_merger_device::in_w<0>)); - acia6850_device &acia(ACIA6850(config, "acia", 0)); + acia6850_device &acia(ACIA6850(config, "acia")); acia.irq_handler().set("irq_ipl1", FUNC(input_merger_device::in_w<1>)); clock_device &acia_clock(CLOCK(config, "acia_clock", 3.6864_MHz_XTAL / 12)); @@ -130,7 +130,7 @@ const tiny_rom_entry *electron_mc68k_device::device_rom_region() const // electron_mc68k_device - constructor //------------------------------------------------- -electron_mc68k_device::electron_mc68k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +electron_mc68k_device::electron_mc68k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_MC68K, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_maincpu(*this, "maincpu") diff --git a/src/devices/bus/electron/mc68k.h b/src/devices/bus/electron/mc68k.h index c469d06e357..ef27b553e3b 100644 --- a/src/devices/bus/electron/mc68k.h +++ b/src/devices/bus/electron/mc68k.h @@ -27,7 +27,7 @@ class electron_mc68k_device: { public: // construction/destruction - electron_mc68k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_mc68k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/mode7.cpp b/src/devices/bus/electron/mode7.cpp index 408b6a92300..5093b84499e 100644 --- a/src/devices/bus/electron/mode7.cpp +++ b/src/devices/bus/electron/mode7.cpp @@ -95,7 +95,7 @@ const tiny_rom_entry *electron_mode7_device::device_rom_region() const // electron_mode7_device - constructor //------------------------------------------------- -electron_mode7_device::electron_mode7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_mode7_device::electron_mode7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_MODE7, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_screen(*this, "screen") diff --git a/src/devices/bus/electron/mode7.h b/src/devices/bus/electron/mode7.h index b3c447ee87d..afd1641aceb 100644 --- a/src/devices/bus/electron/mode7.h +++ b/src/devices/bus/electron/mode7.h @@ -27,7 +27,7 @@ public: static constexpr feature_type imperfect_features() { return feature::GRAPHICS; } // construction/destruction - electron_mode7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_mode7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(break_button); diff --git a/src/devices/bus/electron/plus1.cpp b/src/devices/bus/electron/plus1.cpp index e9aa67bb16b..6e5511ac7ef 100644 --- a/src/devices/bus/electron/plus1.cpp +++ b/src/devices/bus/electron/plus1.cpp @@ -171,7 +171,7 @@ const tiny_rom_entry *electron_ap6_device::device_rom_region() const // electron_plus1_device - constructor //------------------------------------------------- -electron_plus1_device::electron_plus1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +electron_plus1_device::electron_plus1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_irqs(*this, "irqs") @@ -188,17 +188,17 @@ electron_plus1_device::electron_plus1_device(const machine_config &mconfig, devi { } -electron_plus1_device::electron_plus1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_plus1_device::electron_plus1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : electron_plus1_device(mconfig, ELECTRON_PLUS1, tag, owner, clock) { } -electron_ap1_device::electron_ap1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_ap1_device::electron_ap1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : electron_plus1_device(mconfig, ELECTRON_AP1, tag, owner, clock) { } -electron_ap6_device::electron_ap6_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +electron_ap6_device::electron_ap6_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : electron_plus1_device(mconfig, ELECTRON_AP6, tag, owner, clock) , m_rom(*this, "rom%u", 1) , m_links(*this, "LINKS") diff --git a/src/devices/bus/electron/plus1.h b/src/devices/bus/electron/plus1.h index bdfd35808e7..f48433e37aa 100644 --- a/src/devices/bus/electron/plus1.h +++ b/src/devices/bus/electron/plus1.h @@ -29,10 +29,10 @@ class electron_plus1_device: { public: // construction/destruction - electron_plus1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_plus1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - electron_plus1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + electron_plus1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -62,7 +62,7 @@ protected: class electron_ap1_device : public electron_plus1_device { public: - electron_ap1_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + electron_ap1_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); protected: // optional information overrides @@ -73,7 +73,7 @@ protected: class electron_ap6_device : public electron_plus1_device { public: - electron_ap6_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + electron_ap6_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/plus2.cpp b/src/devices/bus/electron/plus2.cpp index 7a75524ed5c..6f8f68982f1 100644 --- a/src/devices/bus/electron/plus2.cpp +++ b/src/devices/bus/electron/plus2.cpp @@ -76,7 +76,7 @@ void electron_plus2_device::device_add_mconfig(machine_config &config) // electron_plus2_device - constructor //------------------------------------------------- -electron_plus2_device::electron_plus2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_plus2_device::electron_plus2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_PLUS2, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_irqs(*this, "irqs") diff --git a/src/devices/bus/electron/plus2.h b/src/devices/bus/electron/plus2.h index 04e3a280377..390b1ae7277 100644 --- a/src/devices/bus/electron/plus2.h +++ b/src/devices/bus/electron/plus2.h @@ -28,7 +28,7 @@ class electron_plus2_device: { public: // construction/destruction - electron_plus2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_plus2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/plus3.cpp b/src/devices/bus/electron/plus3.cpp index 1589bc722b9..cd7b85e0f1b 100644 --- a/src/devices/bus/electron/plus3.cpp +++ b/src/devices/bus/electron/plus3.cpp @@ -99,7 +99,7 @@ const tiny_rom_entry *electron_plus3_device::device_rom_region() const // electron_plus3_device - constructor //------------------------------------------------- -electron_plus3_device::electron_plus3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_plus3_device::electron_plus3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_PLUS3, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_exp(*this, "exp") diff --git a/src/devices/bus/electron/plus3.h b/src/devices/bus/electron/plus3.h index 2854557675b..8f0a5638a83 100644 --- a/src/devices/bus/electron/plus3.h +++ b/src/devices/bus/electron/plus3.h @@ -24,7 +24,7 @@ class electron_plus3_device: { public: // construction/destruction - electron_plus3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_plus3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/pwrjoy.cpp b/src/devices/bus/electron/pwrjoy.cpp index 1ff7ab79566..38f1a11703b 100644 --- a/src/devices/bus/electron/pwrjoy.cpp +++ b/src/devices/bus/electron/pwrjoy.cpp @@ -55,7 +55,7 @@ const tiny_rom_entry *electron_pwrjoy_device::device_rom_region() const // electron_pwrjoy_device - constructor //------------------------------------------------- -electron_pwrjoy_device::electron_pwrjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_pwrjoy_device::electron_pwrjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_PWRJOY, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_exp_rom(*this, "exp_rom") diff --git a/src/devices/bus/electron/pwrjoy.h b/src/devices/bus/electron/pwrjoy.h index abc91cf3e2b..cf72e5f8284 100644 --- a/src/devices/bus/electron/pwrjoy.h +++ b/src/devices/bus/electron/pwrjoy.h @@ -26,7 +26,7 @@ class electron_pwrjoy_device : { public: // construction/destruction - electron_pwrjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_pwrjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/electron/rombox.cpp b/src/devices/bus/electron/rombox.cpp index 47040271e7f..e6cdb9f8c04 100644 --- a/src/devices/bus/electron/rombox.cpp +++ b/src/devices/bus/electron/rombox.cpp @@ -85,7 +85,7 @@ void electron_rombox_device::device_add_mconfig(machine_config &config) // electron_rombox_device - constructor //------------------------------------------------- -electron_rombox_device::electron_rombox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_rombox_device::electron_rombox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_ROMBOX, tag, owner, clock), device_electron_expansion_interface(mconfig, *this), m_exp(*this, "exp"), diff --git a/src/devices/bus/electron/rombox.h b/src/devices/bus/electron/rombox.h index 65ed2fa80d8..b18fc522904 100644 --- a/src/devices/bus/electron/rombox.h +++ b/src/devices/bus/electron/rombox.h @@ -24,7 +24,7 @@ class electron_rombox_device: { public: // construction/destruction - electron_rombox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_rombox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/romboxp.cpp b/src/devices/bus/electron/romboxp.cpp index 59d83bc4121..2a53446c6ff 100644 --- a/src/devices/bus/electron/romboxp.cpp +++ b/src/devices/bus/electron/romboxp.cpp @@ -120,7 +120,7 @@ const tiny_rom_entry *electron_romboxp_device::device_rom_region() const // electron_romboxp_device - constructor //------------------------------------------------- -electron_romboxp_device::electron_romboxp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_romboxp_device::electron_romboxp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_ROMBOXP, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_irqs(*this, "irqs") diff --git a/src/devices/bus/electron/romboxp.h b/src/devices/bus/electron/romboxp.h index 62b2124c913..2a3b1b02de2 100644 --- a/src/devices/bus/electron/romboxp.h +++ b/src/devices/bus/electron/romboxp.h @@ -29,7 +29,7 @@ class electron_romboxp_device: { public: // construction/destruction - electron_romboxp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_romboxp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/electron/sidewndr.cpp b/src/devices/bus/electron/sidewndr.cpp index a2ab8011b09..0702b416c70 100644 --- a/src/devices/bus/electron/sidewndr.cpp +++ b/src/devices/bus/electron/sidewndr.cpp @@ -84,7 +84,7 @@ const tiny_rom_entry *electron_sidewndr_device::device_rom_region() const // electron_sidewndr_device - constructor //------------------------------------------------- -electron_sidewndr_device::electron_sidewndr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +electron_sidewndr_device::electron_sidewndr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ELECTRON_SIDEWNDR, tag, owner, clock) , device_electron_expansion_interface(mconfig, *this) , m_exp(*this, "exp") diff --git a/src/devices/bus/electron/sidewndr.h b/src/devices/bus/electron/sidewndr.h index 2e1dea53087..5199d8ffdc5 100644 --- a/src/devices/bus/electron/sidewndr.h +++ b/src/devices/bus/electron/sidewndr.h @@ -24,7 +24,7 @@ class electron_sidewndr_device: { public: // construction/destruction - electron_sidewndr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + electron_sidewndr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/ep64/exdos.cpp b/src/devices/bus/ep64/exdos.cpp index 37f382955eb..d18378e053d 100644 --- a/src/devices/bus/ep64/exdos.cpp +++ b/src/devices/bus/ep64/exdos.cpp @@ -124,7 +124,7 @@ void ep64_exdos_device::device_add_mconfig(machine_config &config) // ep64_exdos_device - constructor //------------------------------------------------- -ep64_exdos_device::ep64_exdos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ep64_exdos_device::ep64_exdos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EP64_EXDOS, tag, owner, clock), device_ep64_expansion_bus_card_interface(mconfig, *this), m_fdc(*this, WD1770_TAG), diff --git a/src/devices/bus/ep64/exdos.h b/src/devices/bus/ep64/exdos.h index cb5f9d47cc7..9407c1056af 100644 --- a/src/devices/bus/ep64/exdos.h +++ b/src/devices/bus/ep64/exdos.h @@ -29,7 +29,7 @@ class ep64_exdos_device : public device_t, { public: // construction/destruction - ep64_exdos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ep64_exdos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(); void write(uint8_t data); diff --git a/src/devices/bus/ep64/exp.cpp b/src/devices/bus/ep64/exp.cpp index ebd423cfc7f..293701edcae 100644 --- a/src/devices/bus/ep64/exp.cpp +++ b/src/devices/bus/ep64/exp.cpp @@ -43,7 +43,7 @@ device_ep64_expansion_bus_card_interface::device_ep64_expansion_bus_card_interfa // ep64_expansion_bus_slot_device - constructor //------------------------------------------------- -ep64_expansion_bus_slot_device::ep64_expansion_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ep64_expansion_bus_slot_device::ep64_expansion_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EP64_EXPANSION_BUS_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_ep64_expansion_bus_card_interface>(mconfig, *this) , m_write_irq(*this) diff --git a/src/devices/bus/ep64/exp.h b/src/devices/bus/ep64/exp.h index 354d6f0691e..d5030e24e06 100644 --- a/src/devices/bus/ep64/exp.h +++ b/src/devices/bus/ep64/exp.h @@ -66,14 +66,14 @@ class ep64_expansion_bus_slot_device : public device_t, public: // construction/destruction ep64_expansion_bus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, char const *dflt) - : ep64_expansion_bus_slot_device(mconfig, tag, owner, (uint32_t)0) + : ep64_expansion_bus_slot_device(mconfig, tag, owner) { option_reset(); ep64_expansion_bus_cards(*this); set_default_option(dflt); set_fixed(false); } - ep64_expansion_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ep64_expansion_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> void set_program_space(T &&tag, int spacenum) { m_program_space.set_tag(std::forward<T>(tag), spacenum); } template <typename T> void set_io_space(T &&tag, int spacenum) { m_io_space.set_tag(std::forward<T>(tag), spacenum); } diff --git a/src/devices/bus/epson_qx/multifont.cpp b/src/devices/bus/epson_qx/multifont.cpp index 8349af95dea..38ab373e725 100644 --- a/src/devices/bus/epson_qx/multifont.cpp +++ b/src/devices/bus/epson_qx/multifont.cpp @@ -92,7 +92,7 @@ INPUT_PORTS_END //------------------------------------------------- // multifont_device - constructor //------------------------------------------------- -multifont_device::multifont_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +multifont_device::multifont_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EPSON_QX_OPTION_MULTIFONT, tag, owner, clock), device_option_expansion_interface(mconfig, *this), m_mcu(*this, "mcu"), diff --git a/src/devices/bus/epson_qx/multifont.h b/src/devices/bus/epson_qx/multifont.h index 85cd6739286..7e9839f2d90 100644 --- a/src/devices/bus/epson_qx/multifont.h +++ b/src/devices/bus/epson_qx/multifont.h @@ -27,7 +27,7 @@ class multifont_device : public device_t, public bus::epson_qx::device_option_ex { public: // construction/destruction - multifont_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + multifont_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/epson_qx/option.cpp b/src/devices/bus/epson_qx/option.cpp index 5b6ad3a0f3e..7096be2d10c 100644 --- a/src/devices/bus/epson_qx/option.cpp +++ b/src/devices/bus/epson_qx/option.cpp @@ -24,7 +24,7 @@ namespace bus::epson_qx { //------------------------------------------------- // option_bus_slot_device - constructor //------------------------------------------------- -option_slot_device::option_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +option_slot_device::option_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EPSON_QX_OPTION_BUS_SLOT, tag, owner, clock), device_single_card_slot_interface<device_option_expansion_interface>(mconfig, *this), m_bus(*this, finder_base::DUMMY_TAG), @@ -79,7 +79,7 @@ WRITE_LINE_MEMBER(option_slot_device::rdys_w) { (*m_bus).set_rdys_line(state, m_ //------------------------------------------------- // option_bus_device - constructor //------------------------------------------------- -option_bus_device::option_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +option_bus_device::option_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EPSON_QX_OPTION_BUS, tag, owner, clock), m_iospace(*this, finder_base::DUMMY_TAG, -1), m_inth1_cb(*this), diff --git a/src/devices/bus/epson_qx/option.h b/src/devices/bus/epson_qx/option.h index db74d46deb3..7103bc1990a 100644 --- a/src/devices/bus/epson_qx/option.h +++ b/src/devices/bus/epson_qx/option.h @@ -136,7 +136,7 @@ public: m_bus.set_tag(std::forward<T>(bus_tag)); m_slot = slot; } - option_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + option_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(inth1_w); DECLARE_WRITE_LINE_MEMBER(inth2_w); @@ -182,7 +182,7 @@ class option_bus_device : public device_t { public: // construction/destruction - option_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + option_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_iospace(T &&tag, int spacenum) { m_iospace.set_tag(std::forward<T>(tag), spacenum); } void set_memview(memory_view::memory_view_entry &view) { m_view = &view; } diff --git a/src/devices/bus/epson_sio/epson_sio.cpp b/src/devices/bus/epson_sio/epson_sio.cpp index adb75b853b7..a72f65f3028 100644 --- a/src/devices/bus/epson_sio/epson_sio.cpp +++ b/src/devices/bus/epson_sio/epson_sio.cpp @@ -53,7 +53,7 @@ device_epson_sio_interface::~device_epson_sio_interface() // epson_sio_device - constructor //------------------------------------------------- -epson_sio_device::epson_sio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +epson_sio_device::epson_sio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EPSON_SIO, tag, owner, clock), device_single_card_slot_interface<device_epson_sio_interface>(mconfig, *this), m_cart(nullptr), diff --git a/src/devices/bus/epson_sio/epson_sio.h b/src/devices/bus/epson_sio/epson_sio.h index 99bf6bce7a3..e7a594d5709 100644 --- a/src/devices/bus/epson_sio/epson_sio.h +++ b/src/devices/bus/epson_sio/epson_sio.h @@ -26,7 +26,7 @@ class epson_sio_device : public device_t, public device_single_card_slot_interfa public: // construction/destruction epson_sio_device(machine_config const &mconfig, char const *tag, device_t *owner, char const *dflt) - : epson_sio_device(mconfig, tag, owner, (uint32_t)0) + : epson_sio_device(mconfig, tag, owner) { option_reset(); epson_sio_devices(*this); @@ -34,7 +34,7 @@ public: set_fixed(false); } - epson_sio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + epson_sio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~epson_sio_device(); // callbacks diff --git a/src/devices/bus/epson_sio/pf10.cpp b/src/devices/bus/epson_sio/pf10.cpp index 067931da4e8..5fe21eeda1b 100644 --- a/src/devices/bus/epson_sio/pf10.cpp +++ b/src/devices/bus/epson_sio/pf10.cpp @@ -70,7 +70,7 @@ void epson_pf10_device::device_add_mconfig(machine_config &config) m_cpu->out_p2_cb().set(FUNC(epson_pf10_device::port2_w)); m_cpu->out_ser_tx_cb().set(FUNC(epson_pf10_device::hd6303_tx_w)); - UPD765A(config, m_fdc, 4'000'000, false, true); + UPD765A(config, m_fdc, XTAL::u(4'000'000), false, true); FLOPPY_CONNECTOR(config, m_floppy, pf10_floppies, "smd165", floppy_image_device::default_mfm_floppy_formats); EPSON_SIO(config, m_sio_output, nullptr); @@ -87,7 +87,7 @@ void epson_pf10_device::device_add_mconfig(machine_config &config) // epson_pf10_device - constructor //------------------------------------------------- -epson_pf10_device::epson_pf10_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +epson_pf10_device::epson_pf10_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EPSON_PF10, tag, owner, clock), device_epson_sio_interface(mconfig, *this), m_cpu(*this, "maincpu"), diff --git a/src/devices/bus/epson_sio/pf10.h b/src/devices/bus/epson_sio/pf10.h index ce5f2ee6f3d..a2bf134a25b 100644 --- a/src/devices/bus/epson_sio/pf10.h +++ b/src/devices/bus/epson_sio/pf10.h @@ -28,7 +28,7 @@ class epson_pf10_device : public device_t, { public: // construction/destruction - epson_pf10_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + epson_pf10_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/epson_sio/tf20.cpp b/src/devices/bus/epson_sio/tf20.cpp index a2f9c2e9320..4eec8534410 100644 --- a/src/devices/bus/epson_sio/tf20.cpp +++ b/src/devices/bus/epson_sio/tf20.cpp @@ -124,7 +124,7 @@ void epson_tf20_device::device_add_mconfig(machine_config &config) // epson_tf20_device - constructor //------------------------------------------------- -epson_tf20_device::epson_tf20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +epson_tf20_device::epson_tf20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EPSON_TF20, tag, owner, clock), device_epson_sio_interface(mconfig, *this), m_cpu(*this, "19b"), diff --git a/src/devices/bus/epson_sio/tf20.h b/src/devices/bus/epson_sio/tf20.h index 906ae0a4b9c..3a101038211 100644 --- a/src/devices/bus/epson_sio/tf20.h +++ b/src/devices/bus/epson_sio/tf20.h @@ -30,7 +30,7 @@ class epson_tf20_device : public device_t, { public: // construction/destruction - epson_tf20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + epson_tf20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/fmt_scsi/fmt121.cpp b/src/devices/bus/fmt_scsi/fmt121.cpp index 34f784115a0..1044c77d9e0 100644 --- a/src/devices/bus/fmt_scsi/fmt121.cpp +++ b/src/devices/bus/fmt_scsi/fmt121.cpp @@ -59,7 +59,7 @@ DEFINE_DEVICE_TYPE(FMT121, fmt121_device, "fmt121", "FMT-121 SCSI Card") // fmt121_device - construction //------------------------------------------------- -fmt121_device::fmt121_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +fmt121_device::fmt121_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, FMT121, tag, owner, clock) , fmt_scsi_card_interface(mconfig, *this) , m_scsi_ctlr(*this, "fmscsi") @@ -74,14 +74,14 @@ fmt121_device::fmt121_device(const machine_config &mconfig, const char *tag, dev void fmt121_device::device_add_mconfig(machine_config &config) { - scsi_port_device &scsi(SCSI_PORT(config, "scsi", 0)); + scsi_port_device &scsi(SCSI_PORT(config, "scsi")); scsi.set_slot_device(1, "harddisk", SCSIHD, DEVICE_INPUT_DEFAULTS_NAME(SCSI_ID_0)); scsi.set_slot_device(2, "harddisk", SCSIHD, DEVICE_INPUT_DEFAULTS_NAME(SCSI_ID_1)); scsi.set_slot_device(3, "harddisk", SCSIHD, DEVICE_INPUT_DEFAULTS_NAME(SCSI_ID_2)); scsi.set_slot_device(4, "harddisk", SCSIHD, DEVICE_INPUT_DEFAULTS_NAME(SCSI_ID_3)); scsi.set_slot_device(5, "harddisk", SCSIHD, DEVICE_INPUT_DEFAULTS_NAME(SCSI_ID_4)); - FMSCSI(config, m_scsi_ctlr, 0); + FMSCSI(config, m_scsi_ctlr); m_scsi_ctlr->set_scsi_port("scsi"); m_scsi_ctlr->irq_handler().set(FUNC(fmt121_device::irq_w)); m_scsi_ctlr->drq_handler().set(FUNC(fmt121_device::drq_w)); diff --git a/src/devices/bus/fmt_scsi/fmt121.h b/src/devices/bus/fmt_scsi/fmt121.h index 9b80b2c70f1..582ca0bdd79 100644 --- a/src/devices/bus/fmt_scsi/fmt121.h +++ b/src/devices/bus/fmt_scsi/fmt121.h @@ -21,7 +21,7 @@ class fmt121_device : public device_t, public fmt_scsi_card_interface { public: // device type constructor - fmt121_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + fmt121_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/fmt_scsi/fmt_scsi.cpp b/src/devices/bus/fmt_scsi/fmt_scsi.cpp index b5d62fb3577..5ae4a09ee24 100644 --- a/src/devices/bus/fmt_scsi/fmt_scsi.cpp +++ b/src/devices/bus/fmt_scsi/fmt_scsi.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(FMT_SCSI_SLOT, fmt_scsi_slot_device, "fmt_scsi_slot", "FM Tow // fmt_scsi_slot_device - construction //------------------------------------------------- -fmt_scsi_slot_device::fmt_scsi_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +fmt_scsi_slot_device::fmt_scsi_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, FMT_SCSI_SLOT, tag, owner, clock) , device_single_card_slot_interface<fmt_scsi_card_interface>(mconfig, *this) , m_card(nullptr) diff --git a/src/devices/bus/fmt_scsi/fmt_scsi.h b/src/devices/bus/fmt_scsi/fmt_scsi.h index 549b1047f4c..780aa33060f 100644 --- a/src/devices/bus/fmt_scsi/fmt_scsi.h +++ b/src/devices/bus/fmt_scsi/fmt_scsi.h @@ -29,7 +29,7 @@ public: // construction/destruction template <typename T> fmt_scsi_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : fmt_scsi_slot_device(mconfig, tag, owner, 0) + : fmt_scsi_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -37,7 +37,7 @@ public: set_fixed(false); } - fmt_scsi_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + fmt_scsi_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto irq_handler() { return m_irq_handler.bind(); } auto drq_handler() { return m_drq_handler.bind(); } diff --git a/src/devices/bus/gamate/gamate_protection.cpp b/src/devices/bus/gamate/gamate_protection.cpp index 4218a237a3f..1e26ca76691 100644 --- a/src/devices/bus/gamate/gamate_protection.cpp +++ b/src/devices/bus/gamate/gamate_protection.cpp @@ -10,7 +10,7 @@ DEFINE_DEVICE_TYPE(GAMATE_PROT, gamate_protection_device, "gamate_prot", "Gamate Protection Mapper") -gamate_protection_device::gamate_protection_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gamate_protection_device::gamate_protection_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GAMATE_PROT, tag, owner, clock), m_is_protection_passed(0), m_has_failed(0), diff --git a/src/devices/bus/gamate/gamate_protection.h b/src/devices/bus/gamate/gamate_protection.h index 5ee37ff3e20..ca98821f602 100644 --- a/src/devices/bus/gamate/gamate_protection.h +++ b/src/devices/bus/gamate/gamate_protection.h @@ -12,7 +12,7 @@ class gamate_protection_device : public device_t { public: // construction/destruction - gamate_protection_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gamate_protection_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); bool is_protection_passed(); diff --git a/src/devices/bus/gamate/rom.cpp b/src/devices/bus/gamate/rom.cpp index 7301b6bdfc7..d1373396f17 100644 --- a/src/devices/bus/gamate/rom.cpp +++ b/src/devices/bus/gamate/rom.cpp @@ -15,31 +15,31 @@ DEFINE_DEVICE_TYPE(GAMATE_ROM_BANKED, gamate_rom_banked_device, "gam DEFINE_DEVICE_TYPE(GAMATE_ROM_4IN1, gamate_rom_4in1_device, "gamate_rom_4in1", "GAMATE 4-in-1 Cartridge") -gamate_rom_plain_device::gamate_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +gamate_rom_plain_device::gamate_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_gamate_cart_interface(mconfig, *this), m_protection(*this, "protection") { } -gamate_rom_plain_device::gamate_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gamate_rom_plain_device::gamate_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gamate_rom_plain_device(mconfig, GAMATE_ROM_PLAIN, tag, owner, clock) { } -gamate_rom_banked_device::gamate_rom_banked_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gamate_rom_banked_device::gamate_rom_banked_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gamate_rom_plain_device(mconfig, GAMATE_ROM_BANKED, tag, owner, clock), m_bank(0) { } -gamate_rom_banked_device::gamate_rom_banked_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +gamate_rom_banked_device::gamate_rom_banked_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : gamate_rom_plain_device(mconfig, type, tag, owner, clock), m_bank(0) { } -gamate_rom_4in1_device::gamate_rom_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gamate_rom_4in1_device::gamate_rom_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gamate_rom_banked_device(mconfig, GAMATE_ROM_4IN1, tag, owner, clock), m_multibank(0) { @@ -170,7 +170,7 @@ void gamate_rom_4in1_device::write_rom(offs_t offset, uint8_t data) void gamate_rom_plain_device::device_add_mconfig(machine_config &config) { - GAMATE_PROT(config, m_protection, 0); + GAMATE_PROT(config, m_protection); } diff --git a/src/devices/bus/gamate/rom.h b/src/devices/bus/gamate/rom.h index cad923f3d54..d2db0bf768e 100644 --- a/src/devices/bus/gamate/rom.h +++ b/src/devices/bus/gamate/rom.h @@ -15,7 +15,7 @@ class gamate_rom_plain_device : public device_t, { public: // construction/destruction - gamate_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gamate_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -24,7 +24,7 @@ public: virtual void write_rom(offs_t offset, uint8_t data); protected: - gamate_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gamate_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; @@ -41,10 +41,10 @@ class gamate_rom_banked_device : public gamate_rom_plain_device { public: // construction/destruction - gamate_rom_banked_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gamate_rom_banked_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - gamate_rom_banked_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gamate_rom_banked_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; @@ -64,7 +64,7 @@ class gamate_rom_4in1_device : public gamate_rom_banked_device { public: // construction/destruction - gamate_rom_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gamate_rom_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; diff --git a/src/devices/bus/gamate/slot.cpp b/src/devices/bus/gamate/slot.cpp index d46ed1d0a65..e24a593db36 100644 --- a/src/devices/bus/gamate/slot.cpp +++ b/src/devices/bus/gamate/slot.cpp @@ -54,7 +54,7 @@ void device_gamate_cart_interface::rom_alloc(uint32_t size) //------------------------------------------------- // gamate_cart_slot_device - constructor //------------------------------------------------- -gamate_cart_slot_device::gamate_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gamate_cart_slot_device::gamate_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GAMATE_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface(mconfig, *this), diff --git a/src/devices/bus/gamate/slot.h b/src/devices/bus/gamate/slot.h index b78fa012705..efb8ccf4040 100644 --- a/src/devices/bus/gamate/slot.h +++ b/src/devices/bus/gamate/slot.h @@ -53,7 +53,7 @@ public: // construction/destruction template <typename T> gamate_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : gamate_cart_slot_device(mconfig, tag, owner, 0) + : gamate_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -61,7 +61,7 @@ public: set_fixed(false); } - gamate_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + gamate_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~gamate_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/gameboy/mbc.cpp b/src/devices/bus/gameboy/mbc.cpp index 4bad4a2522d..d270bf6f0aa 100644 --- a/src/devices/bus/gameboy/mbc.cpp +++ b/src/devices/bus/gameboy/mbc.cpp @@ -88,7 +88,7 @@ namespace { class rom_mbc_device_base : public mbc_ram_device_base<mbc_dual_device_base> { protected: - rom_mbc_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) : + rom_mbc_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : mbc_ram_device_base<mbc_dual_device_base>(mconfig, type, tag, owner, clock), m_view_ram(*this, "ram"), m_bank_lines{ 0U, 0U } diff --git a/src/devices/bus/gameboy/rom.cpp b/src/devices/bus/gameboy/rom.cpp index cf593b95c8a..e7729b30850 100644 --- a/src/devices/bus/gameboy/rom.cpp +++ b/src/devices/bus/gameboy/rom.cpp @@ -50,7 +50,7 @@ namespace { class sachen_mmc_device_base : public mbc_dual_uniform_device_base { protected: - sachen_mmc_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) : + sachen_mmc_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : mbc_dual_uniform_device_base(mconfig, type, tag, owner, clock), m_bank_mux_rom(0U), m_bank_sel_rom{ 0U, 0U } diff --git a/src/devices/bus/gamegear/ggext.cpp b/src/devices/bus/gamegear/ggext.cpp index dad471f1f9b..7fe1d43e142 100644 --- a/src/devices/bus/gamegear/ggext.cpp +++ b/src/devices/bus/gamegear/ggext.cpp @@ -56,7 +56,7 @@ device_gg_ext_port_interface::~device_gg_ext_port_interface() // gg_ext_port_device - constructor //------------------------------------------------- -gg_ext_port_device::gg_ext_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gg_ext_port_device::gg_ext_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GG_EXT_PORT, tag, owner, clock), device_single_card_slot_interface<device_gg_ext_port_interface>(mconfig, *this), m_screen(*this, finder_base::DUMMY_TAG), diff --git a/src/devices/bus/gamegear/ggext.h b/src/devices/bus/gamegear/ggext.h index 04d802eca02..025e8f6cb0e 100644 --- a/src/devices/bus/gamegear/ggext.h +++ b/src/devices/bus/gamegear/ggext.h @@ -30,7 +30,7 @@ public: // construction/destruction template <typename T> gg_ext_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : gg_ext_port_device(mconfig, tag, owner, 0) + : gg_ext_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -38,7 +38,7 @@ public: set_fixed(false); } - gg_ext_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + gg_ext_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~gg_ext_port_device(); // static configuration helpers diff --git a/src/devices/bus/gamegear/smsctrladp.cpp b/src/devices/bus/gamegear/smsctrladp.cpp index d066f815697..34df9be6244 100644 --- a/src/devices/bus/gamegear/smsctrladp.cpp +++ b/src/devices/bus/gamegear/smsctrladp.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(SMS_CTRL_ADAPTOR, sms_ctrl_adaptor_device, "sms_ctrl_adaptor" // sms_ctrl_adaptor_device - constructor //------------------------------------------------- -sms_ctrl_adaptor_device::sms_ctrl_adaptor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_ctrl_adaptor_device::sms_ctrl_adaptor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_CTRL_ADAPTOR, tag, owner, clock), device_gg_ext_port_interface(mconfig, *this), m_subctrl_port(*this, "ctrl") diff --git a/src/devices/bus/gamegear/smsctrladp.h b/src/devices/bus/gamegear/smsctrladp.h index 46646bde0f0..67d7c1e21e1 100644 --- a/src/devices/bus/gamegear/smsctrladp.h +++ b/src/devices/bus/gamegear/smsctrladp.h @@ -29,7 +29,7 @@ class sms_ctrl_adaptor_device : public device_t, { public: // construction/destruction - sms_ctrl_adaptor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_ctrl_adaptor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/gba/gba_slot.cpp b/src/devices/bus/gba/gba_slot.cpp index bb5ad11048e..e574578f700 100644 --- a/src/devices/bus/gba/gba_slot.cpp +++ b/src/devices/bus/gba/gba_slot.cpp @@ -532,7 +532,7 @@ void device_gba_cart_interface::nvram_alloc(uint32_t size) //------------------------------------------------- // gba_cart_slot_device - constructor //------------------------------------------------- -gba_cart_slot_device::gba_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gba_cart_slot_device::gba_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GBA_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_slot_interface(mconfig, *this), diff --git a/src/devices/bus/gba/gba_slot.h b/src/devices/bus/gba/gba_slot.h index 70fad8e4581..e1e7fffb845 100644 --- a/src/devices/bus/gba/gba_slot.h +++ b/src/devices/bus/gba/gba_slot.h @@ -86,7 +86,7 @@ public: // construction/destruction template <typename T> gba_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : gba_cart_slot_device(mconfig, tag, owner, 0) + : gba_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -94,7 +94,7 @@ public: set_fixed(false); } - gba_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + gba_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~gba_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/gba/rom.cpp b/src/devices/bus/gba/rom.cpp index 643432b8433..cff51b9c308 100644 --- a/src/devices/bus/gba/rom.cpp +++ b/src/devices/bus/gba/rom.cpp @@ -36,108 +36,108 @@ DEFINE_DEVICE_TYPE(GBA_ROM_FLASH1M_RTC, gba_rom_flash1m_rtc_device, "gba_rom_fla DEFINE_DEVICE_TYPE(GBA_ROM_3DMATRIX, gba_rom_3dmatrix_device, "gba_rom_3dmatrix", "3D Matrix Memory Mapper") -gba_rom_device::gba_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gba_rom_device::gba_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_gba_cart_interface(mconfig, *this) { } -gba_rom_device::gba_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_device::gba_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_device(mconfig, GBA_ROM_STD, tag, owner, clock) { } -gba_rom_sram_device::gba_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gba_rom_sram_device::gba_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_device(mconfig, type, tag, owner, clock) { } -gba_rom_sram_device::gba_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_sram_device::gba_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_sram_device(mconfig, GBA_ROM_SRAM, tag, owner, clock) { } -gba_rom_drilldoz_device::gba_rom_drilldoz_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_drilldoz_device::gba_rom_drilldoz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_sram_device(mconfig, GBA_ROM_DRILLDOZ, tag, owner, clock) , m_rumble(*this, "Rumble") { } -gba_rom_wariotws_device::gba_rom_wariotws_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_wariotws_device::gba_rom_wariotws_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_sram_device(mconfig, GBA_ROM_WARIOTWS, tag, owner, clock) , m_rumble(*this, "Rumble") , m_gyro_z(*this, "GYROZ") { } -gba_rom_eeprom_device::gba_rom_eeprom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gba_rom_eeprom_device::gba_rom_eeprom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_device(mconfig, type, tag, owner, clock) { } -gba_rom_eeprom_device::gba_rom_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_eeprom_device::gba_rom_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_eeprom_device(mconfig, GBA_ROM_EEPROM, tag, owner, clock) { } -gba_rom_yoshiug_device::gba_rom_yoshiug_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_yoshiug_device::gba_rom_yoshiug_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_eeprom_device(mconfig, GBA_ROM_YOSHIUG, tag, owner, clock) , m_tilt_x(*this, "TILTX") , m_tilt_y(*this, "TILTY") { } -gba_rom_eeprom64_device::gba_rom_eeprom64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gba_rom_eeprom64_device::gba_rom_eeprom64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_device(mconfig, type, tag, owner, clock) { } -gba_rom_eeprom64_device::gba_rom_eeprom64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_eeprom64_device::gba_rom_eeprom64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_eeprom64_device(mconfig, GBA_ROM_EEPROM64, tag, owner, clock) { } -gba_rom_boktai_device::gba_rom_boktai_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_boktai_device::gba_rom_boktai_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_eeprom64_device(mconfig, GBA_ROM_BOKTAI, tag, owner, clock) , m_sensor(*this, "LIGHTSENSE") { } -gba_rom_flash_device::gba_rom_flash_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gba_rom_flash_device::gba_rom_flash_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_device(mconfig, type, tag, owner, clock) , m_flash_mask(0) , m_flash(*this, "flash") { } -gba_rom_flash_device::gba_rom_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_flash_device::gba_rom_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_flash_device(mconfig, GBA_ROM_FLASH, tag, owner, clock) { } -gba_rom_flash_rtc_device::gba_rom_flash_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_flash_rtc_device::gba_rom_flash_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_flash_device(mconfig, GBA_ROM_FLASH_RTC, tag, owner, clock) { } -gba_rom_flash1m_device::gba_rom_flash1m_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gba_rom_flash1m_device::gba_rom_flash1m_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_device(mconfig, type, tag, owner, clock) , m_flash_mask(0) , m_flash(*this, "flash") { } -gba_rom_flash1m_device::gba_rom_flash1m_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_flash1m_device::gba_rom_flash1m_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_flash1m_device(mconfig, GBA_ROM_FLASH1M, tag, owner, clock) { } -gba_rom_flash1m_rtc_device::gba_rom_flash1m_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_flash1m_rtc_device::gba_rom_flash1m_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_flash1m_device(mconfig, GBA_ROM_FLASH1M_RTC, tag, owner, clock) { } -gba_rom_3dmatrix_device::gba_rom_3dmatrix_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_rom_3dmatrix_device::gba_rom_3dmatrix_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gba_rom_device(mconfig, GBA_ROM_3DMATRIX, tag, owner, clock) { } diff --git a/src/devices/bus/gba/rom.h b/src/devices/bus/gba/rom.h index 3a1ac4005a1..d009f10a426 100644 --- a/src/devices/bus/gba/rom.h +++ b/src/devices/bus/gba/rom.h @@ -88,7 +88,7 @@ class gba_rom_device : public device_t, { public: // construction/destruction - gba_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint32_t read_rom(offs_t offset) override { return m_rom[offset]; } @@ -100,7 +100,7 @@ public: virtual void gpio_dev_write(uint16_t data, int gpio_dirs) { } protected: - gba_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gba_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -118,14 +118,14 @@ class gba_rom_sram_device : public gba_rom_device { public: // construction/destruction - gba_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint32_t read_ram(offs_t offset, uint32_t mem_mask = ~0) override; virtual void write_ram(offs_t offset, uint32_t data, uint32_t mem_mask = ~0) override; protected: - gba_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gba_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -135,7 +135,7 @@ class gba_rom_drilldoz_device : public gba_rom_sram_device { public: // construction/destruction - gba_rom_drilldoz_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_drilldoz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -153,7 +153,7 @@ class gba_rom_wariotws_device : public gba_rom_sram_device { public: // construction/destruction - gba_rom_wariotws_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_wariotws_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; @@ -180,14 +180,14 @@ class gba_rom_flash_device : public gba_rom_device { public: // construction/destruction - gba_rom_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint32_t read_ram(offs_t offset, uint32_t mem_mask = ~0) override; virtual void write_ram(offs_t offset, uint32_t data, uint32_t mem_mask = ~0) override; protected: - gba_rom_flash_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gba_rom_flash_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_reset() override; @@ -206,7 +206,7 @@ class gba_rom_flash_rtc_device : public gba_rom_flash_device { public: // construction/destruction - gba_rom_flash_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_flash_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual uint16_t gpio_dev_read(int gpio_dirs) override; @@ -226,14 +226,14 @@ class gba_rom_flash1m_device : public gba_rom_device { public: // construction/destruction - gba_rom_flash1m_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_flash1m_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint32_t read_ram(offs_t offset, uint32_t mem_mask = ~0) override; virtual void write_ram(offs_t offset, uint32_t data, uint32_t mem_mask = ~0) override; protected: - gba_rom_flash1m_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gba_rom_flash1m_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_reset() override; @@ -252,7 +252,7 @@ class gba_rom_flash1m_rtc_device : public gba_rom_flash1m_device { public: // construction/destruction - gba_rom_flash1m_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_flash1m_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual uint16_t gpio_dev_read(int gpio_dirs) override; @@ -272,14 +272,14 @@ class gba_rom_eeprom_device : public gba_rom_device { public: // construction/destruction - gba_rom_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint32_t read_ram(offs_t offset, uint32_t mem_mask = ~0) override; virtual void write_ram(offs_t offset, uint32_t data, uint32_t mem_mask = ~0) override; protected: - gba_rom_eeprom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gba_rom_eeprom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -295,7 +295,7 @@ class gba_rom_yoshiug_device : public gba_rom_eeprom_device { public: // construction/destruction - gba_rom_yoshiug_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_yoshiug_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; @@ -322,14 +322,14 @@ class gba_rom_eeprom64_device : public gba_rom_device { public: // construction/destruction - gba_rom_eeprom64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_eeprom64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint32_t read_ram(offs_t offset, uint32_t mem_mask = ~0) override; virtual void write_ram(offs_t offset, uint32_t data, uint32_t mem_mask = ~0) override; protected: - gba_rom_eeprom64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gba_rom_eeprom64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -344,7 +344,7 @@ class gba_rom_boktai_device : public gba_rom_eeprom64_device { public: // construction/destruction - gba_rom_boktai_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_boktai_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; @@ -369,7 +369,7 @@ class gba_rom_3dmatrix_device : public gba_rom_device { public: // construction/destruction - gba_rom_3dmatrix_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_rom_3dmatrix_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual void write_mapper(offs_t offset, uint32_t data) override; diff --git a/src/devices/bus/generic/ram.cpp b/src/devices/bus/generic/ram.cpp index 1c9a63d7306..ee71561e5d1 100644 --- a/src/devices/bus/generic/ram.cpp +++ b/src/devices/bus/generic/ram.cpp @@ -34,14 +34,14 @@ DEFINE_DEVICE_TYPE(GENERIC_RAM_64K_LINEAR, generic_ram_64k_linear_device, "ge DEFINE_DEVICE_TYPE(GENERIC_RAM_128K_LINEAR, generic_ram_128k_linear_device, "generic_ram128l", "Generic RAM 128K (linear mapping)") -generic_ram_plain_device::generic_ram_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t size) +generic_ram_plain_device::generic_ram_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t size) : device_t(mconfig, type, tag, owner, clock) , device_generic_cart_interface(mconfig, *this) , m_size(size) { } -generic_ram_linear_device::generic_ram_linear_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t size) +generic_ram_linear_device::generic_ram_linear_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t size) : device_t(mconfig, type, tag, owner, clock) , device_generic_cart_interface(mconfig, *this) , m_size(size) @@ -49,32 +49,32 @@ generic_ram_linear_device::generic_ram_linear_device(const machine_config &mconf } -generic_ram_32k_plain_device::generic_ram_32k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +generic_ram_32k_plain_device::generic_ram_32k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_ram_plain_device(mconfig, GENERIC_RAM_32K_PLAIN, tag, owner, clock, 0x8000) { } -generic_ram_64k_plain_device::generic_ram_64k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +generic_ram_64k_plain_device::generic_ram_64k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_ram_plain_device(mconfig, GENERIC_RAM_64K_PLAIN, tag, owner, clock, 0x10000) { } -generic_ram_128k_plain_device::generic_ram_128k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +generic_ram_128k_plain_device::generic_ram_128k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_ram_plain_device(mconfig, GENERIC_RAM_128K_PLAIN, tag, owner, clock, 0x20000) { } -generic_ram_32k_linear_device::generic_ram_32k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +generic_ram_32k_linear_device::generic_ram_32k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_ram_linear_device(mconfig, GENERIC_RAM_32K_LINEAR, tag, owner, clock, 0x8000) { } -generic_ram_64k_linear_device::generic_ram_64k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +generic_ram_64k_linear_device::generic_ram_64k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_ram_linear_device(mconfig, GENERIC_RAM_64K_LINEAR, tag, owner, clock, 0x10000) { } -generic_ram_128k_linear_device::generic_ram_128k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +generic_ram_128k_linear_device::generic_ram_128k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_ram_linear_device(mconfig, GENERIC_RAM_128K_LINEAR, tag, owner, clock, 0x20000) { } diff --git a/src/devices/bus/generic/ram.h b/src/devices/bus/generic/ram.h index 5cd8c8092b0..04dd4281528 100644 --- a/src/devices/bus/generic/ram.h +++ b/src/devices/bus/generic/ram.h @@ -19,7 +19,7 @@ public: protected: // construction/destruction - generic_ram_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t size); + generic_ram_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t size); // device-level overrides virtual void device_start() override; @@ -40,7 +40,7 @@ public: protected: // construction/destruction - generic_ram_linear_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t size); + generic_ram_linear_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t size); // device-level overrides virtual void device_start() override; @@ -56,21 +56,21 @@ class generic_ram_32k_plain_device : public generic_ram_plain_device { public: // construction/destruction - generic_ram_32k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_ram_32k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class generic_ram_64k_plain_device : public generic_ram_plain_device { public: // construction/destruction - generic_ram_64k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_ram_64k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class generic_ram_128k_plain_device : public generic_ram_plain_device { public: // construction/destruction - generic_ram_128k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_ram_128k_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -80,21 +80,21 @@ class generic_ram_32k_linear_device : public generic_ram_linear_device { public: // construction/destruction - generic_ram_32k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_ram_32k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class generic_ram_64k_linear_device : public generic_ram_linear_device { public: // construction/destruction - generic_ram_64k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_ram_64k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class generic_ram_128k_linear_device : public generic_ram_linear_device { public: // construction/destruction - generic_ram_128k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_ram_128k_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/generic/rom.cpp b/src/devices/bus/generic/rom.cpp index e52854d5b64..eec2cb35f5a 100644 --- a/src/devices/bus/generic/rom.cpp +++ b/src/devices/bus/generic/rom.cpp @@ -31,27 +31,27 @@ DEFINE_DEVICE_TYPE(GENERIC_ROM_LINEAR, generic_rom_linear_device, "generic_r DEFINE_DEVICE_TYPE(GENERIC_ROMRAM_PLAIN, generic_romram_plain_device, "generic_romram_plain", "Generic ROM + RAM (plain mapping)") -generic_rom_device::generic_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +generic_rom_device::generic_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_generic_cart_interface(mconfig, *this) { } -generic_rom_plain_device::generic_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +generic_rom_plain_device::generic_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : generic_rom_device(mconfig, type, tag, owner, clock) { } -generic_rom_plain_device::generic_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +generic_rom_plain_device::generic_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_rom_plain_device(mconfig, GENERIC_ROM_PLAIN, tag, owner, clock) { } -generic_rom_linear_device::generic_rom_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +generic_rom_linear_device::generic_rom_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_rom_device(mconfig, GENERIC_ROM_LINEAR, tag, owner, clock) { } -generic_romram_plain_device::generic_romram_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +generic_romram_plain_device::generic_romram_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_rom_plain_device(mconfig, GENERIC_ROMRAM_PLAIN, tag, owner, clock) { } diff --git a/src/devices/bus/generic/rom.h b/src/devices/bus/generic/rom.h index 6c5df5d4bf4..c3627320298 100644 --- a/src/devices/bus/generic/rom.h +++ b/src/devices/bus/generic/rom.h @@ -14,7 +14,7 @@ class generic_rom_device : public device_t, public device_generic_cart_interface { protected: // construction/destruction - generic_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + generic_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -27,7 +27,7 @@ class generic_rom_plain_device : public generic_rom_device { public: // construction/destruction - generic_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; @@ -35,7 +35,7 @@ public: virtual uint32_t read32_rom(offs_t offset, uint32_t mem_mask) override; protected: - generic_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + generic_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -45,7 +45,7 @@ class generic_romram_plain_device : public generic_rom_plain_device { public: // construction/destruction - generic_romram_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_romram_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_ram(offs_t offset) override; @@ -59,7 +59,7 @@ class generic_rom_linear_device : public generic_rom_device { public: // construction/destruction - generic_rom_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_rom_linear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; diff --git a/src/devices/bus/generic/slot.cpp b/src/devices/bus/generic/slot.cpp index 8827706e657..356b45cf11d 100644 --- a/src/devices/bus/generic/slot.cpp +++ b/src/devices/bus/generic/slot.cpp @@ -119,7 +119,7 @@ void device_generic_cart_interface::ram_alloc(u32 size) // generic_slot_device //************************************************************************** -generic_slot_device::generic_slot_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) : +generic_slot_device::generic_slot_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_rom_image_interface(mconfig, *this), device_single_card_slot_interface<device_generic_cart_interface>(mconfig, *this), @@ -134,12 +134,12 @@ generic_slot_device::generic_slot_device(machine_config const &mconfig, device_t { } -generic_socket_device::generic_socket_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +generic_socket_device::generic_socket_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_slot_device(mconfig, GENERIC_SOCKET, tag, owner, clock) { } -generic_cartslot_device::generic_cartslot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +generic_cartslot_device::generic_cartslot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_slot_device(mconfig, GENERIC_CARTSLOT, tag, owner, clock) { } diff --git a/src/devices/bus/generic/slot.h b/src/devices/bus/generic/slot.h index c6f506a03bf..f15e23ce68a 100644 --- a/src/devices/bus/generic/slot.h +++ b/src/devices/bus/generic/slot.h @@ -196,7 +196,7 @@ public: void save_ram() { if (m_cart && m_cart->get_ram_size()) m_cart->save_ram(); } protected: - generic_slot_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + generic_slot_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override ATTR_COLD; @@ -216,7 +216,7 @@ class generic_socket_device : public generic_slot_device public: template <typename T> generic_socket_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *intf, char const *exts = nullptr) - : generic_socket_device(mconfig, tag, owner, u32(0)) + : generic_socket_device(mconfig, tag, owner) { opts(*this); set_fixed(false); @@ -225,7 +225,7 @@ public: set_extensions(exts); } - generic_socket_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + generic_socket_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual const char *image_type_name() const noexcept override { return "romimage"; } virtual const char *image_brief_type_name() const noexcept override { return "rom"; } @@ -236,7 +236,7 @@ class generic_cartslot_device : public generic_slot_device public: template <typename T> generic_cartslot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *intf, char const *exts = nullptr) - : generic_cartslot_device(mconfig, tag, owner, u32(0)) + : generic_cartslot_device(mconfig, tag, owner) { opts(*this); set_fixed(false); @@ -245,7 +245,7 @@ public: set_extensions(exts); } - generic_cartslot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + generic_cartslot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual const char *image_type_name() const noexcept override { return "cartridge"; } virtual const char *image_brief_type_name() const noexcept override { return "cart"; } diff --git a/src/devices/bus/gio64/gio64.cpp b/src/devices/bus/gio64/gio64.cpp index 589e2fdf6d7..e62f774f4d3 100644 --- a/src/devices/bus/gio64/gio64.cpp +++ b/src/devices/bus/gio64/gio64.cpp @@ -21,7 +21,7 @@ void gio64_cards(device_slot_interface &device) DEFINE_DEVICE_TYPE(GIO64_SLOT, gio64_slot_device, "gio64_slot", "SGI GIO64 Slot") -gio64_slot_device::gio64_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, slot_type_t slot_type) +gio64_slot_device::gio64_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, slot_type_t slot_type) : device_t(mconfig, GIO64_SLOT, tag, owner, clock) , device_slot_interface(mconfig, *this) , m_gio64(*this, finder_base::DUMMY_TAG) @@ -60,12 +60,12 @@ device_memory_interface::space_config_vector gio64_device::memory_space_config() }; } -gio64_device::gio64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gio64_device::gio64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gio64_device(mconfig, GIO64, tag, owner, clock) { } -gio64_device::gio64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gio64_device::gio64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_space_config("gio64", ENDIANNESS_BIG, 64, 32, 0) diff --git a/src/devices/bus/gio64/gio64.h b/src/devices/bus/gio64/gio64.h index df99dc70dd9..109fbd6ba0a 100644 --- a/src/devices/bus/gio64/gio64.h +++ b/src/devices/bus/gio64/gio64.h @@ -26,7 +26,7 @@ public: // construction/destruction template <typename T, typename U> gio64_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&gio64_tag, slot_type_t slot_type, U &&opts, const char *dflt) - : gio64_slot_device(mconfig, tag, owner, (uint32_t)0, slot_type) + : gio64_slot_device(mconfig, tag, owner, slot_type) { option_reset(); opts(*this); @@ -34,7 +34,7 @@ public: set_fixed(false); m_gio64.set_tag(std::forward<T>(gio64_tag)); } - gio64_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, slot_type_t slot_type = GIO64_SLOT_EXP0); + gio64_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, slot_type_t slot_type = GIO64_SLOT_EXP0); protected: // device-level overrides @@ -80,11 +80,11 @@ public: // construction/destruction template <typename T> gio64_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag) - : gio64_device(mconfig, tag, owner, (uint32_t)0) + : gio64_device(mconfig, tag, owner) { } - gio64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gio64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration template <int N> auto interrupt_cb() { return m_interrupt_cb[N].bind(); } @@ -113,7 +113,7 @@ public: void write(offs_t offset, u64 data, u64 mem_mask); protected: - gio64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gio64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; diff --git a/src/devices/bus/gio64/newport.cpp b/src/devices/bus/gio64/newport.cpp index ab796ba3645..b30e94c7d74 100644 --- a/src/devices/bus/gio64/newport.cpp +++ b/src/devices/bus/gio64/newport.cpp @@ -63,7 +63,7 @@ DEFINE_DEVICE_TYPE(GIO64_XL24, gio64_xl24_device, "gio64_xl24", "SGI 24-bit XL b * *************************************/ -xmap9_device::xmap9_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +xmap9_device::xmap9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, XMAP9, tag, owner, clock) { } @@ -215,7 +215,7 @@ void xmap9_device::write(uint32_t offset, uint32_t data) * *************************************/ -cmap_device::cmap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cmap_device::cmap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CMAP, tag, owner, clock) , device_palette_interface(mconfig, *this) { @@ -297,7 +297,7 @@ uint32_t cmap_device::read(uint32_t offset) /*static*/ const size_t vc2_device::RAM_SIZE = 0x8000; -vc2_device::vc2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vc2_device::vc2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VC2, tag, owner, clock) , m_vert_int(*this) , m_screen_timing_changed(*this) @@ -836,7 +836,7 @@ WRITE_LINE_MEMBER(vc2_device::vblank_w) /*static*/ const size_t rb2_device::BUFFER_SIZE = (1280 + 64) * (1024 + 64); -rb2_device::rb2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rb2_device::rb2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RB2, tag, owner, clock) { } @@ -1079,7 +1079,7 @@ void rb2_device::store_pixel(uint32_t value) /*static*/ const uint32_t newport_base_device::s_host_shifts[4] = { 8, 8, 16, 32 }; -newport_base_device::newport_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +newport_base_device::newport_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_gio64_card_interface(mconfig, *this) , m_screen(*this, "screen") @@ -1095,12 +1095,12 @@ newport_base_device::newport_base_device(const machine_config &mconfig, device_t { } -gio64_xl8_device::gio64_xl8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gio64_xl8_device::gio64_xl8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : newport_base_device(mconfig, GIO64_XL8, tag, owner, clock) { } -gio64_xl24_device::gio64_xl24_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gio64_xl24_device::gio64_xl24_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : newport_base_device(mconfig, GIO64_XL24, tag, owner, clock) { } @@ -4430,7 +4430,7 @@ void newport_base_device::rex3_w(offs_t offset, uint64_t data, uint64_t mem_mask void newport_base_device::device_add_mconfig(machine_config &config) { - VC2(config, m_vc2, 0); + VC2(config, m_vc2); m_vc2->vert_int().set(FUNC(newport_base_device::vrint_w)); m_vc2->screen_timing_changed().set(FUNC(newport_base_device::update_screen_size)); diff --git a/src/devices/bus/gio64/newport.h b/src/devices/bus/gio64/newport.h index 00a6e36e22d..4423ef64454 100644 --- a/src/devices/bus/gio64/newport.h +++ b/src/devices/bus/gio64/newport.h @@ -28,13 +28,13 @@ class xmap9_device : public device_t { public: - xmap9_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t revision) + xmap9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t revision) : xmap9_device(mconfig, tag, owner, clock) { set_revision(revision); } - xmap9_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xmap9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t read(uint32_t offset); void write(uint32_t offset, uint32_t data); @@ -79,13 +79,13 @@ class cmap_device : public device_t , public device_palette_interface { public: - cmap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t revision) + cmap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t revision) : cmap_device(mconfig, tag, owner, clock) { set_revision(revision); } - cmap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cmap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t read(uint32_t offset); void write(uint32_t offset, uint32_t data); @@ -125,7 +125,7 @@ DECLARE_DEVICE_TYPE(CMAP, cmap_device) class vc2_device : public device_t { public: - vc2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vc2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t read(uint32_t offset); void write(uint32_t offset, uint32_t data, uint32_t mem_mask); @@ -221,13 +221,13 @@ DECLARE_DEVICE_TYPE(VC2, vc2_device) class rb2_device : public device_t { public: - rb2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t global_mask) + rb2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t global_mask) : rb2_device(mconfig, tag, owner, clock) { set_global_mask(global_mask); } - rb2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rb2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Getters const uint32_t *rgbci(int y) const { return &m_rgbci[1344 * y]; } @@ -290,7 +290,7 @@ class newport_base_device : public device_t , public device_gio64_card_interface { public: - newport_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + newport_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); uint64_t rex3_r(offs_t offset, uint64_t mem_mask = ~0); void rex3_w(offs_t offset, uint64_t data, uint64_t mem_mask = ~0); @@ -528,7 +528,7 @@ protected: class gio64_xl8_device : public newport_base_device { public: - gio64_xl8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0U); + gio64_xl8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -537,7 +537,7 @@ protected: class gio64_xl24_device : public newport_base_device { public: - gio64_xl24_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0U); + gio64_xl24_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/hexbus/hexbus.cpp b/src/devices/bus/hexbus/hexbus.cpp index 40189262457..ca6ff20250e 100644 --- a/src/devices/bus/hexbus/hexbus.cpp +++ b/src/devices/bus/hexbus/hexbus.cpp @@ -168,7 +168,7 @@ device_hexbus_interface::device_hexbus_interface(const machine_config &mconfig, } -hexbus_device::hexbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +hexbus_device::hexbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HEXBUS, tag, owner, clock), device_single_card_slot_interface<device_hexbus_interface>(mconfig, *this), m_next_dev(nullptr), @@ -221,7 +221,7 @@ uint8_t hexbus_device::read(int dir) // ------------------------------------------------------------------------ -hexbus_chained_device::hexbus_chained_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock): +hexbus_chained_device::hexbus_chained_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, type, tag, owner, clock), device_hexbus_interface(mconfig, *this), m_hexbus_outbound(nullptr), diff --git a/src/devices/bus/hexbus/hexbus.h b/src/devices/bus/hexbus/hexbus.h index 1d225c55749..3b920d67afd 100644 --- a/src/devices/bus/hexbus/hexbus.h +++ b/src/devices/bus/hexbus/hexbus.h @@ -56,7 +56,7 @@ class hexbus_chained_device : public device_t, public device_hexbus_interface friend class hexbus_device; protected: - hexbus_chained_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + hexbus_chained_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void set_outbound_hexbus(hexbus_device *outbound) { m_hexbus_outbound = outbound; } @@ -142,7 +142,7 @@ class hexbus_device : public device_t, public device_single_card_slot_interface< { public: template <typename U> - hexbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, U &&opts, const char *dflt) + hexbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, U &&opts, const char *dflt) : hexbus_device(mconfig, tag, owner, clock) { option_reset(); @@ -151,7 +151,7 @@ public: set_fixed(false); } - hexbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hexbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Used to establish the reverse link (inbound) void set_chain_element(hexbus_chained_device* chain) { m_chain_element = chain; } diff --git a/src/devices/bus/hexbus/hx5102.cpp b/src/devices/bus/hexbus/hx5102.cpp index 740b5f93f4c..f80c0b9a4ab 100644 --- a/src/devices/bus/hexbus/hx5102.cpp +++ b/src/devices/bus/hexbus/hx5102.cpp @@ -126,7 +126,7 @@ void hx5102_device::crumap(address_map &map) map(0x17f0, 0x17ff).w(m_crulatch[1], FUNC(ls259_device::write_d0)); } -hx5102_device::hx5102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +hx5102_device::hx5102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): hexbus_chained_device(mconfig, HX5102, tag, owner, clock), m_flopcpu(*this, TMS9995_TAG), m_ready_old(CLEAR_LINE), @@ -663,7 +663,7 @@ INPUT_PORTS_END void hx5102_device::device_add_mconfig(machine_config& config) { // Hexbus controller - IBC(config, m_hexbus_ctrl, 0); + IBC(config, m_hexbus_ctrl); m_hexbus_ctrl->hexbus_cb().set(FUNC(hx5102_device::hexbus_out)); m_hexbus_ctrl->hsklatch_cb().set(FUNC(hx5102_device::hsklatch_out)); @@ -722,7 +722,7 @@ void hx5102_device::device_add_mconfig(machine_config& config) m_speedmf->out_cb().set(FUNC(hx5102_device::mspeed_w)); // READY flipflop - TTL7474(config, m_readyff, 0); + TTL7474(config, m_readyff); m_readyff->comp_output_cb().set(FUNC(hx5102_device::board_ready)); // RAM diff --git a/src/devices/bus/hexbus/hx5102.h b/src/devices/bus/hexbus/hx5102.h index 15d717bd028..b225e669c5f 100644 --- a/src/devices/bus/hexbus/hx5102.h +++ b/src/devices/bus/hexbus/hx5102.h @@ -33,7 +33,7 @@ namespace bus::hexbus { class hx5102_device : public hexbus_chained_device { public: - hx5102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hx5102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/hexbus/tp0370.cpp b/src/devices/bus/hexbus/tp0370.cpp index e4d1ac50863..2677f1f74db 100644 --- a/src/devices/bus/hexbus/tp0370.cpp +++ b/src/devices/bus/hexbus/tp0370.cpp @@ -132,7 +132,7 @@ DEFINE_DEVICE_TYPE(IBC, bus::hexbus::ibc_device, "hexbus_ibc", "Intelligent Pe namespace bus::hexbus { -ibc_device::ibc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ibc_device::ibc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IBC, tag, owner, clock), m_int(*this), m_hexout(*this), diff --git a/src/devices/bus/hexbus/tp0370.h b/src/devices/bus/hexbus/tp0370.h index 9aafc27804a..81302099c19 100644 --- a/src/devices/bus/hexbus/tp0370.h +++ b/src/devices/bus/hexbus/tp0370.h @@ -21,7 +21,7 @@ namespace bus::hexbus { class ibc_device : public device_t { public: - ibc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ibc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void device_start() override; void device_reset() override; diff --git a/src/devices/bus/hp80_io/82900.cpp b/src/devices/bus/hp80_io/82900.cpp index 72b9c08c092..b8b2a5ac3fa 100644 --- a/src/devices/bus/hp80_io/82900.cpp +++ b/src/devices/bus/hp80_io/82900.cpp @@ -28,7 +28,7 @@ namespace { } } -hp82900_io_card_device::hp82900_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp82900_io_card_device::hp82900_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , HP82900_IO_CARD , tag , owner , clock), device_hp80_io_interface(mconfig, *this), m_cpu(*this , "cpu"), @@ -163,7 +163,7 @@ void hp82900_io_card_device::device_add_mconfig(machine_config &config) m_cpu->set_addrmap(AS_IO , &hp82900_io_card_device::cpu_io_map); m_cpu->refresh_cb().set(FUNC(hp82900_io_card_device::z80_m1_w)); - HP_1MB5(config, m_translator, 0); + HP_1MB5(config, m_translator); m_translator->irl_handler().set(FUNC(hp82900_io_card_device::irl_w)); m_translator->halt_handler().set(FUNC(hp82900_io_card_device::halt_w)); m_translator->reset_handler().set(FUNC(hp82900_io_card_device::reset_w)); diff --git a/src/devices/bus/hp80_io/82900.h b/src/devices/bus/hp80_io/82900.h index 613783cbc3f..b233de376b6 100644 --- a/src/devices/bus/hp80_io/82900.h +++ b/src/devices/bus/hp80_io/82900.h @@ -21,7 +21,7 @@ class hp82900_io_card_device : public device_t, public device_hp80_io_interface { public: // construction/destruction - hp82900_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp82900_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp82900_io_card_device(); protected: diff --git a/src/devices/bus/hp80_io/82937.cpp b/src/devices/bus/hp80_io/82937.cpp index 24fae1d68c6..8ef6ee169e2 100644 --- a/src/devices/bus/hp80_io/82937.cpp +++ b/src/devices/bus/hp80_io/82937.cpp @@ -54,7 +54,7 @@ constexpr unsigned P1_DAV_BIT = 2; constexpr unsigned P1_NDAC_BIT = 1; constexpr unsigned P1_NRFD_BIT = 0; -hp82937_io_card_device::hp82937_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp82937_io_card_device::hp82937_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , HP82937_IO_CARD , tag , owner , clock), device_hp80_io_interface(mconfig, *this), m_cpu(*this , "cpu"), @@ -337,17 +337,17 @@ void hp82937_io_card_device::device_add_mconfig(machine_config &config) m_cpu->p2_in_cb().set(FUNC(hp82937_io_card_device::dio_r)); m_cpu->p2_out_cb().set(FUNC(hp82937_io_card_device::dio_w)); - HP_1MB5(config, m_translator, 0); + HP_1MB5(config, m_translator); m_translator->irl_handler().set(FUNC(hp82937_io_card_device::irl_w)); m_translator->halt_handler().set(FUNC(hp82937_io_card_device::halt_w)); m_translator->reset_handler().set(FUNC(hp82937_io_card_device::reset_w)); - ieee488_slot_device &ieee_dev(IEEE488_SLOT(config, "ieee_dev", 0)); + ieee488_slot_device &ieee_dev(IEEE488_SLOT(config, "ieee_dev")); hp_ieee488_devices(ieee_dev); - ieee488_slot_device &ieee_rem(IEEE488_SLOT(config, "ieee_rem", 0)); + ieee488_slot_device &ieee_rem(IEEE488_SLOT(config, "ieee_rem")); remote488_devices(ieee_rem); - IEEE488(config, m_ieee488, 0); + IEEE488(config, m_ieee488); m_ieee488->ifc_callback().set(FUNC(hp82937_io_card_device::ieee488_ctrl_w)); m_ieee488->atn_callback().set(FUNC(hp82937_io_card_device::ieee488_ctrl_w)); m_ieee488->ren_callback().set(FUNC(hp82937_io_card_device::ieee488_ctrl_w)); diff --git a/src/devices/bus/hp80_io/82937.h b/src/devices/bus/hp80_io/82937.h index 07f3dec991a..f926c4321f1 100644 --- a/src/devices/bus/hp80_io/82937.h +++ b/src/devices/bus/hp80_io/82937.h @@ -22,7 +22,7 @@ class hp82937_io_card_device : public device_t, public device_hp80_io_interface { public: // construction/destruction - hp82937_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp82937_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp82937_io_card_device(); protected: diff --git a/src/devices/bus/hp80_io/82939.cpp b/src/devices/bus/hp80_io/82939.cpp index 4649758f753..ad93da3017a 100644 --- a/src/devices/bus/hp80_io/82939.cpp +++ b/src/devices/bus/hp80_io/82939.cpp @@ -34,7 +34,7 @@ namespace { } } -hp82939_io_card_device::hp82939_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp82939_io_card_device::hp82939_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , HP82939_IO_CARD , tag , owner , clock), device_hp80_io_interface(mconfig, *this), m_cpu(*this , "cpu"), @@ -203,7 +203,7 @@ void hp82939_io_card_device::device_add_mconfig(machine_config &config) m_cpu->p1_out_cb().set(FUNC(hp82939_io_card_device::p1_w)); m_cpu->p2_in_cb().set(FUNC(hp82939_io_card_device::p2_r)); - HP_1MB5(config, m_translator, 0); + HP_1MB5(config, m_translator); m_translator->irl_handler().set(FUNC(hp82939_io_card_device::irl_w)); m_translator->halt_handler().set(FUNC(hp82939_io_card_device::halt_w)); m_translator->reset_handler().set_inputline(m_cpu , INPUT_LINE_RESET); diff --git a/src/devices/bus/hp80_io/82939.h b/src/devices/bus/hp80_io/82939.h index fb9e07dd3ec..43879059257 100644 --- a/src/devices/bus/hp80_io/82939.h +++ b/src/devices/bus/hp80_io/82939.h @@ -23,7 +23,7 @@ class hp82939_io_card_device : public device_t, public device_hp80_io_interface { public: // construction/destruction - hp82939_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp82939_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp82939_io_card_device(); protected: diff --git a/src/devices/bus/hp80_io/hp80_io.cpp b/src/devices/bus/hp80_io/hp80_io.cpp index 591435bafac..f6ed74c9da1 100644 --- a/src/devices/bus/hp80_io/hp80_io.cpp +++ b/src/devices/bus/hp80_io/hp80_io.cpp @@ -21,13 +21,17 @@ DEFINE_DEVICE_TYPE(HP80_IO_SLOT, hp80_io_slot_device, "hp80_io_slot", "HP80 I/O // +-------------------+ // |hp80_io_slot_device| // +-------------------+ -hp80_io_slot_device::hp80_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +hp80_io_slot_device::hp80_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HP80_IO_SLOT, tag, owner, clock), device_single_card_slot_interface<device_hp80_io_interface>(mconfig, *this), m_irl_cb_func(*this), m_halt_cb_func(*this), m_slot_no(0) { + option_reset(); + hp80_io_slot_devices(*this); + set_default_option(nullptr); + set_fixed(false); } hp80_io_slot_device::~hp80_io_slot_device() diff --git a/src/devices/bus/hp80_io/hp80_io.h b/src/devices/bus/hp80_io/hp80_io.h index 3963d56d29e..86f00677b58 100644 --- a/src/devices/bus/hp80_io/hp80_io.h +++ b/src/devices/bus/hp80_io/hp80_io.h @@ -36,16 +36,7 @@ class hp80_io_slot_device : public device_t, { public: // construction/destruction - hp80_io_slot_device(machine_config const &mconfig, char const *tag, device_t *owner) - : hp80_io_slot_device(mconfig, tag, owner, (uint32_t)0) - { - option_reset(); - hp80_io_slot_devices(*this); - set_default_option(nullptr); - set_fixed(false); - } - - hp80_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp80_io_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~hp80_io_slot_device(); // configuration helpers diff --git a/src/devices/bus/hp9845_io/98032.cpp b/src/devices/bus/hp9845_io/98032.cpp index ecfc92ba706..d12fe1be8fd 100644 --- a/src/devices/bus/hp9845_io/98032.cpp +++ b/src/devices/bus/hp9845_io/98032.cpp @@ -46,7 +46,7 @@ DEFINE_DEVICE_TYPE(HP98032_GPIO_LOOPBACK , hp98032_gpio_loopback_device , "hp980 // |hp98032_io_card_device| // +----------------------+ -hp98032_io_card_device::hp98032_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp98032_io_card_device::hp98032_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HP98032_IO_CARD, tag, owner, clock) , device_hp9845_io_interface(mconfig, *this) , m_gpio(*this, "gpio") @@ -347,7 +347,7 @@ void hp98032_io_card_device::latch_input_LSB() // |hp98032_gpio_slot_device| // +------------------------+ -hp98032_gpio_slot_device::hp98032_gpio_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp98032_gpio_slot_device::hp98032_gpio_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , HP98032_GPIO_SLOT , tag , owner , clock) , device_single_card_slot_interface<device_hp98032_gpio_interface>(mconfig , *this) , m_pflg_handler(*this) @@ -502,7 +502,7 @@ WRITE_LINE_MEMBER(device_hp98032_gpio_interface::eir_w) // |hp98032_gpio_loopback_device| // +----------------------------+ -hp98032_gpio_loopback_device::hp98032_gpio_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp98032_gpio_loopback_device::hp98032_gpio_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HP98032_GPIO_LOOPBACK, tag, owner, clock) , device_hp98032_gpio_interface(mconfig, *this) { diff --git a/src/devices/bus/hp9845_io/98032.h b/src/devices/bus/hp9845_io/98032.h index 059b0248ae9..1d1ab475222 100644 --- a/src/devices/bus/hp9845_io/98032.h +++ b/src/devices/bus/hp9845_io/98032.h @@ -22,7 +22,7 @@ class hp98032_io_card_device : public device_t, public device_hp9845_io_interfac { public: // construction/destruction - hp98032_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp98032_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp98032_io_card_device(); protected: @@ -67,7 +67,7 @@ class hp98032_gpio_slot_device : public device_t, { public: // construction/destruction - hp98032_gpio_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp98032_gpio_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp98032_gpio_slot_device(); // Bits in jumper configuration @@ -163,7 +163,7 @@ class hp98032_gpio_loopback_device : public device_t, public device_hp98032_gpio { public: // construction/destruction - hp98032_gpio_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp98032_gpio_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp98032_gpio_loopback_device(); virtual uint16_t get_jumpers() const override; diff --git a/src/devices/bus/hp9845_io/98034.cpp b/src/devices/bus/hp9845_io/98034.cpp index 988d8e47705..b35eaac9659 100644 --- a/src/devices/bus/hp9845_io/98034.cpp +++ b/src/devices/bus/hp9845_io/98034.cpp @@ -27,7 +27,7 @@ #define BIT_CLR(w , n) ((w) &= ~BIT_MASK(n)) #define BIT_SET(w , n) ((w) |= BIT_MASK(n)) -hp98034_io_card_device::hp98034_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp98034_io_card_device::hp98034_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , HP98034_IO_CARD , tag , owner , clock), device_hp9845_io_interface(mconfig, *this), m_cpu(*this , "np"), @@ -394,7 +394,7 @@ void hp98034_io_card_device::device_add_mconfig(machine_config &config) // Clock for NP is generated by a RC oscillator. Manual says its typical frequency // is around 2 MHz. A quick simulation of the oscillator gives the following data though: // 2.5 MHz frequency, 33% duty cycle. - HP_NANOPROCESSOR(config, m_cpu, 2500000); + HP_NANOPROCESSOR(config, m_cpu, XTAL::u(2500000)); m_cpu->set_addrmap(AS_PROGRAM, &hp98034_io_card_device::np_program_map); m_cpu->set_addrmap(AS_IO, &hp98034_io_card_device::np_io_map); m_cpu->dc_changed().set(FUNC(hp98034_io_card_device::dc_w)); diff --git a/src/devices/bus/hp9845_io/98034.h b/src/devices/bus/hp9845_io/98034.h index c8cb5ff8765..cadffcc1bda 100644 --- a/src/devices/bus/hp9845_io/98034.h +++ b/src/devices/bus/hp9845_io/98034.h @@ -21,7 +21,7 @@ class hp98034_io_card_device : public device_t, public device_hp9845_io_interfac { public: // construction/destruction - hp98034_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp98034_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp98034_io_card_device(); protected: diff --git a/src/devices/bus/hp9845_io/98035.cpp b/src/devices/bus/hp9845_io/98035.cpp index 79017edd4c2..0e19d5e0c71 100644 --- a/src/devices/bus/hp9845_io/98035.cpp +++ b/src/devices/bus/hp9845_io/98035.cpp @@ -142,7 +142,7 @@ static const uint8_t dec_2_seven_segs[] = { 0xc8 // 9 }; -hp98035_io_card_device::hp98035_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp98035_io_card_device::hp98035_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , HP98035_IO_CARD , tag , owner , clock), device_hp9845_io_interface(mconfig, *this), device_rtc_interface(mconfig , *this), diff --git a/src/devices/bus/hp9845_io/98035.h b/src/devices/bus/hp9845_io/98035.h index f92e1734047..2833661d74b 100644 --- a/src/devices/bus/hp9845_io/98035.h +++ b/src/devices/bus/hp9845_io/98035.h @@ -21,7 +21,7 @@ class hp98035_io_card_device : public device_t, public device_hp9845_io_interfac { public: // construction/destruction - hp98035_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp98035_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp98035_io_card_device(); protected: diff --git a/src/devices/bus/hp9845_io/98036.cpp b/src/devices/bus/hp9845_io/98036.cpp index 6f328062152..c67c406f157 100644 --- a/src/devices/bus/hp9845_io/98036.cpp +++ b/src/devices/bus/hp9845_io/98036.cpp @@ -34,7 +34,7 @@ namespace { // device type definitions DEFINE_DEVICE_TYPE(HP98036_IO_CARD, hp98036_io_card_device, "hp98036", "HP98036 card") -hp98036_io_card_device::hp98036_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp98036_io_card_device::hp98036_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HP98036_IO_CARD, tag, owner, clock) , device_hp9845_io_interface(mconfig, *this) , m_uart(*this, "uart") @@ -159,7 +159,7 @@ void hp98036_io_card_device::reg_w(address_space &space, offs_t offset, uint16_t void hp98036_io_card_device::device_add_mconfig(machine_config &config) { - I8251(config, m_uart, 0); + I8251(config, m_uart); m_uart->txd_handler().set(FUNC(hp98036_io_card_device::txd_w)); m_uart->dtr_handler().set(FUNC(hp98036_io_card_device::dtr_w)); m_uart->rts_handler().set(FUNC(hp98036_io_card_device::rts_w)); diff --git a/src/devices/bus/hp9845_io/98036.h b/src/devices/bus/hp9845_io/98036.h index c1ee6b351bd..4f97e622fee 100644 --- a/src/devices/bus/hp9845_io/98036.h +++ b/src/devices/bus/hp9845_io/98036.h @@ -22,7 +22,7 @@ class hp98036_io_card_device : public device_t, public device_hp9845_io_interfac { public: // construction/destruction - hp98036_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp98036_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp98036_io_card_device(); virtual uint16_t reg_r(address_space &space, offs_t offset) override; diff --git a/src/devices/bus/hp9845_io/98046.cpp b/src/devices/bus/hp9845_io/98046.cpp index 8b7e601f0f4..a76dd77c5d1 100644 --- a/src/devices/bus/hp9845_io/98046.cpp +++ b/src/devices/bus/hp9845_io/98046.cpp @@ -58,7 +58,7 @@ namespace { // device type definition DEFINE_DEVICE_TYPE(HP98046_IO_CARD, hp98046_io_card_device , "hp98046" , "HP98046 card") -hp98046_io_card_device::hp98046_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp98046_io_card_device::hp98046_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HP98046_IO_CARD, tag, owner, clock) , device_hp9845_io_interface(mconfig, *this) , m_cpu(*this, "cpu") diff --git a/src/devices/bus/hp9845_io/98046.h b/src/devices/bus/hp9845_io/98046.h index 90debbb8c03..d10767a9017 100644 --- a/src/devices/bus/hp9845_io/98046.h +++ b/src/devices/bus/hp9845_io/98046.h @@ -23,7 +23,7 @@ class hp98046_io_card_device : public device_t, public device_hp9845_io_interfac { public: // construction/destruction - hp98046_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp98046_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp98046_io_card_device(); virtual uint16_t reg_r(address_space &space, offs_t offset) override; diff --git a/src/devices/bus/hp9845_io/hp9845_io.cpp b/src/devices/bus/hp9845_io/hp9845_io.cpp index bf304622f24..2d3f2a45aa6 100644 --- a/src/devices/bus/hp9845_io/hp9845_io.cpp +++ b/src/devices/bus/hp9845_io/hp9845_io.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(HP9845_IO_SLOT, hp9845_io_slot_device, "hp98x5_io_slot", "HP9 // +---------------------+ // |hp9845_io_slot_device| // +---------------------+ -hp9845_io_slot_device::hp9845_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +hp9845_io_slot_device::hp9845_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HP9845_IO_SLOT, tag, owner, clock), device_single_card_slot_interface<device_hp9845_io_interface>(mconfig, *this), m_irq_cb_func(*this), diff --git a/src/devices/bus/hp9845_io/hp9845_io.h b/src/devices/bus/hp9845_io/hp9845_io.h index bebe12c3408..0bb7aed5d55 100644 --- a/src/devices/bus/hp9845_io/hp9845_io.h +++ b/src/devices/bus/hp9845_io/hp9845_io.h @@ -38,7 +38,7 @@ class hp9845_io_slot_device : public device_t, { public: // construction/destruction - hp9845_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp9845_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~hp9845_io_slot_device(); // Callback setups diff --git a/src/devices/bus/hp9845_io/hp9885.cpp b/src/devices/bus/hp9845_io/hp9885.cpp index 1fadbc54679..07e82d4800d 100644 --- a/src/devices/bus/hp9845_io/hp9885.cpp +++ b/src/devices/bus/hp9845_io/hp9885.cpp @@ -224,7 +224,7 @@ enum : unsigned { ERR_HW_FAILURE = 8 }; -hp9885_device::hp9885_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp9885_device::hp9885_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , HP9885 , tag , owner , clock) , device_hp98032_gpio_interface(mconfig, *this) , m_drive_connector{*this , "floppy"} diff --git a/src/devices/bus/hp9845_io/hp9885.h b/src/devices/bus/hp9845_io/hp9885.h index 1c9af5c3066..99ca3fcd91f 100644 --- a/src/devices/bus/hp9845_io/hp9885.h +++ b/src/devices/bus/hp9845_io/hp9885.h @@ -20,7 +20,7 @@ class hp9885_device : public device_t, public device_hp98032_gpio_interface { public: - hp9885_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp9885_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp9885_device(); // hp98032_gpio_card_device overrides diff --git a/src/devices/bus/hp_dio/hp98265a.cpp b/src/devices/bus/hp_dio/hp98265a.cpp index 5ca9d128b53..7b1d5c0f234 100644 --- a/src/devices/bus/hp_dio/hp98265a.cpp +++ b/src/devices/bus/hp_dio/hp98265a.cpp @@ -32,34 +32,34 @@ void dio16_98265a_device::mb87030_scsi_adapter(device_t *device) void dio16_98265a_device::device_add_mconfig(machine_config &config) { - NSCSI_BUS(config, m_scsibus, 0); - nscsi_connector &scsicon0(NSCSI_CONNECTOR(config, "scsibus:0", 0)); + NSCSI_BUS(config, m_scsibus); + nscsi_connector &scsicon0(NSCSI_CONNECTOR(config, "scsibus:0")); default_scsi_devices(scsicon0); scsicon0.set_default_option("harddisk"); - default_scsi_devices(NSCSI_CONNECTOR(config, "scsibus:1", 0)); - default_scsi_devices(NSCSI_CONNECTOR(config, "scsibus:2", 0)); - default_scsi_devices(NSCSI_CONNECTOR(config, "scsibus:3", 0)); - default_scsi_devices(NSCSI_CONNECTOR(config, "scsibus:4", 0)); + default_scsi_devices(NSCSI_CONNECTOR(config, "scsibus:1")); + default_scsi_devices(NSCSI_CONNECTOR(config, "scsibus:2")); + default_scsi_devices(NSCSI_CONNECTOR(config, "scsibus:3")); + default_scsi_devices(NSCSI_CONNECTOR(config, "scsibus:4")); - nscsi_connector &scsicon5(NSCSI_CONNECTOR(config, "scsibus:5", 0)); + nscsi_connector &scsicon5(NSCSI_CONNECTOR(config, "scsibus:5")); default_scsi_devices(scsicon5); scsicon5.set_default_option("cdrom"); - default_scsi_devices(NSCSI_CONNECTOR(config, "scsibus:6", 0)); - nscsi_connector &scsicon7(NSCSI_CONNECTOR(config, "scsibus:7", 0)); + default_scsi_devices(NSCSI_CONNECTOR(config, "scsibus:6")); + nscsi_connector &scsicon7(NSCSI_CONNECTOR(config, "scsibus:7")); scsicon7.option_add_internal("mb87030", MB87030); scsicon7.set_default_option("mb87030"); scsicon7.set_fixed(true); scsicon7.set_option_machine_config("mb87030", mb87030_scsi_adapter); } -dio16_98265a_device::dio16_98265a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio16_98265a_device::dio16_98265a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_98265a_device(mconfig, HPDIO_98265A, tag, owner, clock) { } -dio16_98265a_device::dio16_98265a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio16_98265a_device::dio16_98265a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_dio32_card_interface(mconfig, *this), m_scsibus(*this, "scsibus"), diff --git a/src/devices/bus/hp_dio/hp98265a.h b/src/devices/bus/hp_dio/hp98265a.h index 8246f9bb743..11af5fb425f 100644 --- a/src/devices/bus/hp_dio/hp98265a.h +++ b/src/devices/bus/hp_dio/hp98265a.h @@ -19,12 +19,12 @@ class dio16_98265a_device : { public: // construction/destruction - dio16_98265a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio16_98265a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void mb87030(device_t *device); protected: - dio16_98265a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio16_98265a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides diff --git a/src/devices/bus/hp_dio/hp98543.cpp b/src/devices/bus/hp_dio/hp98543.cpp index a2bfb82f5ee..ce8e97c913c 100644 --- a/src/devices/bus/hp_dio/hp98543.cpp +++ b/src/devices/bus/hp_dio/hp98543.cpp @@ -56,7 +56,7 @@ void dio16_98543_device::device_add_mconfig(machine_config &config) topcat3.set_planemask(8); topcat3.irq_out_cb().set(FUNC(dio16_98543_device::int3_w)); - NEREID(config, m_nereid, 0); + NEREID(config, m_nereid); } const tiny_rom_entry *dio16_98543_device::device_rom_region() const @@ -76,12 +76,12 @@ device_memory_interface::space_config_vector dio16_98543_device::memory_space_co }; } -dio16_98543_device::dio16_98543_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio16_98543_device::dio16_98543_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_98543_device(mconfig, HPDIO_98543, tag, owner, clock) { } -dio16_98543_device::dio16_98543_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio16_98543_device::dio16_98543_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_dio16_card_interface(mconfig, *this), device_memory_interface(mconfig, *this), diff --git a/src/devices/bus/hp_dio/hp98543.h b/src/devices/bus/hp_dio/hp98543.h index c1e86126880..3f4a5727b5a 100644 --- a/src/devices/bus/hp_dio/hp98543.h +++ b/src/devices/bus/hp_dio/hp98543.h @@ -19,7 +19,7 @@ class dio16_98543_device : public device_memory_interface { public: - dio16_98543_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio16_98543_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t rom_r(offs_t offset); void rom_w(offs_t offset, uint16_t data); @@ -36,7 +36,7 @@ public: uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); protected: - dio16_98543_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio16_98543_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/hp_dio/hp98544.cpp b/src/devices/bus/hp_dio/hp98544.cpp index 420dc93919f..f5cbf70a4d5 100644 --- a/src/devices/bus/hp_dio/hp98544.cpp +++ b/src/devices/bus/hp_dio/hp98544.cpp @@ -65,12 +65,12 @@ const tiny_rom_entry *dio16_98544_device::device_rom_region() const // dio16_98544_device - constructor //------------------------------------------------- -dio16_98544_device::dio16_98544_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio16_98544_device::dio16_98544_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_98544_device(mconfig, HPDIO_98544, tag, owner, clock) { } -dio16_98544_device::dio16_98544_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio16_98544_device::dio16_98544_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_dio16_card_interface(mconfig, *this), device_memory_interface(mconfig, *this), diff --git a/src/devices/bus/hp_dio/hp98544.h b/src/devices/bus/hp_dio/hp98544.h index a490f765c84..337a1698bd1 100644 --- a/src/devices/bus/hp_dio/hp98544.h +++ b/src/devices/bus/hp_dio/hp98544.h @@ -23,7 +23,7 @@ class dio16_98544_device : { public: // construction/destruction - dio16_98544_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio16_98544_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t rom_r(offs_t offset); void rom_w(offs_t offset, uint16_t data); @@ -31,7 +31,7 @@ public: required_device<topcat_device> m_topcat; uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); protected: - dio16_98544_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio16_98544_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/hp_dio/hp98550.cpp b/src/devices/bus/hp_dio/hp98550.cpp index 54b89418680..b5023c542a1 100644 --- a/src/devices/bus/hp_dio/hp98550.cpp +++ b/src/devices/bus/hp_dio/hp98550.cpp @@ -42,7 +42,7 @@ void dio32_98550_device::device_add_mconfig(machine_config &config) m_catseye[i]->irq_out_cb().set(FUNC(dio32_98550_device::int_w)); } - NEREID(config, m_nereid, 0); + NEREID(config, m_nereid); } const tiny_rom_entry *dio32_98550_device::device_rom_region() const @@ -63,12 +63,12 @@ device_memory_interface::space_config_vector dio32_98550_device::memory_space_co }; } -dio32_98550_device::dio32_98550_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio32_98550_device::dio32_98550_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio32_98550_device(mconfig, HPDIO_98550, tag, owner, clock) { } -dio32_98550_device::dio32_98550_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio32_98550_device::dio32_98550_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_dio16_card_interface(mconfig, *this), device_memory_interface(mconfig, *this), diff --git a/src/devices/bus/hp_dio/hp98550.h b/src/devices/bus/hp_dio/hp98550.h index eca4da5bed6..2989b357a94 100644 --- a/src/devices/bus/hp_dio/hp98550.h +++ b/src/devices/bus/hp_dio/hp98550.h @@ -19,7 +19,7 @@ class dio32_98550_device : public device_memory_interface { public: - dio32_98550_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio32_98550_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t rom_r(offs_t offset, uint16_t mem_mask = ~0); void rom_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); @@ -38,7 +38,7 @@ protected: required_device<nereid_device> m_nereid; required_device_array<catseye_device, CATSEYE_COUNT> m_catseye; - dio32_98550_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio32_98550_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/hp_dio/hp98603a.cpp b/src/devices/bus/hp_dio/hp98603a.cpp index 37458c43c36..d61c1bf7f4b 100644 --- a/src/devices/bus/hp_dio/hp98603a.cpp +++ b/src/devices/bus/hp_dio/hp98603a.cpp @@ -47,12 +47,12 @@ const tiny_rom_entry *dio16_98603a_device::device_rom_region() const return ROM_NAME(hp98603a); } -dio16_98603a_device::dio16_98603a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio16_98603a_device::dio16_98603a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_98603a_device(mconfig, HPDIO_98603A, tag, owner, clock) { } -dio16_98603a_device::dio16_98603a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio16_98603a_device::dio16_98603a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_dio16_card_interface(mconfig, *this) { diff --git a/src/devices/bus/hp_dio/hp98603a.h b/src/devices/bus/hp_dio/hp98603a.h index 15cccb7ab3d..c1908690c2e 100644 --- a/src/devices/bus/hp_dio/hp98603a.h +++ b/src/devices/bus/hp_dio/hp98603a.h @@ -16,12 +16,12 @@ class dio16_98603a_device : { public: // construction/destruction - dio16_98603a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio16_98603a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t rom_r(offs_t offset); void rom_w(offs_t offset, uint16_t data); protected: - dio16_98603a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio16_98603a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/hp_dio/hp98603b.cpp b/src/devices/bus/hp_dio/hp98603b.cpp index 6210b3b0178..6bb12726edc 100644 --- a/src/devices/bus/hp_dio/hp98603b.cpp +++ b/src/devices/bus/hp_dio/hp98603b.cpp @@ -42,12 +42,12 @@ const tiny_rom_entry *dio16_98603b_device::device_rom_region() const return ROM_NAME(hp98603b); } -dio16_98603b_device::dio16_98603b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio16_98603b_device::dio16_98603b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_98603b_device(mconfig, HPDIO_98603B, tag, owner, clock) { } -dio16_98603b_device::dio16_98603b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio16_98603b_device::dio16_98603b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_dio16_card_interface(mconfig, *this) { diff --git a/src/devices/bus/hp_dio/hp98603b.h b/src/devices/bus/hp_dio/hp98603b.h index 4f910781dba..9052f8742a5 100644 --- a/src/devices/bus/hp_dio/hp98603b.h +++ b/src/devices/bus/hp_dio/hp98603b.h @@ -16,12 +16,12 @@ class dio16_98603b_device : { public: // construction/destruction - dio16_98603b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio16_98603b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t rom_r(offs_t offset); void rom_w(offs_t offset, uint16_t data); protected: - dio16_98603b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio16_98603b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/hp_dio/hp98620.cpp b/src/devices/bus/hp_dio/hp98620.cpp index 88a8491fae8..e3f89b58fa4 100644 --- a/src/devices/bus/hp_dio/hp98620.cpp +++ b/src/devices/bus/hp_dio/hp98620.cpp @@ -17,12 +17,12 @@ DEFINE_DEVICE_TYPE(HPDIO_98620, bus::hp_dio::dio16_98620_device, "hp98620", "HP9 namespace bus::hp_dio { -dio16_98620_device::dio16_98620_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio16_98620_device::dio16_98620_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_98620_device(mconfig, HPDIO_98620, tag, owner, clock) { } -dio16_98620_device::dio16_98620_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio16_98620_device::dio16_98620_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t{mconfig, type, tag, owner, clock}, device_dio32_card_interface{mconfig, *this}, m_installed_io{false}, diff --git a/src/devices/bus/hp_dio/hp98620.h b/src/devices/bus/hp_dio/hp98620.h index d8779f0e852..83df761544f 100644 --- a/src/devices/bus/hp_dio/hp98620.h +++ b/src/devices/bus/hp_dio/hp98620.h @@ -17,10 +17,10 @@ class dio16_98620_device : { public: // construction/destruction - dio16_98620_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio16_98620_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - dio16_98620_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio16_98620_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/hp_dio/hp98643.cpp b/src/devices/bus/hp_dio/hp98643.cpp index f665303097a..2c0cdc31c0b 100644 --- a/src/devices/bus/hp_dio/hp98643.cpp +++ b/src/devices/bus/hp_dio/hp98643.cpp @@ -25,12 +25,12 @@ void dio16_98643_device::device_add_mconfig(machine_config &config) m_lance->dma_in().set(FUNC(dio16_98643_device::lance_dma_in)); } -dio16_98643_device::dio16_98643_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio16_98643_device::dio16_98643_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_98643_device(mconfig, HPDIO_98643, tag, owner, clock) { } -dio16_98643_device::dio16_98643_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio16_98643_device::dio16_98643_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_dio16_card_interface(mconfig, *this), m_lance(*this, "lance"), diff --git a/src/devices/bus/hp_dio/hp98643.h b/src/devices/bus/hp_dio/hp98643.h index c1944bb1b8f..c7f379dcad3 100644 --- a/src/devices/bus/hp_dio/hp98643.h +++ b/src/devices/bus/hp_dio/hp98643.h @@ -34,10 +34,10 @@ class dio16_98643_device : { public: // construction/destruction - dio16_98643_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio16_98643_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - dio16_98643_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio16_98643_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides diff --git a/src/devices/bus/hp_dio/hp98644.cpp b/src/devices/bus/hp_dio/hp98644.cpp index d74b8c02fea..ac77bc5a02a 100644 --- a/src/devices/bus/hp_dio/hp98644.cpp +++ b/src/devices/bus/hp_dio/hp98644.cpp @@ -49,12 +49,12 @@ void dio16_98644_device::device_add_mconfig(machine_config &config) // dio16_98644_device - constructor //------------------------------------------------- -dio16_98644_device::dio16_98644_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio16_98644_device::dio16_98644_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_98644_device(mconfig, HPDIO_98644, tag, owner, clock) { } -dio16_98644_device::dio16_98644_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio16_98644_device::dio16_98644_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_dio16_card_interface(mconfig, *this), m_uart{*this, INS8250_TAG}, diff --git a/src/devices/bus/hp_dio/hp98644.h b/src/devices/bus/hp_dio/hp98644.h index 6cd99123b92..b26a9bceae2 100644 --- a/src/devices/bus/hp_dio/hp98644.h +++ b/src/devices/bus/hp_dio/hp98644.h @@ -23,10 +23,10 @@ class dio16_98644_device : { public: // construction/destruction - dio16_98644_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio16_98644_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - dio16_98644_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio16_98644_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides diff --git a/src/devices/bus/hp_dio/hp_dio.cpp b/src/devices/bus/hp_dio/hp_dio.cpp index 647b28f83c9..74726b327e2 100644 --- a/src/devices/bus/hp_dio/hp_dio.cpp +++ b/src/devices/bus/hp_dio/hp_dio.cpp @@ -34,12 +34,12 @@ namespace bus::hp_dio { // LIVE DEVICE //************************************************************************** -dio16_slot_device::dio16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio16_slot_device::dio16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_slot_device(mconfig, DIO16_SLOT, tag, owner, clock) { } -dio16_slot_device::dio16_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio16_slot_device::dio16_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_slot_interface(mconfig, *this), m_dio(*this, finder_base::DUMMY_TAG) @@ -74,7 +74,7 @@ void dio16_slot_device::device_start() //------------------------------------------------- // dio32_slot_device - constructor //------------------------------------------------- -dio32_slot_device::dio32_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio32_slot_device::dio32_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_slot_device(mconfig, DIO32_SLOT, tag, owner, clock) { } @@ -96,12 +96,12 @@ void dio32_slot_device::device_start() // dio16_device - constructor //------------------------------------------------- -dio16_device::dio16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio16_device::dio16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_device(mconfig, DIO16, tag, owner, clock) { } -dio16_device::dio16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +dio16_device::dio16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_prgspace(*this, finder_base::DUMMY_TAG, -1), m_bus_index{0}, @@ -321,7 +321,7 @@ void device_dio16_card_interface::interface_pre_start() // DIO32 DEVICE //************************************************************************** -dio32_device::dio32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dio32_device::dio32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dio16_device(mconfig, DIO32, tag, owner, clock) { } diff --git a/src/devices/bus/hp_dio/hp_dio.h b/src/devices/bus/hp_dio/hp_dio.h index c3ad5e0d178..3b5988cfee3 100644 --- a/src/devices/bus/hp_dio/hp_dio.h +++ b/src/devices/bus/hp_dio/hp_dio.h @@ -31,8 +31,8 @@ class dio16_slot_device : public device_t, public device_slot_interface public: // construction/destruction template <typename T, typename U> - dio16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&dio_tag, U &&opts, const char *dflt, bool fixed) : - dio16_slot_device(mconfig, tag, owner, clock) + dio16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&dio_tag, U &&opts, const char *dflt, bool fixed) : + dio16_slot_device(mconfig, tag, owner) { set_dio(std::forward<T>(dio_tag)); option_reset(); @@ -40,13 +40,13 @@ public: set_default_option(dflt); set_fixed(fixed); } - dio16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration template <typename T> void set_dio(T &&dio_tag) { m_dio.set_tag(std::forward<T>(dio_tag)); } protected: - dio16_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio16_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -62,7 +62,7 @@ class dio16_device : public device_t { public: // construction/destruction - dio16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration template <typename T> void set_program_space(T &&tag, int spacenum) { m_prgspace.set_tag(std::forward<T>(tag), spacenum); } @@ -128,7 +128,7 @@ public: void set_dmar(unsigned int index, unsigned int num, int state); protected: - dio16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + dio16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void install_space(int spacenum, offs_t start, offs_t end, read8_delegate rhandler, write8_delegate whandler); // device-level overrides @@ -232,8 +232,8 @@ class dio32_slot_device : public dio16_slot_device public: // construction/destruction template <typename T, typename U> - dio32_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&dio_tag, U &&opts, const char *dflt, bool fixed) : - dio32_slot_device(mconfig, tag, owner, clock) + dio32_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&dio_tag, U &&opts, const char *dflt, bool fixed) : + dio32_slot_device(mconfig, tag, owner) { set_dio(std::forward<T>(dio_tag)); option_reset(); @@ -241,7 +241,7 @@ public: set_default_option(dflt); set_fixed(fixed); } - dio32_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio32_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device-level overrides @@ -253,7 +253,7 @@ class dio32_device : public dio16_device { public: // construction/destruction - dio32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dio32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void install16_device(offs_t start, offs_t end, read16_delegate rhandler, write16_delegate whandler); diff --git a/src/devices/bus/hp_dio/human_interface.cpp b/src/devices/bus/hp_dio/human_interface.cpp index a0957977f10..fa9ba0c9af7 100644 --- a/src/devices/bus/hp_dio/human_interface.cpp +++ b/src/devices/bus/hp_dio/human_interface.cpp @@ -39,7 +39,7 @@ void human_interface_device::device_add_mconfig(machine_config &config) HP_HIL_SLOT(config, "hil2", m_mlc, hp_hil_devices, "hp_46060b"); SPEAKER(config, "mono").front_center(); - sn76494_device &sound(SN76494(config, "sn76494", 333333)); + sn76494_device &sound(SN76494(config, "sn76494", XTAL::u(333333))); sound.add_route(ALL_OUTPUTS, "mono", 0.75); msm58321_device &rtc(MSM58321(config, "rtc", 32.768_kHz_XTAL)); @@ -63,7 +63,7 @@ void human_interface_device::device_add_mconfig(machine_config &config) gpib.int_write_cb().set(FUNC(human_interface_device::gpib_irq)); gpib.accrq_write_cb().set(FUNC(human_interface_device::gpib_dreq)); - ieee488_device &ieee488(IEEE488(config, IEEE488_TAG, 0)); + ieee488_device &ieee488(IEEE488(config, IEEE488_TAG)); ieee488.eoi_callback().set(m_tms9914, FUNC(tms9914_device::eoi_w)); ieee488.dav_callback().set(m_tms9914, FUNC(tms9914_device::dav_w)); ieee488.nrfd_callback().set(m_tms9914, FUNC(tms9914_device::nrfd_w)); @@ -74,7 +74,7 @@ void human_interface_device::device_add_mconfig(machine_config &config) ieee488.ren_callback().set(m_tms9914, FUNC(tms9914_device::ren_w)); ieee488.dio_callback().set(FUNC(human_interface_device::ieee488_dio_w)); - ieee488_slot_device &slot0(IEEE488_SLOT(config, "ieee0", 0)); + ieee488_slot_device &slot0(IEEE488_SLOT(config, "ieee0")); hp_ieee488_devices(slot0); slot0.set_default_option("hp9122c"); } @@ -94,12 +94,12 @@ void human_interface_device::iocpu_map(address_map& map) map(0x0000, 0x07ff).rom().region("iocpu", 0); } -human_interface_device::human_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +human_interface_device::human_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : human_interface_device(mconfig, HPDIO_HUMAN_INTERFACE, tag, owner, clock) { } -human_interface_device::human_interface_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +human_interface_device::human_interface_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_dio16_card_interface(mconfig, *this), m_iocpu(*this, "iocpu"), diff --git a/src/devices/bus/hp_dio/human_interface.h b/src/devices/bus/hp_dio/human_interface.h index 2e1d1376211..84b0cc7e7d0 100644 --- a/src/devices/bus/hp_dio/human_interface.h +++ b/src/devices/bus/hp_dio/human_interface.h @@ -22,10 +22,10 @@ class human_interface_device : public device_dio16_card_interface { public: - human_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + human_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - human_interface_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + human_interface_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/hp_hil/hlebase.cpp b/src/devices/bus/hp_hil/hlebase.cpp index 247dafeea51..8296e188190 100644 --- a/src/devices/bus/hp_hil/hlebase.cpp +++ b/src/devices/bus/hp_hil/hlebase.cpp @@ -17,7 +17,7 @@ namespace bus::hp_hil { designated device constructor --------------------------------------------------*/ -hle_device_base::hle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock) +hle_device_base::hle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_hp_hil_interface(mconfig, *this) , m_powerup(true) diff --git a/src/devices/bus/hp_hil/hlebase.h b/src/devices/bus/hp_hil/hlebase.h index 96efcdd2073..bdf95b59975 100644 --- a/src/devices/bus/hp_hil/hlebase.h +++ b/src/devices/bus/hp_hil/hlebase.h @@ -20,7 +20,7 @@ public: void transmit_byte(uint8_t byte); protected: // constructor/destructor - hle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock); + hle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device overrides virtual void device_start() override; diff --git a/src/devices/bus/hp_hil/hlekbd.cpp b/src/devices/bus/hp_hil/hlekbd.cpp index 25414fc2de5..c02584386c7 100644 --- a/src/devices/bus/hp_hil/hlekbd.cpp +++ b/src/devices/bus/hp_hil/hlekbd.cpp @@ -436,7 +436,7 @@ void hle_hp_itf_device::transmit_byte(uint8_t byte) abbreviated constructor --------------------------------------------------*/ -hle_hp_ipc_device::hle_hp_ipc_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +hle_hp_ipc_device::hle_hp_ipc_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : hle_device_base(mconfig, HP_IPC_HLE_KEYBOARD, tag, owner, clock) , device_matrix_keyboard_interface(mconfig, *this, "COL1", "COL2", "COL3", "COL4", "COL5", "COL6", "COL7", "COL8", "COL9", "COL10", "COL11", "COL12", "COL13", "COL14", "COL15") , m_modifiers(*this, "COL8") @@ -568,7 +568,7 @@ ioport_constructor hle_hp_ipc_device::device_input_ports() const abbreviated constructor --------------------------------------------------*/ -hle_hp_itf_device::hle_hp_itf_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +hle_hp_itf_device::hle_hp_itf_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : hle_device_base(mconfig, HP_ITF_HLE_KEYBOARD, tag, owner, clock) , device_matrix_keyboard_interface(mconfig, *this, "COL1", "COL2", "COL3", "COL4", "COL5", "COL6", "COL7", "COL8", "COL9", "COL10", "COL11", "COL12", "COL13", "COL14", "COL15") { } diff --git a/src/devices/bus/hp_hil/hlekbd.h b/src/devices/bus/hp_hil/hlekbd.h index e1b5c08fd5a..cdc507ab16e 100644 --- a/src/devices/bus/hp_hil/hlekbd.h +++ b/src/devices/bus/hp_hil/hlekbd.h @@ -17,7 +17,7 @@ class hle_hp_ipc_device , protected device_matrix_keyboard_interface<15U> { public: - hle_hp_ipc_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + hle_hp_ipc_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; virtual void device_reset() override; @@ -50,7 +50,7 @@ class hle_hp_itf_device , protected device_matrix_keyboard_interface<15U> { public: - hle_hp_itf_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + hle_hp_itf_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual void device_reset() override; virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/hp_hil/hlemouse.cpp b/src/devices/bus/hp_hil/hlemouse.cpp index 215912b5cc6..b13366ca75b 100644 --- a/src/devices/bus/hp_hil/hlemouse.cpp +++ b/src/devices/bus/hp_hil/hlemouse.cpp @@ -33,7 +33,7 @@ INPUT_PORTS_START( hle_hp_46060b_device ) INPUT_PORTS_END } // anonymous namespace -hle_hp_46060b_device::hle_hp_46060b_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +hle_hp_46060b_device::hle_hp_46060b_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : hle_device_base(mconfig, HP_46060B_MOUSE, tag, owner, clock), mouse_x_delta{0}, mouse_y_delta{0}, diff --git a/src/devices/bus/hp_hil/hlemouse.h b/src/devices/bus/hp_hil/hlemouse.h index 830ffd20bfe..6fbb256da1b 100644 --- a/src/devices/bus/hp_hil/hlemouse.h +++ b/src/devices/bus/hp_hil/hlemouse.h @@ -16,7 +16,7 @@ class hle_hp_46060b_device : public hle_device_base { public: - hle_hp_46060b_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + hle_hp_46060b_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual void device_reset() override; virtual ioport_constructor device_input_ports() const override; virtual int hil_poll() override; diff --git a/src/devices/bus/hp_hil/hp_hil.cpp b/src/devices/bus/hp_hil/hp_hil.cpp index e86b9b24a9c..ae14ba2280c 100644 --- a/src/devices/bus/hp_hil/hp_hil.cpp +++ b/src/devices/bus/hp_hil/hp_hil.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(HP_HIL_SLOT, hp_hil_slot_device, "hp_hil_slot", "HP-HIL Slot" //------------------------------------------------- // hp_hil_slot_device - constructor //------------------------------------------------- -hp_hil_slot_device::hp_hil_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp_hil_slot_device::hp_hil_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HP_HIL_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_hp_hil_interface>(mconfig, *this) , m_mlc(*this, finder_base::DUMMY_TAG) @@ -55,7 +55,7 @@ DEFINE_DEVICE_TYPE(HP_HIL_MLC, hp_hil_mlc_device, "hp_hil_mlc", "HP-HIL Master L //------------------------------------------------- // hp_hil_mlc_device - constructor //------------------------------------------------- -hp_hil_mlc_device::hp_hil_mlc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp_hil_mlc_device::hp_hil_mlc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t{mconfig, HP_HIL_MLC, tag, owner, clock} , m_r2{0} , m_r3{0} diff --git a/src/devices/bus/hp_hil/hp_hil.h b/src/devices/bus/hp_hil/hp_hil.h index c50c4742340..c1ad4566efd 100644 --- a/src/devices/bus/hp_hil/hp_hil.h +++ b/src/devices/bus/hp_hil/hp_hil.h @@ -89,7 +89,7 @@ public: // construction/destruction template <typename T, typename U> hp_hil_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&mlc_tag, U &&opts, const char *dflt) - : hp_hil_slot_device(mconfig, tag, owner, 0) + : hp_hil_slot_device(mconfig, tag, owner) { m_mlc.set_tag(std::forward<T>(mlc_tag)); option_reset(); @@ -97,7 +97,7 @@ public: set_default_option(dflt); set_fixed(false); } - hp_hil_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_hil_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device-level overrides @@ -116,7 +116,7 @@ class hp_hil_mlc_device : public device_t { public: // construction/destruction - hp_hil_mlc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_hil_mlc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~hp_hil_mlc_device() { m_device_list.detach_all(); } auto int_callback() { return int_cb.bind(); } diff --git a/src/devices/bus/hp_ipc_io/82919.cpp b/src/devices/bus/hp_ipc_io/82919.cpp index e5835ebafc7..4dd2bb264b3 100644 --- a/src/devices/bus/hp_ipc_io/82919.cpp +++ b/src/devices/bus/hp_ipc_io/82919.cpp @@ -32,7 +32,7 @@ namespace { } } -hp82919_io_card_device::hp82919_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp82919_io_card_device::hp82919_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , HP82919_IO_CARD , tag , owner , clock) , device_hp_ipc_io_interface(mconfig, *this) , m_rs232_prim(*this , "rs232_prim") diff --git a/src/devices/bus/hp_ipc_io/82919.h b/src/devices/bus/hp_ipc_io/82919.h index 331a42b0b00..d5df86e38f5 100644 --- a/src/devices/bus/hp_ipc_io/82919.h +++ b/src/devices/bus/hp_ipc_io/82919.h @@ -21,7 +21,7 @@ class hp82919_io_card_device : public device_t, public device_hp_ipc_io_interfac { public: // construction/destruction - hp82919_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp82919_io_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~hp82919_io_card_device(); uint8_t read(offs_t addr); diff --git a/src/devices/bus/hp_ipc_io/hp_ipc_io.cpp b/src/devices/bus/hp_ipc_io/hp_ipc_io.cpp index 8d5648754bf..a79fc2db3fe 100644 --- a/src/devices/bus/hp_ipc_io/hp_ipc_io.cpp +++ b/src/devices/bus/hp_ipc_io/hp_ipc_io.cpp @@ -21,12 +21,16 @@ DEFINE_DEVICE_TYPE(HP_IPC_IO_SLOT, hp_ipc_io_slot_device, "hp_ipc_io_slot", "HP // +---------------------+ // |hp_ipc_io_slot_device| // +---------------------+ -hp_ipc_io_slot_device::hp_ipc_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +hp_ipc_io_slot_device::hp_ipc_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HP_IPC_IO_SLOT, tag, owner, clock), device_single_card_slot_interface<device_hp_ipc_io_interface>(mconfig, *this), m_irq_cb_func(*this), m_slot_idx(0) { + option_reset(); + hp_ipc_io_slot_devices(*this); + set_default_option(nullptr); + set_fixed(false); } hp_ipc_io_slot_device::~hp_ipc_io_slot_device() diff --git a/src/devices/bus/hp_ipc_io/hp_ipc_io.h b/src/devices/bus/hp_ipc_io/hp_ipc_io.h index 856b140c7ef..f0fcc4f620a 100644 --- a/src/devices/bus/hp_ipc_io/hp_ipc_io.h +++ b/src/devices/bus/hp_ipc_io/hp_ipc_io.h @@ -22,16 +22,7 @@ class hp_ipc_io_slot_device : public device_t, { public: // construction/destruction - hp_ipc_io_slot_device(machine_config const &mconfig, char const *tag, device_t *owner) - : hp_ipc_io_slot_device(mconfig, tag, owner, (uint32_t)0) - { - option_reset(); - hp_ipc_io_slot_devices(*this); - set_default_option(nullptr); - set_fixed(false); - } - - hp_ipc_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_ipc_io_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~hp_ipc_io_slot_device(); // Set A/B slot diff --git a/src/devices/bus/ieee488/c2031.cpp b/src/devices/bus/ieee488/c2031.cpp index 4efdd03e7b5..9a41957ab46 100644 --- a/src/devices/bus/ieee488/c2031.cpp +++ b/src/devices/bus/ieee488/c2031.cpp @@ -320,7 +320,7 @@ void c2031_device::device_add_mconfig(machine_config &config) C64H156(config, m_ga, XTAL(16'000'000)); m_ga->byte_callback().set(FUNC(c2031_device::byte_w)); - floppy_connector &connector(FLOPPY_CONNECTOR(config, C64H156_TAG":0", 0)); + floppy_connector &connector(FLOPPY_CONNECTOR(config, C64H156_TAG":0")); connector.option_add("525ssqd", FLOPPY_525_SSQD); connector.set_default_option("525ssqd"); connector.set_fixed(true); @@ -386,7 +386,7 @@ inline int c2031_device::get_device_number() // c2031_device - constructor //------------------------------------------------- -c2031_device::c2031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c2031_device::c2031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C2031, tag, owner, clock) , device_ieee488_interface(mconfig, *this) , m_maincpu(*this, M6502_TAG) diff --git a/src/devices/bus/ieee488/c2031.h b/src/devices/bus/ieee488/c2031.h index f3a0dc02074..783fa06c4fd 100644 --- a/src/devices/bus/ieee488/c2031.h +++ b/src/devices/bus/ieee488/c2031.h @@ -30,7 +30,7 @@ class c2031_device : public device_t, { public: // construction/destruction - c2031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c2031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/ieee488/c2040.cpp b/src/devices/bus/ieee488/c2040.cpp index 886dd01bbf2..237e7739df0 100644 --- a/src/devices/bus/ieee488/c2040.cpp +++ b/src/devices/bus/ieee488/c2040.cpp @@ -573,7 +573,7 @@ inline void c2040_device::update_ieee_signals() // c2040_device - constructor //------------------------------------------------- -c2040_device::c2040_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +c2040_device::c2040_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_ieee488_interface(mconfig, *this), m_maincpu(*this, M6502_TAG), @@ -595,7 +595,7 @@ c2040_device::c2040_device(const machine_config &mconfig, device_type type, cons { } -c2040_device::c2040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c2040_device::c2040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c2040_device(mconfig, C2040, tag, owner, clock) { } @@ -605,7 +605,7 @@ c2040_device::c2040_device(const machine_config &mconfig, const char *tag, devic // c3040_device - constructor //------------------------------------------------- -c3040_device::c3040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c3040_device::c3040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c2040_device(mconfig, C3040, tag, owner, clock) { } @@ -615,7 +615,7 @@ c3040_device::c3040_device(const machine_config &mconfig, const char *tag, devic // c4040_device - constructor //------------------------------------------------- -c4040_device::c4040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c4040_device::c4040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c2040_device(mconfig, C4040, tag, owner, clock) { } diff --git a/src/devices/bus/ieee488/c2040.h b/src/devices/bus/ieee488/c2040.h index 41f4f4f967e..0dc7195f20d 100644 --- a/src/devices/bus/ieee488/c2040.h +++ b/src/devices/bus/ieee488/c2040.h @@ -30,7 +30,7 @@ class c2040_device : public device_t, public device_ieee488_interface { public: // construction/destruction - c2040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c2040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t dio_r(); void dio_w(uint8_t data); @@ -43,7 +43,7 @@ public: void c2040_fdc_mem(address_map &map); void c2040_main_mem(address_map &map); protected: - c2040_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + c2040_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -98,7 +98,7 @@ class c3040_device : public c2040_device { public: // construction/destruction - c3040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c3040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -116,7 +116,7 @@ class c4040_device : public c2040_device { public: // construction/destruction - c4040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c4040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/ieee488/c2040fdc.cpp b/src/devices/bus/ieee488/c2040fdc.cpp index 18c02bba831..fb14726d397 100644 --- a/src/devices/bus/ieee488/c2040fdc.cpp +++ b/src/devices/bus/ieee488/c2040fdc.cpp @@ -70,7 +70,7 @@ const tiny_rom_entry *c2040_fdc_device::device_rom_region() const // c2040_fdc_device - constructor //------------------------------------------------- -c2040_fdc_device::c2040_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c2040_fdc_device::c2040_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C2040_FDC, tag, owner, clock), m_write_sync(*this), m_write_ready(*this), diff --git a/src/devices/bus/ieee488/c2040fdc.h b/src/devices/bus/ieee488/c2040fdc.h index 2198f6aa738..2b97150d2fe 100644 --- a/src/devices/bus/ieee488/c2040fdc.h +++ b/src/devices/bus/ieee488/c2040fdc.h @@ -28,7 +28,7 @@ class c2040_fdc_device : public device_t { public: // construction/destruction - c2040_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c2040_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto sync_wr_callback() { return m_write_sync.bind(); } auto ready_wr_callback() { return m_write_ready.bind(); } diff --git a/src/devices/bus/ieee488/c8050.cpp b/src/devices/bus/ieee488/c8050.cpp index 60358de4944..7c2ec038ebe 100644 --- a/src/devices/bus/ieee488/c8050.cpp +++ b/src/devices/bus/ieee488/c8050.cpp @@ -680,7 +680,7 @@ inline void c8050_device::update_ieee_signals() // c8050_device - constructor //------------------------------------------------- -c8050_device::c8050_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +c8050_device::c8050_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_ieee488_interface(mconfig, *this), m_maincpu(*this, M6502_TAG), @@ -701,7 +701,7 @@ c8050_device::c8050_device(const machine_config &mconfig, device_type type, cons { } -c8050_device::c8050_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c8050_device::c8050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c8050_device(mconfig, C8050, tag, owner, clock) { } @@ -711,7 +711,7 @@ c8050_device::c8050_device(const machine_config &mconfig, const char *tag, devic // c8250_device - constructor //------------------------------------------------- -c8250_device::c8250_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c8250_device::c8250_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c8050_device(mconfig, C8250, tag, owner, clock) { } @@ -721,7 +721,7 @@ c8250_device::c8250_device(const machine_config &mconfig, const char *tag, devic // c8250lp_device - constructor //------------------------------------------------- -c8250lp_device::c8250lp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c8250lp_device::c8250lp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c8050_device(mconfig, C8250LP, tag, owner, clock) { } @@ -731,7 +731,7 @@ c8250lp_device::c8250lp_device(const machine_config &mconfig, const char *tag, d // sfd1001_device - constructor //------------------------------------------------- -sfd1001_device::sfd1001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sfd1001_device::sfd1001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c8050_device(mconfig, SFD1001, tag, owner, clock) { } diff --git a/src/devices/bus/ieee488/c8050.h b/src/devices/bus/ieee488/c8050.h index a8047617408..284704ab608 100644 --- a/src/devices/bus/ieee488/c8050.h +++ b/src/devices/bus/ieee488/c8050.h @@ -30,7 +30,7 @@ class c8050_device : public device_t, public device_ieee488_interface { public: // construction/destruction - c8050_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c8050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t dio_r(); void dio_w(uint8_t data); @@ -45,7 +45,7 @@ public: void c8250lp_fdc_mem(address_map &map); void sfd1001_fdc_mem(address_map &map); protected: - c8050_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + c8050_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -92,7 +92,7 @@ class c8250_device : public c8050_device { public: // construction/destruction - c8250_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c8250_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -109,7 +109,7 @@ class c8250lp_device : public c8050_device { public: // construction/destruction - c8250lp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c8250lp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -127,7 +127,7 @@ class sfd1001_device : public c8050_device { public: // construction/destruction - sfd1001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sfd1001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/ieee488/c8050fdc.cpp b/src/devices/bus/ieee488/c8050fdc.cpp index eea107417c9..b044566b5c5 100644 --- a/src/devices/bus/ieee488/c8050fdc.cpp +++ b/src/devices/bus/ieee488/c8050fdc.cpp @@ -72,7 +72,7 @@ const tiny_rom_entry *c8050_fdc_device::device_rom_region() const // c8050_fdc_device - constructor //------------------------------------------------- -c8050_fdc_device::c8050_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c8050_fdc_device::c8050_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C8050_FDC, tag, owner, clock), m_write_sync(*this), m_write_ready(*this), diff --git a/src/devices/bus/ieee488/c8050fdc.h b/src/devices/bus/ieee488/c8050fdc.h index dd390b1b7c5..03248c63379 100644 --- a/src/devices/bus/ieee488/c8050fdc.h +++ b/src/devices/bus/ieee488/c8050fdc.h @@ -28,7 +28,7 @@ class c8050_fdc_device : public device_t { public: // construction/destruction - c8050_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c8050_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto sync_wr_callback() { return m_write_sync.bind(); } auto ready_wr_callback() { return m_write_ready.bind(); } diff --git a/src/devices/bus/ieee488/c8280.cpp b/src/devices/bus/ieee488/c8280.cpp index 1d9eb476110..a347272ec06 100644 --- a/src/devices/bus/ieee488/c8280.cpp +++ b/src/devices/bus/ieee488/c8280.cpp @@ -379,7 +379,7 @@ inline void c8280_device::update_ieee_signals() // c8280_device - constructor //------------------------------------------------- -c8280_device::c8280_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c8280_device::c8280_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C8280, tag, owner, clock), device_ieee488_interface(mconfig, *this), m_maincpu(*this, M6502_DOS_TAG), diff --git a/src/devices/bus/ieee488/c8280.h b/src/devices/bus/ieee488/c8280.h index 1317a6c13f7..c8196f60033 100644 --- a/src/devices/bus/ieee488/c8280.h +++ b/src/devices/bus/ieee488/c8280.h @@ -30,7 +30,7 @@ class c8280_device : public device_t, public device_ieee488_interface { public: // construction/destruction - c8280_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c8280_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/ieee488/d9060.cpp b/src/devices/bus/ieee488/d9060.cpp index 464db8cc902..b88ab032d9c 100644 --- a/src/devices/bus/ieee488/d9060.cpp +++ b/src/devices/bus/ieee488/d9060.cpp @@ -469,7 +469,7 @@ inline void d9060_device_base::update_ieee_signals() // d9060_device_base - constructor //------------------------------------------------- -d9060_device_base::d9060_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +d9060_device_base::d9060_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock) , device_ieee488_interface(mconfig, *this) , m_maincpu(*this, M6502_DOS_TAG) @@ -496,7 +496,7 @@ d9060_device_base::d9060_device_base(const machine_config &mconfig, device_type // d9060_device - constructor //------------------------------------------------- -d9060_device::d9060_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +d9060_device::d9060_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : d9060_device_base(mconfig, D9060, tag, owner, clock, TYPE_9060) { } @@ -506,7 +506,7 @@ d9060_device::d9060_device(const machine_config &mconfig, const char *tag, devic // d9090_device - constructor //------------------------------------------------- -d9090_device::d9090_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +d9090_device::d9090_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : d9060_device_base(mconfig, D9090, tag, owner, clock, TYPE_9090) { } diff --git a/src/devices/bus/ieee488/d9060.h b/src/devices/bus/ieee488/d9060.h index a5da444dbcf..0027bad7dcf 100644 --- a/src/devices/bus/ieee488/d9060.h +++ b/src/devices/bus/ieee488/d9060.h @@ -36,7 +36,7 @@ protected: }; // construction/destruction - d9060_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + d9060_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_start() override; @@ -97,7 +97,7 @@ class d9060_device : public d9060_device_base { public: // construction/destruction - d9060_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + d9060_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -107,7 +107,7 @@ class d9090_device : public d9060_device_base { public: // construction/destruction - d9090_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + d9090_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/ieee488/grid2102.cpp b/src/devices/bus/ieee488/grid2102.cpp index 4e6bc92c391..3a0bc8e5a20 100644 --- a/src/devices/bus/ieee488/grid2102.cpp +++ b/src/devices/bus/ieee488/grid2102.cpp @@ -65,7 +65,7 @@ uint8_t grid2101_hdd_device::identify_response[56] = { }; -grid210x_device::grid210x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int bus_addr, uint8_t *identify_response, attotime read_delay) +grid210x_device::grid210x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int bus_addr, uint8_t *identify_response, attotime read_delay) : device_t(mconfig, type, tag, owner, clock), device_ieee488_interface(mconfig, *this), device_image_interface(mconfig, *this), @@ -298,18 +298,18 @@ void grid210x_device::ieee488_ren(int state) { LOG("grid210x_device ren state set to %d\n", state); } -grid2101_hdd_device::grid2101_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +grid2101_hdd_device::grid2101_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : grid210x_device(mconfig, GRID2101_HDD, tag, owner, clock, 4, identify_response, attotime::from_usec(150)) { } -grid2101_floppy_device::grid2101_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : grid210x_device(mconfig, GRID2101_FLOPPY, tag, owner, clock, 5, identify_response) +grid2101_floppy_device::grid2101_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : grid210x_device(mconfig, GRID2101_FLOPPY, tag, owner, clock, 5, identify_response) { } -grid2102_device::grid2102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : grid210x_device(mconfig, GRID2102, tag, owner, clock, 6, identify_response) +grid2102_device::grid2102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : grid210x_device(mconfig, GRID2102, tag, owner, clock, 6, identify_response) { } diff --git a/src/devices/bus/ieee488/grid2102.h b/src/devices/bus/ieee488/grid2102.h index 11cdbcecdd0..501cf62f41c 100644 --- a/src/devices/bus/ieee488/grid2102.h +++ b/src/devices/bus/ieee488/grid2102.h @@ -28,7 +28,7 @@ class grid210x_device : public device_t, { public: // construction/destruction - grid210x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int bus_addr, uint8_t *identify_response, attotime read_delay = attotime::from_msec(5)); + grid210x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int bus_addr, uint8_t *identify_response, attotime read_delay = attotime::from_msec(5)); protected: // device-level overrides @@ -84,7 +84,7 @@ protected: class grid2102_device : public grid210x_device { public: // construction/destruction - grid2102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + grid2102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: static uint8_t identify_response[]; }; @@ -92,7 +92,7 @@ private: class grid2101_floppy_device : public grid210x_device { public: // construction/destruction - grid2101_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + grid2101_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: static uint8_t identify_response[]; }; @@ -100,7 +100,7 @@ private: class grid2101_hdd_device : public grid210x_device { public: // construction/destruction - grid2101_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + grid2101_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // image-level overrides virtual const char *image_type_name() const noexcept override { return "harddisk"; } diff --git a/src/devices/bus/ieee488/hardbox.cpp b/src/devices/bus/ieee488/hardbox.cpp index 0ad2db1abfb..96dca16c18a 100644 --- a/src/devices/bus/ieee488/hardbox.cpp +++ b/src/devices/bus/ieee488/hardbox.cpp @@ -286,7 +286,7 @@ void hardbox_device::device_add_mconfig(machine_config &config) ppi1.in_pc_callback().set(FUNC(hardbox_device::ppi1_pc_r)); ppi1.out_pc_callback().set(FUNC(hardbox_device::ppi1_pc_w)); - CORVUS_HDC(config, m_hdc, 0); + CORVUS_HDC(config, m_hdc); HARDDISK(config, "harddisk1", "corvus_hdd"); HARDDISK(config, "harddisk2", "corvus_hdd"); HARDDISK(config, "harddisk3", "corvus_hdd"); @@ -336,7 +336,7 @@ ioport_constructor hardbox_device::device_input_ports() const // hardbox_device - constructor //------------------------------------------------- -hardbox_device::hardbox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hardbox_device::hardbox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HARDBOX, tag, owner, clock) , device_ieee488_interface(mconfig, *this) , m_maincpu(*this, Z80_TAG) diff --git a/src/devices/bus/ieee488/hardbox.h b/src/devices/bus/ieee488/hardbox.h index 4b22ab57354..6b9fdcc194c 100644 --- a/src/devices/bus/ieee488/hardbox.h +++ b/src/devices/bus/ieee488/hardbox.h @@ -31,7 +31,7 @@ class hardbox_device : public device_t, { public: // construction/destruction - hardbox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hardbox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/ieee488/hp9122c.cpp b/src/devices/bus/ieee488/hp9122c.cpp index f9619617ca1..cc8328ba658 100644 --- a/src/devices/bus/ieee488/hp9122c.cpp +++ b/src/devices/bus/ieee488/hp9122c.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(HP9122C, hp9122c_device, "hp9122c", "HP9122C Dual High density disk drive") -hp9122c_device::hp9122c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp9122c_device::hp9122c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t{mconfig, HP9122C, tag, owner, clock}, device_ieee488_interface{mconfig, *this}, m_cpu{*this , "cpu"}, diff --git a/src/devices/bus/ieee488/hp9122c.h b/src/devices/bus/ieee488/hp9122c.h index 0c2d4854251..4d31493f6f0 100644 --- a/src/devices/bus/ieee488/hp9122c.h +++ b/src/devices/bus/ieee488/hp9122c.h @@ -25,7 +25,7 @@ class hp9122c_device : public device_t, { public: // construction/destruction - hp9122c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp9122c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/ieee488/hp9895.cpp b/src/devices/bus/ieee488/hp9895.cpp index aead54c0a18..fa9f4cd8925 100644 --- a/src/devices/bus/ieee488/hp9895.cpp +++ b/src/devices/bus/ieee488/hp9895.cpp @@ -132,7 +132,7 @@ static const uint8_t xv_drive_masks[] = { BIT_MASK(REG_XV_DRIVE1_BIT) }; -hp9895_device::hp9895_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp9895_device::hp9895_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HP9895, tag, owner, clock), device_ieee488_interface(mconfig, *this), m_cpu(*this , "cpu"), @@ -870,12 +870,12 @@ const tiny_rom_entry *hp9895_device::device_rom_region() const void hp9895_device::device_add_mconfig(machine_config &config) { - Z80(config, m_cpu, 4000000); + Z80(config, m_cpu, XTAL::u(4000000)); m_cpu->set_addrmap(AS_PROGRAM, &hp9895_device::z80_program_map); m_cpu->set_addrmap(AS_IO, &hp9895_device::z80_io_map); m_cpu->refresh_cb().set(FUNC(hp9895_device::z80_m1_w)); - PHI(config, m_phi, 0); + PHI(config, m_phi); m_phi->eoi_write_cb().set(FUNC(hp9895_device::phi_eoi_w)); m_phi->dav_write_cb().set(FUNC(hp9895_device::phi_dav_w)); m_phi->nrfd_write_cb().set(FUNC(hp9895_device::phi_nrfd_w)); diff --git a/src/devices/bus/ieee488/hp9895.h b/src/devices/bus/ieee488/hp9895.h index 1cb77d60090..8ee212a7a78 100644 --- a/src/devices/bus/ieee488/hp9895.h +++ b/src/devices/bus/ieee488/hp9895.h @@ -24,7 +24,7 @@ class hp9895_device : public device_t, { public: // construction/destruction - hp9895_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp9895_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/ieee488/ieee488.cpp b/src/devices/bus/ieee488/ieee488.cpp index 947aad2d1f7..6caf46b2f72 100644 --- a/src/devices/bus/ieee488/ieee488.cpp +++ b/src/devices/bus/ieee488/ieee488.cpp @@ -64,7 +64,7 @@ device_ieee488_interface::~device_ieee488_interface() // ieee488_slot_device - constructor //------------------------------------------------- -ieee488_slot_device::ieee488_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ieee488_slot_device::ieee488_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IEEE488_SLOT, tag, owner, clock), device_slot_interface(mconfig, *this), m_address(0) @@ -95,7 +95,7 @@ void ieee488_slot_device::device_start() void ieee488_slot_device::add_cbm_slot(machine_config &config, const char *_tag, int _address, const char *_def_slot) { - ieee488_slot_device &slot(IEEE488_SLOT(config, _tag, 0)); + ieee488_slot_device &slot(IEEE488_SLOT(config, _tag)); cbm_ieee488_devices(slot); slot.set_default_option(_def_slot); slot.set_address(_address); @@ -109,7 +109,7 @@ void ieee488_slot_device::add_cbm_slot(machine_config &config, const char *_tag, // ieee488_device - constructor //------------------------------------------------- -ieee488_device::ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ieee488_device::ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IEEE488, tag, owner, clock), m_write_eoi(*this), m_write_dav(*this), diff --git a/src/devices/bus/ieee488/ieee488.h b/src/devices/bus/ieee488/ieee488.h index 5a83d0fe927..cb5c3f06501 100644 --- a/src/devices/bus/ieee488/ieee488.h +++ b/src/devices/bus/ieee488/ieee488.h @@ -41,7 +41,7 @@ class ieee488_device : public device_t { public: // construction/destruction - ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ieee488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto eoi_callback() { return m_write_eoi.bind(); } auto dav_callback() { return m_write_dav.bind(); } @@ -171,7 +171,7 @@ public: // construction/destruction template <typename T> ieee488_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, int address, T &&opts, char const *dflt) - : ieee488_slot_device(mconfig, tag, owner, (uint32_t)0) + : ieee488_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -179,7 +179,7 @@ public: set_fixed(false); set_address(address); } - ieee488_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ieee488_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); static void add_cbm_slot(machine_config &config, const char *_tag, int _address, const char *_def_slot); static void add_cbm_defaults(machine_config &config, const char *_default_drive) diff --git a/src/devices/bus/ieee488/remote488.cpp b/src/devices/bus/ieee488/remote488.cpp index d559622dad6..83843d09c95 100644 --- a/src/devices/bus/ieee488/remote488.cpp +++ b/src/devices/bus/ieee488/remote488.cpp @@ -243,7 +243,7 @@ constexpr unsigned AH_TO_MS = 10; // Timeout in AH to report a byte st // device type definition DEFINE_DEVICE_TYPE(REMOTE488, remote488_device, "remote488", "IEEE-488 Remotizer") -remote488_device::remote488_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +remote488_device::remote488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , REMOTE488 , tag , owner , clock), device_ieee488_interface(mconfig , *this), m_stream(*this , "stream") @@ -252,7 +252,7 @@ remote488_device::remote488_device(const machine_config &mconfig, const char *ta void remote488_device::device_add_mconfig(machine_config &config) { - BITBANGER(config, m_stream, 0); + BITBANGER(config, m_stream); } void remote488_device::ieee488_eoi(int state) diff --git a/src/devices/bus/ieee488/remote488.h b/src/devices/bus/ieee488/remote488.h index bcb64866a05..3112fa607bc 100644 --- a/src/devices/bus/ieee488/remote488.h +++ b/src/devices/bus/ieee488/remote488.h @@ -19,7 +19,7 @@ class remote488_device : public device_t, { public: // construction/destruction - remote488_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + remote488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_ieee488_interface overrides virtual void ieee488_eoi(int state) override; diff --git a/src/devices/bus/ieee488/shark.cpp b/src/devices/bus/ieee488/shark.cpp index 1e160b6c310..0d4db989a43 100644 --- a/src/devices/bus/ieee488/shark.cpp +++ b/src/devices/bus/ieee488/shark.cpp @@ -83,12 +83,12 @@ void mshark_device::mshark_io(address_map &map) void mshark_device::device_add_mconfig(machine_config &config) { // basic machine hardware - I8085A(config, m_maincpu, 1000000); + I8085A(config, m_maincpu, XTAL::u(1000000)); m_maincpu->set_addrmap(AS_PROGRAM, &mshark_device::mshark_mem); m_maincpu->set_addrmap(AS_IO, &mshark_device::mshark_io); // devices - HARDDISK(config, "harddisk1", 0); + HARDDISK(config, "harddisk1"); RS232_PORT(config, RS232_TAG, default_rs232_devices, nullptr); } @@ -120,7 +120,7 @@ ioport_constructor mshark_device::device_input_ports() const // mshark_device - constructor //------------------------------------------------- -mshark_device::mshark_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mshark_device::mshark_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSHARK, tag, owner, clock) , device_ieee488_interface(mconfig, *this) , m_maincpu(*this, I8085_TAG) diff --git a/src/devices/bus/ieee488/shark.h b/src/devices/bus/ieee488/shark.h index 6ba13e138e8..a79c7b4d4db 100644 --- a/src/devices/bus/ieee488/shark.h +++ b/src/devices/bus/ieee488/shark.h @@ -28,7 +28,7 @@ class mshark_device : public device_t, { public: // construction/destruction - mshark_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mshark_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/ieee488/softbox.cpp b/src/devices/bus/ieee488/softbox.cpp index 0a38d5ce9cf..c834e999812 100644 --- a/src/devices/bus/ieee488/softbox.cpp +++ b/src/devices/bus/ieee488/softbox.cpp @@ -239,7 +239,7 @@ void softbox_device::device_add_mconfig(machine_config &config) m_maincpu->set_addrmap(AS_IO, &softbox_device::softbox_io); // devices - i8251_device &i8251(I8251(config, I8251_TAG, 0)); + i8251_device &i8251(I8251(config, I8251_TAG)); i8251.txd_handler().set(RS232_TAG, FUNC(rs232_port_device::write_txd)); i8251.dtr_handler().set(RS232_TAG, FUNC(rs232_port_device::write_dtr)); i8251.rts_handler().set(RS232_TAG, FUNC(rs232_port_device::write_rts)); @@ -264,7 +264,7 @@ void softbox_device::device_add_mconfig(machine_config &config) m_dbrg->fr_handler().set(I8251_TAG, FUNC(i8251_device::write_rxc)); m_dbrg->ft_handler().set(I8251_TAG, FUNC(i8251_device::write_txc)); - CORVUS_HDC(config, m_hdc, 0); + CORVUS_HDC(config, m_hdc); HARDDISK(config, "harddisk1", "corvus_hdd"); HARDDISK(config, "harddisk2", "corvus_hdd"); HARDDISK(config, "harddisk3", "corvus_hdd"); @@ -312,7 +312,7 @@ ioport_constructor softbox_device::device_input_ports() const // softbox_device - constructor //------------------------------------------------- -softbox_device::softbox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +softbox_device::softbox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SOFTBOX, tag, owner, clock) , device_ieee488_interface(mconfig, *this) , m_maincpu(*this, Z80_TAG) diff --git a/src/devices/bus/ieee488/softbox.h b/src/devices/bus/ieee488/softbox.h index 6b1f4a1dee0..656cc4d268a 100644 --- a/src/devices/bus/ieee488/softbox.h +++ b/src/devices/bus/ieee488/softbox.h @@ -33,7 +33,7 @@ class softbox_device : public device_t, { public: // construction/destruction - softbox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + softbox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/imi7000/imi5000h.cpp b/src/devices/bus/imi7000/imi5000h.cpp index f32e7fdf2b3..f7af91e4276 100644 --- a/src/devices/bus/imi7000/imi5000h.cpp +++ b/src/devices/bus/imi7000/imi5000h.cpp @@ -380,7 +380,7 @@ void imi5000h_device::device_add_mconfig(machine_config & config) pio3.out_pb_callback().set(FUNC(imi5000h_device::pio3_pb_w)); pio3.out_brdy_callback().set(Z80PIO_3_TAG, FUNC(z80pio_device::strobe_b)); - //HARDDISK(config, "harddisk1", 0); + //HARDDISK(config, "harddisk1"); } @@ -438,7 +438,7 @@ ioport_constructor imi5000h_device::device_input_ports() const // imi5000h_device - constructor //------------------------------------------------- -imi5000h_device::imi5000h_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +imi5000h_device::imi5000h_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IMI5000H, tag, owner, clock), device_imi7000_interface(mconfig, *this), m_maincpu(*this, Z80_TAG), diff --git a/src/devices/bus/imi7000/imi5000h.h b/src/devices/bus/imi7000/imi5000h.h index 77d276b154b..a4beb0e0c81 100644 --- a/src/devices/bus/imi7000/imi5000h.h +++ b/src/devices/bus/imi7000/imi5000h.h @@ -32,7 +32,7 @@ class imi5000h_device : public device_t, { public: // construction/destruction - imi5000h_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + imi5000h_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/imi7000/imi7000.cpp b/src/devices/bus/imi7000/imi7000.cpp index 3c9e417867b..ce18864b0f4 100644 --- a/src/devices/bus/imi7000/imi7000.cpp +++ b/src/devices/bus/imi7000/imi7000.cpp @@ -52,7 +52,7 @@ device_imi7000_interface::device_imi7000_interface(const machine_config &mconfig // imi7000_slot_device - constructor //------------------------------------------------- -imi7000_slot_device::imi7000_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +imi7000_slot_device::imi7000_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IMI7000_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_imi7000_interface>(mconfig, *this) , m_card(nullptr) @@ -78,7 +78,7 @@ void imi7000_slot_device::device_start() // imi7000_bus_device - constructor //------------------------------------------------- -imi7000_bus_device::imi7000_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +imi7000_bus_device::imi7000_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IMI7000_BUS, tag, owner, clock) , m_units(*this, "%u", 0U) { diff --git a/src/devices/bus/imi7000/imi7000.h b/src/devices/bus/imi7000/imi7000.h index c1cf590091c..a89d5acce03 100644 --- a/src/devices/bus/imi7000/imi7000.h +++ b/src/devices/bus/imi7000/imi7000.h @@ -52,14 +52,14 @@ public: // construction/destruction template <typename T> imi7000_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : imi7000_slot_device(mconfig, tag, owner, (uint32_t)0) + : imi7000_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - imi7000_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + imi7000_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -75,7 +75,7 @@ class imi7000_bus_device : public device_t { public: // construction/destruction - imi7000_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + imi7000_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T, typename U, typename V, typename W> void set_slot_default_options(T &&def1, U &&def2, V &&def3, W &&def4) diff --git a/src/devices/bus/intellec4/insdatastor.cpp b/src/devices/bus/intellec4/insdatastor.cpp index 81bbf713db7..18f68688d13 100644 --- a/src/devices/bus/intellec4/insdatastor.cpp +++ b/src/devices/bus/intellec4/insdatastor.cpp @@ -166,7 +166,7 @@ class imm4_22_device , public device_image_interface { public: - imm4_22_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + imm4_22_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual image_init_result call_load() override; virtual void call_unload() override; @@ -208,7 +208,7 @@ private: }; -imm4_22_device::imm4_22_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +imm4_22_device::imm4_22_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTELLEC4_INST_DATA_STORAGE, tag, owner, clock) , bus::intellec4::device_univ_card_interface(mconfig, *this) , device_image_interface(mconfig, *this) diff --git a/src/devices/bus/intellec4/intellec4.cpp b/src/devices/bus/intellec4/intellec4.cpp index f1eb0934448..f6bfa73f496 100644 --- a/src/devices/bus/intellec4/intellec4.cpp +++ b/src/devices/bus/intellec4/intellec4.cpp @@ -17,7 +17,7 @@ namespace bus::intellec4 { SLOT DEVICE ***********************************************************************/ -univ_slot_device::univ_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +univ_slot_device::univ_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTELLEC4_UNIV_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_univ_card_interface>(mconfig, *this) , m_bus(*this, finder_base::DUMMY_TAG) @@ -45,7 +45,7 @@ void univ_slot_device::device_start() BUS DEVICE ***********************************************************************/ -univ_bus_device::univ_bus_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +univ_bus_device::univ_bus_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTELLEC4_UNIV_BUS, tag, owner, clock) , m_rom_space(*this, finder_base::DUMMY_TAG, -1) , m_rom_ports_space(*this, finder_base::DUMMY_TAG, -1) diff --git a/src/devices/bus/intellec4/intellec4.h b/src/devices/bus/intellec4/intellec4.h index 287c23681bf..a08b9fb0283 100644 --- a/src/devices/bus/intellec4/intellec4.h +++ b/src/devices/bus/intellec4/intellec4.h @@ -125,7 +125,7 @@ class univ_slot_device : public device_t, public device_single_card_slot_interfa { public: template <typename T, typename U> - univ_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&bus_tag, U &&opts, const char *dflt) + univ_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&bus_tag, U &&opts, const char *dflt) : univ_slot_device(mconfig, tag, owner, clock) { m_bus.set_tag(std::forward<T>(bus_tag)); @@ -134,7 +134,7 @@ public: set_default_option(dflt); set_fixed(false); } - univ_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + univ_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t implementation @@ -164,7 +164,7 @@ public: auto reset_4002_out_cb() { return m_reset_4002_out_cb.bind(); } auto user_reset_out_cb() { return m_user_reset_out_cb.bind(); } - univ_bus_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + univ_bus_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // input lines DECLARE_WRITE_LINE_MEMBER(sync_in); diff --git a/src/devices/bus/intellec4/prommemory.cpp b/src/devices/bus/intellec4/prommemory.cpp index 7af8a5757f2..d45861a85af 100644 --- a/src/devices/bus/intellec4/prommemory.cpp +++ b/src/devices/bus/intellec4/prommemory.cpp @@ -95,7 +95,7 @@ class imm6_26_device , public device_image_interface { public: - imm6_26_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + imm6_26_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual image_init_result call_load() override; virtual void call_unload() override; @@ -119,7 +119,7 @@ private: }; -imm6_26_device::imm6_26_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +imm6_26_device::imm6_26_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTELLEC4_PROM_MEMORY, tag, owner, clock) , bus::intellec4::device_univ_card_interface(mconfig, *this) , device_image_interface(mconfig, *this) diff --git a/src/devices/bus/intellec4/tapereader.cpp b/src/devices/bus/intellec4/tapereader.cpp index aa1acd9e963..4759b28457a 100644 --- a/src/devices/bus/intellec4/tapereader.cpp +++ b/src/devices/bus/intellec4/tapereader.cpp @@ -26,7 +26,7 @@ class imm4_90_device , public bus::intellec4::device_univ_card_interface { public: - imm4_90_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + imm4_90_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual image_init_result call_load() override; virtual void call_unload() override; @@ -53,7 +53,7 @@ private: }; -imm4_90_device::imm4_90_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +imm4_90_device::imm4_90_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : paper_tape_reader_device(mconfig, INTELLEC4_TAPE_READER, tag, owner, clock) , bus::intellec4::device_univ_card_interface(mconfig, *this) , m_step_timer(nullptr) diff --git a/src/devices/bus/interpro/keyboard/hle.cpp b/src/devices/bus/interpro/keyboard/hle.cpp index 8d773a9fa85..670c7a507d7 100644 --- a/src/devices/bus/interpro/keyboard/hle.cpp +++ b/src/devices/bus/interpro/keyboard/hle.cpp @@ -254,7 +254,7 @@ INPUT_PORTS_END } // anonymous namespace -hle_device_base::hle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) +hle_device_base::hle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_buffered_serial_interface(mconfig, *this) , device_interpro_keyboard_port_interface(mconfig, *this) @@ -429,7 +429,7 @@ void hle_device_base::received_byte(u8 byte) } } -hle_en_us_device::hle_en_us_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +hle_en_us_device::hle_en_us_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : hle_device_base(mconfig, INTERPRO_HLE_EN_US_KEYBOARD, tag, owner, clock), m_modifiers(*this, "modifiers") { diff --git a/src/devices/bus/interpro/keyboard/hle.h b/src/devices/bus/interpro/keyboard/hle.h index 607b7b42087..d1663f3d4e9 100644 --- a/src/devices/bus/interpro/keyboard/hle.h +++ b/src/devices/bus/interpro/keyboard/hle.h @@ -25,7 +25,7 @@ public: protected: // constructor/destructor - hle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + hle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device overrides virtual void device_add_mconfig(machine_config &config) override; @@ -105,7 +105,7 @@ private: class hle_en_us_device : public hle_device_base { public: - hle_en_us_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + hle_en_us_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/interpro/keyboard/keyboard.cpp b/src/devices/bus/interpro/keyboard/keyboard.cpp index 2e31ee7e258..4943d7f72b0 100644 --- a/src/devices/bus/interpro/keyboard/keyboard.cpp +++ b/src/devices/bus/interpro/keyboard/keyboard.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(INTERPRO_KEYBOARD_PORT, interpro_keyboard_port_device, "interpro_keyboard_port", "InterPro Keyboard Port") -interpro_keyboard_port_device::interpro_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +interpro_keyboard_port_device::interpro_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTERPRO_KEYBOARD_PORT, tag, owner, clock) , device_single_card_slot_interface<device_interpro_keyboard_port_interface>(mconfig, *this) , m_rxd_handler(*this) diff --git a/src/devices/bus/interpro/keyboard/keyboard.h b/src/devices/bus/interpro/keyboard/keyboard.h index a51c254d7f8..2d40a2e769a 100644 --- a/src/devices/bus/interpro/keyboard/keyboard.h +++ b/src/devices/bus/interpro/keyboard/keyboard.h @@ -22,7 +22,7 @@ public: set_fixed(false); } - interpro_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + interpro_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // callback configuration auto rxd_handler_cb() { return m_rxd_handler.bind(); } diff --git a/src/devices/bus/interpro/keyboard/lle.cpp b/src/devices/bus/interpro/keyboard/lle.cpp index 1556a3f4779..56a798b602e 100644 --- a/src/devices/bus/interpro/keyboard/lle.cpp +++ b/src/devices/bus/interpro/keyboard/lle.cpp @@ -421,7 +421,7 @@ ROM_END } // anonymous namespace -lle_device_base::lle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) +lle_device_base::lle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_interpro_keyboard_port_interface(mconfig, *this) , m_mcu(*this, "mcu") @@ -447,7 +447,7 @@ void lle_device_base::device_add_mconfig(machine_config &config) ADDRESS_MAP_BANK(config, m_ext).set_map(&lle_device_base::ext_map).set_options(ENDIANNESS_NATIVE, 8, 12, 0x100); SPEAKER(config, "keyboard").front_center(); - SPEAKER_SOUND(config, m_speaker, 0).add_route(ALL_OUTPUTS, "keyboard", 0.25); + SPEAKER_SOUND(config, m_speaker).add_route(ALL_OUTPUTS, "keyboard", 0.25); } void lle_device_base::device_start() @@ -595,7 +595,7 @@ void lle_device_base::bus_w(u8 data) m_bus = data; } -lle_en_us_device::lle_en_us_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +lle_en_us_device::lle_en_us_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : lle_device_base(mconfig, INTERPRO_LLE_EN_US_KEYBOARD, tag, owner, clock) { } diff --git a/src/devices/bus/interpro/keyboard/lle.h b/src/devices/bus/interpro/keyboard/lle.h index 385f2484fab..aa3edf5a215 100644 --- a/src/devices/bus/interpro/keyboard/lle.h +++ b/src/devices/bus/interpro/keyboard/lle.h @@ -20,7 +20,7 @@ class lle_device_base { protected: // constructor/destructor - lle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + lle_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device overrides virtual void device_add_mconfig(machine_config &config) override; @@ -60,7 +60,7 @@ private: class lle_en_us_device : public lle_device_base { public: - lle_en_us_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + lle_en_us_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; virtual tiny_rom_entry const *device_rom_region() const override; diff --git a/src/devices/bus/interpro/mouse/mouse.cpp b/src/devices/bus/interpro/mouse/mouse.cpp index 835bcd1f68d..c32d80b0884 100644 --- a/src/devices/bus/interpro/mouse/mouse.cpp +++ b/src/devices/bus/interpro/mouse/mouse.cpp @@ -36,7 +36,7 @@ static INPUT_PORTS_START(interpro_mouse) PORT_BIT(0xff, 0x00, IPT_MOUSE_Y) PORT_SENSITIVITY(50) PORT_KEYDELTA(0) PORT_PLAYER(1) PORT_CHANGED_MEMBER(DEVICE_SELF, interpro_mouse_device, mouse_y, 0) INPUT_PORTS_END -interpro_mouse_port_device::interpro_mouse_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +interpro_mouse_port_device::interpro_mouse_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTERPRO_MOUSE_PORT, tag, owner, clock) , device_single_card_slot_interface<device_interpro_mouse_port_interface>(mconfig, *this) , m_state_func(*this) @@ -60,7 +60,7 @@ device_interpro_mouse_port_interface::device_interpro_mouse_port_interface(machi { } -interpro_mouse_device::interpro_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +interpro_mouse_device::interpro_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTERPRO_MOUSE, tag, owner, clock) , device_interpro_mouse_port_interface(mconfig, *this) { diff --git a/src/devices/bus/interpro/mouse/mouse.h b/src/devices/bus/interpro/mouse/mouse.h index f10019605cb..98988eb2841 100644 --- a/src/devices/bus/interpro/mouse/mouse.h +++ b/src/devices/bus/interpro/mouse/mouse.h @@ -22,7 +22,7 @@ public: set_fixed(false); } - interpro_mouse_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + interpro_mouse_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // callback configuration auto state_func() { return m_state_func.bind(); } @@ -66,7 +66,7 @@ public: }; // constructor/destructor - interpro_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + interpro_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(mouse_button); DECLARE_INPUT_CHANGED_MEMBER(mouse_x); diff --git a/src/devices/bus/interpro/sr/edge.cpp b/src/devices/bus/interpro/sr/edge.cpp index 7b5dc82d95f..26466c79261 100644 --- a/src/devices/bus/interpro/sr/edge.cpp +++ b/src/devices/bus/interpro/sr/edge.cpp @@ -477,7 +477,7 @@ void mpcb828_device::device_add_mconfig(machine_config &config) m_dsp->set_disable(); //m_dsp->set_addrmap(0, map_dynamic<2>); - BT458(config, "ramdac", 83'020'800); + BT458(config, "ramdac", XTAL::u(83'020'800)); SCC8530N(config, m_scc, 4.9152_MHz_XTAL); m_scc->out_int_callback().set(FUNC(mpcb828_device::scc_irq)); @@ -508,7 +508,7 @@ void mpcb849_device::device_add_mconfig(machine_config &config) m_dsp->holda().set(FUNC(mpcb828_device::holda)); m_dsp->set_disable(); - BT458(config, "ramdac", 0); // unconfirmed clock + BT458(config, "ramdac"); // unconfirmed clock SCC8530N(config, m_scc, 4.9152_MHz_XTAL); m_scc->out_int_callback().set(FUNC(mpcb849_device::scc_irq)); @@ -536,9 +536,9 @@ void mpcba63_device::device_add_mconfig(machine_config &config) //m_screen->set_raw(83'020'800, 1504, 296 + 20, 1184 + 296 + 20, 920, 34, 884 + 34); //m_screen->set_screen_update().set(FUNC(mpcba63_device::screen_update)); //m_screen->screen_vblank().set(FUNC(?, vblank)); - //BT457(config, "ramdac0", 0); // PS045701-165 - //BT457(config, "ramdac1", 0); - //BT457(config, "ramdac2", 0); + //BT457(config, "ramdac0"); // PS045701-165 + //BT457(config, "ramdac1"); + //BT457(config, "ramdac2"); } /* @@ -579,12 +579,12 @@ void mpcb896_device::device_add_mconfig(machine_config &config) RAM(config, "sram").set_default_size("256KiB").set_default_value(0); RAM(config, "vram").set_default_size("18MiB").set_default_value(0); - BT457(config, "ramdac0", 164'609'300); - BT457(config, "ramdac1", 164'609'300); - BT457(config, "ramdac2", 164'609'300); + BT457(config, "ramdac0", XTAL::u(164'609'300)); + BT457(config, "ramdac1", XTAL::u(164'609'300)); + BT457(config, "ramdac2", XTAL::u(164'609'300)); } -edge1_device_base::edge1_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +edge1_device_base::edge1_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_srx_card_interface(mconfig, *this) , m_screen(*this, "screen") @@ -596,13 +596,13 @@ edge1_device_base::edge1_device_base(const machine_config &mconfig, device_type { } -edge2_processor_device_base::edge2_processor_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +edge2_processor_device_base::edge2_processor_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_srx_card_interface(mconfig, *this) { } -edge2plus_processor_device_base::edge2plus_processor_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +edge2plus_processor_device_base::edge2plus_processor_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_srx_card_interface(mconfig, *this) , m_dsp1(*this, "dsp1") @@ -611,13 +611,13 @@ edge2plus_processor_device_base::edge2plus_processor_device_base(const machine_c { } -edge2_framebuffer_device_base::edge2_framebuffer_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +edge2_framebuffer_device_base::edge2_framebuffer_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_srx_card_interface(mconfig, *this) { } -edge2plus_framebuffer_device_base::edge2plus_framebuffer_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +edge2plus_framebuffer_device_base::edge2plus_framebuffer_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_srx_card_interface(mconfig, *this) , m_screen(*this, "screen") @@ -627,32 +627,32 @@ edge2plus_framebuffer_device_base::edge2plus_framebuffer_device_base(const machi { } -mpcb828_device::mpcb828_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcb828_device::mpcb828_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : edge1_device_base(mconfig, MPCB828, tag, owner, clock) { } -mpcb849_device::mpcb849_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcb849_device::mpcb849_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : edge1_device_base(mconfig, MPCB849, tag, owner, clock) { } -mpcb030_device::mpcb030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcb030_device::mpcb030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : edge2_processor_device_base(mconfig, MPCB030, tag, owner, clock) { } -mpcba63_device::mpcba63_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcba63_device::mpcba63_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : edge2_framebuffer_device_base(mconfig, MPCBA63, tag, owner, clock) { } -msmt094_device::msmt094_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msmt094_device::msmt094_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : edge2plus_processor_device_base(mconfig, MSMT094, tag, owner, clock) { } -mpcb896_device::mpcb896_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcb896_device::mpcb896_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : edge2plus_framebuffer_device_base(mconfig, MPCB896, tag, owner, clock) { } diff --git a/src/devices/bus/interpro/sr/edge.h b/src/devices/bus/interpro/sr/edge.h index d96896dd187..1a8852f976e 100644 --- a/src/devices/bus/interpro/sr/edge.h +++ b/src/devices/bus/interpro/sr/edge.h @@ -21,7 +21,7 @@ public: DECLARE_WRITE_LINE_MEMBER(vblank); protected: - edge1_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + edge1_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; virtual void map_dynamic(address_map &map); @@ -77,7 +77,7 @@ private: class edge2_processor_device_base : public device_t, public device_srx_card_interface { protected: - edge2_processor_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + edge2_processor_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; @@ -87,7 +87,7 @@ protected: class edge2_framebuffer_device_base : public device_t, public device_srx_card_interface { protected: - edge2_framebuffer_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + edge2_framebuffer_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; @@ -101,7 +101,7 @@ public: required_device<tms3203x_device> m_dsp1; protected: - edge2plus_processor_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + edge2plus_processor_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; @@ -150,7 +150,7 @@ class edge2plus_framebuffer_device_base : public device_t, public device_srx_car protected: friend class edge2plus_processor_device_base; - edge2plus_framebuffer_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + edge2plus_framebuffer_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; virtual void device_start() override; @@ -179,7 +179,7 @@ private: class mpcb828_device : public edge1_device_base { public: - mpcb828_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcb828_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -189,7 +189,7 @@ protected: class mpcb849_device : public edge1_device_base { public: - mpcb849_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcb849_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -201,7 +201,7 @@ protected: class mpcb030_device : public edge2_processor_device_base { public: - mpcb030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcb030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -211,7 +211,7 @@ protected: class msmt094_device : public edge2plus_processor_device_base { public: - msmt094_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msmt094_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -221,7 +221,7 @@ protected: class mpcba63_device : public edge2_framebuffer_device_base { public: - mpcba63_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcba63_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -233,7 +233,7 @@ protected: class mpcb896_device : public edge2plus_framebuffer_device_base { public: - mpcb896_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcb896_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/interpro/sr/gt.cpp b/src/devices/bus/interpro/sr/gt.cpp index 15158ede040..4a636d44bea 100644 --- a/src/devices/bus/interpro/sr/gt.cpp +++ b/src/devices/bus/interpro/sr/gt.cpp @@ -296,8 +296,8 @@ ROM_END void gt_device_base::device_add_mconfig(machine_config &config) { - DP8510(config, m_bpu[0], 0); - DP8510(config, m_bpu[1], 0); + DP8510(config, m_bpu[0]); + DP8510(config, m_bpu[1]); } void interpro_digitizer_devices(device_slot_interface &device) @@ -349,8 +349,8 @@ void mpcb963_device::device_add_mconfig(machine_config &config) m_screen[0]->set_screen_update(FUNC(mpcb963_device::screen_update<0>)); m_screen[0]->screen_vblank().set(FUNC(device_cbus_card_interface::irq3)); BT459(config, m_ramdac[0], pixclock); - RAM(config, m_vram[0], 0).set_default_size("1M"); - RAM(config, m_mram[0], 0).set_default_size("128K"); + RAM(config, m_vram[0]).set_default_size("1M"); + RAM(config, m_mram[0]).set_default_size("128K"); } void mpcba79_device::device_add_mconfig(machine_config &config) @@ -364,15 +364,15 @@ void mpcba79_device::device_add_mconfig(machine_config &config) m_screen[0]->set_screen_update(FUNC(mpcba79_device::screen_update<0>)); m_screen[0]->screen_vblank().set(FUNC(device_cbus_card_interface::irq3)); BT459(config, m_ramdac[0], pixclock); - RAM(config, m_vram[0], 0).set_default_size("1M"); - RAM(config, m_mram[0], 0).set_default_size("128K"); + RAM(config, m_vram[0]).set_default_size("1M"); + RAM(config, m_mram[0]).set_default_size("128K"); SCREEN(config, m_screen[1], SCREEN_TYPE_RASTER); m_screen[1]->set_raw(pixclock, 1504, 296 + GT_X_DELTA, 1184 + 296 + GT_X_DELTA, 920, 34, 884 + 34); m_screen[1]->set_screen_update(FUNC(mpcba79_device::screen_update<1>)); BT459(config, m_ramdac[1], pixclock); - RAM(config, m_vram[1], 0).set_default_size("1M"); - RAM(config, m_mram[1], 0).set_default_size("128K"); + RAM(config, m_vram[1]).set_default_size("1M"); + RAM(config, m_mram[1]).set_default_size("128K"); } /* @@ -397,8 +397,8 @@ void msmt070_device::device_add_mconfig(machine_config &config) m_screen[0]->set_screen_update(FUNC(msmt070_device::screen_update<0>)); m_screen[0]->screen_vblank().set(FUNC(device_cbus_card_interface::irq3)); BT459(config, m_ramdac[0], pixclock); - RAM(config, m_vram[0], 0).set_default_size("2M"); - RAM(config, m_mram[0], 0).set_default_size("128K"); + RAM(config, m_vram[0]).set_default_size("2M"); + RAM(config, m_mram[0]).set_default_size("128K"); } void msmt071_device::device_add_mconfig(machine_config &config) @@ -412,15 +412,15 @@ void msmt071_device::device_add_mconfig(machine_config &config) m_screen[0]->set_screen_update(FUNC(msmt071_device::screen_update<0>)); m_screen[0]->screen_vblank().set(FUNC(device_cbus_card_interface::irq3)); BT459(config, m_ramdac[0], pixclock); - RAM(config, m_vram[0], 0).set_default_size("2M"); - RAM(config, m_mram[0], 0).set_default_size("128K"); + RAM(config, m_vram[0]).set_default_size("2M"); + RAM(config, m_mram[0]).set_default_size("128K"); SCREEN(config, m_screen[1], SCREEN_TYPE_RASTER); m_screen[1]->set_raw(pixclock, 1472, 264 + GT_X_DELTA, 1184 + 264 + GT_X_DELTA, 944, 57, 884 + 57); m_screen[1]->set_screen_update(FUNC(msmt071_device::screen_update<1>)); BT459(config, m_ramdac[1], pixclock); - RAM(config, m_vram[1], 0).set_default_size("2M"); - RAM(config, m_mram[1], 0).set_default_size("128K"); + RAM(config, m_vram[1]).set_default_size("2M"); + RAM(config, m_mram[1]).set_default_size("128K"); } /* @@ -447,8 +447,8 @@ void msmt081_device::device_add_mconfig(machine_config &config) BT459(config, m_ramdac[0], pixclock); // FIXME: following memory sizes are pure speculation - RAM(config, m_vram[0], 0).set_default_size("4M"); // guess - RAM(config, m_mram[0], 0).set_default_size("256K"); // guess + RAM(config, m_vram[0]).set_default_size("4M"); // guess + RAM(config, m_mram[0]).set_default_size("256K"); // guess } /* @@ -467,9 +467,9 @@ void mpcbb68_device::device_add_mconfig(machine_config &config) BT459(config, m_ramdac[0], pixclock); // FIXME: pure speculation - RAM(config, m_vram[0], 0).set_default_size("2M"); - RAM(config, m_mram[0], 0).set_default_size("128K"); - RAM(config, m_hram[0], 0).set_default_size("512K"); + RAM(config, m_vram[0]).set_default_size("2M"); + RAM(config, m_mram[0]).set_default_size("128K"); + RAM(config, m_hram[0]).set_default_size("512K"); } /* @@ -494,12 +494,12 @@ void mpcbb92_device::device_add_mconfig(machine_config &config) BT459(config, m_ramdac[0], pixclock); // FIXME: following memory sizes are pure speculation (40 parts @ 256Kx4?) - RAM(config, m_vram[0], 0).set_default_size("4M"); - RAM(config, m_mram[0], 0).set_default_size("256K"); - RAM(config, m_hram[0], 0).set_default_size("1M"); + RAM(config, m_vram[0]).set_default_size("4M"); + RAM(config, m_mram[0]).set_default_size("256K"); + RAM(config, m_hram[0]).set_default_size("1M"); } -gt_device_base::gt_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const bool double_buffered, const bool masked_reads) +gt_device_base::gt_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const bool double_buffered, const bool masked_reads) : device_t(mconfig, type, tag, owner, clock) , m_screen(*this, "screen%u", 0) , m_ramdac(*this, "ramdac%u", 0) @@ -512,13 +512,13 @@ gt_device_base::gt_device_base(const machine_config &mconfig, device_type type, { } -gt_device::gt_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const bool double_buffered) +gt_device::gt_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const bool double_buffered) : gt_device_base(mconfig, type, tag, owner, clock, double_buffered, true) , device_cbus_card_interface(mconfig, *this) { } -gtdb_device::gtdb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gtdb_device::gtdb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : gt_device_base(mconfig, type, tag, owner, clock, true, false) , device_srx_card_interface(mconfig, *this) , m_hram(*this, "hram%u", 0) @@ -526,37 +526,37 @@ gtdb_device::gtdb_device(const machine_config &mconfig, device_type type, const { } -mpcb963_device::mpcb963_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcb963_device::mpcb963_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gt_device(mconfig, MPCB963, tag, owner, clock, false) { } -mpcba79_device::mpcba79_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcba79_device::mpcba79_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gt_device(mconfig, MPCBA79, tag, owner, clock, false) { } -msmt070_device::msmt070_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msmt070_device::msmt070_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gt_device(mconfig, MSMT070, tag, owner, clock, true) { } -msmt071_device::msmt071_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msmt071_device::msmt071_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gt_device(mconfig, MSMT071, tag, owner, clock, true) { } -msmt081_device::msmt081_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msmt081_device::msmt081_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gt_device(mconfig, MSMT081, tag, owner, clock, true) { } -mpcbb68_device::mpcbb68_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcbb68_device::mpcbb68_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gtdb_device(mconfig, MPCBB68, tag, owner, clock) { } -mpcbb92_device::mpcbb92_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcbb92_device::mpcbb92_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gtdb_device(mconfig, MPCBB92, tag, owner, clock) { } diff --git a/src/devices/bus/interpro/sr/gt.h b/src/devices/bus/interpro/sr/gt.h index aeeb70941ea..d5bb514d230 100644 --- a/src/devices/bus/interpro/sr/gt.h +++ b/src/devices/bus/interpro/sr/gt.h @@ -15,7 +15,7 @@ class gt_device_base : public device_t { protected: - gt_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const bool double_buffered, const bool masked_reads); + gt_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const bool double_buffered, const bool masked_reads); virtual void map(address_map &map); @@ -248,7 +248,7 @@ private: class gt_device : public gt_device_base, public device_cbus_card_interface { protected: - gt_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const bool double_buffered); + gt_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const bool double_buffered); virtual void map(address_map &map) override; }; @@ -256,7 +256,7 @@ protected: class gtdb_device : public gt_device_base, public device_srx_card_interface { protected: - gtdb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gtdb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; virtual void map_dynamic(address_map &map); @@ -306,7 +306,7 @@ private: class mpcb963_device : public gt_device { public: - mpcb963_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcb963_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -316,7 +316,7 @@ protected: class mpcba79_device : public gt_device { public: - mpcba79_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcba79_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -327,7 +327,7 @@ protected: class msmt070_device : public gt_device { public: - msmt070_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msmt070_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -337,7 +337,7 @@ protected: class msmt071_device : public gt_device { public: - msmt071_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msmt071_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -347,7 +347,7 @@ protected: class msmt081_device : public gt_device { public: - msmt081_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msmt081_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -357,7 +357,7 @@ protected: class mpcbb68_device : public gtdb_device { public: - mpcbb68_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcbb68_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -367,7 +367,7 @@ protected: class mpcbb92_device : public gtdb_device { public: - mpcbb92_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcbb92_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/interpro/sr/sr.cpp b/src/devices/bus/interpro/sr/sr.cpp index 82071af86d2..634ba65ed4e 100644 --- a/src/devices/bus/interpro/sr/sr.cpp +++ b/src/devices/bus/interpro/sr/sr.cpp @@ -274,7 +274,7 @@ void interpro_bus_device::device_resolve_objects() m_out_irq3_cb.resolve_safe(); } -cbus_bus_device::cbus_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cbus_bus_device::cbus_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : interpro_bus_device(mconfig, CBUS_BUS, tag, owner, clock) , m_slot_count(0) { @@ -285,7 +285,7 @@ void cbus_bus_device::device_start() { } -cbus_slot_device::cbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cbus_slot_device::cbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CBUS_SLOT, tag, owner, clock) , device_slot_interface(mconfig, *this) , m_bus(*this, finder_base::DUMMY_TAG) @@ -313,7 +313,7 @@ void device_cbus_card_interface::set_bus_device(cbus_bus_device &bus_device) m_bus->install_card(*this, device().memregion(m_idprom_region), &device_cbus_card_interface::map); } -srx_bus_device::srx_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +srx_bus_device::srx_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : interpro_bus_device(mconfig, SRX_BUS, tag, owner, clock) , m_slot_count(1) // first slot is used by the system board { @@ -324,7 +324,7 @@ void srx_bus_device::device_start() { } -srx_slot_device::srx_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +srx_slot_device::srx_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SRX_SLOT, tag, owner, clock) , device_slot_interface(mconfig, *this) , m_bus(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/bus/interpro/sr/sr.h b/src/devices/bus/interpro/sr/sr.h index 0d30905943b..0e6ed8e46aa 100644 --- a/src/devices/bus/interpro/sr/sr.h +++ b/src/devices/bus/interpro/sr/sr.h @@ -26,7 +26,7 @@ public: protected: // construction/destruction - interpro_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) + interpro_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_main_space(*this, finder_base::DUMMY_TAG, -1) , m_io_space(*this, finder_base::DUMMY_TAG, -1) @@ -57,7 +57,7 @@ class cbus_bus_device : public interpro_bus_device { public: // construction/destruction - cbus_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cbus_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static const u32 CBUS_BASE = 0x87000000; static const u32 CBUS_SIZE = 0x01000000; @@ -100,8 +100,8 @@ class cbus_slot_device : public device_t, public device_slot_interface public: // construction/destruction template <typename T, typename U> - cbus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, T &&bus_tag, U &&slot_options, const char *default_option, const bool fixed) - : cbus_slot_device(mconfig, tag, owner, clock) + cbus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bus_tag, U &&slot_options, const char *default_option, const bool fixed) + : cbus_slot_device(mconfig, tag, owner) { m_bus.set_tag(std::forward<T>(bus_tag)); option_reset(); @@ -109,7 +109,7 @@ public: set_default_option(default_option); set_fixed(fixed); } - cbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device-level overrides @@ -154,7 +154,7 @@ class srx_bus_device : public interpro_bus_device { public: // construction/destruction - srx_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + srx_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static const u32 SRX_BASE = 0x8f000000; static const u32 SRX_SIZE = 0x8000; @@ -212,8 +212,8 @@ class srx_slot_device : public device_t, public device_slot_interface public: // construction/destruction template <typename T, typename U> - srx_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, T &&bus_tag, U &&slot_options, const char *default_option, const bool fixed) - : srx_slot_device(mconfig, tag, owner, clock) + srx_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bus_tag, U &&slot_options, const char *default_option, const bool fixed) + : srx_slot_device(mconfig, tag, owner) { m_bus.set_tag(std::forward<T>(bus_tag)); option_reset(); @@ -221,7 +221,7 @@ public: set_default_option(default_option); set_fixed(fixed); } - srx_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + srx_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device-level overrides diff --git a/src/devices/bus/intv/ecs.cpp b/src/devices/bus/intv/ecs.cpp index 50d52a85c77..cd9bedf54f7 100644 --- a/src/devices/bus/intv/ecs.cpp +++ b/src/devices/bus/intv/ecs.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(INTV_ROM_ECS, intv_ecs_device, "intv_ecs", "Intellivision ECS Expansion") -intv_ecs_device::intv_ecs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +intv_ecs_device::intv_ecs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intv_rom_device(mconfig, INTV_ROM_ECS, tag, owner, clock), m_snd(*this, "ay8914"), m_subslot(*this, "subslot"), diff --git a/src/devices/bus/intv/ecs.h b/src/devices/bus/intv/ecs.h index 68911831c0a..e8b4d543ae8 100644 --- a/src/devices/bus/intv/ecs.h +++ b/src/devices/bus/intv/ecs.h @@ -17,7 +17,7 @@ class intv_ecs_device : public intv_rom_device { public: // construction/destruction - intv_ecs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + intv_ecs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing diff --git a/src/devices/bus/intv/rom.cpp b/src/devices/bus/intv/rom.cpp index f320d1cae49..af2f0dbe29b 100644 --- a/src/devices/bus/intv/rom.cpp +++ b/src/devices/bus/intv/rom.cpp @@ -23,28 +23,28 @@ DEFINE_DEVICE_TYPE(INTV_ROM_GFACT, intv_gfact_device, "intv_gfact", "Intellivisi DEFINE_DEVICE_TYPE(INTV_ROM_WSMLB, intv_wsmlb_device, "intv_wsmlb", "Intellivision World Series Baseball Cart") -intv_rom_device::intv_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +intv_rom_device::intv_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_intv_cart_interface(mconfig, *this) { } -intv_rom_device::intv_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intv_rom_device::intv_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intv_rom_device(mconfig, INTV_ROM_STD, tag, owner, clock) { } -intv_ram_device::intv_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intv_ram_device::intv_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intv_rom_device(mconfig, INTV_ROM_RAM, tag, owner, clock) { } -intv_gfact_device::intv_gfact_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intv_gfact_device::intv_gfact_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intv_rom_device(mconfig, INTV_ROM_GFACT, tag, owner, clock) { } -intv_wsmlb_device::intv_wsmlb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intv_wsmlb_device::intv_wsmlb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intv_rom_device(mconfig, INTV_ROM_WSMLB, tag, owner, clock) { } diff --git a/src/devices/bus/intv/rom.h b/src/devices/bus/intv/rom.h index 5266220e1ec..485bf8cb472 100644 --- a/src/devices/bus/intv/rom.h +++ b/src/devices/bus/intv/rom.h @@ -13,7 +13,7 @@ class intv_rom_device : public device_t, { public: // construction/destruction - intv_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + intv_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_rom04(offs_t offset) override { return INTV_ROM16_READ(offset + 0x0400); } @@ -33,7 +33,7 @@ public: virtual uint16_t read_romf0(offs_t offset) override { return INTV_ROM16_READ(offset + 0xf000); } protected: - intv_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + intv_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override {} @@ -46,7 +46,7 @@ class intv_ram_device : public intv_rom_device { public: // construction/destruction - intv_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + intv_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_ram(offs_t offset) override { return (int)m_ram[offset & (m_ram.size() - 1)]; } @@ -59,7 +59,7 @@ class intv_gfact_device : public intv_rom_device { public: // construction/destruction - intv_gfact_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + intv_gfact_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_ram(offs_t offset) override { return (int)m_ram[offset & (m_ram.size() - 1)]; } @@ -72,7 +72,7 @@ class intv_wsmlb_device : public intv_rom_device { public: // construction/destruction - intv_wsmlb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + intv_wsmlb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/intv/slot.cpp b/src/devices/bus/intv/slot.cpp index 97d5b9ee308..061fdc9d311 100644 --- a/src/devices/bus/intv/slot.cpp +++ b/src/devices/bus/intv/slot.cpp @@ -144,7 +144,7 @@ void device_intv_cart_interface::ram_alloc(uint32_t size) //------------------------------------------------- // intv_cart_slot_device - constructor //------------------------------------------------- -intv_cart_slot_device::intv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +intv_cart_slot_device::intv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTV_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_intv_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/intv/slot.h b/src/devices/bus/intv/slot.h index 4e4bc130730..54c419e3ff0 100644 --- a/src/devices/bus/intv/slot.h +++ b/src/devices/bus/intv/slot.h @@ -100,7 +100,7 @@ public: // construction/destruction template <typename T> intv_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : intv_cart_slot_device(mconfig, tag, owner, 0) + : intv_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -108,7 +108,7 @@ public: set_fixed(false); } - intv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + intv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~intv_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/intv/voice.cpp b/src/devices/bus/intv/voice.cpp index 8f5e542b0e2..e5c825f7855 100644 --- a/src/devices/bus/intv/voice.cpp +++ b/src/devices/bus/intv/voice.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(INTV_ROM_VOICE, intv_voice_device, "intv_voice", "Intellivision Intellivoice Expansion") -intv_voice_device::intv_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intv_voice_device::intv_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intv_rom_device(mconfig, INTV_ROM_VOICE, tag, owner, clock), m_speech(*this, "sp0256_speech"), m_subslot(*this, "subslot"), @@ -73,7 +73,7 @@ void intv_voice_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "mono_voice").front_center(); - SP0256(config, m_speech, 3120000); + SP0256(config, m_speech, XTAL::u(3120000)); /* The Intellivoice uses a speaker with its own volume control so the relative volumes to use are subjective */ m_speech->add_route(ALL_OUTPUTS, "mono_voice", 1.00); diff --git a/src/devices/bus/intv/voice.h b/src/devices/bus/intv/voice.h index 7369058c435..b9262b718b8 100644 --- a/src/devices/bus/intv/voice.h +++ b/src/devices/bus/intv/voice.h @@ -14,7 +14,7 @@ class intv_voice_device : public intv_rom_device { public: // construction/destruction - intv_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + intv_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing // actual IntelliVoice access diff --git a/src/devices/bus/intv_ctrl/ctrl.cpp b/src/devices/bus/intv_ctrl/ctrl.cpp index 287789296a9..2ab75c508c6 100644 --- a/src/devices/bus/intv_ctrl/ctrl.cpp +++ b/src/devices/bus/intv_ctrl/ctrl.cpp @@ -51,7 +51,7 @@ device_intv_control_port_interface::~device_intv_control_port_interface() // intv_control_port_device - constructor //------------------------------------------------- -intv_control_port_device::intv_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +intv_control_port_device::intv_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTV_CONTROL_PORT, tag, owner, clock), device_single_card_slot_interface<device_intv_control_port_interface>(mconfig, *this), m_device(nullptr) diff --git a/src/devices/bus/intv_ctrl/ctrl.h b/src/devices/bus/intv_ctrl/ctrl.h index b68d6bbba7d..e69fc0dcfe3 100644 --- a/src/devices/bus/intv_ctrl/ctrl.h +++ b/src/devices/bus/intv_ctrl/ctrl.h @@ -42,7 +42,7 @@ public: // construction/destruction template <typename T> intv_control_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : intv_control_port_device(mconfig, tag, owner, 0) + : intv_control_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -50,7 +50,7 @@ public: set_fixed(false); } - intv_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + intv_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~intv_control_port_device(); uint8_t ctrl_r() { return m_device ? m_device->read_ctrl() : 0; } diff --git a/src/devices/bus/intv_ctrl/ecs_ctrl.cpp b/src/devices/bus/intv_ctrl/ecs_ctrl.cpp index ef873489015..de584b8c884 100644 --- a/src/devices/bus/intv_ctrl/ecs_ctrl.cpp +++ b/src/devices/bus/intv_ctrl/ecs_ctrl.cpp @@ -65,7 +65,7 @@ device_intvecs_control_port_interface::~device_intvecs_control_port_interface() // intvecs_control_port_device - constructor //------------------------------------------------- -intvecs_control_port_device::intvecs_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +intvecs_control_port_device::intvecs_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTVECS_CONTROL_PORT, tag, owner, clock), device_single_card_slot_interface<device_intvecs_control_port_interface>(mconfig, *this), m_device(nullptr) @@ -130,7 +130,7 @@ void intvecs_ctrls_device::device_add_mconfig(machine_config &config) } -intvecs_ctrls_device::intvecs_ctrls_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +intvecs_ctrls_device::intvecs_ctrls_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ECS_CTRLS, tag, owner, clock), device_intvecs_control_port_interface(mconfig, *this), m_hand1(*this, "port1"), @@ -256,7 +256,7 @@ ioport_constructor intvecs_keybd_device::device_input_ports() const return INPUT_PORTS_NAME( intvecs_keybd ); } -intvecs_keybd_device::intvecs_keybd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intvecs_keybd_device::intvecs_keybd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ECS_KEYBD, tag, owner, clock) , device_intvecs_control_port_interface(mconfig, *this) , m_keybd(*this, "ROW.%u", 0) @@ -389,7 +389,7 @@ ioport_constructor intvecs_synth_device::device_input_ports() const } -intvecs_synth_device::intvecs_synth_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +intvecs_synth_device::intvecs_synth_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ECS_SYNTH, tag, owner, clock), device_intvecs_control_port_interface(mconfig, *this), m_synth(*this, "SYNTH.%u", 0) diff --git a/src/devices/bus/intv_ctrl/ecs_ctrl.h b/src/devices/bus/intv_ctrl/ecs_ctrl.h index 77fdfc72a92..6cd18cdf73d 100644 --- a/src/devices/bus/intv_ctrl/ecs_ctrl.h +++ b/src/devices/bus/intv_ctrl/ecs_ctrl.h @@ -47,7 +47,7 @@ public: // construction/destruction template <typename T> intvecs_control_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : intvecs_control_port_device(mconfig, tag, owner, 0) + : intvecs_control_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -55,7 +55,7 @@ public: set_fixed(false); } - intvecs_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + intvecs_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~intvecs_control_port_device(); uint8_t porta_r() { return m_device ? m_device->read_portA() : 0; } @@ -88,7 +88,7 @@ class intvecs_ctrls_device : public device_t, { public: // construction/destruction - intvecs_ctrls_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + intvecs_ctrls_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -113,7 +113,7 @@ class intvecs_keybd_device : public device_t, { public: // construction/destruction - intvecs_keybd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + intvecs_keybd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; @@ -138,7 +138,7 @@ class intvecs_synth_device : public device_t, { public: // construction/destruction - intvecs_synth_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + intvecs_synth_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/intv_ctrl/handctrl.cpp b/src/devices/bus/intv_ctrl/handctrl.cpp index 43cdfad91b1..eb131ca4850 100644 --- a/src/devices/bus/intv_ctrl/handctrl.cpp +++ b/src/devices/bus/intv_ctrl/handctrl.cpp @@ -86,7 +86,7 @@ ioport_constructor intv_handctrl_device::device_input_ports() const // intv_handctrl_device - constructor //------------------------------------------------- -intv_handctrl_device::intv_handctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +intv_handctrl_device::intv_handctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INTV_HANDCTRL, tag, owner, clock), device_intv_control_port_interface(mconfig, *this), m_cfg(*this, "OPTIONS"), diff --git a/src/devices/bus/intv_ctrl/handctrl.h b/src/devices/bus/intv_ctrl/handctrl.h index 4aa021c1ff8..4fe312cc6ac 100644 --- a/src/devices/bus/intv_ctrl/handctrl.h +++ b/src/devices/bus/intv_ctrl/handctrl.h @@ -25,7 +25,7 @@ class intv_handctrl_device : public device_t, { public: // construction/destruction - intv_handctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + intv_handctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/iq151/disc2.cpp b/src/devices/bus/iq151/disc2.cpp index 76dfcf2ce13..eedae5a43cd 100644 --- a/src/devices/bus/iq151/disc2.cpp +++ b/src/devices/bus/iq151/disc2.cpp @@ -45,7 +45,7 @@ DEFINE_DEVICE_TYPE(IQ151_DISC2, iq151_disc2_device, "iq151_disc2", "IQ151 Disc2" // iq151_disc2_device - constructor //------------------------------------------------- -iq151_disc2_device::iq151_disc2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_disc2_device::iq151_disc2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IQ151_DISC2, tag, owner, clock) , device_iq151cart_interface(mconfig, *this) , m_fdc(*this, "fdc"), m_rom(nullptr), m_rom_enabled(false) @@ -76,7 +76,7 @@ void iq151_disc2_device::device_reset() void iq151_disc2_device::device_add_mconfig(machine_config &config) { - UPD765A(config, m_fdc, 8'000'000, false, true); + UPD765A(config, m_fdc, XTAL::u(8'000'000), false, true); FLOPPY_CONNECTOR(config, "fdc:1", iq151_disc2_floppies, "8sssd", iq151_disc2_device::floppy_formats); FLOPPY_CONNECTOR(config, "fdc:2", iq151_disc2_floppies, "8sssd", iq151_disc2_device::floppy_formats); } diff --git a/src/devices/bus/iq151/disc2.h b/src/devices/bus/iq151/disc2.h index 776bb9363fd..d488a68a902 100644 --- a/src/devices/bus/iq151/disc2.h +++ b/src/devices/bus/iq151/disc2.h @@ -21,7 +21,7 @@ class iq151_disc2_device : { public: // construction/destruction - iq151_disc2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_disc2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/iq151/grafik.cpp b/src/devices/bus/iq151/grafik.cpp index 497012cf2cd..ebf61a23bc5 100644 --- a/src/devices/bus/iq151/grafik.cpp +++ b/src/devices/bus/iq151/grafik.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(IQ151_GRAFIK, iq151_grafik_device, "iq151_grafik", "IQ151 gra // iq151_grafik_device - constructor //------------------------------------------------- -iq151_grafik_device::iq151_grafik_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_grafik_device::iq151_grafik_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IQ151_GRAFIK, tag, owner, clock) , device_iq151cart_interface(mconfig, *this) , m_ppi8255(*this, "ppi8255"), m_posx(0), m_posy(0), m_all(0), m_pen(0), m_fast(0), m_ev(0), m_ex(0), m_sel(0) diff --git a/src/devices/bus/iq151/grafik.h b/src/devices/bus/iq151/grafik.h index 5ac4ef42723..65edc0e43e4 100644 --- a/src/devices/bus/iq151/grafik.h +++ b/src/devices/bus/iq151/grafik.h @@ -20,7 +20,7 @@ class iq151_grafik_device : { public: // construction/destruction - iq151_grafik_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_grafik_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/iq151/iq151.cpp b/src/devices/bus/iq151/iq151.cpp index d4ad9a8a865..c0f3882042e 100644 --- a/src/devices/bus/iq151/iq151.cpp +++ b/src/devices/bus/iq151/iq151.cpp @@ -53,7 +53,7 @@ device_iq151cart_interface::~device_iq151cart_interface() //------------------------------------------------- // iq151cart_slot_device - constructor //------------------------------------------------- -iq151cart_slot_device::iq151cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151cart_slot_device::iq151cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IQ151CART_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_iq151cart_interface>(mconfig, *this) , device_cartrom_image_interface(mconfig, *this) diff --git a/src/devices/bus/iq151/iq151.h b/src/devices/bus/iq151/iq151.h index ff3992c7585..5e74c029152 100644 --- a/src/devices/bus/iq151/iq151.h +++ b/src/devices/bus/iq151/iq151.h @@ -89,7 +89,7 @@ public: // construction/destruction template <typename T> iq151cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : iq151cart_slot_device(mconfig, tag, owner, 0) + : iq151cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -97,7 +97,7 @@ public: set_fixed(false); } - iq151cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + iq151cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~iq151cart_slot_device(); template <typename T> void set_screen_tag(T &&tag) { m_screen.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/bus/iq151/minigraf.cpp b/src/devices/bus/iq151/minigraf.cpp index b3d51bdf8d3..ebb78d671ae 100644 --- a/src/devices/bus/iq151/minigraf.cpp +++ b/src/devices/bus/iq151/minigraf.cpp @@ -48,7 +48,7 @@ DEFINE_DEVICE_TYPE(IQ151_MINIGRAF, iq151_minigraf_device, "iq151_minigraf", "IQ1 // iq151_minigraf_device - constructor //------------------------------------------------- -iq151_minigraf_device::iq151_minigraf_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_minigraf_device::iq151_minigraf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IQ151_MINIGRAF, tag, owner, clock) , device_iq151cart_interface(mconfig, *this) , m_rom(nullptr), m_posx(0), m_posy(0), m_pen(0), m_control(0), m_paper(nullptr) diff --git a/src/devices/bus/iq151/minigraf.h b/src/devices/bus/iq151/minigraf.h index 16113288094..81669197a21 100644 --- a/src/devices/bus/iq151/minigraf.h +++ b/src/devices/bus/iq151/minigraf.h @@ -19,7 +19,7 @@ class iq151_minigraf_device : { public: // construction/destruction - iq151_minigraf_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_minigraf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/iq151/ms151a.cpp b/src/devices/bus/iq151/ms151a.cpp index 6b4116f3d42..6e6ec4f21b3 100644 --- a/src/devices/bus/iq151/ms151a.cpp +++ b/src/devices/bus/iq151/ms151a.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(IQ151_MS151A, iq151_ms151a_device, "iq151_ms15a", "IQ151 MS15 // iq151_ms151a_device - constructor //------------------------------------------------- -iq151_ms151a_device::iq151_ms151a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_ms151a_device::iq151_ms151a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IQ151_MS151A, tag, owner, clock) , device_iq151cart_interface(mconfig, *this) , m_rom(nullptr), m_posx(0), m_posy(0), m_pen(0), m_paper(nullptr) diff --git a/src/devices/bus/iq151/ms151a.h b/src/devices/bus/iq151/ms151a.h index 735729b15f1..89d4e3954fa 100644 --- a/src/devices/bus/iq151/ms151a.h +++ b/src/devices/bus/iq151/ms151a.h @@ -19,7 +19,7 @@ class iq151_ms151a_device : { public: // construction/destruction - iq151_ms151a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_ms151a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/iq151/rom.cpp b/src/devices/bus/iq151/rom.cpp index 94658c100db..41927f4bb75 100644 --- a/src/devices/bus/iq151/rom.cpp +++ b/src/devices/bus/iq151/rom.cpp @@ -41,7 +41,7 @@ DEFINE_DEVICE_TYPE(IQ151_AMOS3, iq151_amos3_device, "iq151_amos3", "IQ151 AMO // iq151_rom_device - constructor //------------------------------------------------- -iq151_rom_device::iq151_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +iq151_rom_device::iq151_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_iq151cart_interface(mconfig, *this), m_rom(*this, "rom") @@ -83,7 +83,7 @@ uint8_t* iq151_rom_device::get_cart_base() // iq151_basic6_device - constructor //------------------------------------------------- -iq151_basic6_device::iq151_basic6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_basic6_device::iq151_basic6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : iq151_rom_device(mconfig, IQ151_BASIC6, tag, owner, clock) { } @@ -108,7 +108,7 @@ void iq151_basic6_device::read(offs_t offset, uint8_t &data) // iq151_basicg_device - constructor //------------------------------------------------- -iq151_basicg_device::iq151_basicg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_basicg_device::iq151_basicg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : iq151_rom_device(mconfig, IQ151_BASICG, tag, owner, clock) { } @@ -134,7 +134,7 @@ void iq151_basicg_device::read(offs_t offset, uint8_t &data) // iq151_amos1_device - constructor //------------------------------------------------- -iq151_amos1_device::iq151_amos1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_amos1_device::iq151_amos1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : iq151_rom_device(mconfig, IQ151_AMOS1, tag, owner, clock) , m_active(true) { @@ -168,7 +168,7 @@ void iq151_amos1_device::io_write(offs_t offset, uint8_t data) // iq151_amos2_device - constructor //------------------------------------------------- -iq151_amos2_device::iq151_amos2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_amos2_device::iq151_amos2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : iq151_rom_device(mconfig, IQ151_AMOS2, tag, owner, clock) , m_active(false) { @@ -202,7 +202,7 @@ void iq151_amos2_device::io_write(offs_t offset, uint8_t data) // iq151_amos3_device - constructor //------------------------------------------------- -iq151_amos3_device::iq151_amos3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_amos3_device::iq151_amos3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : iq151_rom_device(mconfig, IQ151_AMOS3, tag, owner, clock) , m_active(true) { diff --git a/src/devices/bus/iq151/rom.h b/src/devices/bus/iq151/rom.h index 56544a24d9f..af727ffd216 100644 --- a/src/devices/bus/iq151/rom.h +++ b/src/devices/bus/iq151/rom.h @@ -24,7 +24,7 @@ public: protected: // construction/destruction - iq151_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + iq151_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -43,7 +43,7 @@ class iq151_basic6_device : { public: // construction/destruction - iq151_basic6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_basic6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // iq151cart_interface overrides @@ -57,7 +57,7 @@ class iq151_basicg_device : { public: // construction/destruction - iq151_basicg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_basicg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // iq151cart_interface overrides @@ -72,7 +72,7 @@ class iq151_amos1_device : { public: // construction/destruction - iq151_amos1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_amos1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // iq151cart_interface overrides @@ -90,7 +90,7 @@ class iq151_amos2_device : { public: // construction/destruction - iq151_amos2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_amos2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // iq151cart_interface overrides @@ -108,7 +108,7 @@ class iq151_amos3_device : { public: // construction/destruction - iq151_amos3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_amos3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // iq151cart_interface overrides diff --git a/src/devices/bus/iq151/staper.cpp b/src/devices/bus/iq151/staper.cpp index 63a365282d0..60cb78bff5d 100644 --- a/src/devices/bus/iq151/staper.cpp +++ b/src/devices/bus/iq151/staper.cpp @@ -36,7 +36,7 @@ DEFINE_DEVICE_TYPE(IQ151_STAPER, iq151_staper_device, "iq151_staper", "IQ151 STA // iq151_staper_device - constructor //------------------------------------------------- -iq151_staper_device::iq151_staper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_staper_device::iq151_staper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IQ151_STAPER, tag, owner, clock) , device_iq151cart_interface(mconfig, *this) , m_ppi(*this, "ppi8255") @@ -74,7 +74,7 @@ void iq151_staper_device::device_add_mconfig(machine_config &config) m_ppi->out_pb_callback().set(FUNC(iq151_staper_device::ppi_portb_w)); m_ppi->out_pc_callback().set(FUNC(iq151_staper_device::ppi_portc_w)); - PRINTER(config, "printer", 0); + PRINTER(config, "printer"); } //------------------------------------------------- diff --git a/src/devices/bus/iq151/staper.h b/src/devices/bus/iq151/staper.h index 98aefb609d1..8820428d580 100644 --- a/src/devices/bus/iq151/staper.h +++ b/src/devices/bus/iq151/staper.h @@ -21,7 +21,7 @@ class iq151_staper_device : { public: // construction/destruction - iq151_staper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_staper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/iq151/video32.cpp b/src/devices/bus/iq151/video32.cpp index 2d3f75b66ed..66d3089fb67 100644 --- a/src/devices/bus/iq151/video32.cpp +++ b/src/devices/bus/iq151/video32.cpp @@ -51,7 +51,7 @@ DEFINE_DEVICE_TYPE(IQ151_VIDEO32, iq151_video32_device, "iq151_video32", "IQ151 // iq151_video32_device - constructor //------------------------------------------------- -iq151_video32_device::iq151_video32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_video32_device::iq151_video32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IQ151_VIDEO32, tag, owner, clock) , device_gfx_interface(mconfig, *this, nullptr, "^^palette") , device_iq151cart_interface(mconfig, *this) diff --git a/src/devices/bus/iq151/video32.h b/src/devices/bus/iq151/video32.h index 9dc32765f6b..1625f8cdd56 100644 --- a/src/devices/bus/iq151/video32.h +++ b/src/devices/bus/iq151/video32.h @@ -20,7 +20,7 @@ class iq151_video32_device : { public: // construction/destruction - iq151_video32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_video32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/iq151/video64.cpp b/src/devices/bus/iq151/video64.cpp index 487bf63ca33..ab009f1a63e 100644 --- a/src/devices/bus/iq151/video64.cpp +++ b/src/devices/bus/iq151/video64.cpp @@ -52,7 +52,7 @@ DEFINE_DEVICE_TYPE(IQ151_VIDEO64, iq151_video64_device, "iq151_video64", "IQ151 // iq151_video64_device - constructor //------------------------------------------------- -iq151_video64_device::iq151_video64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iq151_video64_device::iq151_video64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IQ151_VIDEO64, tag, owner, clock) , device_gfx_interface(mconfig, *this, nullptr, "^^palette") , device_iq151cart_interface( mconfig, *this ) diff --git a/src/devices/bus/iq151/video64.h b/src/devices/bus/iq151/video64.h index 7b152fc8fd6..90b4c89c43d 100644 --- a/src/devices/bus/iq151/video64.h +++ b/src/devices/bus/iq151/video64.h @@ -20,7 +20,7 @@ class iq151_video64_device : { public: // construction/destruction - iq151_video64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iq151_video64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/isa/3c503.cpp b/src/devices/bus/isa/3c503.cpp index 0bf96c34f53..eeba392b7aa 100644 --- a/src/devices/bus/isa/3c503.cpp +++ b/src/devices/bus/isa/3c503.cpp @@ -7,7 +7,7 @@ void el2_3c503_device::device_add_mconfig(machine_config &config) { - DP8390D(config, m_dp8390, 0); + DP8390D(config, m_dp8390); m_dp8390->irq_callback().set(FUNC(el2_3c503_device::el2_3c503_irq_w)); m_dp8390->mem_read_callback().set(FUNC(el2_3c503_device::el2_3c503_mem_read)); m_dp8390->mem_write_callback().set(FUNC(el2_3c503_device::el2_3c503_mem_write)); @@ -15,7 +15,7 @@ void el2_3c503_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(EL2_3C503, el2_3c503_device, "el2_3c503", "3C503 Network Adapter") -el2_3c503_device::el2_3c503_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +el2_3c503_device::el2_3c503_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, EL2_3C503, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_dp8390(*this, "dp8390d") diff --git a/src/devices/bus/isa/3c503.h b/src/devices/bus/isa/3c503.h index f9597f00137..a4b8685203b 100644 --- a/src/devices/bus/isa/3c503.h +++ b/src/devices/bus/isa/3c503.h @@ -13,7 +13,7 @@ class el2_3c503_device : public device_t, public device_isa8_card_interface { public: - el2_3c503_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + el2_3c503_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t el2_3c503_loport_r(offs_t offset); void el2_3c503_loport_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/isa/3c505.cpp b/src/devices/bus/isa/3c505.cpp index a50c28b2c1b..6ed4325b597 100644 --- a/src/devices/bus/isa/3c505.cpp +++ b/src/devices/bus/isa/3c505.cpp @@ -193,7 +193,7 @@ static INPUT_PORTS_START(3c505) PORT_DIPSETTING( 0x01, DEF_STR(On)) INPUT_PORTS_END -isa16_3c505_device::isa16_3c505_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +isa16_3c505_device::isa16_3c505_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_3C505, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_cpu(*this, "cpu") diff --git a/src/devices/bus/isa/3c505.h b/src/devices/bus/isa/3c505.h index 4c1c22383a2..f4f9acc6462 100644 --- a/src/devices/bus/isa/3c505.h +++ b/src/devices/bus/isa/3c505.h @@ -17,7 +17,7 @@ class isa16_3c505_device , public device_isa16_card_interface { public: - isa16_3c505_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + isa16_3c505_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/isa/3xtwin.cpp b/src/devices/bus/isa/3xtwin.cpp index b30c83ab1ce..12310ead4a9 100644 --- a/src/devices/bus/isa/3xtwin.cpp +++ b/src/devices/bus/isa/3xtwin.cpp @@ -25,7 +25,7 @@ // device type definition DEFINE_DEVICE_TYPE(ISA8_3XTWIN, isa8_3xtwin_device, "3xtwin", "Emerald Technology 3XTwin Twinax Emulation Card") -isa8_3xtwin_device::isa8_3xtwin_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +isa8_3xtwin_device::isa8_3xtwin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_3XTWIN, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) { diff --git a/src/devices/bus/isa/3xtwin.h b/src/devices/bus/isa/3xtwin.h index cb9aeb286eb..62f86f2934d 100644 --- a/src/devices/bus/isa/3xtwin.h +++ b/src/devices/bus/isa/3xtwin.h @@ -20,7 +20,7 @@ class isa8_3xtwin_device : public device_t, public device_isa8_card_interface { public: // device type constructor - isa8_3xtwin_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + isa8_3xtwin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/acb2072.cpp b/src/devices/bus/isa/acb2072.cpp index c9d7917a114..a8022006f75 100644 --- a/src/devices/bus/isa/acb2072.cpp +++ b/src/devices/bus/isa/acb2072.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(ACB2072, acb2072_device, "acb2072", "ACB-2072 RLL Drive Controller") -acb2072_device::acb2072_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +acb2072_device::acb2072_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACB2072, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_mcu(*this, "mcu") diff --git a/src/devices/bus/isa/acb2072.h b/src/devices/bus/isa/acb2072.h index be4185400b9..26af89897d9 100644 --- a/src/devices/bus/isa/acb2072.h +++ b/src/devices/bus/isa/acb2072.h @@ -16,7 +16,7 @@ class acb2072_device : public device_t, public device_isa8_card_interface { public: - acb2072_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + acb2072_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/isa/adlib.cpp b/src/devices/bus/isa/adlib.cpp index 0f859a0ebbd..9f72e98f75b 100644 --- a/src/devices/bus/isa/adlib.cpp +++ b/src/devices/bus/isa/adlib.cpp @@ -58,7 +58,7 @@ void isa8_adlib_device::device_add_mconfig(machine_config &config) // isa8_adlib_device - constructor //------------------------------------------------- -isa8_adlib_device::isa8_adlib_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +isa8_adlib_device::isa8_adlib_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_ADLIB, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_ym3812(*this, "ym3812") diff --git a/src/devices/bus/isa/adlib.h b/src/devices/bus/isa/adlib.h index 511d0b4663c..6ab31e7c216 100644 --- a/src/devices/bus/isa/adlib.h +++ b/src/devices/bus/isa/adlib.h @@ -20,7 +20,7 @@ class isa8_adlib_device : { public: // construction/destruction - isa8_adlib_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_adlib_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t ym3812_16_r(offs_t offset); void ym3812_16_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/isa/aga.cpp b/src/devices/bus/isa/aga.cpp index 81e6ba053fe..0658b428900 100644 --- a/src/devices/bus/isa/aga.cpp +++ b/src/devices/bus/isa/aga.cpp @@ -62,12 +62,12 @@ DEFINE_DEVICE_TYPE(ISA8_AGA_PC200, isa8_aga_pc200_device, "isa_aga_pc200", "AGA // isa8_aga_device - constructor //------------------------------------------------- -isa8_aga_device::isa8_aga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_aga_device::isa8_aga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_aga_device(mconfig, ISA8_AGA, tag, owner, clock) { } -isa8_aga_device::isa8_aga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_aga_device::isa8_aga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_palette(*this, "palette"), @@ -148,7 +148,7 @@ ioport_constructor isa8_aga_device::device_input_ports() const // isa8_aga_pc200_device - constructor //------------------------------------------------- -isa8_aga_pc200_device::isa8_aga_pc200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_aga_pc200_device::isa8_aga_pc200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_aga_device(mconfig, ISA8_AGA_PC200, tag, owner, clock), m_port8(0), m_portd(0), diff --git a/src/devices/bus/isa/aga.h b/src/devices/bus/isa/aga.h index b5f986e9a34..180dbf42195 100644 --- a/src/devices/bus/isa/aga.h +++ b/src/devices/bus/isa/aga.h @@ -36,10 +36,10 @@ public: enum mode_t { AGA_OFF, AGA_COLOR, AGA_MONO }; // construction/destruction - isa8_aga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_aga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - isa8_aga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_aga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); uint8_t pc_aga_mda_r(offs_t offset); void pc_aga_mda_w(offs_t offset, uint8_t data); @@ -105,7 +105,7 @@ class isa8_aga_pc200_device : { public: // construction/destruction - isa8_aga_pc200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_aga_pc200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: uint8_t pc200_videoram_r(offs_t offset); diff --git a/src/devices/bus/isa/aha1542b.cpp b/src/devices/bus/isa/aha1542b.cpp index bba0bb76d41..15a21fd38d0 100644 --- a/src/devices/bus/isa/aha1542b.cpp +++ b/src/devices/bus/isa/aha1542b.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(AHA1542A, aha1542a_device, "aha1542a", "AHA-1542A SCSI Contro DEFINE_DEVICE_TYPE(AHA1542B, aha1542b_device, "aha1542b", "AHA-1542B SCSI Controller") -aha154x_device::aha154x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +aha154x_device::aha154x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_localcpu(*this, "localcpu") @@ -33,12 +33,12 @@ aha154x_device::aha154x_device(const machine_config &mconfig, device_type type, { } -aha1542a_device::aha1542a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +aha1542a_device::aha1542a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aha154x_device(mconfig, AHA1542A, tag, owner, clock) { } -aha1542b_device::aha1542b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +aha1542b_device::aha1542b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aha154x_device(mconfig, AHA1542B, tag, owner, clock) , m_busaic(*this, "busaic") { diff --git a/src/devices/bus/isa/aha1542b.h b/src/devices/bus/isa/aha1542b.h index c46f456bfe9..1673fb03ef7 100644 --- a/src/devices/bus/isa/aha1542b.h +++ b/src/devices/bus/isa/aha1542b.h @@ -19,7 +19,7 @@ class aha154x_device : public device_t, public device_isa16_card_interface { protected: - aha154x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + aha154x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -37,7 +37,7 @@ protected: class aha1542a_device : public aha154x_device { public: - aha1542a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + aha1542a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } @@ -61,7 +61,7 @@ private: class aha1542b_device : public aha154x_device { public: - aha1542b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + aha1542b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/isa/aha1542c.cpp b/src/devices/bus/isa/aha1542c.cpp index 34e716647ac..9fb169d4b57 100644 --- a/src/devices/bus/isa/aha1542c.cpp +++ b/src/devices/bus/isa/aha1542c.cpp @@ -344,7 +344,7 @@ const tiny_rom_entry *aha1542cp_device::device_rom_region() const void aha1542c_device::device_add_mconfig(machine_config &config) { - z80_device &cpu(Z80(config, Z84C0010_TAG, 10'000'000)); + z80_device &cpu(Z80(config, Z84C0010_TAG, XTAL::u(10'000'000))); cpu.set_addrmap(AS_PROGRAM, &aha1542c_device::z84c0010_mem); EEPROM_93C46_16BIT(config, m_eeprom); @@ -352,30 +352,30 @@ void aha1542c_device::device_add_mconfig(machine_config &config) void aha1542cp_device::device_add_mconfig(machine_config &config) { - z80_device &cpu(Z80(config, Z84C0010_TAG, 10'000'000)); + z80_device &cpu(Z80(config, Z84C0010_TAG, XTAL::u(10'000'000))); cpu.set_addrmap(AS_PROGRAM, &aha1542cp_device::local_mem); EEPROM_93C46_16BIT(config, m_eeprom); } -aha1542c_device::aha1542c_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +aha1542c_device::aha1542c_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_eeprom(*this, "eeprom") { } -aha1542c_device::aha1542c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +aha1542c_device::aha1542c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aha1542c_device(mconfig, AHA1542C, tag, owner, clock) { } -aha1542cf_device::aha1542cf_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +aha1542cf_device::aha1542cf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aha1542c_device(mconfig, AHA1542CF, tag, owner, clock) { } -aha1542cp_device::aha1542cp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +aha1542cp_device::aha1542cp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aha1542c_device(mconfig, AHA1542CP, tag, owner, clock) { } diff --git a/src/devices/bus/isa/aha1542c.h b/src/devices/bus/isa/aha1542c.h index 3a79fb3125f..9f3a618da47 100644 --- a/src/devices/bus/isa/aha1542c.h +++ b/src/devices/bus/isa/aha1542c.h @@ -31,13 +31,13 @@ class aha1542c_device : public device_t, public: static constexpr feature_type unemulated_features() { return feature::DISK; } // construction/destruction - aha1542c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + aha1542c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 aha1542_r(offs_t offset); void aha1542_w(offs_t offset, u8 data); protected: - aha1542c_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + aha1542c_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void local_latch_w(u8 data); @@ -62,7 +62,7 @@ class aha1542cf_device : public aha1542c_device { public: // construction/destruction - aha1542cf_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + aha1542cf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -74,7 +74,7 @@ class aha1542cp_device : public aha1542c_device { public: // construction/destruction - aha1542cp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + aha1542cp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/isa/aha174x.cpp b/src/devices/bus/isa/aha174x.cpp index 1b212fe6ae2..945566c5d1d 100644 --- a/src/devices/bus/isa/aha174x.cpp +++ b/src/devices/bus/isa/aha174x.cpp @@ -42,7 +42,7 @@ DEFINE_DEVICE_TYPE(AHA1740, aha1740_device, "aha1740", "AHA-1740 Fast SCSI Host DEFINE_DEVICE_TYPE(AHA1742A, aha1742a_device, "aha1742a", "AHA-1742A Fast SCSI Host Adapter") -aha174x_device::aha174x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +aha174x_device::aha174x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_hpc(*this, "hpc") @@ -52,12 +52,12 @@ aha174x_device::aha174x_device(const machine_config &mconfig, device_type type, { } -aha1740_device::aha1740_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +aha1740_device::aha1740_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aha174x_device(mconfig, AHA1740, tag, owner, clock) { } -aha1742a_device::aha1742a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +aha1742a_device::aha1742a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aha174x_device(mconfig, AHA1742A, tag, owner, clock) , m_fdc(*this, "fdc") { @@ -94,7 +94,7 @@ void aha1740_device::device_add_mconfig(machine_config &config) m_busaic->hrst_callback().set_inputline(m_hpc, INPUT_LINE_RESET); //m_busaic->srst_callback().set_inputline(m_hpc, hpc_device::EI_LINE); - I82355(config, "bmic", 0); + I82355(config, "bmic"); //bmic.lint_callback().set_inputline(m_hpc, hpc_device::I2_LINE); IDT7201(config, m_fifo[0]); @@ -121,7 +121,7 @@ void aha1742a_device::device_add_mconfig(machine_config &config) m_busaic->hrst_callback().set_inputline(m_hpc, INPUT_LINE_RESET); //m_busaic->srst_callback().set_inputline(m_hpc, hpc_device::EI_LINE); - I82355(config, "bmic", 0); + I82355(config, "bmic"); //bmic.lint_callback().set_inputline(m_hpc, hpc_device::I2_LINE); IDT7201(config, m_fifo[0]); diff --git a/src/devices/bus/isa/aha174x.h b/src/devices/bus/isa/aha174x.h index 1b96d78a690..f6da5d51c42 100644 --- a/src/devices/bus/isa/aha174x.h +++ b/src/devices/bus/isa/aha174x.h @@ -20,7 +20,7 @@ class aha174x_device : public device_t, public device_isa16_card_interface { protected: - aha174x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + aha174x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -36,7 +36,7 @@ protected: class aha1740_device : public aha174x_device { public: - aha1740_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + aha1740_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } @@ -48,7 +48,7 @@ protected: class aha1742a_device : public aha174x_device { public: - aha1742a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + aha1742a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/isa/asc88.cpp b/src/devices/bus/isa/asc88.cpp index 7bdb707f6a6..0eefbf7296f 100644 --- a/src/devices/bus/isa/asc88.cpp +++ b/src/devices/bus/isa/asc88.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(ASC88, asc88_device, "asc88", "ASC-88 SCSI Adapter") -asc88_device::asc88_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +asc88_device::asc88_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASC88, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_scsic(*this, "scsi:7:scsic") diff --git a/src/devices/bus/isa/asc88.h b/src/devices/bus/isa/asc88.h index 8cfdd784b98..4bfc3a50b22 100644 --- a/src/devices/bus/isa/asc88.h +++ b/src/devices/bus/isa/asc88.h @@ -19,7 +19,7 @@ class asc88_device : public device_t, public device_isa8_card_interface { public: - asc88_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + asc88_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/isa/bblue2.cpp b/src/devices/bus/isa/bblue2.cpp index ad997664cc2..f9dc8c1d772 100644 --- a/src/devices/bus/isa/bblue2.cpp +++ b/src/devices/bus/isa/bblue2.cpp @@ -163,7 +163,7 @@ INPUT_PORTS_END // isa8_adlib_device - constructor //------------------------------------------------- -isa8_babyblue2_device::isa8_babyblue2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +isa8_babyblue2_device::isa8_babyblue2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_BABYBLUE2, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_z80(*this, "z80cpu") diff --git a/src/devices/bus/isa/bblue2.h b/src/devices/bus/isa/bblue2.h index cdce099d883..de1a22645a6 100644 --- a/src/devices/bus/isa/bblue2.h +++ b/src/devices/bus/isa/bblue2.h @@ -23,7 +23,7 @@ class isa8_babyblue2_device : { public: // construction/destruction - isa8_babyblue2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_babyblue2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t z80_control_r(offs_t offset); void z80_control_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/isa/bt54x.cpp b/src/devices/bus/isa/bt54x.cpp index 1c3c4bdf3f1..d9682fc45e3 100644 --- a/src/devices/bus/isa/bt54x.cpp +++ b/src/devices/bus/isa/bt54x.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(BT542B, bt542b_device, "bt542b", "BusTek BT-542B SCSI Host Ad DEFINE_DEVICE_TYPE(BT542BH, bt542bh_device, "bt542bh", "BusLogic BT-542B SCSI Host Adapter (Rev. H)") DEFINE_DEVICE_TYPE(BT545S, bt545s_device, "bt545s", "BusLogic BT-545S Fast SCSI Host Adapter") -bt54x_device::bt54x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +bt54x_device::bt54x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_mpu(*this, "mpu") @@ -34,17 +34,17 @@ bt54x_device::bt54x_device(const machine_config &mconfig, device_type type, cons { } -bt542b_device::bt542b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +bt542b_device::bt542b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bt54x_device(mconfig, BT542B, tag, owner, clock) { } -bt542bh_device::bt542bh_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +bt542bh_device::bt542bh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bt54x_device(mconfig, BT542BH, tag, owner, clock) { } -bt545s_device::bt545s_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +bt545s_device::bt545s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bt54x_device(mconfig, BT545S, tag, owner, clock) { } @@ -89,7 +89,7 @@ void bt54x_device::fsc_config(device_t *device) void bt54x_device::fsc_base(machine_config &config) { - //ncr86c05_device &busintf(NCR86C05(config, "busintf", 0)); + //ncr86c05_device &busintf(NCR86C05(config, "busintf")); //busintf.mint_callback().set(m_mpu, FUNC(i80188_cpu_device::int1_w)); //busintf.dma_ack_callback().set("scsi:7:scsic", FUNC(ncr53cf94_device::dma_w)); @@ -111,7 +111,7 @@ void bt542b_device::device_add_mconfig(machine_config &config) I80188(config, m_mpu, 16_MHz_XTAL); m_mpu->set_addrmap(AS_PROGRAM, &bt542b_device::local_map); - //ncr86c05_device &busintf(NCR86C05(config, "busintf", 0)); + //ncr86c05_device &busintf(NCR86C05(config, "busintf")); //busintf.mint_callback().set(m_mpu, FUNC(i80188_cpu_device::int1_w)); //busintf.dma_ack_callback().set("scsi:7:scsic", FUNC(ncr53c94_device::dma_w)); diff --git a/src/devices/bus/isa/bt54x.h b/src/devices/bus/isa/bt54x.h index dfdd0009416..a5266794360 100644 --- a/src/devices/bus/isa/bt54x.h +++ b/src/devices/bus/isa/bt54x.h @@ -21,7 +21,7 @@ public: static constexpr feature_type unemulated_features() { return feature::DISK; } protected: - bt54x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + bt54x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -40,7 +40,7 @@ protected: class bt542b_device : public bt54x_device { public: - bt542b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + bt542b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -50,7 +50,7 @@ protected: class bt542bh_device : public bt54x_device { public: - bt542bh_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + bt542bh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -60,7 +60,7 @@ protected: class bt545s_device : public bt54x_device { public: - bt545s_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + bt545s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/isa/cga.cpp b/src/devices/bus/isa/cga.cpp index 77595bbbfb0..28c3628694f 100644 --- a/src/devices/bus/isa/cga.cpp +++ b/src/devices/bus/isa/cga.cpp @@ -298,12 +298,12 @@ const tiny_rom_entry *isa8_cga_device::device_rom_region() const // isa8_cga_device - constructor //------------------------------------------------- -isa8_cga_device::isa8_cga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_device::isa8_cga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_device(mconfig, ISA8_CGA, tag, owner, clock) { } -isa8_cga_device::isa8_cga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_device::isa8_cga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_crtc(*this, CGA_MC6845_NAME), m_cga_config(*this, "cga_config"), m_framecnt(0), m_mode_control(0), m_color_select(0), @@ -426,7 +426,7 @@ DEFINE_DEVICE_TYPE(ISA8_CGA_POISK2, isa8_cga_poisk2_device, "cga_poisk2", "ISA8_ // isa8_cga_poisk2_device - constructor //------------------------------------------------- -isa8_cga_poisk2_device::isa8_cga_poisk2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_poisk2_device::isa8_cga_poisk2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_device(mconfig, ISA8_CGA_POISK2, tag, owner, clock) { m_chr_gen_offset[0] = 0x0000; @@ -455,12 +455,12 @@ DEFINE_DEVICE_TYPE(ISA8_CGA_SUPERIMPOSE, isa8_cga_superimpose_device, "cga_super // isa8_cga_superimpose_device - constructor //------------------------------------------------- -isa8_cga_superimpose_device::isa8_cga_superimpose_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_superimpose_device::isa8_cga_superimpose_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_superimpose_device(mconfig, ISA8_CGA_SUPERIMPOSE, tag, owner, clock) { } -isa8_cga_superimpose_device::isa8_cga_superimpose_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_superimpose_device::isa8_cga_superimpose_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_device(mconfig, type, tag, owner, clock) { m_superimpose = true; @@ -1310,7 +1310,7 @@ const uint8_t isa8_cga_pc1512_device::mc6845_writeonce_register[31] = // isa8_cga_pc1512_device - constructor //------------------------------------------------- -isa8_cga_pc1512_device::isa8_cga_pc1512_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_pc1512_device::isa8_cga_pc1512_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_device(mconfig, ISA8_CGA_PC1512, tag, owner, clock), m_write(0), m_read(0), m_mc6845_address(0) { m_vram_size = 0x10000; @@ -1436,7 +1436,7 @@ DEFINE_DEVICE_TYPE(ISA8_WYSE700, isa8_wyse700_device, "wyse700", "Wyse 700") // isa8_wyse700_device - constructor //------------------------------------------------- -isa8_wyse700_device::isa8_wyse700_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_wyse700_device::isa8_wyse700_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_device(mconfig, ISA8_WYSE700, tag, owner, clock), m_vrambank(*this, "wy1"), m_bank_offset(0), m_bank_base(0), m_control(0) { m_vram_size = 0x20000; @@ -1535,7 +1535,7 @@ DEFINE_DEVICE_TYPE(ISA8_EC1841_0002, isa8_ec1841_0002_device, "ec1841_0002", "EC // isa8_ec1841_0002_device - constructor //------------------------------------------------- -isa8_ec1841_0002_device::isa8_ec1841_0002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_ec1841_0002_device::isa8_ec1841_0002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_device(mconfig, ISA8_EC1841_0002, tag, owner, clock), m_p3df(0) { } @@ -1645,7 +1645,7 @@ MC6845_RECONFIGURE( isa8_cga_mc1502_device::reconfigure ) // isa8_cga_mc1502_device - constructor //------------------------------------------------- -isa8_cga_mc1502_device::isa8_cga_mc1502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_mc1502_device::isa8_cga_mc1502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_device(mconfig, ISA8_CGA_MC1502, tag, owner, clock) { m_vram_size = 0x8000; @@ -1674,7 +1674,7 @@ DEFINE_DEVICE_TYPE(ISA8_CGA_ISKR1031, isa8_cga_iskr1031_device, "cga_iskr1031", // isa8_cga_iskr1031_device - constructor //------------------------------------------------- -isa8_cga_iskr1031_device::isa8_cga_iskr1031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_iskr1031_device::isa8_cga_iskr1031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_device(mconfig, ISA8_CGA_ISKR1031, tag, owner, clock) { } @@ -1699,7 +1699,7 @@ DEFINE_DEVICE_TYPE(ISA8_CGA_ISKR1030M, isa8_cga_iskr1030m_device, "cga_iskr1030m // isa8_cga_iskr1030m_device - constructor //------------------------------------------------- -isa8_cga_iskr1030m_device::isa8_cga_iskr1030m_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_iskr1030m_device::isa8_cga_iskr1030m_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_device(mconfig, ISA8_CGA_ISKR1030M, tag, owner, clock) { } @@ -1737,12 +1737,12 @@ void isa8_cga_m24_device::device_add_mconfig(machine_config &config) m_crtc->set_reconfigure_callback(FUNC(isa8_cga_m24_device::reconfigure)); } -isa8_cga_m24_device::isa8_cga_m24_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_m24_device::isa8_cga_m24_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_m24_device(mconfig, ISA8_CGA_M24, tag, owner, clock) { } -isa8_cga_m24_device::isa8_cga_m24_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_m24_device::isa8_cga_m24_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_device(mconfig, type, tag, owner, clock), m_mode2(0), m_index(0) { m_vram_size = 0x8000; @@ -1930,7 +1930,7 @@ void isa8_cga_cportiii_device::device_add_mconfig(machine_config &config) subdevice<screen_device>(CGA_SCREEN_NAME)->set_color(rgb_t(255, 125, 0)); } -isa8_cga_cportiii_device::isa8_cga_cportiii_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_cga_cportiii_device::isa8_cga_cportiii_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_cga_m24_device(mconfig, ISA8_CGA_CPORTIII, tag, owner, clock) { } diff --git a/src/devices/bus/isa/cga.h b/src/devices/bus/isa/cga.h index 029dc35095f..a9978e1e338 100644 --- a/src/devices/bus/isa/cga.h +++ b/src/devices/bus/isa/cga.h @@ -29,7 +29,7 @@ class isa8_cga_device : public: static constexpr feature_type imperfect_features() { return feature::GRAPHICS; } // construction/destruction - isa8_cga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual MC6845_UPDATE_ROW( crtc_update_row ); template<bool blink, bool si, bool comp, bool alt, int width> MC6845_UPDATE_ROW( cga_text ); @@ -39,7 +39,7 @@ public: MC6845_UPDATE_ROW( cga_gfx_1bpp_update_row ); protected: - isa8_cga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); required_device<mc6845_device> m_crtc; required_ioport m_cga_config; @@ -103,9 +103,9 @@ class isa8_cga_superimpose_device : { public: // construction/destruction - isa8_cga_superimpose_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_superimpose_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - isa8_cga_superimpose_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_superimpose_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition @@ -119,7 +119,7 @@ class isa8_cga_poisk2_device : { public: // construction/destruction - isa8_cga_poisk2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_poisk2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; }; @@ -135,7 +135,7 @@ class isa8_cga_pc1512_device : { public: // construction/destruction - isa8_cga_pc1512_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_pc1512_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; virtual const tiny_rom_entry *device_rom_region() const override; @@ -177,7 +177,7 @@ class isa8_wyse700_device : { public: // construction/destruction - isa8_wyse700_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_wyse700_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -208,7 +208,7 @@ class isa8_ec1841_0002_device : { public: // construction/destruction - isa8_ec1841_0002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_ec1841_0002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -234,7 +234,7 @@ class isa8_cga_iskr1030m_device : { public: // construction/destruction - isa8_cga_iskr1030m_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_iskr1030m_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; @@ -248,7 +248,7 @@ class isa8_cga_iskr1031_device : { public: // construction/destruction - isa8_cga_iskr1031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_iskr1031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; @@ -262,7 +262,7 @@ class isa8_cga_mc1502_device : { public: // construction/destruction - isa8_cga_mc1502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_mc1502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; virtual const tiny_rom_entry *device_rom_region() const override; @@ -279,7 +279,7 @@ class isa8_cga_m24_device : { public: // construction/destruction - isa8_cga_m24_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_m24_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t io_read(offs_t offset) override; virtual void io_write(offs_t offset, uint8_t data) override; virtual MC6845_UPDATE_ROW( crtc_update_row ) override; @@ -287,7 +287,7 @@ public: MC6845_RECONFIGURE(reconfigure); protected: - isa8_cga_m24_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_m24_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_reset() override; // optional information overrides virtual void device_add_mconfig(machine_config &config) override; @@ -302,7 +302,7 @@ class isa8_cga_cportiii_device : public isa8_cga_m24_device { public: - isa8_cga_cportiii_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_cga_cportiii_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t port_13c6_r(); void port_13c6_w(uint8_t data); uint8_t port_23c6_r(); diff --git a/src/devices/bus/isa/chessmdr.cpp b/src/devices/bus/isa/chessmdr.cpp index b1035945761..326f90c361c 100644 --- a/src/devices/bus/isa/chessmdr.cpp +++ b/src/devices/bus/isa/chessmdr.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(ISA8_CHESSMDR, isa8_chessmdr_device, "isa_chessmdr", "The Che // constructor //------------------------------------------------- -isa8_chessmdr_device::isa8_chessmdr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_chessmdr_device::isa8_chessmdr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_CHESSMDR, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_chessm(*this, "chessm") @@ -97,7 +97,7 @@ ioport_constructor isa8_chessmdr_device::device_input_ports() const void isa8_chessmdr_device::device_add_mconfig(machine_config &config) { - CHESSMACHINE(config, m_chessm, 15'000'000); + CHESSMACHINE(config, m_chessm, XTAL::u(15'000'000)); } diff --git a/src/devices/bus/isa/chessmdr.h b/src/devices/bus/isa/chessmdr.h index 9f5d1bf270f..1efde0ede38 100644 --- a/src/devices/bus/isa/chessmdr.h +++ b/src/devices/bus/isa/chessmdr.h @@ -21,7 +21,7 @@ class isa8_chessmdr_device : { public: // construction/destruction - isa8_chessmdr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_chessmdr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/chessmsr.cpp b/src/devices/bus/isa/chessmsr.cpp index f466f392227..1a7681d64cc 100644 --- a/src/devices/bus/isa/chessmsr.cpp +++ b/src/devices/bus/isa/chessmsr.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(ISA8_CHESSMSR, isa8_chessmsr_device, "isa_chessmsr", "The Che // constructor //------------------------------------------------- -isa8_chessmsr_device::isa8_chessmsr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_chessmsr_device::isa8_chessmsr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_CHESSMSR, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_maincpu(*this, "maincpu"), diff --git a/src/devices/bus/isa/chessmsr.h b/src/devices/bus/isa/chessmsr.h index 6d4becc4b64..b8f86cc3bfe 100644 --- a/src/devices/bus/isa/chessmsr.h +++ b/src/devices/bus/isa/chessmsr.h @@ -22,7 +22,7 @@ class isa8_chessmsr_device : { public: // construction/destruction - isa8_chessmsr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_chessmsr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/cl_sh260.cpp b/src/devices/bus/isa/cl_sh260.cpp index a06b7b625a6..f33971fbac1 100644 --- a/src/devices/bus/isa/cl_sh260.cpp +++ b/src/devices/bus/isa/cl_sh260.cpp @@ -16,19 +16,19 @@ DEFINE_DEVICE_TYPE(EV346, isa16_ev346_device, "ev346", "Everex EV-346 disk controller") DEFINE_DEVICE_TYPE(JC1310, isa16_jc1310_device, "jc1310", "Joincom JC-1310 disk controller") -isa16_cl_sh260_device::isa16_cl_sh260_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +isa16_cl_sh260_device::isa16_cl_sh260_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_fdc(*this, "fdc") { } -isa16_ev346_device::isa16_ev346_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +isa16_ev346_device::isa16_ev346_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa16_cl_sh260_device(mconfig, EV346, tag, owner, clock) { } -isa16_jc1310_device::isa16_jc1310_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +isa16_jc1310_device::isa16_jc1310_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa16_cl_sh260_device(mconfig, JC1310, tag, owner, clock) { } diff --git a/src/devices/bus/isa/cl_sh260.h b/src/devices/bus/isa/cl_sh260.h index 18612ab6456..cbe94a6c0a4 100644 --- a/src/devices/bus/isa/cl_sh260.h +++ b/src/devices/bus/isa/cl_sh260.h @@ -19,7 +19,7 @@ class isa16_cl_sh260_device : public device_t, public device_isa16_card_interface { protected: - isa16_cl_sh260_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + isa16_cl_sh260_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -31,7 +31,7 @@ protected: class isa16_ev346_device : public isa16_cl_sh260_device { public: - isa16_ev346_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + isa16_ev346_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } @@ -46,7 +46,7 @@ private: class isa16_jc1310_device : public isa16_cl_sh260_device { public: - isa16_jc1310_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + isa16_jc1310_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/isa/com.cpp b/src/devices/bus/isa/com.cpp index 4a1cc1ebd00..2af209675a2 100644 --- a/src/devices/bus/isa/com.cpp +++ b/src/devices/bus/isa/com.cpp @@ -99,12 +99,12 @@ void isa8_com_device::device_add_mconfig(machine_config &config) // isa8_com_device - constructor //------------------------------------------------- -isa8_com_device::isa8_com_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_com_device::isa8_com_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_com_device(mconfig, ISA8_COM, tag, owner, clock) { } -isa8_com_device::isa8_com_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_com_device::isa8_com_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this) { @@ -187,7 +187,7 @@ void isa8_com_at_device::device_add_mconfig(machine_config &config) // isa8_com_device - constructor //------------------------------------------------- -isa8_com_at_device::isa8_com_at_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_com_at_device::isa8_com_at_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_com_device(mconfig, ISA8_COM_AT, tag, owner, clock) { } diff --git a/src/devices/bus/isa/com.h b/src/devices/bus/isa/com.h index ff7b5e4eef8..433d38cf583 100644 --- a/src/devices/bus/isa/com.h +++ b/src/devices/bus/isa/com.h @@ -20,13 +20,13 @@ class isa8_com_device : { public: // construction/destruction - isa8_com_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_com_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(pc_com_interrupt_1) { m_isa->irq4_w(state); } DECLARE_WRITE_LINE_MEMBER(pc_com_interrupt_2) { m_isa->irq3_w(state); } protected: - isa8_com_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_com_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -47,7 +47,7 @@ class isa8_com_at_device : { public: // construction/destruction - isa8_com_at_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_com_at_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/isa/dcb.cpp b/src/devices/bus/isa/dcb.cpp index db5768d6758..902b219cd7b 100644 --- a/src/devices/bus/isa/dcb.cpp +++ b/src/devices/bus/isa/dcb.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(NOVELL_DCB, novell_dcb_device, "novell_dcb", "Novell Disk Coprocessor Board (#738-133-001)") -novell_dcb_device::novell_dcb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +novell_dcb_device::novell_dcb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NOVELL_DCB, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_localcpu(*this, "localcpu") diff --git a/src/devices/bus/isa/dcb.h b/src/devices/bus/isa/dcb.h index fbca0303978..4fdf8809bf5 100644 --- a/src/devices/bus/isa/dcb.h +++ b/src/devices/bus/isa/dcb.h @@ -18,7 +18,7 @@ class novell_dcb_device : public device_t, public device_isa16_card_interface { public: - novell_dcb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + novell_dcb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/isa/dectalk.cpp b/src/devices/bus/isa/dectalk.cpp index 9312d063158..82bb547a9cd 100644 --- a/src/devices/bus/isa/dectalk.cpp +++ b/src/devices/bus/isa/dectalk.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(ISA8_DECTALK, dectalk_isa_device, "dectalk_isa", "DECTalk-PC") -dectalk_isa_device::dectalk_isa_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +dectalk_isa_device::dectalk_isa_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, ISA8_DECTALK, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_cmd(0), @@ -170,7 +170,7 @@ void dectalk_isa_device::device_add_mconfig(machine_config &config) m_dsp->bio().set(FUNC(dectalk_isa_device::bio_line_r)); SPEAKER(config, "speaker").front_center(); - DAC_12BIT_R2R(config, m_dac, 0).add_route(0, "speaker", 1.0); // unknown DAC + DAC_12BIT_R2R(config, m_dac).add_route(0, "speaker", 1.0); // unknown DAC } void dectalk_isa_device::write(offs_t offset, uint8_t data) diff --git a/src/devices/bus/isa/dectalk.h b/src/devices/bus/isa/dectalk.h index 674efa91d5d..6665df8cf4d 100644 --- a/src/devices/bus/isa/dectalk.h +++ b/src/devices/bus/isa/dectalk.h @@ -14,7 +14,7 @@ class dectalk_isa_device : public device_t, public device_isa8_card_interface { public: - dectalk_isa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dectalk_isa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/ega.cpp b/src/devices/bus/isa/ega.cpp index 1aca9ba7cb2..adc9ec21ae4 100644 --- a/src/devices/bus/isa/ega.cpp +++ b/src/devices/bus/isa/ega.cpp @@ -579,12 +579,12 @@ ioport_constructor isa8_ega_device::device_input_ports() const // isa8_ega_device - constructor //------------------------------------------------- -isa8_ega_device::isa8_ega_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_ega_device::isa8_ega_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_ega_device(mconfig, ISA8_EGA, tag, owner, clock) { } -isa8_ega_device::isa8_ega_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_ega_device::isa8_ega_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_crtc_ega(*this, EGA_CRTC_NAME), m_videoram(nullptr), m_charA(nullptr), m_charB(nullptr), diff --git a/src/devices/bus/isa/ega.h b/src/devices/bus/isa/ega.h index cea8667ba8e..32661a2f29d 100644 --- a/src/devices/bus/isa/ega.h +++ b/src/devices/bus/isa/ega.h @@ -21,7 +21,7 @@ class isa8_ega_device : { public: // construction/destruction - isa8_ega_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_ega_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); @@ -36,7 +36,7 @@ public: CRTC_EGA_PIXEL_UPDATE(pc_ega_text); protected: - isa8_ega_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_ega_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/isa/eis_hgb107x.cpp b/src/devices/bus/isa/eis_hgb107x.cpp index ed3100c3e97..8adc0365c84 100644 --- a/src/devices/bus/isa/eis_hgb107x.cpp +++ b/src/devices/bus/isa/eis_hgb107x.cpp @@ -174,12 +174,12 @@ const tiny_rom_entry *isa8_epc_mda_device::device_rom_region() const //------------------------------------------------- // isa8_epc_mda_device - constructor //------------------------------------------------- -isa8_epc_mda_device::isa8_epc_mda_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_epc_mda_device::isa8_epc_mda_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_epc_mda_device(mconfig, ISA8_EPC_MDA, tag, owner, clock) { } -isa8_epc_mda_device::isa8_epc_mda_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_epc_mda_device::isa8_epc_mda_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_crtc(*this, MC6845_NAME), diff --git a/src/devices/bus/isa/eis_hgb107x.h b/src/devices/bus/isa/eis_hgb107x.h index 6689e7db0a8..d131af39d9e 100644 --- a/src/devices/bus/isa/eis_hgb107x.h +++ b/src/devices/bus/isa/eis_hgb107x.h @@ -18,7 +18,7 @@ class isa8_epc_mda_device : public device_t, public device_isa8_card_interface { public: // construction/destruction - isa8_epc_mda_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_epc_mda_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t io_read(offs_t offset); void io_write(offs_t offset, uint8_t data); @@ -31,7 +31,7 @@ public: DECLARE_INPUT_CHANGED_MEMBER(monitor_changed); protected: - isa8_epc_mda_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_epc_mda_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/isa/eis_sad8852.cpp b/src/devices/bus/isa/eis_sad8852.cpp index d8b1fec4d87..53c171d87f5 100644 --- a/src/devices/bus/isa/eis_sad8852.cpp +++ b/src/devices/bus/isa/eis_sad8852.cpp @@ -208,7 +208,7 @@ void isa16_sad8852_device::device_add_mconfig(machine_config &config) I8274(config, "terminal", XTAL(12'000'000) / 3); // Needs verification } -isa16_sad8852_device::isa16_sad8852_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_sad8852_device::isa16_sad8852_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_SAD8852, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_sw1(*this, "SW1") diff --git a/src/devices/bus/isa/eis_sad8852.h b/src/devices/bus/isa/eis_sad8852.h index 224680c83e7..11237dcb368 100644 --- a/src/devices/bus/isa/eis_sad8852.h +++ b/src/devices/bus/isa/eis_sad8852.h @@ -13,7 +13,7 @@ class isa16_sad8852_device : { public: // construction/destruction - isa16_sad8852_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_sad8852_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t sad8852_r(offs_t offset); void sad8852_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/isa/eis_twib.cpp b/src/devices/bus/isa/eis_twib.cpp index 4ca179e5055..3292a5a0bc4 100644 --- a/src/devices/bus/isa/eis_twib.cpp +++ b/src/devices/bus/isa/eis_twib.cpp @@ -199,7 +199,7 @@ ioport_constructor isa8_eistwib_device::device_input_ports() const //------------------------------------------------- void isa8_eistwib_device::device_add_mconfig(machine_config &config) { - SDLC_LOGGER(config, m_sdlclogger, 0); // To decode the frames + SDLC_LOGGER(config, m_sdlclogger); // To decode the frames I8274(config, m_uart8274, (XTAL(14'318'181)/ 3) / 2); // Half the 4,77 MHz ISA bus CLK signal //m_uart8274->out_rtsa_callback().set([this] (int state) { m_rts = state; }); m_uart8274->out_txda_callback().set([this] (int state) { m_txd = state; m_sdlclogger->data_w(state); }); @@ -215,7 +215,7 @@ void isa8_eistwib_device::device_add_mconfig(machine_config &config) TIMER(config, "bitclock").configure_periodic(FUNC(isa8_eistwib_device::tick_bitclock), attotime::from_hz(300000)); } -isa8_eistwib_device::isa8_eistwib_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_eistwib_device::isa8_eistwib_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_EIS_TWIB, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_uart8274(*this, "terminal") diff --git a/src/devices/bus/isa/eis_twib.h b/src/devices/bus/isa/eis_twib.h index 03aa10b5544..9b66c89439b 100644 --- a/src/devices/bus/isa/eis_twib.h +++ b/src/devices/bus/isa/eis_twib.h @@ -16,7 +16,7 @@ class isa8_eistwib_device : { public: // construction/destruction - isa8_eistwib_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_eistwib_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t twib_r(offs_t offset); void twib_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/isa/ex1280.cpp b/src/devices/bus/isa/ex1280.cpp index 2d9153616e9..fa15be8434a 100644 --- a/src/devices/bus/isa/ex1280.cpp +++ b/src/devices/bus/isa/ex1280.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(ISA16_EX1280, isa16_ex1280_device, "ex1280", "Vectrix EX1280" // isa16_ex1280_device - constructor //------------------------------------------------- -isa16_ex1280_device::isa16_ex1280_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +isa16_ex1280_device::isa16_ex1280_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_EX1280, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_cpu(*this, "maincpu") @@ -64,7 +64,7 @@ void isa16_ex1280_device::main_map(address_map &map) void isa16_ex1280_device::device_add_mconfig(machine_config &config) { - TMS34010(config, m_cpu, 64000000); + TMS34010(config, m_cpu, XTAL::u(64000000)); m_cpu->set_addrmap(AS_PROGRAM, &isa16_ex1280_device::main_map); m_cpu->set_halt_on_reset(false); m_cpu->set_pixel_clock(64000000); @@ -82,7 +82,7 @@ void isa16_ex1280_device::device_add_mconfig(machine_config &config) m_screen->set_screen_update(m_cpu, FUNC(tms34010_device::tms340x0_rgb32)); m_screen->screen_vblank().set(FUNC(isa16_ex1280_device::vblank_w)); - BT451(config, m_ramdac, 0); + BT451(config, m_ramdac); } diff --git a/src/devices/bus/isa/ex1280.h b/src/devices/bus/isa/ex1280.h index a9637a1b1f6..dfc2004b0ed 100644 --- a/src/devices/bus/isa/ex1280.h +++ b/src/devices/bus/isa/ex1280.h @@ -21,7 +21,7 @@ class isa16_ex1280_device : public device_t, { public: // construction/destruction - isa16_ex1280_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_ex1280_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Flag non working features static constexpr feature_type unemulated_features() { return feature::GRAPHICS | feature::PALETTE; } diff --git a/src/devices/bus/isa/fdc.cpp b/src/devices/bus/isa/fdc.cpp index a08ec8b899a..3969ac95427 100644 --- a/src/devices/bus/isa/fdc.cpp +++ b/src/devices/bus/isa/fdc.cpp @@ -39,7 +39,7 @@ static void pc_hd_floppies(device_slot_interface &device) } -isa8_fdc_device::isa8_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_fdc_device::isa8_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_fdc(*this, "fdc") @@ -77,7 +77,7 @@ void isa8_fdc_device::eop_w(int state) } -isa8_upd765_fdc_device::isa8_upd765_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +isa8_upd765_fdc_device::isa8_upd765_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : isa8_fdc_device(mconfig, type, tag, owner, clock) , dor(0x00) { @@ -179,17 +179,17 @@ void isa8_upd765_fdc_device::check_drq() } -isa8_fdc_xt_device::isa8_fdc_xt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : isa8_fdc_xt_device(mconfig, ISA8_FDC_XT, tag, owner, clock) +isa8_fdc_xt_device::isa8_fdc_xt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_fdc_xt_device(mconfig, ISA8_FDC_XT, tag, owner, clock) { } -isa8_fdc_xt_device::isa8_fdc_xt_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : isa8_upd765_fdc_device(mconfig, type, tag, owner, clock) +isa8_fdc_xt_device::isa8_fdc_xt_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : isa8_upd765_fdc_device(mconfig, type, tag, owner, clock) { } void isa8_fdc_xt_device::device_add_mconfig(machine_config &config) { - upd765a_device &upd765a(UPD765A(config, m_fdc, 8'000'000, false, false)); + upd765a_device &upd765a(UPD765A(config, m_fdc, XTAL::u(8'000'000), false, false)); upd765a.intrq_wr_callback().set(FUNC(isa8_fdc_xt_device::fdc_irq_w)); upd765a.drq_wr_callback().set(FUNC(isa8_fdc_xt_device::fdc_drq_w)); FLOPPY_CONNECTOR(config, "fdc:0", pc_dd_floppies, "525dd", isa8_fdc_device::floppy_formats).enable_sound(true); @@ -222,13 +222,13 @@ void isa8_fdc_xt_device::dor_fifo_w(uint8_t data) } -isa8_fdc_at_device::isa8_fdc_at_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : isa8_upd765_fdc_device(mconfig, ISA8_FDC_AT, tag, owner, clock) +isa8_fdc_at_device::isa8_fdc_at_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_upd765_fdc_device(mconfig, ISA8_FDC_AT, tag, owner, clock) { } void isa8_fdc_at_device::device_add_mconfig(machine_config &config) { - upd765a_device &upd765a(UPD765A(config, m_fdc, 8'000'000, false, false)); + upd765a_device &upd765a(UPD765A(config, m_fdc, XTAL::u(8'000'000), false, false)); upd765a.intrq_wr_callback().set(FUNC(isa8_fdc_at_device::fdc_irq_w)); upd765a.drq_wr_callback().set(FUNC(isa8_fdc_at_device::fdc_drq_w)); FLOPPY_CONNECTOR(config, "fdc:0", pc_hd_floppies, "35hd", isa8_fdc_device::floppy_formats).enable_sound(true); @@ -252,13 +252,13 @@ void isa8_fdc_at_device::device_start() isa8_upd765_fdc_device::device_start(); } -isa8_fdc_smc_device::isa8_fdc_smc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : isa8_fdc_device(mconfig, ISA8_FDC_SMC, tag, owner, clock) +isa8_fdc_smc_device::isa8_fdc_smc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_fdc_device(mconfig, ISA8_FDC_SMC, tag, owner, clock) { } void isa8_fdc_smc_device::device_add_mconfig(machine_config &config) { - smc37c78_device &smc(SMC37C78(config, m_fdc, 24'000'000)); + smc37c78_device &smc(SMC37C78(config, m_fdc, XTAL::u(24'000'000))); smc.intrq_wr_callback().set(FUNC(isa8_fdc_device::irq_w)); smc.drq_wr_callback().set(FUNC(isa8_fdc_device::drq_w)); FLOPPY_CONNECTOR(config, "fdc:0", pc_hd_floppies, "35hd", isa8_fdc_device::floppy_formats).enable_sound(true); @@ -272,13 +272,13 @@ void isa8_fdc_smc_device::device_start() m_isa->set_dma_channel(2, this, true); } -isa8_fdc_ps2_device::isa8_fdc_ps2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : isa8_fdc_device(mconfig, ISA8_FDC_PS2, tag, owner, clock) +isa8_fdc_ps2_device::isa8_fdc_ps2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_fdc_device(mconfig, ISA8_FDC_PS2, tag, owner, clock) { } void isa8_fdc_ps2_device::device_add_mconfig(machine_config &config) { - n82077aa_device &n82077aa(N82077AA(config, m_fdc, 24'000'000)); + n82077aa_device &n82077aa(N82077AA(config, m_fdc, XTAL::u(24'000'000))); n82077aa.set_mode(n82077aa_device::mode_t::PS2); n82077aa.intrq_wr_callback().set(FUNC(isa8_fdc_device::irq_w)); n82077aa.drq_wr_callback().set(FUNC(isa8_fdc_device::drq_w)); @@ -293,13 +293,13 @@ void isa8_fdc_ps2_device::device_start() m_isa->set_dma_channel(2, this, true); } -isa8_fdc_superio_device::isa8_fdc_superio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : isa8_fdc_device(mconfig, ISA8_FDC_SUPERIO, tag, owner, clock) +isa8_fdc_superio_device::isa8_fdc_superio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_fdc_device(mconfig, ISA8_FDC_SUPERIO, tag, owner, clock) { } void isa8_fdc_superio_device::device_add_mconfig(machine_config &config) { - pc_fdc_superio_device &superio(PC_FDC_SUPERIO(config, m_fdc, 24'000'000)); + pc_fdc_superio_device &superio(PC_FDC_SUPERIO(config, m_fdc, XTAL::u(24'000'000))); superio.intrq_wr_callback().set(FUNC(isa8_fdc_device::irq_w)); superio.drq_wr_callback().set(FUNC(isa8_fdc_device::drq_w)); FLOPPY_CONNECTOR(config, "fdc:0", pc_hd_floppies, "35hd", isa8_fdc_device::floppy_formats).enable_sound(true); @@ -313,7 +313,7 @@ void isa8_fdc_superio_device::device_start() m_isa->set_dma_channel(2, this, true); } -isa8_ec1841_0003_device::isa8_ec1841_0003_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +isa8_ec1841_0003_device::isa8_ec1841_0003_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_fdc_xt_device(mconfig, ISA8_EC1841_0003, tag, owner, clock) , m_bus_mouse(*this, "bus_mouse") { @@ -334,7 +334,7 @@ void isa8_ec1841_0003_device::device_add_mconfig(machine_config &config) { isa8_fdc_xt_device::device_add_mconfig(config); - BUS_MOUSE(config, "bus_mouse", 0).extint_callback().set(FUNC(isa8_ec1841_0003_device::aux_irq_w)); + BUS_MOUSE(config, "bus_mouse").extint_callback().set(FUNC(isa8_ec1841_0003_device::aux_irq_w)); } diff --git a/src/devices/bus/isa/fdc.h b/src/devices/bus/isa/fdc.h index 00431ef3e5c..e287b808191 100644 --- a/src/devices/bus/isa/fdc.h +++ b/src/devices/bus/isa/fdc.h @@ -32,7 +32,7 @@ public: protected: // construction/destruction - isa8_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t dack_r(int line) override; virtual void dack_w(int line, uint8_t data) override; @@ -46,7 +46,7 @@ class isa8_upd765_fdc_device : public isa8_fdc_device { protected: // construction/destruction - isa8_upd765_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_upd765_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -72,10 +72,10 @@ private: class isa8_fdc_xt_device : public isa8_upd765_fdc_device { public: - isa8_fdc_xt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_fdc_xt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - isa8_fdc_xt_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_fdc_xt_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_add_mconfig(machine_config &config) override; @@ -87,7 +87,7 @@ protected: class isa8_fdc_at_device : public isa8_upd765_fdc_device { public: - isa8_fdc_at_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_fdc_at_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -99,7 +99,7 @@ protected: class isa8_fdc_smc_device : public isa8_fdc_device { public: - isa8_fdc_smc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_fdc_smc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -109,7 +109,7 @@ protected: class isa8_fdc_ps2_device : public isa8_fdc_device { public: - isa8_fdc_ps2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_fdc_ps2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -119,7 +119,7 @@ protected: class isa8_fdc_superio_device : public isa8_fdc_device { public: - isa8_fdc_superio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_fdc_superio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -129,7 +129,7 @@ protected: class isa8_ec1841_0003_device : public isa8_fdc_xt_device { public: - isa8_ec1841_0003_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_ec1841_0003_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/isa/finalchs.cpp b/src/devices/bus/isa/finalchs.cpp index 2ee3b169371..e643cdcc36b 100644 --- a/src/devices/bus/isa/finalchs.cpp +++ b/src/devices/bus/isa/finalchs.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(ISA8_FINALCHS, isa8_finalchs_device, "isa_finalchs", "The Fin // constructor //------------------------------------------------- -isa8_finalchs_device::isa8_finalchs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_finalchs_device::isa8_finalchs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_FINALCHS, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_maincpu(*this, "maincpu"), diff --git a/src/devices/bus/isa/finalchs.h b/src/devices/bus/isa/finalchs.h index 2b04f69ec6b..24a869c48c8 100644 --- a/src/devices/bus/isa/finalchs.h +++ b/src/devices/bus/isa/finalchs.h @@ -22,7 +22,7 @@ class isa8_finalchs_device : { public: // construction/destruction - isa8_finalchs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_finalchs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/gblaster.cpp b/src/devices/bus/isa/gblaster.cpp index 1cbd9458c04..3baa98d5518 100644 --- a/src/devices/bus/isa/gblaster.cpp +++ b/src/devices/bus/isa/gblaster.cpp @@ -88,7 +88,7 @@ void isa8_gblaster_device::device_add_mconfig(machine_config &config) // isa8_gblaster_device - constructor //------------------------------------------------- -isa8_gblaster_device::isa8_gblaster_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_gblaster_device::isa8_gblaster_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_GAME_BLASTER, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_saa1099_1(*this, "saa1099.1"), diff --git a/src/devices/bus/isa/gblaster.h b/src/devices/bus/isa/gblaster.h index 77cec10eded..2743e66732a 100644 --- a/src/devices/bus/isa/gblaster.h +++ b/src/devices/bus/isa/gblaster.h @@ -20,7 +20,7 @@ class isa8_gblaster_device : { public: // construction/destruction - isa8_gblaster_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_gblaster_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t saa1099_16_r(offs_t offset); void saa1099_1_16_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/isa/gus.cpp b/src/devices/bus/isa/gus.cpp index 7884ac37c8d..9ce6ab154cf 100644 --- a/src/devices/bus/isa/gus.cpp +++ b/src/devices/bus/isa/gus.cpp @@ -351,7 +351,7 @@ void gf1_device::sound_stream_update(sound_stream &stream, std::vector<read_stre // gf1_device - constructor //------------------------------------------------- -gf1_device::gf1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gf1_device::gf1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : acia6850_device(mconfig, GGF1, tag, owner, clock), device_sound_interface(mconfig, *this), m_dma_dram_ctrl(0), m_dma_start_addr(0), m_dram_addr(0), m_timer_ctrl(0), m_timer1_count(0), m_timer2_count(0), m_timer1_value(0), m_timer2_value(0), m_sampling_freq(0), m_sampling_ctrl(0), m_joy_trim_dac(0), m_reset(0), m_active_voices(14), m_irq_source(0), @@ -1275,7 +1275,7 @@ void isa16_gus_device::device_add_mconfig(machine_config &config) MIDI_PORT(config, "mdout", midiout_slot, "midiout"); - clock_device &acia_clock(CLOCK(config, "acia_clock", 31250*16)); + clock_device &acia_clock(CLOCK(config, "acia_clock", XTAL::u(31250*16))); acia_clock.signal_handler().set(FUNC(isa16_gus_device::write_acia_clock)); } @@ -1285,7 +1285,7 @@ ioport_constructor isa16_gus_device::device_input_ports() const } -isa16_gus_device::isa16_gus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_gus_device::isa16_gus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_GUS, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_gf1(*this, "gf1"), diff --git a/src/devices/bus/isa/gus.h b/src/devices/bus/isa/gus.h index c39695997da..0d280e755f0 100644 --- a/src/devices/bus/isa/gus.h +++ b/src/devices/bus/isa/gus.h @@ -78,7 +78,7 @@ public: }; // construction/destruction - gf1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gf1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto txirq_handler() { return m_txirq_handler.bind(); } auto rxirq_handler() { return m_rxirq_handler.bind(); } @@ -222,7 +222,7 @@ class isa16_gus_device : public device_isa16_card_interface { public: - isa16_gus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_gus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_irq(uint8_t source); void reset_irq(uint8_t source); void set_midi_irq(uint8_t source); diff --git a/src/devices/bus/isa/hdc.cpp b/src/devices/bus/isa/hdc.cpp index 74d2a23d11b..e4167d07d2a 100644 --- a/src/devices/bus/isa/hdc.cpp +++ b/src/devices/bus/isa/hdc.cpp @@ -148,13 +148,13 @@ DEFINE_DEVICE_TYPE(XT_HDC, xt_hdc_device, "xt_hdc", "Generic PC-XT Fixed Dis DEFINE_DEVICE_TYPE(EC1841_HDC, ec1841_device, "ec1481", "EX1841 Fixed Disk Controller") DEFINE_DEVICE_TYPE(ST11M_HDC, st11m_device, "st11m", "Seagate ST11M Fixed Disk Controller") -xt_hdc_device::xt_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +xt_hdc_device::xt_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : xt_hdc_device(mconfig, XT_HDC, tag, owner, clock) { m_type = STANDARD; } -xt_hdc_device::xt_hdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +xt_hdc_device::xt_hdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_buffer_ptr(nullptr), m_csb(0), @@ -176,7 +176,7 @@ xt_hdc_device::xt_hdc_device(const machine_config &mconfig, device_type type, co { } -ec1841_device::ec1841_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ec1841_device::ec1841_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : xt_hdc_device(mconfig, EC1841_HDC, tag, owner, clock), m_irq_handler(*this), m_drq_handler(*this) @@ -184,7 +184,7 @@ ec1841_device::ec1841_device(const machine_config &mconfig, const char *tag, dev m_type = EC1841; } -st11m_device::st11m_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +st11m_device::st11m_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : xt_hdc_device(mconfig, ST11M_HDC, tag, owner, clock), m_irq_handler(*this), m_drq_handler(*this) @@ -958,12 +958,12 @@ ioport_constructor isa8_hdc_device::device_input_ports() const // isa8_hdc_device - constructor //------------------------------------------------- -isa8_hdc_device::isa8_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_hdc_device::isa8_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_hdc_device(mconfig, ISA8_HDC, tag, owner, clock) { } -isa8_hdc_device::isa8_hdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_hdc_device::isa8_hdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_hdc(*this,"hdc"), @@ -971,7 +971,7 @@ isa8_hdc_device::isa8_hdc_device(const machine_config &mconfig, device_type type { } -isa8_hdc_ec1841_device::isa8_hdc_ec1841_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_hdc_ec1841_device::isa8_hdc_ec1841_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_hdc_device( mconfig, ISA8_HDC_EC1841, tag, owner, clock), m_hdc(*this,"hdc") { diff --git a/src/devices/bus/isa/hdc.h b/src/devices/bus/isa/hdc.h index 0f49d2118f9..98fa199b4ab 100644 --- a/src/devices/bus/isa/hdc.h +++ b/src/devices/bus/isa/hdc.h @@ -25,7 +25,7 @@ class xt_hdc_device : { public: // construction/destruction - xt_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xt_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_handler() { return m_irq_handler.bind(); } auto drq_handler() { return m_drq_handler.bind(); } @@ -46,7 +46,7 @@ public: bool install_rom() { return (m_type != EC1841); } protected: - xt_hdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + xt_hdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -113,7 +113,7 @@ private: class ec1841_device : public xt_hdc_device { public: - ec1841_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ec1841_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: devcb_write_line m_irq_handler; devcb_write_line m_drq_handler; @@ -122,7 +122,7 @@ protected: class st11m_device : public xt_hdc_device { public: - st11m_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + st11m_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: devcb_write_line m_irq_handler; @@ -141,14 +141,14 @@ class isa8_hdc_device : { public: // construction/destruction - isa8_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t pc_hdc_r(offs_t offset); void pc_hdc_w(offs_t offset, uint8_t data); required_device<xt_hdc_device> m_hdc; protected: - isa8_hdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_hdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -174,7 +174,7 @@ public: class isa8_hdc_ec1841_device : public isa8_hdc_device { public: - isa8_hdc_ec1841_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_hdc_ec1841_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/isa/ibm_mfc.cpp b/src/devices/bus/isa/ibm_mfc.cpp index a6dbfc81efa..40b5b2b9546 100644 --- a/src/devices/bus/isa/ibm_mfc.cpp +++ b/src/devices/bus/isa/ibm_mfc.cpp @@ -390,7 +390,7 @@ void isa8_ibm_mfc_device::device_add_mconfig(machine_config &config) m_d71055c_1->in_pb_callback().set(FUNC(isa8_ibm_mfc_device::ppi1_i_b)); m_d71055c_1->out_pc_callback().set(FUNC(isa8_ibm_mfc_device::ppi1_o_c)); - I8251(config, m_d71051, 0); + I8251(config, m_d71051); clock_device &usart_clock(CLOCK(config, "usart_clock", XTAL(4'000'000) / 8)); // 500KHz usart_clock.signal_handler().set(FUNC(isa8_ibm_mfc_device::write_usart_clock)); @@ -441,7 +441,7 @@ const tiny_rom_entry *isa8_ibm_mfc_device::device_rom_region() const // isa8_ibm_mfc_device - constructor //------------------------------------------------- -isa8_ibm_mfc_device::isa8_ibm_mfc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_ibm_mfc_device::isa8_ibm_mfc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_IBM_MFC, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_tcr(0), m_pc_ppi_c(0), m_z80_ppi_c(0), m_pc_irq_state(0), m_z80_irq_state(0), diff --git a/src/devices/bus/isa/ibm_mfc.h b/src/devices/bus/isa/ibm_mfc.h index c6efe79d0da..8cc10f9231c 100644 --- a/src/devices/bus/isa/ibm_mfc.h +++ b/src/devices/bus/isa/ibm_mfc.h @@ -29,7 +29,7 @@ class isa8_ibm_mfc_device : public device_t, { public: // Construction/destruction - isa8_ibm_mfc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_ibm_mfc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // Device-level overrides diff --git a/src/devices/bus/isa/ide.cpp b/src/devices/bus/isa/ide.cpp index 656995add4e..16c7e2a114f 100644 --- a/src/devices/bus/isa/ide.cpp +++ b/src/devices/bus/isa/ide.cpp @@ -100,7 +100,7 @@ ioport_constructor isa16_ide_device::device_input_ports() const // isa16_ide_device - constructor //------------------------------------------------- -isa16_ide_device::isa16_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +isa16_ide_device::isa16_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_IDE, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_is_primary(true) diff --git a/src/devices/bus/isa/ide.h b/src/devices/bus/isa/ide.h index 5cdccca6d90..f19afad7c96 100644 --- a/src/devices/bus/isa/ide.h +++ b/src/devices/bus/isa/ide.h @@ -19,7 +19,7 @@ class isa16_ide_device : public device_t, { public: // construction/destruction - isa16_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void cdrom_headphones(device_t *device); diff --git a/src/devices/bus/isa/isa.cpp b/src/devices/bus/isa/isa.cpp index 11aca68d0e7..3746ddb1349 100644 --- a/src/devices/bus/isa/isa.cpp +++ b/src/devices/bus/isa/isa.cpp @@ -23,12 +23,12 @@ DEFINE_DEVICE_TYPE(ISA8_SLOT, isa8_slot_device, "isa8_slot", "8-bit ISA slot") //------------------------------------------------- // isa8_slot_device - constructor //------------------------------------------------- -isa8_slot_device::isa8_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_slot_device::isa8_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_slot_device(mconfig, ISA8_SLOT, tag, owner, clock) { } -isa8_slot_device::isa8_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_slot_device::isa8_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_slot_interface(mconfig, *this), m_isa_bus(*this, finder_base::DUMMY_TAG) @@ -67,7 +67,7 @@ DEFINE_DEVICE_TYPE(ISA16_SLOT, isa16_slot_device, "isa16_slot", "16-bit ISA slot //------------------------------------------------- // isa16_slot_device - constructor //------------------------------------------------- -isa16_slot_device::isa16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_slot_device::isa16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_slot_device(mconfig, ISA16_SLOT, tag, owner, clock) { } @@ -99,12 +99,12 @@ DEFINE_DEVICE_TYPE(ISA8, isa8_device, "isa8", "8-bit ISA bus") // isa8_device - constructor //------------------------------------------------- -isa8_device::isa8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_device::isa8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_device(mconfig, ISA8, tag, owner, clock) { } -isa8_device::isa8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_device::isa8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_memory_interface(mconfig, *this), m_mem_config("mem8", ENDIANNESS_LITTLE, 8, 24, 0, address_map_constructor()), @@ -507,7 +507,7 @@ DEFINE_DEVICE_TYPE(ISA16, isa16_device, "isa16", "16-bit ISA bus") // isa16_device - constructor //------------------------------------------------- -isa16_device::isa16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_device::isa16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_device(mconfig, ISA16, tag, owner, clock), m_out_irq10_cb(*this), m_out_irq11_cb(*this), diff --git a/src/devices/bus/isa/isa.h b/src/devices/bus/isa/isa.h index 939f8d88a26..83276cf075a 100644 --- a/src/devices/bus/isa/isa.h +++ b/src/devices/bus/isa/isa.h @@ -81,8 +81,8 @@ class isa8_slot_device : public device_t, public device_slot_interface public: // construction/destruction template <typename T, typename U> - isa8_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&isa_tag, U &&opts, const char *dflt, bool fixed) - : isa8_slot_device(mconfig, tag, owner, clock) + isa8_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&isa_tag, U &&opts, const char *dflt, bool fixed) + : isa8_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -90,10 +90,10 @@ public: set_fixed(fixed); m_isa_bus.set_tag(std::forward<T>(isa_tag)); } - isa8_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: - isa8_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -120,7 +120,7 @@ public: }; // construction/destruction - isa8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration template <typename T> void set_memspace(T &&tag, int spacenum) { m_memspace.set_tag(std::forward<T>(tag), spacenum); } @@ -206,7 +206,7 @@ public: const address_space_config m_mem_config, m_io_config, m_mem16_config, m_io16_config; protected: - isa8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); template<typename R, typename W> void install_space(int spacenum, offs_t start, offs_t end, R rhandler, W whandler); @@ -286,8 +286,8 @@ class isa16_slot_device : public isa8_slot_device public: // construction/destruction template <typename T, typename U> - isa16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&isa_tag, U &&opts, const char *dflt, bool fixed) - : isa16_slot_device(mconfig, tag, owner, clock) + isa16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&isa_tag, U &&opts, const char *dflt, bool fixed) + : isa16_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -295,7 +295,7 @@ public: set_fixed(fixed); m_isa_bus.set_tag(std::forward<T>(isa_tag)); } - isa16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device-level overrides @@ -311,7 +311,7 @@ class isa16_device : public isa8_device { public: // construction/destruction - isa16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq10_callback() { return m_out_irq10_cb.bind(); } auto irq11_callback() { return m_out_irq11_cb.bind(); } diff --git a/src/devices/bus/isa/lbaenhancer.cpp b/src/devices/bus/isa/lbaenhancer.cpp index 242f1f47afe..b4b02884bde 100644 --- a/src/devices/bus/isa/lbaenhancer.cpp +++ b/src/devices/bus/isa/lbaenhancer.cpp @@ -86,7 +86,7 @@ const tiny_rom_entry *lba_enhancer_device::device_rom_region() const //------------------------------------------------- void lba_enhancer_device::device_add_mconfig(machine_config &config) { -// lba_enhancer(config, "lba_enhancer", 0); +// lba_enhancer(config, "lba_enhancer"); } @@ -143,7 +143,7 @@ void lba_enhancer_device::device_reset() // lba_enhancer_device - constructor //------------------------------------------------- -lba_enhancer_device::lba_enhancer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lba_enhancer_device::lba_enhancer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_LBA_ENHANCER, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) { diff --git a/src/devices/bus/isa/lbaenhancer.h b/src/devices/bus/isa/lbaenhancer.h index 71e36c02665..88ab460febe 100644 --- a/src/devices/bus/isa/lbaenhancer.h +++ b/src/devices/bus/isa/lbaenhancer.h @@ -22,7 +22,7 @@ class lba_enhancer_device : public device_t, { public: // construction/destruction - lba_enhancer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + lba_enhancer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/lpt.cpp b/src/devices/bus/isa/lpt.cpp index 268ff2c9caf..e7749180acb 100644 --- a/src/devices/bus/isa/lpt.cpp +++ b/src/devices/bus/isa/lpt.cpp @@ -12,7 +12,7 @@ DEFINE_DEVICE_TYPE(ISA8_LPT, isa8_lpt_device, "isa_lpt", "Printer Adapter") -isa8_lpt_device::isa8_lpt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_lpt_device::isa8_lpt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_LPT, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_is_primary(false) diff --git a/src/devices/bus/isa/lpt.h b/src/devices/bus/isa/lpt.h index 1aa2731bfaf..022360650e1 100644 --- a/src/devices/bus/isa/lpt.h +++ b/src/devices/bus/isa/lpt.h @@ -25,7 +25,7 @@ class isa8_lpt_device : public device_t, { public: // construction/destruction - isa8_lpt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_lpt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); bool is_primary() { return m_is_primary; } diff --git a/src/devices/bus/isa/lrk330.cpp b/src/devices/bus/isa/lrk330.cpp index 18cd1bfe29e..d1dd97e6011 100644 --- a/src/devices/bus/isa/lrk330.cpp +++ b/src/devices/bus/isa/lrk330.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(LRK331, lrk331_device, "lrk331", "Lark Associates LRK-331 ESDI Controller") -lrk331_device::lrk331_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +lrk331_device::lrk331_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LRK331, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_mcu(*this, "mcu") diff --git a/src/devices/bus/isa/lrk330.h b/src/devices/bus/isa/lrk330.h index b75a50fa7a3..ca2db1dfd59 100644 --- a/src/devices/bus/isa/lrk330.h +++ b/src/devices/bus/isa/lrk330.h @@ -12,7 +12,7 @@ class lrk331_device : public device_t, public device_isa16_card_interface { public: - lrk331_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + lrk331_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/isa/mach32.cpp b/src/devices/bus/isa/mach32.cpp index 064947d5c7c..daa549754a7 100644 --- a/src/devices/bus/isa/mach32.cpp +++ b/src/devices/bus/isa/mach32.cpp @@ -25,31 +25,31 @@ DEFINE_DEVICE_TYPE(ATIMACH64_8514A, mach64_8514a_device, "mach64_8514a", "ATi ma */ // 8514/A device -mach32_8514a_device::mach32_8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mach32_8514a_device::mach32_8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mach32_8514a_device(mconfig, ATIMACH32_8514A, tag, owner, clock) { } -mach32_8514a_device::mach32_8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mach32_8514a_device::mach32_8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : mach8_device(mconfig, type, tag, owner, clock), m_chip_ID(0), m_membounds(0) { } // SVGA device -mach32_device::mach32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mach32_device::mach32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mach32_device(mconfig, ATIMACH32, tag, owner, clock) { } -mach32_device::mach32_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mach32_device::mach32_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ati_vga_device(mconfig, type, tag, owner, clock), m_8514a(*this,"8514a") { } void mach32_device::device_add_mconfig(machine_config &config) { - ATIMACH32_8514A(config, "8514a", 0).set_vga(DEVICE_SELF); + ATIMACH32_8514A(config, "8514a").set_vga(DEVICE_SELF); EEPROM_93C56_16BIT(config, "ati_eeprom"); } @@ -304,31 +304,31 @@ void mach32_device::mach32_cursor_offset_w(offs_t offset, uint16_t data, uint16_ */ // 8514/A device -mach64_8514a_device::mach64_8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mach64_8514a_device::mach64_8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mach64_8514a_device(mconfig, ATIMACH64_8514A, tag, owner, clock) { } -mach64_8514a_device::mach64_8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mach64_8514a_device::mach64_8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : mach32_8514a_device(mconfig, type, tag, owner, clock) { } // SVGA device -mach64_device::mach64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mach64_device::mach64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mach64_device(mconfig, ATIMACH64, tag, owner, clock) { } -mach64_device::mach64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mach64_device::mach64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : mach32_device(mconfig, type, tag, owner, clock), m_8514a(*this, "8514a") { } void mach64_device::device_add_mconfig(machine_config &config) { - ATIMACH64_8514A(config, "8514a", 0).set_vga(DEVICE_SELF); + ATIMACH64_8514A(config, "8514a").set_vga(DEVICE_SELF); EEPROM_93C56_16BIT(config, "ati_eeprom"); } diff --git a/src/devices/bus/isa/mach32.h b/src/devices/bus/isa/mach32.h index 38b4f673530..70a705e8db5 100644 --- a/src/devices/bus/isa/mach32.h +++ b/src/devices/bus/isa/mach32.h @@ -21,7 +21,7 @@ class mach32_8514a_device : public mach8_device { public: // construction/destruction - mach32_8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mach32_8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t mach32_chipid_r() { return m_chip_ID; } uint16_t mach32_mem_boundary_r() { return m_membounds; } @@ -35,7 +35,7 @@ public: bool has_display_mode_changed() { if(display_mode_change) { display_mode_change = false; return true; } else return false; } protected: - mach32_8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mach32_8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -51,7 +51,7 @@ class mach32_device : public ati_vga_device { public: // construction/destruction - mach32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mach32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) override; required_device<mach32_8514a_device> m_8514a; // provides accelerated 2D drawing, derived from the Mach8 device @@ -160,7 +160,7 @@ public: void mach32_cursor_offset_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); protected: - mach32_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mach32_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -194,10 +194,10 @@ class mach64_8514a_device : public mach32_8514a_device { public: // construction/destruction - mach64_8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mach64_8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - mach64_8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mach64_8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -208,13 +208,13 @@ class mach64_device : public mach32_device { public: // construction/destruction - mach64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mach64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void mach64_config1_w(uint16_t data) { } // why does the mach64 BIOS write to these, they are read only on the mach32 and earlier void mach64_config2_w(uint16_t data) { } protected: - mach64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mach64_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/isa/mc1502_fdc.cpp b/src/devices/bus/isa/mc1502_fdc.cpp index ad1c1bd8b8c..217feee9317 100644 --- a/src/devices/bus/isa/mc1502_fdc.cpp +++ b/src/devices/bus/isa/mc1502_fdc.cpp @@ -190,7 +190,7 @@ void mc1502_fdc_device::mc1502_fdc_w(offs_t offset, uint8_t data) // mc1502_fdc_device - constructor //------------------------------------------------- -mc1502_fdc_device::mc1502_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc1502_fdc_device::mc1502_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC1502_FDC, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_fdc(*this, "fdc") diff --git a/src/devices/bus/isa/mc1502_fdc.h b/src/devices/bus/isa/mc1502_fdc.h index 45fde02945d..d6de540df6c 100644 --- a/src/devices/bus/isa/mc1502_fdc.h +++ b/src/devices/bus/isa/mc1502_fdc.h @@ -25,7 +25,7 @@ class mc1502_fdc_device : public device_t, { public: // construction/destruction - mc1502_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc1502_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_cpu(T &&tag) { m_cpu.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/bus/isa/mc1502_rom.cpp b/src/devices/bus/isa/mc1502_rom.cpp index f3a78cb93a6..655c6a737d7 100644 --- a/src/devices/bus/isa/mc1502_rom.cpp +++ b/src/devices/bus/isa/mc1502_rom.cpp @@ -45,7 +45,7 @@ const tiny_rom_entry *mc1502_rom_device::device_rom_region() const // mc1502_rom_device - constructor //------------------------------------------------- -mc1502_rom_device::mc1502_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc1502_rom_device::mc1502_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC1502_ROM, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) { diff --git a/src/devices/bus/isa/mc1502_rom.h b/src/devices/bus/isa/mc1502_rom.h index bbb152df72f..3a9e8957f3f 100644 --- a/src/devices/bus/isa/mc1502_rom.h +++ b/src/devices/bus/isa/mc1502_rom.h @@ -22,7 +22,7 @@ class mc1502_rom_device : public device_t, { public: // construction/destruction - mc1502_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc1502_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/isa/mcd.cpp b/src/devices/bus/isa/mcd.cpp index 9bb8b82a5da..b40d824554e 100644 --- a/src/devices/bus/isa/mcd.cpp +++ b/src/devices/bus/isa/mcd.cpp @@ -35,7 +35,7 @@ void mcd_isa_device::device_add_mconfig(machine_config &config) // mcd_isa_device - constructor //------------------------------------------------- -mcd_isa_device::mcd_isa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mcd_isa_device::mcd_isa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cdrom_image_device(mconfig, ISA16_MCD, tag, owner, clock), device_isa16_card_interface( mconfig, *this ), m_cdda(*this, "cdda") diff --git a/src/devices/bus/isa/mcd.h b/src/devices/bus/isa/mcd.h index 4c2b7a0e636..a8dfcf64dfd 100644 --- a/src/devices/bus/isa/mcd.h +++ b/src/devices/bus/isa/mcd.h @@ -20,7 +20,7 @@ class mcd_isa_device : public cdrom_image_device, { public: // construction/destruction - mcd_isa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mcd_isa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual uint16_t dack16_r(int line) override; diff --git a/src/devices/bus/isa/mda.cpp b/src/devices/bus/isa/mda.cpp index e3ff8e90f99..542ded743bb 100644 --- a/src/devices/bus/isa/mda.cpp +++ b/src/devices/bus/isa/mda.cpp @@ -158,12 +158,12 @@ const tiny_rom_entry *isa8_mda_device::device_rom_region() const // isa8_mda_device - constructor //------------------------------------------------- -isa8_mda_device::isa8_mda_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_mda_device::isa8_mda_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_mda_device(mconfig, ISA8_MDA, tag, owner, clock) { } -isa8_mda_device::isa8_mda_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_mda_device::isa8_mda_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_crtc(*this, MC6845_NAME), m_lpt(*this, "lpt"), m_framecnt(0), m_mode_control(0), m_update_row_type(-1), m_chr_gen(nullptr), m_vsync(0), m_hsync(0), m_pixel(0), @@ -584,7 +584,7 @@ const tiny_rom_entry *isa8_hercules_device::device_rom_region() const // isa8_hercules_device - constructor //------------------------------------------------- -isa8_hercules_device::isa8_hercules_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_hercules_device::isa8_hercules_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_mda_device(mconfig, ISA8_HERCULES, tag, owner, clock), m_configuration_switch(0) { } @@ -783,7 +783,7 @@ void isa8_ec1840_0002_device::device_add_mconfig(machine_config &config) // isa8_ec1840_0002_device - constructor //------------------------------------------------- -isa8_ec1840_0002_device::isa8_ec1840_0002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_ec1840_0002_device::isa8_ec1840_0002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_mda_device(mconfig, ISA8_EC1840_0002, tag, owner, clock), m_soft_chr_gen(nullptr) { } diff --git a/src/devices/bus/isa/mda.h b/src/devices/bus/isa/mda.h index e16c80e8ce1..4be9f20ad98 100644 --- a/src/devices/bus/isa/mda.h +++ b/src/devices/bus/isa/mda.h @@ -24,7 +24,7 @@ public: friend class isa8_hercules_device; // construction/destruction - isa8_mda_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_mda_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t io_read(offs_t offset); virtual void io_write(offs_t offset, uint8_t data); @@ -37,7 +37,7 @@ public: virtual MC6845_UPDATE_ROW( crtc_update_row ); protected: - isa8_mda_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_mda_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -81,7 +81,7 @@ class isa8_hercules_device : { public: // construction/destruction - isa8_hercules_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_hercules_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t io_read(offs_t offset) override; virtual void io_write(offs_t offset, uint8_t data) override; @@ -115,7 +115,7 @@ class isa8_ec1840_0002_device : { public: // construction/destruction - isa8_ec1840_0002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_ec1840_0002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/mpu401.cpp b/src/devices/bus/isa/mpu401.cpp index 7f6a28b87b4..6ca06038fc1 100644 --- a/src/devices/bus/isa/mpu401.cpp +++ b/src/devices/bus/isa/mpu401.cpp @@ -62,7 +62,7 @@ void isa8_mpu401_device::device_add_mconfig(machine_config &config) // isa8_adlib_device - constructor //------------------------------------------------- -isa8_mpu401_device::isa8_mpu401_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +isa8_mpu401_device::isa8_mpu401_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_MPU401, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_mpu401(*this, MPU_CORE_TAG) diff --git a/src/devices/bus/isa/mpu401.h b/src/devices/bus/isa/mpu401.h index 89974be7b84..7a811fe3e6d 100644 --- a/src/devices/bus/isa/mpu401.h +++ b/src/devices/bus/isa/mpu401.h @@ -20,7 +20,7 @@ class isa8_mpu401_device : { public: // construction/destruction - isa8_mpu401_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_mpu401_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/mufdc.cpp b/src/devices/bus/isa/mufdc.cpp index 2a078f812f9..39a29177bdd 100644 --- a/src/devices/bus/isa/mufdc.cpp +++ b/src/devices/bus/isa/mufdc.cpp @@ -128,7 +128,7 @@ const tiny_rom_entry *fdcmag_device::device_rom_region() const // mufdc_device - constructor //------------------------------------------------- -mufdc_device::mufdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +mufdc_device::mufdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface( mconfig, *this), m_fdc(*this, "fdc"), @@ -136,12 +136,12 @@ mufdc_device::mufdc_device(const machine_config &mconfig, device_type type, cons { } -fdc344_device::fdc344_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +fdc344_device::fdc344_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mufdc_device(mconfig, ISA8_FDC344, tag, owner, clock) { } -fdcmag_device::fdcmag_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +fdcmag_device::fdcmag_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mufdc_device(mconfig, ISA8_FDCMAG, tag, owner, clock) { } diff --git a/src/devices/bus/isa/mufdc.h b/src/devices/bus/isa/mufdc.h index b746d135003..5c1457ff679 100644 --- a/src/devices/bus/isa/mufdc.h +++ b/src/devices/bus/isa/mufdc.h @@ -34,7 +34,7 @@ class mufdc_device : public device_t, public device_isa8_card_interface { protected: // construction/destruction - mufdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mufdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -65,7 +65,7 @@ class fdc344_device : public mufdc_device { public: // construction/destruction - fdc344_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fdc344_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; @@ -74,7 +74,7 @@ class fdcmag_device : public mufdc_device { public: // construction/destruction - fdcmag_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fdcmag_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; diff --git a/src/devices/bus/isa/myb3k_com.cpp b/src/devices/bus/isa/myb3k_com.cpp index b500d95b993..b7347901357 100644 --- a/src/devices/bus/isa/myb3k_com.cpp +++ b/src/devices/bus/isa/myb3k_com.cpp @@ -49,7 +49,7 @@ void isa8_myb3k_com_device::device_add_mconfig(machine_config &config) // TODO: configure RxC and TxC from RS232 connector when these are defined is rs232.h /* Timer chip */ - pit8253_device &pit(PIT8253(config, "pit", 0)); + pit8253_device &pit(PIT8253(config, "pit")); pit.set_clk<0>(XTAL(15'974'400) / 8); /* TxC */ pit.out_handler<0>().set(FUNC(isa8_myb3k_com_device::pit_txc)); pit.set_clk<1>(XTAL(15'974'400) / 8); /* RxC */ @@ -66,12 +66,12 @@ void isa8_myb3k_com_device::device_add_mconfig(machine_config &config) //------------------------------------------------- // isa8_myb3k_com_device - constructor //------------------------------------------------- -isa8_myb3k_com_device::isa8_myb3k_com_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_myb3k_com_device::isa8_myb3k_com_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_myb3k_com_device(mconfig, ISA8_MYB3K_COM, tag, owner, clock) { } -isa8_myb3k_com_device::isa8_myb3k_com_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_myb3k_com_device::isa8_myb3k_com_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_iobase(*this, "DPSW1") diff --git a/src/devices/bus/isa/myb3k_com.h b/src/devices/bus/isa/myb3k_com.h index bdd591b5291..f3267f716be 100644 --- a/src/devices/bus/isa/myb3k_com.h +++ b/src/devices/bus/isa/myb3k_com.h @@ -37,7 +37,7 @@ class isa8_myb3k_com_device : { public: // construction/destruction - isa8_myb3k_com_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_myb3k_com_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(pit_txc); DECLARE_WRITE_LINE_MEMBER(pit_rxc); @@ -51,7 +51,7 @@ public: uint8_t dce_status(); protected: - isa8_myb3k_com_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_myb3k_com_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/isa/myb3k_fdc.cpp b/src/devices/bus/isa/myb3k_fdc.cpp index 1ca69a19be5..8687464c811 100644 --- a/src/devices/bus/isa/myb3k_fdc.cpp +++ b/src/devices/bus/isa/myb3k_fdc.cpp @@ -116,7 +116,7 @@ void isa8_myb3k_fdc4712_device::device_add_mconfig(machine_config &config) //************************************************************************** // LIVE DEVICES //************************************************************************** -isa8_myb3k_fdc471x_device_base::isa8_myb3k_fdc471x_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_myb3k_fdc471x_device_base::isa8_myb3k_fdc471x_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_fdc(*this, "fdc"), @@ -124,7 +124,7 @@ isa8_myb3k_fdc471x_device_base::isa8_myb3k_fdc471x_device_base(const machine_con { } -isa8_myb3k_fdc4710_device::isa8_myb3k_fdc4710_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_myb3k_fdc4710_device::isa8_myb3k_fdc4710_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_myb3k_fdc471x_device_base(mconfig, ISA8_MYB3K_FDC4710, tag, owner, clock) { has_motor_control = true; @@ -132,7 +132,7 @@ isa8_myb3k_fdc4710_device::isa8_myb3k_fdc4710_device(const machine_config &mconf dma_channel = 2; } -isa8_myb3k_fdc4711_device::isa8_myb3k_fdc4711_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_myb3k_fdc4711_device::isa8_myb3k_fdc4711_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_myb3k_fdc471x_device_base(mconfig, ISA8_MYB3K_FDC4711, tag, owner, clock) { has_motor_control = true; @@ -140,7 +140,7 @@ isa8_myb3k_fdc4711_device::isa8_myb3k_fdc4711_device(const machine_config &mconf dma_channel = 2; } -isa8_myb3k_fdc4712_device::isa8_myb3k_fdc4712_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_myb3k_fdc4712_device::isa8_myb3k_fdc4712_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_myb3k_fdc471x_device_base(mconfig, ISA8_MYB3K_FDC4712, tag, owner, clock), selected_drive(0) { diff --git a/src/devices/bus/isa/myb3k_fdc.h b/src/devices/bus/isa/myb3k_fdc.h index b2a645423d6..f1223096c38 100644 --- a/src/devices/bus/isa/myb3k_fdc.h +++ b/src/devices/bus/isa/myb3k_fdc.h @@ -20,7 +20,7 @@ class isa8_myb3k_fdc471x_device_base : public device_isa8_card_interface { protected: - isa8_myb3k_fdc471x_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_myb3k_fdc471x_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_add_mconfig(machine_config &config) override; @@ -67,11 +67,11 @@ class isa8_myb3k_fdc4710_device : public isa8_myb3k_fdc471x_device_base { public: // construction/destruction - isa8_myb3k_fdc4710_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_myb3k_fdc4710_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // construction/destruction - isa8_myb3k_fdc4710_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_myb3k_fdc4710_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_add_mconfig(machine_config &config) override; @@ -81,11 +81,11 @@ class isa8_myb3k_fdc4711_device : public isa8_myb3k_fdc471x_device_base { public: // construction/destruction - isa8_myb3k_fdc4711_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_myb3k_fdc4711_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // construction/destruction - isa8_myb3k_fdc4711_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_myb3k_fdc4711_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_add_mconfig(machine_config &config) override; @@ -95,11 +95,11 @@ class isa8_myb3k_fdc4712_device : public isa8_myb3k_fdc471x_device_base { public: // construction/destruction - isa8_myb3k_fdc4712_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_myb3k_fdc4712_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // construction/destruction - isa8_myb3k_fdc4712_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_myb3k_fdc4712_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/isa/ne1000.cpp b/src/devices/bus/isa/ne1000.cpp index d2234098c34..4f5e5a0a1b6 100644 --- a/src/devices/bus/isa/ne1000.cpp +++ b/src/devices/bus/isa/ne1000.cpp @@ -8,13 +8,13 @@ DEFINE_DEVICE_TYPE(NE1000, ne1000_device, "ne1000", "NE1000 Network Adapter") void ne1000_device::device_add_mconfig(machine_config &config) { - DP8390D(config, m_dp8390, 0); + DP8390D(config, m_dp8390); m_dp8390->irq_callback().set(FUNC(ne1000_device::ne1000_irq_w)); m_dp8390->mem_read_callback().set(FUNC(ne1000_device::ne1000_mem_read)); m_dp8390->mem_write_callback().set(FUNC(ne1000_device::ne1000_mem_write)); } -ne1000_device::ne1000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ne1000_device::ne1000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NE1000, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_dp8390(*this, "dp8390d"), diff --git a/src/devices/bus/isa/ne1000.h b/src/devices/bus/isa/ne1000.h index fa6011b45e1..af1e4fbfdbd 100644 --- a/src/devices/bus/isa/ne1000.h +++ b/src/devices/bus/isa/ne1000.h @@ -14,7 +14,7 @@ class ne1000_device: public device_t, public device_isa8_card_interface { public: - ne1000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ne1000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t ne1000_port_r(offs_t offset); void ne1000_port_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/isa/ne2000.cpp b/src/devices/bus/isa/ne2000.cpp index 08c73b96dac..e168dc2f9af 100644 --- a/src/devices/bus/isa/ne2000.cpp +++ b/src/devices/bus/isa/ne2000.cpp @@ -8,13 +8,13 @@ DEFINE_DEVICE_TYPE(NE2000, ne2000_device, "ne2000", "NE2000 Network Adapter") void ne2000_device::device_add_mconfig(machine_config &config) { - DP8390D(config, m_dp8390, 0); + DP8390D(config, m_dp8390); m_dp8390->irq_callback().set(FUNC(ne2000_device::ne2000_irq_w)); m_dp8390->mem_read_callback().set(FUNC(ne2000_device::ne2000_mem_read)); m_dp8390->mem_write_callback().set(FUNC(ne2000_device::ne2000_mem_write)); } -ne2000_device::ne2000_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +ne2000_device::ne2000_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, NE2000, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_dp8390(*this, "dp8390d"), diff --git a/src/devices/bus/isa/ne2000.h b/src/devices/bus/isa/ne2000.h index 328443fd9b2..e812a9881ff 100644 --- a/src/devices/bus/isa/ne2000.h +++ b/src/devices/bus/isa/ne2000.h @@ -12,7 +12,7 @@ class ne2000_device: public device_t, public device_isa16_card_interface { public: - ne2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ne2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t ne2000_port_r(offs_t offset, uint16_t mem_mask = ~0); void ne2000_port_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/bus/isa/np600.cpp b/src/devices/bus/isa/np600.cpp index 5fca3ff1910..3b7da41dc69 100644 --- a/src/devices/bus/isa/np600.cpp +++ b/src/devices/bus/isa/np600.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(NP600A3, np600a3_device, "np600a3", "InterLan NP600A-3 Intelligent Protocol Processor") -np600a3_device::np600a3_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +np600a3_device::np600a3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NP600A3, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_npcpu(*this, "npcpu") diff --git a/src/devices/bus/isa/np600.h b/src/devices/bus/isa/np600.h index 51bdf8813c1..57ea34a0d31 100644 --- a/src/devices/bus/isa/np600.h +++ b/src/devices/bus/isa/np600.h @@ -17,7 +17,7 @@ class np600a3_device : public device_t, public device_isa16_card_interface { public: - np600a3_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + np600a3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::LAN; } diff --git a/src/devices/bus/isa/num9rev.cpp b/src/devices/bus/isa/num9rev.cpp index c7756b8294b..a9652d60e53 100644 --- a/src/devices/bus/isa/num9rev.cpp +++ b/src/devices/bus/isa/num9rev.cpp @@ -76,7 +76,7 @@ void isa8_number_9_rev_device::device_add_mconfig(machine_config &config) // isa16_vga_device - constructor //------------------------------------------------- -isa8_number_9_rev_device::isa8_number_9_rev_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_number_9_rev_device::isa8_number_9_rev_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_NUM_9_REV, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_upd7220(*this, "upd7220"), diff --git a/src/devices/bus/isa/num9rev.h b/src/devices/bus/isa/num9rev.h index 298af6d91f5..e0e12f6a1c7 100644 --- a/src/devices/bus/isa/num9rev.h +++ b/src/devices/bus/isa/num9rev.h @@ -22,7 +22,7 @@ class isa8_number_9_rev_device : { public: // construction/destruction - isa8_number_9_rev_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_number_9_rev_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/omti8621.cpp b/src/devices/bus/isa/omti8621.cpp index 186e398c411..35a3a43c6ea 100644 --- a/src/devices/bus/isa/omti8621.cpp +++ b/src/devices/bus/isa/omti8621.cpp @@ -51,7 +51,7 @@ class omti_disk_image_device : public harddisk_image_base_device { public: // construction/destruction - omti_disk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + omti_disk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // image-level overrides virtual bool support_command_line_image_creation() const noexcept override { return true; } @@ -239,8 +239,8 @@ INPUT_PORTS_END void omti8621_device::device_add_mconfig(machine_config &config) { - OMTI_DISK(config, OMTI_DISK0_TAG, 0); - OMTI_DISK(config, OMTI_DISK1_TAG, 0); + OMTI_DISK(config, OMTI_DISK0_TAG); + OMTI_DISK(config, OMTI_DISK1_TAG); UPD765A(config, m_fdc, 48_MHz_XTAL / 6, false, false); // clocked through FDC9239BT m_fdc->intrq_wr_callback().set(FUNC(omti8621_device::fdc_irq_w)); @@ -370,14 +370,14 @@ void omti8621_device::device_reset() DEFINE_DEVICE_TYPE(ISA16_OMTI8621, omti8621_pc_device, "omti8621isa", "OMTI 8621 ESDI/floppy controller (ISA)") -omti8621_pc_device::omti8621_pc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +omti8621_pc_device::omti8621_pc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : omti8621_device(mconfig, ISA16_OMTI8621, tag, owner, clock) { } DEFINE_DEVICE_TYPE(ISA16_OMTI8621_APOLLO, omti8621_apollo_device, "omti8621ap", "OMTI 8621 ESDI/floppy controller (Apollo)") -omti8621_apollo_device::omti8621_apollo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +omti8621_apollo_device::omti8621_apollo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : omti8621_device(mconfig, ISA16_OMTI8621_APOLLO, tag, owner, clock) { } @@ -1379,7 +1379,7 @@ uint8_t omti8621_device::fd_disk_chg_r() // device type definition DEFINE_DEVICE_TYPE(OMTI_DISK, omti_disk_image_device, "omti_disk_image", "OMTI 8621 ESDI disk") -omti_disk_image_device::omti_disk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +omti_disk_image_device::omti_disk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : harddisk_image_base_device(mconfig, OMTI_DISK, tag, owner, clock) , m_type(0), m_cylinders(0), m_heads(0), m_sectors(0), m_sectorbytes(0), m_sector_count(0), m_image(nullptr) { diff --git a/src/devices/bus/isa/omti8621.h b/src/devices/bus/isa/omti8621.h index 3e5cce1c59a..2d80d8fec01 100644 --- a/src/devices/bus/isa/omti8621.h +++ b/src/devices/bus/isa/omti8621.h @@ -148,7 +148,7 @@ private: class omti8621_pc_device : public omti8621_device { public: - omti8621_pc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + omti8621_pc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(ISA16_OMTI8621, omti8621_pc_device) @@ -158,7 +158,7 @@ DECLARE_DEVICE_TYPE(ISA16_OMTI8621, omti8621_pc_device) class omti8621_apollo_device : public omti8621_device { public: - omti8621_apollo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + omti8621_apollo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // get sector diskaddr of logical unit lun into data_buffer uint32_t get_sector(int32_t diskaddr, uint8_t *buffer, uint32_t length, uint8_t lun); diff --git a/src/devices/bus/isa/p1_fdc.cpp b/src/devices/bus/isa/p1_fdc.cpp index 390f98727b0..46fd1b1bac9 100644 --- a/src/devices/bus/isa/p1_fdc.cpp +++ b/src/devices/bus/isa/p1_fdc.cpp @@ -152,7 +152,7 @@ void p1_fdc_device::p1_fdc_w(offs_t offset, uint8_t data) // p1_fdc_device - constructor //------------------------------------------------- -p1_fdc_device::p1_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +p1_fdc_device::p1_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, P1_FDC, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_fdc(*this, "fdc") diff --git a/src/devices/bus/isa/p1_fdc.h b/src/devices/bus/isa/p1_fdc.h index ceeb278f5c7..7c5fbd9f831 100644 --- a/src/devices/bus/isa/p1_fdc.h +++ b/src/devices/bus/isa/p1_fdc.h @@ -25,7 +25,7 @@ class p1_fdc_device : public device_t, { public: // construction/destruction - p1_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + p1_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_cpu(T &&tag) { m_cpu.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/bus/isa/p1_hdc.cpp b/src/devices/bus/isa/p1_hdc.cpp index 9ee84ece875..fe397c371f0 100644 --- a/src/devices/bus/isa/p1_hdc.cpp +++ b/src/devices/bus/isa/p1_hdc.cpp @@ -55,15 +55,15 @@ ROM_END void p1_hdc_device::device_add_mconfig(machine_config &config) { - WD2010(config, m_hdc, 5'000'000); // XXX clock? + WD2010(config, m_hdc, XTAL::u(5'000'000)); // XXX clock? m_hdc->in_drdy_callback().set_constant(1); m_hdc->in_index_callback().set_constant(1); m_hdc->in_wf_callback().set_constant(1); m_hdc->in_tk000_callback().set_constant(1); m_hdc->in_sc_callback().set_constant(1); - HARDDISK(config, "hard0", 0); - HARDDISK(config, "hard1", 0); + HARDDISK(config, "hard0"); + HARDDISK(config, "hard1"); } @@ -111,7 +111,7 @@ void p1_hdc_device::p1_HDC_w(offs_t offset, uint8_t data) // p1_hdc_device - constructor //------------------------------------------------- -p1_hdc_device::p1_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +p1_hdc_device::p1_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, P1_HDC, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_hdc(*this, "d17") diff --git a/src/devices/bus/isa/p1_hdc.h b/src/devices/bus/isa/p1_hdc.h index 2947dba1e84..0109dec1e89 100644 --- a/src/devices/bus/isa/p1_hdc.h +++ b/src/devices/bus/isa/p1_hdc.h @@ -25,7 +25,7 @@ class p1_hdc_device : public device_t, { public: // construction/destruction - p1_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + p1_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/p1_rom.cpp b/src/devices/bus/isa/p1_rom.cpp index 76013aca719..864eaec5e3e 100644 --- a/src/devices/bus/isa/p1_rom.cpp +++ b/src/devices/bus/isa/p1_rom.cpp @@ -50,7 +50,7 @@ const tiny_rom_entry *p1_rom_device::device_rom_region() const // p1_rom_device - constructor //------------------------------------------------- -p1_rom_device::p1_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +p1_rom_device::p1_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, P1_ROM, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) { diff --git a/src/devices/bus/isa/p1_rom.h b/src/devices/bus/isa/p1_rom.h index d5fd89662d5..884a1681e37 100644 --- a/src/devices/bus/isa/p1_rom.h +++ b/src/devices/bus/isa/p1_rom.h @@ -22,7 +22,7 @@ class p1_rom_device : public device_t, { public: // construction/destruction - p1_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + p1_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/isa/p1_sound.cpp b/src/devices/bus/isa/p1_sound.cpp index f2e69debf95..c81c61b15d0 100644 --- a/src/devices/bus/isa/p1_sound.cpp +++ b/src/devices/bus/isa/p1_sound.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(P1_SOUND, p1_sound_device, "p1_sound", "Poisk-1 sound card (B void p1_sound_device::device_add_mconfig(machine_config &config) { - I8251(config, m_midi, 0); + I8251(config, m_midi); m_midi->txd_handler().set("mdout", FUNC(midi_port_device::write_txd)); m_midi->rxrdy_handler().set(":isa", FUNC(isa8_device::irq3_w)); @@ -35,7 +35,7 @@ void p1_sound_device::device_add_mconfig(machine_config &config) MIDI_PORT(config, "mdout", midiout_slot, "midiout"); - PIT8253(config, m_d14, 0); + PIT8253(config, m_d14); m_d14->set_clk<0>(XTAL(12'500'000)/10); // sampler at 10 KHz m_d14->out_handler<0>().set(FUNC(p1_sound_device::sampler_sync)); @@ -44,7 +44,7 @@ void p1_sound_device::device_add_mconfig(machine_config &config) m_d14->set_clk<2>(XTAL(12'500'000)/10); m_d14->out_handler<2>().set(m_midi, FUNC(i8251_device::write_rxc)); - PIT8253(config, m_d16, 0); + PIT8253(config, m_d16); m_d16->set_clk<0>(XTAL(12'500'000)/10); // m_d16->out_handler<0>().set(FUNC(XXX)); m_d16->set_clk<1>(XTAL(12'500'000)/10); @@ -52,7 +52,7 @@ void p1_sound_device::device_add_mconfig(machine_config &config) m_d16->set_clk<2>(XTAL(12'500'000)/10); // m_d16->out_handler<2>().set(FUNC(XXX)); - PIT8253(config, m_d17, 0); + PIT8253(config, m_d17); m_d17->set_clk<0>(XTAL(12'500'000)/10); // m_d17->out_handler<0>().set(FUNC(XXX)); m_d17->set_clk<1>(XTAL(12'500'000)/10); @@ -62,7 +62,7 @@ void p1_sound_device::device_add_mconfig(machine_config &config) SPEAKER(config, "speaker").front_center(); FILTER_RC(config, m_filter).add_route(ALL_OUTPUTS, "speaker", 1.0); - DAC_8BIT_R2R(config, m_dac, 0).add_route(ALL_OUTPUTS, "filter", 0.5); // unknown DAC + DAC_8BIT_R2R(config, m_dac).add_route(ALL_OUTPUTS, "filter", 0.5); // unknown DAC } @@ -74,7 +74,7 @@ void p1_sound_device::device_add_mconfig(machine_config &config) // p1_sound_device - constructor //------------------------------------------------- -p1_sound_device::p1_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +p1_sound_device::p1_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, P1_SOUND, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_dac(*this, "dac") diff --git a/src/devices/bus/isa/p1_sound.h b/src/devices/bus/isa/p1_sound.h index 3b7f1c40af9..e85c524ff1c 100644 --- a/src/devices/bus/isa/p1_sound.h +++ b/src/devices/bus/isa/p1_sound.h @@ -28,7 +28,7 @@ class p1_sound_device : public device_t, { public: // construction/destruction - p1_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + p1_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t d14_r(offs_t offset); uint8_t d16_r(offs_t offset); diff --git a/src/devices/bus/isa/pc1640_iga.cpp b/src/devices/bus/isa/pc1640_iga.cpp index 96ae2da109b..6fd14d76f10 100644 --- a/src/devices/bus/isa/pc1640_iga.cpp +++ b/src/devices/bus/isa/pc1640_iga.cpp @@ -66,7 +66,7 @@ const tiny_rom_entry *isa8_pc1640_iga_device::device_rom_region() const // isa8_pc1640_iga_device - constructor //------------------------------------------------- -isa8_pc1640_iga_device::isa8_pc1640_iga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +isa8_pc1640_iga_device::isa8_pc1640_iga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_ega_device(mconfig, ISA8_PC1640_IGA, tag, owner, clock) { } diff --git a/src/devices/bus/isa/pc1640_iga.h b/src/devices/bus/isa/pc1640_iga.h index 0cee53d6329..d52d8dfaabd 100644 --- a/src/devices/bus/isa/pc1640_iga.h +++ b/src/devices/bus/isa/pc1640_iga.h @@ -26,7 +26,7 @@ class isa8_pc1640_iga_device : public isa8_ega_device { public: // construction/destruction - isa8_pc1640_iga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_pc1640_iga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/isa/pcmidi.cpp b/src/devices/bus/isa/pcmidi.cpp index 45cc41ff4f4..283b23963d6 100644 --- a/src/devices/bus/isa/pcmidi.cpp +++ b/src/devices/bus/isa/pcmidi.cpp @@ -65,7 +65,7 @@ DEFINE_DEVICE_TYPE(ISA8_PCMIDI, isa8_pcmidi_device, "isa_pcmidi", "Music Quest P // isa8_pcmidi_device - constructor //------------------------------------------------- -isa8_pcmidi_device::isa8_pcmidi_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +isa8_pcmidi_device::isa8_pcmidi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_PCMIDI, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_mpu(*this, "mpu") diff --git a/src/devices/bus/isa/pcmidi.h b/src/devices/bus/isa/pcmidi.h index 90bca2b5752..649e9664f16 100644 --- a/src/devices/bus/isa/pcmidi.h +++ b/src/devices/bus/isa/pcmidi.h @@ -14,7 +14,7 @@ class isa8_pcmidi_device : public device_t, public device_isa8_card_interface { public: - isa8_pcmidi_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + isa8_pcmidi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/isa/pds.cpp b/src/devices/bus/isa/pds.cpp index 255d0f7dbe0..4dc2c8d387f 100644 --- a/src/devices/bus/isa/pds.cpp +++ b/src/devices/bus/isa/pds.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(ISA8_PDS, isa8_pds_device, "isa_pds", "Programmers Development System (host)") -isa8_pds_device::isa8_pds_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +isa8_pds_device::isa8_pds_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_PDS, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_ppi(*this,"pds_ppi") diff --git a/src/devices/bus/isa/pds.h b/src/devices/bus/isa/pds.h index 3188fdac0ad..92bb842562a 100644 --- a/src/devices/bus/isa/pds.h +++ b/src/devices/bus/isa/pds.h @@ -17,7 +17,7 @@ class isa8_pds_device : public device_isa8_card_interface { public: - isa8_pds_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_pds_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t ppi_r(offs_t offset); void ppi_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/isa/pgc.cpp b/src/devices/bus/isa/pgc.cpp index b8329e0ee53..962e3b99da2 100644 --- a/src/devices/bus/isa/pgc.cpp +++ b/src/devices/bus/isa/pgc.cpp @@ -197,12 +197,12 @@ ioport_constructor isa8_pgc_device::device_input_ports() const // isa8_pgc_device - constructor //------------------------------------------------- -isa8_pgc_device::isa8_pgc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_pgc_device::isa8_pgc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : isa8_pgc_device(mconfig, ISA8_PGC, tag, owner, clock) { } -isa8_pgc_device::isa8_pgc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +isa8_pgc_device::isa8_pgc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_cpu(*this, "maincpu"), diff --git a/src/devices/bus/isa/pgc.h b/src/devices/bus/isa/pgc.h index d560dbdda09..c2a06dadb0d 100644 --- a/src/devices/bus/isa/pgc.h +++ b/src/devices/bus/isa/pgc.h @@ -24,10 +24,10 @@ class isa8_pgc_device : { public: // construction/destruction - isa8_pgc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_pgc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - isa8_pgc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + isa8_pgc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/isa/s3virge.cpp b/src/devices/bus/isa/s3virge.cpp index 9fb6f98d204..9a3b395ee50 100644 --- a/src/devices/bus/isa/s3virge.cpp +++ b/src/devices/bus/isa/s3virge.cpp @@ -35,28 +35,28 @@ DEFINE_DEVICE_TYPE(S3VIRGE, s3virge_vga_device, "virge_vga", "S3 DEFINE_DEVICE_TYPE(S3VIRGEDX, s3virgedx_vga_device, "virgedx_vga", "S3 86C375") DEFINE_DEVICE_TYPE(S3VIRGEDX1, s3virgedx_rev1_vga_device, "virgedx_vga_r1", "S3 86C375 (rev 1)") -s3virge_vga_device::s3virge_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s3virge_vga_device::s3virge_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : s3virge_vga_device(mconfig, S3VIRGE, tag, owner, clock) { } -s3virge_vga_device::s3virge_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +s3virge_vga_device::s3virge_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : s3_vga_device(mconfig, type, tag, owner, clock) , m_linear_config_changed_cb(*this) { } -s3virgedx_vga_device::s3virgedx_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s3virgedx_vga_device::s3virgedx_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : s3virgedx_vga_device(mconfig, S3VIRGEDX, tag, owner, clock) { } -s3virgedx_vga_device::s3virgedx_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +s3virgedx_vga_device::s3virgedx_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : s3virge_vga_device(mconfig, type, tag, owner, clock) { } -s3virgedx_rev1_vga_device::s3virgedx_rev1_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s3virgedx_rev1_vga_device::s3virgedx_rev1_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : s3virgedx_vga_device(mconfig, S3VIRGEDX1, tag, owner, clock) { } diff --git a/src/devices/bus/isa/s3virge.h b/src/devices/bus/isa/s3virge.h index aec31340d7b..6146c8300e0 100644 --- a/src/devices/bus/isa/s3virge.h +++ b/src/devices/bus/isa/s3virge.h @@ -20,7 +20,7 @@ class s3virge_vga_device : public s3_vga_device { public: // construction/destruction - s3virge_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s3virge_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto linear_config_changed() { return m_linear_config_changed_cb.bind(); } @@ -75,7 +75,7 @@ public: ibm8514a_device* get_8514() { fatalerror("s3virge requested non-existent 8514/A device\n"); return nullptr; } protected: - s3virge_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + s3virge_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -220,10 +220,10 @@ class s3virgedx_vga_device : public s3virge_vga_device { public: // construction/destruction - s3virgedx_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s3virgedx_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - s3virgedx_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + s3virgedx_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -236,7 +236,7 @@ class s3virgedx_rev1_vga_device : public s3virgedx_vga_device { public: // construction/destruction - s3virgedx_rev1_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s3virgedx_rev1_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/sb16.cpp b/src/devices/bus/isa/sb16.cpp index 333703f2cfc..4435981f030 100644 --- a/src/devices/bus/isa/sb16.cpp +++ b/src/devices/bus/isa/sb16.cpp @@ -434,8 +434,8 @@ void sb16_lle_device::device_add_mconfig(machine_config &config) ymf262.add_route(2, "lspeaker", 1.00); ymf262.add_route(3, "rspeaker", 1.00); - DAC_16BIT_R2R(config, m_ldac, 0).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // unknown DAC - DAC_16BIT_R2R(config, m_rdac, 0).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // unknown DAC + DAC_16BIT_R2R(config, m_ldac).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // unknown DAC + DAC_16BIT_R2R(config, m_rdac).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // unknown DAC PC_JOY(config, m_joy); } @@ -684,7 +684,7 @@ void sb16_lle_device::mpu401_w(offs_t offset, uint8_t data) } -sb16_lle_device::sb16_lle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sb16_lle_device::sb16_lle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_SB16, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_ldac(*this, "ldac"), diff --git a/src/devices/bus/isa/sb16.h b/src/devices/bus/isa/sb16.h index 8710574ba85..06bf6254c8e 100644 --- a/src/devices/bus/isa/sb16.h +++ b/src/devices/bus/isa/sb16.h @@ -20,7 +20,7 @@ class sb16_lle_device : public device_t, public device_isa16_card_interface { public: // construction/destruction - sb16_lle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sb16_lle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/sblaster.cpp b/src/devices/bus/isa/sblaster.cpp index 33905e05da3..9a9c1fd7f02 100644 --- a/src/devices/bus/isa/sblaster.cpp +++ b/src/devices/bus/isa/sblaster.cpp @@ -1152,8 +1152,8 @@ void sb_device::common(machine_config &config) SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - DAC_16BIT_R2R(config, m_ldac, 0).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // unknown DAC - DAC_16BIT_R2R(config, m_rdac, 0).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // unknown DAC + DAC_16BIT_R2R(config, m_ldac).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // unknown DAC + DAC_16BIT_R2R(config, m_rdac).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // unknown DAC PC_JOY(config, m_joy); @@ -1203,7 +1203,7 @@ void isa16_sblaster16_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -sb_device::sb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +sb_device::sb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_serial_interface(mconfig, *this), m_ldac(*this, "ldac"), @@ -1214,14 +1214,14 @@ sb_device::sb_device(const machine_config &mconfig, device_type type, const char { } -sb8_device::sb8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +sb8_device::sb8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sb_device(mconfig, type, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_ym3812(*this, "ym3812") { } -sb16_device::sb16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +sb16_device::sb16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sb_device(mconfig, type, tag, owner, clock), device_isa16_card_interface(mconfig, *this) { @@ -1231,19 +1231,19 @@ sb16_device::sb16_device(const machine_config &mconfig, device_type type, const // isa8_sblaster_device - constructor //------------------------------------------------- -isa8_sblaster1_0_device::isa8_sblaster1_0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_sblaster1_0_device::isa8_sblaster1_0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sb8_device(mconfig, ISA8_SOUND_BLASTER_1_0, tag, owner, clock), m_saa1099_1(*this, "saa1099.1"), m_saa1099_2(*this, "saa1099.2") { } -isa8_sblaster1_5_device::isa8_sblaster1_5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_sblaster1_5_device::isa8_sblaster1_5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sb8_device(mconfig, ISA8_SOUND_BLASTER_1_5, tag, owner, clock) { } -isa16_sblaster16_device::isa16_sblaster16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_sblaster16_device::isa16_sblaster16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sb16_device(mconfig, ISA16_SOUND_BLASTER_16, tag, owner, clock) { } @@ -1425,7 +1425,7 @@ void sb_device::device_reset() // MIDI is 31250 baud, 8-N-1 set_data_frame(1, 8, PARITY_NONE, STOP_BITS_1); - set_rate(31250); + set_rate(XTAL::u(31250)); } uint8_t sb_device::dack_r(int line) diff --git a/src/devices/bus/isa/sblaster.h b/src/devices/bus/isa/sblaster.h index f09f05957be..32748cb8230 100644 --- a/src/devices/bus/isa/sblaster.h +++ b/src/devices/bus/isa/sblaster.h @@ -105,7 +105,7 @@ protected: }; // construction/destruction - sb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -157,7 +157,7 @@ public: virtual ioport_constructor device_input_ports() const override; protected: // construction/destruction - sb8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sb8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void drq_w(int state) override; @@ -172,7 +172,7 @@ class isa8_sblaster1_0_device : public sb8_device { public: // construction/destruction - isa8_sblaster1_0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_sblaster1_0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t saa1099_16_r(offs_t offset); void saa1099_1_16_w(offs_t offset, uint8_t data); @@ -195,7 +195,7 @@ class isa8_sblaster1_5_device : public sb8_device { public: // construction/destruction - isa8_sblaster1_5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_sblaster1_5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -216,7 +216,7 @@ public: virtual ioport_constructor device_input_ports() const override; protected: // construction/destruction - sb16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sb16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual uint16_t dack16_r(int line) override; virtual uint8_t dack_r(int line) override { return sb_device::dack_r(line); } @@ -236,7 +236,7 @@ class isa16_sblaster16_device : public sb16_device { public: // construction/destruction - isa16_sblaster16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_sblaster16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/sc499.cpp b/src/devices/bus/isa/sc499.cpp index a670bb38aa4..ec1ef5cb84b 100644 --- a/src/devices/bus/isa/sc499.cpp +++ b/src/devices/bus/isa/sc499.cpp @@ -177,7 +177,7 @@ INPUT_PORTS_END void sc499_device::device_add_mconfig(machine_config &config) { - SC499_CTAPE(config, m_image, 0); + SC499_CTAPE(config, m_image); } @@ -307,7 +307,7 @@ DEFINE_DEVICE_TYPE(ISA8_SC499, sc499_device, "sc499", "Archive SC-499") // sc499_device - constructor //------------------------------------------------- -sc499_device::sc499_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sc499_device::sc499_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_SC499, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_iobase(*this, "IO_BASE"), @@ -1272,7 +1272,7 @@ void sc499_device::block_set_filemark() DEFINE_DEVICE_TYPE(SC499_CTAPE, sc499_ctape_image_device, "sc499_ctape", "SC-499 Cartridge Tape") -sc499_ctape_image_device::sc499_ctape_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sc499_ctape_image_device::sc499_ctape_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : microtape_image_device(mconfig, SC499_CTAPE, tag, owner, clock) { } diff --git a/src/devices/bus/isa/sc499.h b/src/devices/bus/isa/sc499.h index ffcd8c37a85..582c60a56b4 100644 --- a/src/devices/bus/isa/sc499.h +++ b/src/devices/bus/isa/sc499.h @@ -27,7 +27,7 @@ class sc499_ctape_image_device : public microtape_image_device { public: // construction/destruction - sc499_ctape_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sc499_ctape_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // image-level overrides virtual image_init_result call_load() override; @@ -56,7 +56,7 @@ class sc499_device: public device_t, public device_isa8_card_interface { public: // construction/destruction - sc499_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sc499_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: required_ioport m_iobase; diff --git a/src/devices/bus/isa/side116.cpp b/src/devices/bus/isa/side116.cpp index bad6645bf5a..7ddb89f6945 100644 --- a/src/devices/bus/isa/side116.cpp +++ b/src/devices/bus/isa/side116.cpp @@ -83,7 +83,7 @@ const tiny_rom_entry *side116_device::device_rom_region() const // side116_device - constructor //------------------------------------------------- -side116_device::side116_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +side116_device::side116_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_SIDE116, tag, owner, clock), device_isa8_card_interface( mconfig, *this ), m_ata(*this, "ata"), diff --git a/src/devices/bus/isa/side116.h b/src/devices/bus/isa/side116.h index 380e6206222..36d96e2d0b3 100644 --- a/src/devices/bus/isa/side116.h +++ b/src/devices/bus/isa/side116.h @@ -27,7 +27,7 @@ class side116_device : public device_t, public device_isa8_card_interface { public: // construction/destruction - side116_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + side116_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/bus/isa/ssi2001.cpp b/src/devices/bus/isa/ssi2001.cpp index e1d271dc6b4..96b4f2653cf 100644 --- a/src/devices/bus/isa/ssi2001.cpp +++ b/src/devices/bus/isa/ssi2001.cpp @@ -18,7 +18,7 @@ void ssi2001_device::device_add_mconfig(machine_config &config) PC_JOY(config, m_joy); } -ssi2001_device::ssi2001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ssi2001_device::ssi2001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_SSI2001, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_joy(*this, "pc_joy"), diff --git a/src/devices/bus/isa/ssi2001.h b/src/devices/bus/isa/ssi2001.h index 85efa17c5ac..0123785e6b3 100644 --- a/src/devices/bus/isa/ssi2001.h +++ b/src/devices/bus/isa/ssi2001.h @@ -20,7 +20,7 @@ class ssi2001_device : public device_t, { public: // construction/destruction - ssi2001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ssi2001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/stereo_fx.cpp b/src/devices/bus/isa/stereo_fx.cpp index 70f3c5160c7..18336c15149 100644 --- a/src/devices/bus/isa/stereo_fx.cpp +++ b/src/devices/bus/isa/stereo_fx.cpp @@ -131,8 +131,8 @@ void stereo_fx_device::device_add_mconfig(machine_config &config) ym3812.add_route(ALL_OUTPUTS, "rspeaker", 1.00); /* no CM/S support (empty sockets) */ - DAC_8BIT_R2R(config, "ldac", 0).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // unknown DAC - DAC_8BIT_R2R(config, "rdac", 0).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // unknown DAC + DAC_8BIT_R2R(config, "ldac").add_route(ALL_OUTPUTS, "lspeaker", 0.5); // unknown DAC + DAC_8BIT_R2R(config, "rdac").add_route(ALL_OUTPUTS, "rspeaker", 0.5); // unknown DAC PC_JOY(config, m_joy); } @@ -194,7 +194,7 @@ uint8_t stereo_fx_device::invalid_r() return 0xff; } -stereo_fx_device::stereo_fx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +stereo_fx_device::stereo_fx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_STEREO_FX, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_joy(*this, "pc_joy"), diff --git a/src/devices/bus/isa/stereo_fx.h b/src/devices/bus/isa/stereo_fx.h index 376d5dbff98..4ad2927d450 100644 --- a/src/devices/bus/isa/stereo_fx.h +++ b/src/devices/bus/isa/stereo_fx.h @@ -21,7 +21,7 @@ class stereo_fx_device : public device_t, { public: // construction/destruction - stereo_fx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + stereo_fx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/svga_cirrus.cpp b/src/devices/bus/isa/svga_cirrus.cpp index 750d0f41142..b68f34df1b9 100644 --- a/src/devices/bus/isa/svga_cirrus.cpp +++ b/src/devices/bus/isa/svga_cirrus.cpp @@ -36,7 +36,7 @@ void isa16_svga_cirrus_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update("vga", FUNC(cirrus_gd5430_device::screen_update)); - CIRRUS_GD5430(config, m_vga, 0); + CIRRUS_GD5430(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x200000); } @@ -58,7 +58,7 @@ const tiny_rom_entry *isa16_svga_cirrus_device::device_rom_region() const // isa16_vga_device - constructor //------------------------------------------------- -isa16_svga_cirrus_device::isa16_svga_cirrus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_svga_cirrus_device::isa16_svga_cirrus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_SVGA_CIRRUS, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_vga(*this, "vga") @@ -116,7 +116,7 @@ void isa16_svga_cirrus_gd542x_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update("vga", FUNC(cirrus_gd5428_device::screen_update)); - CIRRUS_GD5428(config, m_vga, 0); + CIRRUS_GD5428(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x200000); } @@ -138,7 +138,7 @@ const tiny_rom_entry *isa16_svga_cirrus_gd542x_device::device_rom_region() const // isa16_vga_device - constructor //------------------------------------------------- -isa16_svga_cirrus_gd542x_device::isa16_svga_cirrus_gd542x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_svga_cirrus_gd542x_device::isa16_svga_cirrus_gd542x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_SVGA_CIRRUS_GD542X, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_vga(*this, "vga") diff --git a/src/devices/bus/isa/svga_cirrus.h b/src/devices/bus/isa/svga_cirrus.h index d2e7d75595c..bc805319f27 100644 --- a/src/devices/bus/isa/svga_cirrus.h +++ b/src/devices/bus/isa/svga_cirrus.h @@ -18,7 +18,7 @@ class isa16_svga_cirrus_device : { public: // construction/destruction - isa16_svga_cirrus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_svga_cirrus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); @@ -41,7 +41,7 @@ class isa16_svga_cirrus_gd542x_device : { public: // construction/destruction - isa16_svga_cirrus_gd542x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_svga_cirrus_gd542x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); diff --git a/src/devices/bus/isa/svga_s3.cpp b/src/devices/bus/isa/svga_s3.cpp index 58984396d86..a55d9a8c2d3 100644 --- a/src/devices/bus/isa/svga_s3.cpp +++ b/src/devices/bus/isa/svga_s3.cpp @@ -57,7 +57,7 @@ void isa16_svga_s3_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update(m_vga, FUNC(s3_vga_device::screen_update)); - S3_VGA(config, m_vga, 0); + S3_VGA(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x100000); } @@ -79,7 +79,7 @@ const tiny_rom_entry *isa16_svga_s3_device::device_rom_region() const // isa16_vga_device - constructor //------------------------------------------------- -isa16_svga_s3_device::isa16_svga_s3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_svga_s3_device::isa16_svga_s3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_SVGA_S3, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_vga(*this, "vga"), m_8514(*this, "vga:8514a") @@ -162,7 +162,7 @@ void isa16_s3virge_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update(m_vga, FUNC(s3virge_vga_device::screen_update)); - S3VIRGE(config, m_vga, 0); + S3VIRGE(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x400000); m_vga->linear_config_changed().set(FUNC(isa16_s3virge_device::linear_config_changed_w)); @@ -195,7 +195,7 @@ const tiny_rom_entry *isa16_s3virge_device::device_rom_region() const // isa16_vga_device - constructor //------------------------------------------------- -isa16_s3virge_device::isa16_s3virge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_s3virge_device::isa16_s3virge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_S3VIRGE, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_vga(*this, "vga") @@ -254,7 +254,7 @@ void isa16_s3virgedx_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update(m_vga, FUNC(s3virgedx_vga_device::screen_update)); - S3VIRGEDX(config, m_vga, 0); + S3VIRGEDX(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x400000); m_vga->linear_config_changed().set(FUNC(isa16_s3virgedx_device::linear_config_changed_w)); @@ -303,7 +303,7 @@ const tiny_rom_entry *isa16_s3virgedx_device::device_rom_region() const // isa16_vga_device - constructor //------------------------------------------------- -isa16_s3virgedx_device::isa16_s3virgedx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_s3virgedx_device::isa16_s3virgedx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_S3VIRGEDX, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_vga(*this, "vga") @@ -370,7 +370,7 @@ void isa16_stealth3d2kpro_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update(m_vga, FUNC(s3virgedx_rev1_vga_device::screen_update)); - S3VIRGEDX1(config, m_vga, 0); + S3VIRGEDX1(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x400000); m_vga->linear_config_changed().set(FUNC(isa16_stealth3d2kpro_device::linear_config_changed_w)); @@ -403,7 +403,7 @@ const tiny_rom_entry *isa16_stealth3d2kpro_device::device_rom_region() const // isa16_vga_device - constructor //------------------------------------------------- -isa16_stealth3d2kpro_device::isa16_stealth3d2kpro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_stealth3d2kpro_device::isa16_stealth3d2kpro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_DMS3D2KPRO, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_vga(*this, "vga") diff --git a/src/devices/bus/isa/svga_s3.h b/src/devices/bus/isa/svga_s3.h index a07b0e039c6..eed9603c59e 100644 --- a/src/devices/bus/isa/svga_s3.h +++ b/src/devices/bus/isa/svga_s3.h @@ -21,7 +21,7 @@ class isa16_svga_s3_device : { public: // construction/destruction - isa16_svga_s3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_svga_s3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); @@ -45,7 +45,7 @@ class isa16_s3virge_device : { public: // construction/destruction - isa16_s3virge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_s3virge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); @@ -70,7 +70,7 @@ class isa16_s3virgedx_device : { public: // construction/destruction - isa16_s3virgedx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_s3virgedx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); @@ -98,7 +98,7 @@ class isa16_stealth3d2kpro_device : { public: // construction/destruction - isa16_stealth3d2kpro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_stealth3d2kpro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); diff --git a/src/devices/bus/isa/svga_trident.cpp b/src/devices/bus/isa/svga_trident.cpp index f3b4e0f9a6f..240874a13ae 100644 --- a/src/devices/bus/isa/svga_trident.cpp +++ b/src/devices/bus/isa/svga_trident.cpp @@ -36,7 +36,7 @@ void isa16_svga_tgui9680_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update(m_vga, FUNC(trident_vga_device::screen_update)); - TRIDENT_VGA(config, m_vga, 0); + TRIDENT_VGA(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x200000); } @@ -58,7 +58,7 @@ const tiny_rom_entry *isa16_svga_tgui9680_device::device_rom_region() const // isa8_vga_device - constructor //------------------------------------------------- -isa16_svga_tgui9680_device::isa16_svga_tgui9680_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_svga_tgui9680_device::isa16_svga_tgui9680_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_SVGA_TGUI9680, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_vga(*this, "vga") diff --git a/src/devices/bus/isa/svga_trident.h b/src/devices/bus/isa/svga_trident.h index c5c7bfdcf1d..bd537628845 100644 --- a/src/devices/bus/isa/svga_trident.h +++ b/src/devices/bus/isa/svga_trident.h @@ -25,7 +25,7 @@ class isa16_svga_tgui9680_device : { public: // construction/destruction - isa16_svga_tgui9680_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_svga_tgui9680_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); diff --git a/src/devices/bus/isa/svga_tseng.cpp b/src/devices/bus/isa/svga_tseng.cpp index 0d1485ad17d..dcbf63ead9d 100644 --- a/src/devices/bus/isa/svga_tseng.cpp +++ b/src/devices/bus/isa/svga_tseng.cpp @@ -35,7 +35,7 @@ void isa8_svga_et4k_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update(m_vga, FUNC(tseng_vga_device::screen_update)); - TSENG_VGA(config, m_vga, 0); + TSENG_VGA(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x100000); } @@ -57,7 +57,7 @@ const tiny_rom_entry *isa8_svga_et4k_device::device_rom_region() const // isa8_vga_device - constructor //------------------------------------------------- -isa8_svga_et4k_device::isa8_svga_et4k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_svga_et4k_device::isa8_svga_et4k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_SVGA_ET4K, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_vga(*this, "vga") diff --git a/src/devices/bus/isa/svga_tseng.h b/src/devices/bus/isa/svga_tseng.h index 690956741b5..602856ecf72 100644 --- a/src/devices/bus/isa/svga_tseng.h +++ b/src/devices/bus/isa/svga_tseng.h @@ -20,7 +20,7 @@ class isa8_svga_et4k_device : { public: // construction/destruction - isa8_svga_et4k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_svga_et4k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); diff --git a/src/devices/bus/isa/tekram_dc820.cpp b/src/devices/bus/isa/tekram_dc820.cpp index 56ffd8e4ccb..61233af1f3a 100644 --- a/src/devices/bus/isa/tekram_dc820.cpp +++ b/src/devices/bus/isa/tekram_dc820.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(TEKRAM_DC320E, tekram_dc320e_device, "dc320e", "Tekram DC-320 DEFINE_DEVICE_TYPE(TEKRAM_DC820, tekram_dc820_device, "dc820", "Tekram DC-820 SCSI Cache Controller") DEFINE_DEVICE_TYPE(TEKRAM_DC820B, tekram_dc820b_device, "dc820b", "Tekram DC-820B SCSI Cache Controller") -tekram_eisa_scsi_device::tekram_eisa_scsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +tekram_eisa_scsi_device::tekram_eisa_scsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_mpu(*this, "mpu") @@ -46,22 +46,22 @@ tekram_eisa_scsi_device::tekram_eisa_scsi_device(const machine_config &mconfig, { } -tekram_dc320b_device::tekram_dc320b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tekram_dc320b_device::tekram_dc320b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tekram_eisa_scsi_device(mconfig, TEKRAM_DC320B, tag, owner, clock) { } -tekram_dc320e_device::tekram_dc320e_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tekram_dc320e_device::tekram_dc320e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tekram_eisa_scsi_device(mconfig, TEKRAM_DC320E, tag, owner, clock) { } -tekram_dc820_device::tekram_dc820_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tekram_dc820_device::tekram_dc820_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tekram_eisa_scsi_device(mconfig, TEKRAM_DC820, tag, owner, clock) { } -tekram_dc820b_device::tekram_dc820b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tekram_dc820b_device::tekram_dc820b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tekram_eisa_scsi_device(mconfig, TEKRAM_DC820B, tag, owner, clock) { } @@ -214,7 +214,7 @@ void tekram_eisa_scsi_device::scsi_add(machine_config &config) void tekram_dc320b_device::device_add_mconfig(machine_config &config) { - I80186(config, m_mpu, 25'000'000); // verified for DC-320, but not DC-320B + I80186(config, m_mpu, XTAL::u(25'000'000)); // verified for DC-320, but not DC-320B m_mpu->set_addrmap(AS_PROGRAM, &tekram_dc320b_device::mpu_map); GENERIC_LATCH_8(config, m_cmdlatch); @@ -224,17 +224,17 @@ void tekram_dc320b_device::device_add_mconfig(machine_config &config) EEPROM_93C46_16BIT(config, m_eeprom); - i82355_device &bmic(I82355(config, "bmic", 0)); + i82355_device &bmic(I82355(config, "bmic")); bmic.lint_callback().set(m_mpu, FUNC(i80186_cpu_device::int2_w)); scsi_add(config); - WD37C65C(config, m_fdc, 32'000'000, 9'600'000); // clocks verified for DC-320, but not DC-320B + WD37C65C(config, m_fdc, XTAL::u(32'000'000), 9'600'000); // clocks verified for DC-320, but not DC-320B } void tekram_dc320e_device::device_add_mconfig(machine_config &config) { - I80186(config, m_mpu, 32'000'000); // clock guessed to be same as DC-820B due to identical firmware + I80186(config, m_mpu, XTAL::u(32'000'000)); // clock guessed to be same as DC-820B due to identical firmware m_mpu->set_addrmap(AS_PROGRAM, &tekram_dc320e_device::mpu_map); GENERIC_LATCH_8(config, m_cmdlatch); @@ -244,12 +244,12 @@ void tekram_dc320e_device::device_add_mconfig(machine_config &config) EEPROM_93C46_16BIT(config, m_eeprom); - i82355_device &bmic(I82355(config, "bmic", 0)); + i82355_device &bmic(I82355(config, "bmic")); bmic.lint_callback().set(m_mpu, FUNC(i80186_cpu_device::int2_w)); scsi_add(config); - WD37C65C(config, m_fdc, 32'000'000, 9'600'000); // clocks verified for DC-320, but not DC-320E + WD37C65C(config, m_fdc, XTAL::u(32'000'000), 9'600'000); // clocks verified for DC-320, but not DC-320E } void tekram_dc820_device::device_add_mconfig(machine_config &config) @@ -264,7 +264,7 @@ void tekram_dc820_device::device_add_mconfig(machine_config &config) EEPROM_93C46_16BIT(config, m_eeprom); - i82355_device &bmic(I82355(config, "bmic", 0)); + i82355_device &bmic(I82355(config, "bmic")); bmic.lint_callback().set(m_mpu, FUNC(i80186_cpu_device::int2_w)); scsi_add(config); @@ -284,7 +284,7 @@ void tekram_dc820b_device::device_add_mconfig(machine_config &config) EEPROM_93C46_16BIT(config, m_eeprom); - i82355_device &bmic(I82355(config, "bmic", 0)); + i82355_device &bmic(I82355(config, "bmic")); bmic.lint_callback().set(m_mpu, FUNC(i80186_cpu_device::int2_w)); scsi_add(config); diff --git a/src/devices/bus/isa/tekram_dc820.h b/src/devices/bus/isa/tekram_dc820.h index 2308eb8655a..73177ecaef3 100644 --- a/src/devices/bus/isa/tekram_dc820.h +++ b/src/devices/bus/isa/tekram_dc820.h @@ -22,7 +22,7 @@ public: static constexpr feature_type unemulated_features() { return feature::DISK; } protected: - tekram_eisa_scsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + tekram_eisa_scsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -49,7 +49,7 @@ protected: class tekram_dc320b_device : public tekram_eisa_scsi_device { public: - tekram_dc320b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tekram_dc320b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -66,7 +66,7 @@ private: class tekram_dc320e_device : public tekram_eisa_scsi_device { public: - tekram_dc320e_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tekram_dc320e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -79,7 +79,7 @@ private: class tekram_dc820_device : public tekram_eisa_scsi_device { public: - tekram_dc820_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tekram_dc820_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -94,7 +94,7 @@ private: class tekram_dc820b_device : public tekram_eisa_scsi_device { public: - tekram_dc820b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tekram_dc820b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/isa/trident.cpp b/src/devices/bus/isa/trident.cpp index 943f0de3432..1a91782c2f0 100644 --- a/src/devices/bus/isa/trident.cpp +++ b/src/devices/bus/isa/trident.cpp @@ -23,18 +23,18 @@ DEFINE_DEVICE_TYPE(TVGA9000_VGA, tvga9000_device, "tvga9000_vga", "Trident TVGA9 #define LOG (1) #define LOG_ACCEL (1) -trident_vga_device::trident_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +trident_vga_device::trident_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : svga_device(mconfig, type, tag, owner, clock) { } -tgui9860_device::tgui9860_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tgui9860_device::tgui9860_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : trident_vga_device(mconfig, TRIDENT_VGA, tag, owner, clock) { m_version = 0xd3; // 0xd3 identifies at TGUI9660XGi (set to 0xe3 to identify at TGUI9440AGi) } -tvga9000_device::tvga9000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tvga9000_device::tvga9000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : trident_vga_device(mconfig, TVGA9000_VGA, tag, owner, clock) { m_version = 0x43; diff --git a/src/devices/bus/isa/trident.h b/src/devices/bus/isa/trident.h index 3dc8f63947c..6ffe4457dbc 100644 --- a/src/devices/bus/isa/trident.h +++ b/src/devices/bus/isa/trident.h @@ -38,7 +38,7 @@ public: protected: // construction/destruction - trident_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + trident_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -152,13 +152,13 @@ private: class tgui9860_device : public trident_vga_device { public: - tgui9860_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tgui9860_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tvga9000_device : public trident_vga_device { public: - tvga9000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tvga9000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/bus/isa/ultra12f.cpp b/src/devices/bus/isa/ultra12f.cpp index fb5f89e485c..de3133efd6e 100644 --- a/src/devices/bus/isa/ultra12f.cpp +++ b/src/devices/bus/isa/ultra12f.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(ULTRA12F, ultra12f_device, "ultra12f", "Ultra 12F ESDI Caching Disk Controller") DEFINE_DEVICE_TYPE(ULTRA12F32, ultra12f32_device, "ultra12f32", "Ultra 12F/32 ESDI Caching Disk Controller") -ultra12f_device::ultra12f_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +ultra12f_device::ultra12f_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_hpc(*this, "hpc") @@ -26,12 +26,12 @@ ultra12f_device::ultra12f_device(const machine_config &mconfig, device_type type { } -ultra12f_device::ultra12f_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ultra12f_device::ultra12f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ultra12f_device(mconfig, ULTRA12F, tag, owner, clock) { } -ultra12f32_device::ultra12f32_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ultra12f32_device::ultra12f32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ultra12f_device(mconfig, ULTRA12F32, tag, owner, clock) { } diff --git a/src/devices/bus/isa/ultra12f.h b/src/devices/bus/isa/ultra12f.h index f4bb05d61c7..5ba993e3920 100644 --- a/src/devices/bus/isa/ultra12f.h +++ b/src/devices/bus/isa/ultra12f.h @@ -18,12 +18,12 @@ class ultra12f_device : public device_t, public device_isa16_card_interface { public: - ultra12f_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ultra12f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } protected: - ultra12f_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + ultra12f_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual ioport_constructor device_input_ports() const override; @@ -41,7 +41,7 @@ private: class ultra12f32_device : public ultra12f_device { public: - ultra12f32_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ultra12f32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/isa/ultra14f.cpp b/src/devices/bus/isa/ultra14f.cpp index f97b0acb54e..d5c5cf7447c 100644 --- a/src/devices/bus/isa/ultra14f.cpp +++ b/src/devices/bus/isa/ultra14f.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(ULTRA14F, ultra14f_device, "ultra14f", "Ultra-14F SCSI Host Adapter") -ultra14f_device::ultra14f_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ultra14f_device::ultra14f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ULTRA14F, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_uscpu(*this, "uscpu") diff --git a/src/devices/bus/isa/ultra14f.h b/src/devices/bus/isa/ultra14f.h index 9661e24a4b3..b56869bb1c0 100644 --- a/src/devices/bus/isa/ultra14f.h +++ b/src/devices/bus/isa/ultra14f.h @@ -17,7 +17,7 @@ class ultra14f_device : public device_t, public device_isa16_card_interface { public: - ultra14f_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ultra14f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/isa/ultra24f.cpp b/src/devices/bus/isa/ultra24f.cpp index 211c1ab4b80..3ea77976752 100644 --- a/src/devices/bus/isa/ultra24f.cpp +++ b/src/devices/bus/isa/ultra24f.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(ULTRA24F, ultra24f_device, "ultra24f", "Ultra-24F SCSI Host Adapter") -ultra24f_device::ultra24f_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ultra24f_device::ultra24f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ULTRA24F, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , m_uscpu(*this, "uscpu") @@ -69,7 +69,7 @@ void ultra24f_device::device_add_mconfig(machine_config &config) M68000(config, m_uscpu, 32_MHz_XTAL / 4); // custom-marked as USC080-5-12A; clock guessed m_uscpu->set_addrmap(AS_PROGRAM, &ultra24f_device::uscpu_map); - I82355(config, m_bmic, 0); + I82355(config, m_bmic); NSCSI_BUS(config, "scsi"); NSCSI_CONNECTOR(config, "scsi:0", default_scsi_devices, nullptr); diff --git a/src/devices/bus/isa/ultra24f.h b/src/devices/bus/isa/ultra24f.h index 69a5d3a29d2..628561cba86 100644 --- a/src/devices/bus/isa/ultra24f.h +++ b/src/devices/bus/isa/ultra24f.h @@ -18,7 +18,7 @@ class ultra24f_device : public device_t, public device_isa16_card_interface { public: - ultra24f_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ultra24f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/isa/vga.cpp b/src/devices/bus/isa/vga.cpp index b573f4c5701..e4b250b99d0 100644 --- a/src/devices/bus/isa/vga.cpp +++ b/src/devices/bus/isa/vga.cpp @@ -33,7 +33,7 @@ void isa8_vga_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update(m_vga, FUNC(vga_device::screen_update)); - VGA(config, m_vga, 0); + VGA(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x100000); } @@ -55,7 +55,7 @@ const tiny_rom_entry *isa8_vga_device::device_rom_region() const // isa8_vga_device - constructor //------------------------------------------------- -isa8_vga_device::isa8_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa8_vga_device::isa8_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_VGA, tag, owner, clock), device_isa8_card_interface(mconfig, *this), m_vga(*this, "vga") diff --git a/src/devices/bus/isa/vga.h b/src/devices/bus/isa/vga.h index c1b4d7226aa..6771dc54031 100644 --- a/src/devices/bus/isa/vga.h +++ b/src/devices/bus/isa/vga.h @@ -20,7 +20,7 @@ class isa8_vga_device : { public: // construction/destruction - isa8_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); diff --git a/src/devices/bus/isa/vga_ati.cpp b/src/devices/bus/isa/vga_ati.cpp index aaebcf3969b..99772daaa75 100644 --- a/src/devices/bus/isa/vga_ati.cpp +++ b/src/devices/bus/isa/vga_ati.cpp @@ -82,7 +82,7 @@ void isa16_vga_gfxultra_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update(m_vga, FUNC(ati_vga_device::screen_update)); - ATI_VGA(config, m_vga, 0); + ATI_VGA(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x100000); } @@ -93,7 +93,7 @@ void isa16_vga_gfxultrapro_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update(m_vga, FUNC(mach32_device::screen_update)); - ATIMACH32(config, m_vga, 0); + ATIMACH32(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x400000); } @@ -104,7 +104,7 @@ void isa16_vga_mach64_device::device_add_mconfig(machine_config &config) screen.set_raw(25.175_MHz_XTAL, 800, 0, 640, 524, 0, 480); screen.set_screen_update(m_vga, FUNC(mach64_device::screen_update)); - ATIMACH64(config, m_vga, 0); + ATIMACH64(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x400000); } @@ -137,21 +137,21 @@ const tiny_rom_entry *isa16_vga_mach64_device::device_rom_region() const // isa8_vga_device - constructor //------------------------------------------------- -isa16_vga_gfxultra_device::isa16_vga_gfxultra_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_vga_gfxultra_device::isa16_vga_gfxultra_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_VGA_GFXULTRA, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_vga(*this, "vga"), m_8514(*this, "vga:8514a") { } -isa16_vga_gfxultrapro_device::isa16_vga_gfxultrapro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_vga_gfxultrapro_device::isa16_vga_gfxultrapro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_SVGA_GFXULTRAPRO, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_vga(*this, "vga") { } -isa16_vga_mach64_device::isa16_vga_mach64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isa16_vga_mach64_device::isa16_vga_mach64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA16_SVGA_MACH64, tag, owner, clock), device_isa16_card_interface(mconfig, *this), m_vga(*this, "vga") diff --git a/src/devices/bus/isa/vga_ati.h b/src/devices/bus/isa/vga_ati.h index f92f3c563ca..6a9c563bc56 100644 --- a/src/devices/bus/isa/vga_ati.h +++ b/src/devices/bus/isa/vga_ati.h @@ -28,7 +28,7 @@ class isa16_vga_gfxultra_device : { public: // construction/destruction - isa16_vga_gfxultra_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_vga_gfxultra_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); @@ -52,7 +52,7 @@ class isa16_vga_gfxultrapro_device : { public: // construction/destruction - isa16_vga_gfxultrapro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_vga_gfxultrapro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); @@ -75,7 +75,7 @@ class isa16_vga_mach64_device : { public: // construction/destruction - isa16_vga_mach64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa16_vga_mach64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t input_port_0_r(); diff --git a/src/devices/bus/isa/wd1002a_wx1.cpp b/src/devices/bus/isa/wd1002a_wx1.cpp index 2e86d3b0523..cd52fbfb925 100644 --- a/src/devices/bus/isa/wd1002a_wx1.cpp +++ b/src/devices/bus/isa/wd1002a_wx1.cpp @@ -46,7 +46,7 @@ const tiny_rom_entry *isa8_wd1002a_wx1_device::device_rom_region() const // isa8_wd1002a_wx1_device - constructor //------------------------------------------------- -isa8_wd1002a_wx1_device::isa8_wd1002a_wx1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +isa8_wd1002a_wx1_device::isa8_wd1002a_wx1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_WD1002A_WX1, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) { diff --git a/src/devices/bus/isa/wd1002a_wx1.h b/src/devices/bus/isa/wd1002a_wx1.h index 7a66db54dd5..9d9e13576b4 100644 --- a/src/devices/bus/isa/wd1002a_wx1.h +++ b/src/devices/bus/isa/wd1002a_wx1.h @@ -26,7 +26,7 @@ class isa8_wd1002a_wx1_device : public device_t, { public: // construction/destruction - isa8_wd1002a_wx1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isa8_wd1002a_wx1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/isa/wd1007a.cpp b/src/devices/bus/isa/wd1007a.cpp index 22d9863e392..b83ce881fb4 100644 --- a/src/devices/bus/isa/wd1007a.cpp +++ b/src/devices/bus/isa/wd1007a.cpp @@ -34,7 +34,7 @@ const tiny_rom_entry *wd1007a_device::device_rom_region() const // wd1007a_device - constructor //------------------------------------------------- -wd1007a_device::wd1007a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +wd1007a_device::wd1007a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WD1007A, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) { diff --git a/src/devices/bus/isa/wd1007a.h b/src/devices/bus/isa/wd1007a.h index 1a761ecb66d..320acd80e63 100644 --- a/src/devices/bus/isa/wd1007a.h +++ b/src/devices/bus/isa/wd1007a.h @@ -25,7 +25,7 @@ class wd1007a_device : public device_t, public device_isa16_card_interface { public: // construction/destruction - wd1007a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd1007a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } protected: diff --git a/src/devices/bus/isa/wdxt_gen.cpp b/src/devices/bus/isa/wdxt_gen.cpp index fb2a8fd1965..dd849835376 100644 --- a/src/devices/bus/isa/wdxt_gen.cpp +++ b/src/devices/bus/isa/wdxt_gen.cpp @@ -139,7 +139,7 @@ void wdxt_gen_device::ram_w(offs_t offset, uint8_t data) void wdxt_gen_device::device_add_mconfig(machine_config &config) { - mcs48_cpu_device &cpu(I8049(config, m_maincpu, 5000000)); + mcs48_cpu_device &cpu(I8049(config, m_maincpu, XTAL::u(5000000))); cpu.set_addrmap(AS_IO, &wdxt_gen_device::wd1015_io); cpu.t0_in_cb().set(m_host, FUNC(wd11c00_17_device::busy_r)); cpu.t1_in_cb().set(FUNC(wdxt_gen_device::wd1015_t1_r)); @@ -148,7 +148,7 @@ void wdxt_gen_device::device_add_mconfig(machine_config &config) cpu.p2_in_cb().set(FUNC(wdxt_gen_device::wd1015_p2_r)); cpu.p2_out_cb().set(FUNC(wdxt_gen_device::wd1015_p2_w)); - WD11C00_17(config, m_host, 5000000); + WD11C00_17(config, m_host, XTAL::u(5000000)); m_host->out_irq5_callback().set(FUNC(wdxt_gen_device::irq5_w)); m_host->out_drq3_callback().set(FUNC(wdxt_gen_device::drq3_w)); m_host->out_mr_callback().set(FUNC(wdxt_gen_device::mr_w)); @@ -159,7 +159,7 @@ void wdxt_gen_device::device_add_mconfig(machine_config &config) m_host->in_cs1010_callback().set(m_hdc, FUNC(wd2010_device::read)); m_host->out_cs1010_callback().set(m_hdc, FUNC(wd2010_device::write)); - WD2010(config, m_hdc, 5000000); + WD2010(config, m_hdc, XTAL::u(5000000)); m_hdc->out_bcr_callback().set(m_host, FUNC(wd11c00_17_device::clct_w)); m_hdc->in_bcs_callback().set(m_host, FUNC(wd11c00_17_device::read)); m_hdc->out_bcs_callback().set(m_host, FUNC(wd11c00_17_device::write)); @@ -169,8 +169,8 @@ void wdxt_gen_device::device_add_mconfig(machine_config &config) m_hdc->in_tk000_callback().set_constant(1); m_hdc->in_sc_callback().set_constant(1); - HARDDISK(config, "hard0", 0); - HARDDISK(config, "hard1", 0); + HARDDISK(config, "hard0"); + HARDDISK(config, "hard1"); } @@ -182,7 +182,7 @@ void wdxt_gen_device::device_add_mconfig(machine_config &config) // wdxt_gen_device - constructor //------------------------------------------------- -wdxt_gen_device::wdxt_gen_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +wdxt_gen_device::wdxt_gen_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_WDXT_GEN, tag, owner, clock) , device_isa8_card_interface(mconfig, *this) , m_maincpu(*this, WD1015_TAG) diff --git a/src/devices/bus/isa/wdxt_gen.h b/src/devices/bus/isa/wdxt_gen.h index f238f6750a1..ee55e60bd2c 100644 --- a/src/devices/bus/isa/wdxt_gen.h +++ b/src/devices/bus/isa/wdxt_gen.h @@ -38,7 +38,7 @@ class wdxt_gen_device : public device_t, { public: // construction/destruction - wdxt_gen_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wdxt_gen_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isa/xtide.cpp b/src/devices/bus/isa/xtide.cpp index a22f69a9b13..c62d610e82e 100644 --- a/src/devices/bus/isa/xtide.cpp +++ b/src/devices/bus/isa/xtide.cpp @@ -295,7 +295,7 @@ const tiny_rom_entry *xtide_device::device_rom_region() const // xtide_device - constructor //------------------------------------------------- -xtide_device::xtide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +xtide_device::xtide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISA8_XTIDE, tag, owner, clock), device_isa8_card_interface( mconfig, *this ), m_ata(*this, "ata"), diff --git a/src/devices/bus/isa/xtide.h b/src/devices/bus/isa/xtide.h index b06d39d5dbb..b7a450d0a7c 100644 --- a/src/devices/bus/isa/xtide.h +++ b/src/devices/bus/isa/xtide.h @@ -17,7 +17,7 @@ class xtide_device : public device_t, public device_isa8_card_interface { public: // construction/destruction - xtide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xtide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/bus/isbx/compis_fdc.cpp b/src/devices/bus/isbx/compis_fdc.cpp index b4f72b220ef..f061d933a0d 100644 --- a/src/devices/bus/isbx/compis_fdc.cpp +++ b/src/devices/bus/isbx/compis_fdc.cpp @@ -58,7 +58,7 @@ static void compis_floppies(device_slot_interface &device) void compis_fdc_device::device_add_mconfig(machine_config &config) { - I8272A(config, m_fdc, 8'000'000, true); + I8272A(config, m_fdc, XTAL::u(8'000'000), true); m_fdc->intrq_wr_callback().set(FUNC(compis_fdc_device::fdc_irq)); m_fdc->drq_wr_callback().set(FUNC(compis_fdc_device::fdc_drq)); FLOPPY_CONNECTOR(config, m_floppy0, compis_floppies, "525qd", compis_fdc_device::floppy_formats); @@ -75,7 +75,7 @@ void compis_fdc_device::device_add_mconfig(machine_config &config) // compis_fdc_device - constructor //------------------------------------------------- -compis_fdc_device::compis_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +compis_fdc_device::compis_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COMPIS_FDC, tag, owner, clock), device_isbx_card_interface(mconfig, *this), m_fdc(*this, I8272_TAG), diff --git a/src/devices/bus/isbx/compis_fdc.h b/src/devices/bus/isbx/compis_fdc.h index 5e50b3a3696..845803ee907 100644 --- a/src/devices/bus/isbx/compis_fdc.h +++ b/src/devices/bus/isbx/compis_fdc.h @@ -29,7 +29,7 @@ class compis_fdc_device : public device_t, { public: // construction/destruction - compis_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + compis_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isbx/isbc_218a.cpp b/src/devices/bus/isbx/isbc_218a.cpp index 3c1dd92b4fa..227b7bc8942 100644 --- a/src/devices/bus/isbx/isbc_218a.cpp +++ b/src/devices/bus/isbx/isbc_218a.cpp @@ -63,7 +63,7 @@ void isbc_218a_device::device_add_mconfig(machine_config &config) // isbc_218a_device - constructor //------------------------------------------------- -isbc_218a_device::isbc_218a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isbc_218a_device::isbc_218a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISBC_218A, tag, owner, clock), device_isbx_card_interface(mconfig, *this), m_fdc(*this, I8272_TAG), @@ -94,7 +94,7 @@ void isbc_218a_device::device_reset() if(m_fd8) { m_floppy0->get_device()->mon_w(0); - m_fdc->set_rate(500000); + m_fdc->set_rate(XTAL::u(500000)); } } diff --git a/src/devices/bus/isbx/isbc_218a.h b/src/devices/bus/isbx/isbc_218a.h index c654c74aae8..791a3f4601c 100644 --- a/src/devices/bus/isbx/isbc_218a.h +++ b/src/devices/bus/isbx/isbc_218a.h @@ -29,7 +29,7 @@ class isbc_218a_device : public device_t, { public: // construction/destruction - isbc_218a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isbc_218a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/isbx/isbx.cpp b/src/devices/bus/isbx/isbx.cpp index 373d147cadd..2fffdd48aac 100644 --- a/src/devices/bus/isbx/isbx.cpp +++ b/src/devices/bus/isbx/isbx.cpp @@ -38,7 +38,7 @@ device_isbx_card_interface::device_isbx_card_interface(const machine_config &mco // isbx_slot_device - constructor //------------------------------------------------- -isbx_slot_device::isbx_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +isbx_slot_device::isbx_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISBX_SLOT, tag, owner, clock), device_single_card_slot_interface<device_isbx_card_interface>(mconfig, *this), m_write_mintr0(*this), diff --git a/src/devices/bus/isbx/isbx.h b/src/devices/bus/isbx/isbx.h index af9c51aa842..54b151d6f20 100644 --- a/src/devices/bus/isbx/isbx.h +++ b/src/devices/bus/isbx/isbx.h @@ -75,15 +75,15 @@ class isbx_slot_device : public device_t, public device_single_card_slot_interfa public: // construction/destruction template <typename T> - isbx_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) - : isbx_slot_device(mconfig, tag, owner, clock) + isbx_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) + : isbx_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - isbx_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + isbx_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto mintr0() { return m_write_mintr0.bind(); } auto mintr1() { return m_write_mintr1.bind(); } diff --git a/src/devices/bus/jakks_gamekey/rom.cpp b/src/devices/bus/jakks_gamekey/rom.cpp index 4492d62bddb..07887ee976c 100644 --- a/src/devices/bus/jakks_gamekey/rom.cpp +++ b/src/devices/bus/jakks_gamekey/rom.cpp @@ -13,28 +13,28 @@ DEFINE_DEVICE_TYPE(JAKKS_GAMEKEY_ROM_I2C_BASE, jakks_gamekey_rom_i2c_base_d DEFINE_DEVICE_TYPE(JAKKS_GAMEKEY_ROM_I2C_24LC04, jakks_gamekey_rom_i2c_24lc04_device, "jakks_gamekey_rom_i2c_24lc04", "JAKKS Pacific GameKey with I2C 24LC04") -jakks_gamekey_rom_plain_device::jakks_gamekey_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +jakks_gamekey_rom_plain_device::jakks_gamekey_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_jakks_gamekey_interface(mconfig, *this) { } -jakks_gamekey_rom_plain_device::jakks_gamekey_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +jakks_gamekey_rom_plain_device::jakks_gamekey_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : jakks_gamekey_rom_plain_device(mconfig, JAKKS_GAMEKEY_ROM_PLAIN, tag, owner, clock) { } -jakks_gamekey_rom_i2c_base_device::jakks_gamekey_rom_i2c_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +jakks_gamekey_rom_i2c_base_device::jakks_gamekey_rom_i2c_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : jakks_gamekey_rom_plain_device(mconfig, type, tag, owner, clock), m_i2cmem(*this, "i2cmem") { } -jakks_gamekey_rom_i2c_base_device::jakks_gamekey_rom_i2c_base_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +jakks_gamekey_rom_i2c_base_device::jakks_gamekey_rom_i2c_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : jakks_gamekey_rom_i2c_base_device(mconfig, JAKKS_GAMEKEY_ROM_I2C_BASE, tag, owner, clock) { } -jakks_gamekey_rom_i2c_24lc04_device::jakks_gamekey_rom_i2c_24lc04_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +jakks_gamekey_rom_i2c_24lc04_device::jakks_gamekey_rom_i2c_24lc04_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : jakks_gamekey_rom_i2c_base_device(mconfig, JAKKS_GAMEKEY_ROM_I2C_24LC04, tag, owner, clock) { } @@ -96,7 +96,7 @@ void jakks_gamekey_rom_i2c_base_device::write_cart_seeprom(offs_t offset, uint16 void jakks_gamekey_rom_i2c_24lc04_device::device_add_mconfig(machine_config &config) { - I2C_24C04(config, "i2cmem", 0); // 24LC04 + I2C_24C04(config, "i2cmem"); // 24LC04 } diff --git a/src/devices/bus/jakks_gamekey/rom.h b/src/devices/bus/jakks_gamekey/rom.h index efd9f8d9c7b..00cb33ff2fd 100644 --- a/src/devices/bus/jakks_gamekey/rom.h +++ b/src/devices/bus/jakks_gamekey/rom.h @@ -15,7 +15,7 @@ class jakks_gamekey_rom_plain_device : public device_t, { public: // construction/destruction - jakks_gamekey_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + jakks_gamekey_rom_plain_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_cart(offs_t offset) override; @@ -28,7 +28,7 @@ public: virtual void write_rom(offs_t offset, uint16_t data); protected: - jakks_gamekey_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + jakks_gamekey_rom_plain_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -41,10 +41,10 @@ class jakks_gamekey_rom_i2c_base_device : public jakks_gamekey_rom_plain_device { public: // construction/destruction - jakks_gamekey_rom_i2c_base_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + jakks_gamekey_rom_i2c_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - jakks_gamekey_rom_i2c_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + jakks_gamekey_rom_i2c_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_rom(offs_t offset) override; @@ -63,7 +63,7 @@ class jakks_gamekey_rom_i2c_24lc04_device : public jakks_gamekey_rom_i2c_base_de { public: // construction/destruction - jakks_gamekey_rom_i2c_24lc04_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + jakks_gamekey_rom_i2c_24lc04_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/jakks_gamekey/slot.cpp b/src/devices/bus/jakks_gamekey/slot.cpp index 40fd58b0713..f79f0cd3e60 100644 --- a/src/devices/bus/jakks_gamekey/slot.cpp +++ b/src/devices/bus/jakks_gamekey/slot.cpp @@ -54,7 +54,7 @@ void device_jakks_gamekey_interface::rom_alloc(uint32_t size, const char *tag) //------------------------------------------------- // jakks_gamekey_slot_device - constructor //------------------------------------------------- -jakks_gamekey_slot_device::jakks_gamekey_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +jakks_gamekey_slot_device::jakks_gamekey_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, JAKKS_GAMEKEY_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_jakks_gamekey_interface>(mconfig, *this), diff --git a/src/devices/bus/jakks_gamekey/slot.h b/src/devices/bus/jakks_gamekey/slot.h index 0f02ca86e43..01df5981f8f 100644 --- a/src/devices/bus/jakks_gamekey/slot.h +++ b/src/devices/bus/jakks_gamekey/slot.h @@ -54,10 +54,10 @@ class jakks_gamekey_slot_device : public device_t, { public: // construction/destruction - jakks_gamekey_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + jakks_gamekey_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> - jakks_gamekey_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + jakks_gamekey_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : jakks_gamekey_slot_device(mconfig, tag, owner, clock) { option_reset(); diff --git a/src/devices/bus/kc/d002.cpp b/src/devices/bus/kc/d002.cpp index 288d2278578..73abe806583 100644 --- a/src/devices/bus/kc/d002.cpp +++ b/src/devices/bus/kc/d002.cpp @@ -82,7 +82,7 @@ DEFINE_DEVICE_TYPE(KC_D002, kc_d002_device, "kc_d002", "D002 Bus Driver") // kc_d002_device - constructor //------------------------------------------------- -kc_d002_device::kc_d002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_d002_device::kc_d002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, KC_D002, tag, owner, clock) , device_kcexp_interface(mconfig, *this) , m_slot(nullptr) diff --git a/src/devices/bus/kc/d002.h b/src/devices/bus/kc/d002.h index 7db1418bf5f..caf734506b6 100644 --- a/src/devices/bus/kc/d002.h +++ b/src/devices/bus/kc/d002.h @@ -19,7 +19,7 @@ class kc_d002_device : { public: // construction/destruction - kc_d002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_d002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/kc/d004.cpp b/src/devices/bus/kc/d004.cpp index 45905b23b1d..aec2ebf859d 100644 --- a/src/devices/bus/kc/d004.cpp +++ b/src/devices/bus/kc/d004.cpp @@ -104,12 +104,12 @@ DEFINE_DEVICE_TYPE(KC_D004_GIDE, kc_d004_gide_device, "kc_d004_gide", "D004 Flop // kc_d004_device - constructor //------------------------------------------------- -kc_d004_device::kc_d004_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_d004_device::kc_d004_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_d004_device(mconfig, KC_D004, tag, owner, clock) { } -kc_d004_device::kc_d004_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +kc_d004_device::kc_d004_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_kcexp_interface( mconfig, *this ), m_cpu(*this, Z80_TAG), @@ -364,7 +364,7 @@ WRITE_LINE_MEMBER(kc_d004_device::fdc_irq) // kc_d004_gide_device - constructor //------------------------------------------------- -kc_d004_gide_device::kc_d004_gide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_d004_gide_device::kc_d004_gide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_d004_device(mconfig, KC_D004_GIDE, tag, owner, clock), m_ata(*this, ATA_TAG), m_ata_data(0), m_lh(0) { diff --git a/src/devices/bus/kc/d004.h b/src/devices/bus/kc/d004.h index 570f378b4fa..4bac03dba67 100644 --- a/src/devices/bus/kc/d004.h +++ b/src/devices/bus/kc/d004.h @@ -26,10 +26,10 @@ class kc_d004_device : { public: // construction/destruction - kc_d004_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_d004_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - kc_d004_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + kc_d004_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -89,7 +89,7 @@ class kc_d004_gide_device : { public: // construction/destruction - kc_d004_gide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_d004_gide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/kc/kc.cpp b/src/devices/bus/kc/kc.cpp index 5e2b67cdab3..0a8112b6ad9 100644 --- a/src/devices/bus/kc/kc.cpp +++ b/src/devices/bus/kc/kc.cpp @@ -153,12 +153,12 @@ device_kcexp_interface::~device_kcexp_interface() //------------------------------------------------- // kcexp_slot_device - constructor //------------------------------------------------- -kcexp_slot_device::kcexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +kcexp_slot_device::kcexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kcexp_slot_device(mconfig, KCEXP_SLOT, tag, owner, clock) { } -kcexp_slot_device::kcexp_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +kcexp_slot_device::kcexp_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_single_card_slot_interface<device_kcexp_interface>(mconfig, *this), m_out_irq_cb(*this), @@ -298,7 +298,7 @@ WRITE_LINE_MEMBER( kcexp_slot_device::meo_w ) //------------------------------------------------- // kccart_slot_device - constructor //------------------------------------------------- -kccart_slot_device::kccart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +kccart_slot_device::kccart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kcexp_slot_device(mconfig, KCCART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this) { diff --git a/src/devices/bus/kc/kc.h b/src/devices/bus/kc/kc.h index fdb9cd467ce..45c8b52efac 100644 --- a/src/devices/bus/kc/kc.h +++ b/src/devices/bus/kc/kc.h @@ -49,14 +49,14 @@ public: // construction/destruction template <typename T> kcexp_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : kcexp_slot_device(mconfig, tag, owner, (uint32_t)0) + : kcexp_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - kcexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kcexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~kcexp_slot_device(); auto irq() { return m_out_irq_cb.bind(); } @@ -81,7 +81,7 @@ public: devcb_write_line m_out_halt_cb; protected: - kcexp_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + kcexp_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_validity_check(validity_checker &valid) const override; @@ -100,14 +100,14 @@ public: // construction/destruction template <typename T> kccart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : kccart_slot_device(mconfig, tag, owner, (uint32_t)0) + : kccart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - kccart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kccart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~kccart_slot_device(); // image-level overrides diff --git a/src/devices/bus/kc/ram.cpp b/src/devices/bus/kc/ram.cpp index 5e69b397508..3c654efd5cb 100644 --- a/src/devices/bus/kc/ram.cpp +++ b/src/devices/bus/kc/ram.cpp @@ -42,12 +42,12 @@ DEFINE_DEVICE_TYPE(KC_M036, kc_m036_device, "kc_m036", "M036 128KB segmented RAM // kc_m011_device - constructor //------------------------------------------------- -kc_m011_device::kc_m011_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_m011_device::kc_m011_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_m011_device(mconfig, KC_M011, tag, owner, clock) { } -kc_m011_device::kc_m011_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +kc_m011_device::kc_m011_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_kcexp_interface(mconfig, *this) , m_slot(nullptr), m_mei(0), m_ram(nullptr), m_enabled(0), m_write_enabled(0), m_base(0), m_segment(0) @@ -147,7 +147,7 @@ WRITE_LINE_MEMBER( kc_m011_device::mei_w ) // kc_m022_device - constructor //------------------------------------------------- -kc_m022_device::kc_m022_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_m022_device::kc_m022_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_m011_device(mconfig, KC_M022, tag, owner, clock) { } @@ -192,7 +192,7 @@ void kc_m022_device::write(offs_t offset, uint8_t data) // kc_m032_device - constructor //------------------------------------------------- -kc_m032_device::kc_m032_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_m032_device::kc_m032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_m011_device(mconfig, KC_M032, tag, owner, clock) { } @@ -261,7 +261,7 @@ void kc_m032_device::write(offs_t offset, uint8_t data) // kc_m034_device - constructor //------------------------------------------------- -kc_m034_device::kc_m034_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_m034_device::kc_m034_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_m011_device(mconfig, KC_M034, tag, owner, clock) { } @@ -330,7 +330,7 @@ void kc_m034_device::write(offs_t offset, uint8_t data) // kc_m035_device - constructor //------------------------------------------------- -kc_m035_device::kc_m035_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_m035_device::kc_m035_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_m011_device(mconfig, KC_M035, tag, owner, clock) { } @@ -388,7 +388,7 @@ void kc_m035_device::write(offs_t offset, uint8_t data) // kc_m036_device - constructor //------------------------------------------------- -kc_m036_device::kc_m036_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_m036_device::kc_m036_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_m011_device(mconfig, KC_M036, tag, owner, clock) { } diff --git a/src/devices/bus/kc/ram.h b/src/devices/bus/kc/ram.h index 823d32bdb31..93811052d74 100644 --- a/src/devices/bus/kc/ram.h +++ b/src/devices/bus/kc/ram.h @@ -19,10 +19,10 @@ class kc_m011_device : { public: // construction/destruction - kc_m011_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_m011_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - kc_m011_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + kc_m011_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -59,7 +59,7 @@ class kc_m022_device : { public: // construction/destruction - kc_m022_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_m022_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // kcexp_interface overrides @@ -80,7 +80,7 @@ class kc_m032_device : { public: // construction/destruction - kc_m032_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_m032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -105,7 +105,7 @@ class kc_m034_device : { public: // construction/destruction - kc_m034_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_m034_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -130,7 +130,7 @@ class kc_m035_device : { public: // construction/destruction - kc_m035_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_m035_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // kcexp_interface overrides @@ -152,7 +152,7 @@ class kc_m036_device : { public: // construction/destruction - kc_m036_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_m036_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/kc/rom.cpp b/src/devices/bus/kc/rom.cpp index eca6d6a1907..e431a69f788 100644 --- a/src/devices/bus/kc/rom.cpp +++ b/src/devices/bus/kc/rom.cpp @@ -42,12 +42,12 @@ DEFINE_DEVICE_TYPE(KC_M033, kc_m033_device, "kc_m033", "M033 TypeStar") // kc_8k_device - constructor //------------------------------------------------- -kc_8k_device::kc_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_8k_device::kc_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_8k_device(mconfig, KC_STANDARD, tag, owner, clock) { } -kc_8k_device::kc_8k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +kc_8k_device::kc_8k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_kcexp_interface(mconfig, *this) , m_slot(nullptr), m_mei(0), m_rom(nullptr), m_enabled(0), m_base(0) @@ -142,7 +142,7 @@ WRITE_LINE_MEMBER( kc_8k_device::mei_w ) // kc_m006_device - constructor //------------------------------------------------- -kc_m006_device::kc_m006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_m006_device::kc_m006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_8k_device(mconfig, KC_M006, tag, owner, clock) { } @@ -184,7 +184,7 @@ void kc_m006_device::read(offs_t offset, uint8_t &data) // kc_m033_device - constructor //------------------------------------------------- -kc_m033_device::kc_m033_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kc_m033_device::kc_m033_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc_8k_device(mconfig, KC_M033, tag, owner, clock) , m_bank(0) { diff --git a/src/devices/bus/kc/rom.h b/src/devices/bus/kc/rom.h index 024969d68b4..cb6ae70e072 100644 --- a/src/devices/bus/kc/rom.h +++ b/src/devices/bus/kc/rom.h @@ -19,10 +19,10 @@ class kc_8k_device : { public: // construction/destruction - kc_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - kc_8k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + kc_8k_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -54,7 +54,7 @@ class kc_m006_device : { public: // construction/destruction - kc_m006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_m006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // kcexp_interface overrides @@ -71,7 +71,7 @@ class kc_m033_device : { public: // construction/destruction - kc_m033_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kc_m033_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/lpci/cirrus.cpp b/src/devices/bus/lpci/cirrus.cpp index 659d39677a9..5ed7602e1d2 100644 --- a/src/devices/bus/lpci/cirrus.cpp +++ b/src/devices/bus/lpci/cirrus.cpp @@ -83,7 +83,7 @@ DEFINE_DEVICE_TYPE(PCI_CIRRUS_SVGA, pci_cirrus_svga_device, "pci_cirrus_svga", " // pci_cirrus_svga_device - constructor //------------------------------------------------- -pci_cirrus_svga_device::pci_cirrus_svga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pci_cirrus_svga_device::pci_cirrus_svga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCI_CIRRUS_SVGA, tag, owner, clock) , pci_device_interface(mconfig, *this) , m_vga(*this, "vga") diff --git a/src/devices/bus/lpci/cirrus.h b/src/devices/bus/lpci/cirrus.h index 9f158a79178..786132c1c7c 100644 --- a/src/devices/bus/lpci/cirrus.h +++ b/src/devices/bus/lpci/cirrus.h @@ -21,7 +21,7 @@ class pci_cirrus_svga_device : public device_t, public pci_device_interface { public: // construction/destruction - pci_cirrus_svga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pci_cirrus_svga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_vga(T &&tag) { m_vga.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/bus/lpci/i82371ab.cpp b/src/devices/bus/lpci/i82371ab.cpp index 6d9a1c72bc3..2ef0dda0839 100644 --- a/src/devices/bus/lpci/i82371ab.cpp +++ b/src/devices/bus/lpci/i82371ab.cpp @@ -36,7 +36,7 @@ DEFINE_DEVICE_TYPE(I82371AB, i82371ab_device, "i82371ab", "Intel 82371AB") -i82371ab_device::i82371ab_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82371ab_device::i82371ab_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : southbridge_extended_device(mconfig, I82371AB, tag, owner, clock) , pci_device_interface(mconfig, *this) { diff --git a/src/devices/bus/lpci/i82371ab.h b/src/devices/bus/lpci/i82371ab.h index 5080c135145..7e570bda6c4 100644 --- a/src/devices/bus/lpci/i82371ab.h +++ b/src/devices/bus/lpci/i82371ab.h @@ -23,7 +23,7 @@ class i82371ab_device : public southbridge_extended_device, { public: // construction/destruction - i82371ab_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82371ab_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint32_t pci_read(pci_bus_device *pcibus, int function, int offset, uint32_t mem_mask) override; virtual void pci_write(pci_bus_device *pcibus, int function, int offset, uint32_t data, uint32_t mem_mask) override; diff --git a/src/devices/bus/lpci/i82371sb.cpp b/src/devices/bus/lpci/i82371sb.cpp index 425fc563364..f38530f8f58 100644 --- a/src/devices/bus/lpci/i82371sb.cpp +++ b/src/devices/bus/lpci/i82371sb.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(I82371SB, i82371sb_device, "i82371sb", "Intel 82371SB") -i82371sb_device::i82371sb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82371sb_device::i82371sb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : southbridge_device(mconfig, I82371SB, tag, owner, clock) , pci_device_interface( mconfig, *this ) , m_smi_callback(*this) diff --git a/src/devices/bus/lpci/i82371sb.h b/src/devices/bus/lpci/i82371sb.h index 1b70d33857b..2f4a2e66c1b 100644 --- a/src/devices/bus/lpci/i82371sb.h +++ b/src/devices/bus/lpci/i82371sb.h @@ -22,7 +22,7 @@ class i82371sb_device : public southbridge_device, public pci_device_interface { public: // construction/destruction - i82371sb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82371sb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_cpu(T &&tag) { m_cpu.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/bus/lpci/i82439tx.cpp b/src/devices/bus/lpci/i82439tx.cpp index 0966456831a..4dd49dde714 100644 --- a/src/devices/bus/lpci/i82439tx.cpp +++ b/src/devices/bus/lpci/i82439tx.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(I82439TX_LEGACY, i82439tx_device, "i82439tx_legacy", "Intel 82439TX") -i82439tx_device::i82439tx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i82439tx_device::i82439tx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : northbridge_device(mconfig, I82439TX_LEGACY, tag, owner, clock), pci_device_interface(mconfig, *this), m_region_tag(nullptr), diff --git a/src/devices/bus/lpci/i82439tx.h b/src/devices/bus/lpci/i82439tx.h index af5a0dcf757..4c684124040 100644 --- a/src/devices/bus/lpci/i82439tx.h +++ b/src/devices/bus/lpci/i82439tx.h @@ -22,7 +22,7 @@ class i82439tx_device : public northbridge_device, public pci_device_interface { public: // construction/destruction - i82439tx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82439tx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_region(const char *tag) { m_region_tag = tag; } diff --git a/src/devices/bus/lpci/mpc105.cpp b/src/devices/bus/lpci/mpc105.cpp index de6eee2dcce..4f69fdb1f6f 100644 --- a/src/devices/bus/lpci/mpc105.cpp +++ b/src/devices/bus/lpci/mpc105.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(MPC105, mpc105_device, "mpc105", "Motorola MPC105") // mpc105_device - constructor //------------------------------------------------- -mpc105_device::mpc105_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpc105_device::mpc105_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MPC105, tag, owner, clock), pci_device_interface( mconfig, *this ), m_bank_base_default(0), diff --git a/src/devices/bus/lpci/mpc105.h b/src/devices/bus/lpci/mpc105.h index e469168189d..c4642ad5f10 100644 --- a/src/devices/bus/lpci/mpc105.h +++ b/src/devices/bus/lpci/mpc105.h @@ -26,7 +26,7 @@ class mpc105_device : public device_t, { public: // construction/destruction - mpc105_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpc105_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_cpu(T &&tag) { m_maincpu.set_tag(std::forward<T>(tag)); } void set_bank_base_default(int bank_base_default) { m_bank_base_default = bank_base_default; } diff --git a/src/devices/bus/lpci/northbridge.cpp b/src/devices/bus/lpci/northbridge.cpp index 0384a9637e4..1181929c872 100644 --- a/src/devices/bus/lpci/northbridge.cpp +++ b/src/devices/bus/lpci/northbridge.cpp @@ -13,7 +13,7 @@ // GLOBAL VARIABLES //************************************************************************** -northbridge_device::northbridge_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock) +northbridge_device::northbridge_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_cpu(*this, finder_base::DUMMY_TAG), m_ram(*this, ":" RAM_TAG) diff --git a/src/devices/bus/lpci/northbridge.h b/src/devices/bus/lpci/northbridge.h index 36282d93a9c..49174e07575 100644 --- a/src/devices/bus/lpci/northbridge.h +++ b/src/devices/bus/lpci/northbridge.h @@ -22,7 +22,7 @@ public: protected: // construction/destruction - northbridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + northbridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/lpci/pci.cpp b/src/devices/bus/lpci/pci.cpp index 34470bfa4f9..56a9da9f2a9 100644 --- a/src/devices/bus/lpci/pci.cpp +++ b/src/devices/bus/lpci/pci.cpp @@ -89,7 +89,7 @@ DEFINE_DEVICE_TYPE(PCI_BUS, pci_bus_device, "pci_bus", "PCI Bus") //------------------------------------------------- // pci_bus_device - constructor //------------------------------------------------- -pci_bus_device::pci_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pci_bus_device::pci_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCI_BUS, tag, owner, clock), m_busnum(0), m_address(0), m_devicenum(0), m_busnumber(0), m_busnumaddr(nullptr), m_father(*this, finder_base::DUMMY_TAG) @@ -328,7 +328,7 @@ pci_device_interface::~pci_device_interface() DEFINE_DEVICE_TYPE(PCI_CONNECTOR, pci_connector_device, "pci_connector", "PCI device connector abstraction") -pci_connector_device::pci_connector_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pci_connector_device::pci_connector_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCI_CONNECTOR, tag, owner, clock), device_single_card_slot_interface<pci_device_interface>(mconfig, *this) { diff --git a/src/devices/bus/lpci/pci.h b/src/devices/bus/lpci/pci.h index f962ddd6ff7..b9a647852f5 100644 --- a/src/devices/bus/lpci/pci.h +++ b/src/devices/bus/lpci/pci.h @@ -45,14 +45,14 @@ class pci_connector_device : public device_t, public: template <typename T> pci_connector_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt, bool fixed) - : pci_connector_device(mconfig, tag, owner, (uint32_t)0) + : pci_connector_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(fixed); } - pci_connector_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pci_connector_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~pci_connector_device(); pci_device_interface *get_device(); @@ -69,7 +69,7 @@ class pci_bus_device : public device_t { public: // construction/destruction - pci_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pci_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t read(offs_t offset, uint32_t mem_mask = ~0); void write(offs_t offset, uint32_t data, uint32_t mem_mask = ~0); diff --git a/src/devices/bus/lpci/southbridge.cpp b/src/devices/bus/lpci/southbridge.cpp index 2f9faa4aab0..33ded5cf5d4 100644 --- a/src/devices/bus/lpci/southbridge.cpp +++ b/src/devices/bus/lpci/southbridge.cpp @@ -27,7 +27,7 @@ void southbridge_device::device_add_mconfig(machine_config &config) { - PIT8254(config, m_pit8254, 0); + PIT8254(config, m_pit8254); m_pit8254->set_clk<0>(4772720/4); // heartbeat IRQ m_pit8254->out_handler<0>().set(FUNC(southbridge_device::at_pit8254_out0_changed)); m_pit8254->set_clk<1>(4772720/4); // DRAM refresh @@ -68,12 +68,12 @@ void southbridge_device::device_add_mconfig(machine_config &config) m_dma8237_2->out_dack_callback<2>().set(FUNC(southbridge_device::pc_dack6_w)); m_dma8237_2->out_dack_callback<3>().set(FUNC(southbridge_device::pc_dack7_w)); - PIC8259(config, m_pic8259_master, 0); + PIC8259(config, m_pic8259_master); m_pic8259_master->out_int_callback().set_inputline(m_maincpu, 0); m_pic8259_master->in_sp_callback().set_constant(1); m_pic8259_master->read_slave_ack_callback().set(FUNC(southbridge_device::get_slave_ack)); - PIC8259(config, m_pic8259_slave, 0); + PIC8259(config, m_pic8259_slave); m_pic8259_slave->out_int_callback().set(m_pic8259_master, FUNC(pic8259_device::ir2_w)); m_pic8259_slave->in_sp_callback().set_constant(0); @@ -89,7 +89,7 @@ void southbridge_device::device_add_mconfig(machine_config &config) SPEAKER(config, "mono").front_center(); SPEAKER_SOUND(config, m_speaker).add_route(ALL_OUTPUTS, "mono", 0.50); - ISA16(config, m_isabus, 0); + ISA16(config, m_isabus); m_isabus->set_memspace(":maincpu", AS_PROGRAM); m_isabus->set_iospace(":maincpu", AS_IO); m_isabus->irq3_callback().set("pic8259_master", FUNC(pic8259_device::ir3_w)); @@ -113,7 +113,7 @@ void southbridge_device::device_add_mconfig(machine_config &config) m_isabus->iochck_callback().set(FUNC(southbridge_device::iochck_w)); } -southbridge_device::southbridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +southbridge_device::southbridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_maincpu(*this, ":maincpu"), m_pic8259_master(*this, "pic8259_master"), @@ -536,12 +536,12 @@ void southbridge_extended_device::device_add_mconfig(machine_config &config) rtc.set_century_index(0x32); // on board devices - ISA16_SLOT(config, "board1", 0, "isabus", pc_isa_onboard, "fdcsmc", true); // FIXME: determine ISA bus clock - ISA16_SLOT(config, "board2", 0, "isabus", pc_isa_onboard, "comat", true); - ISA16_SLOT(config, "board3", 0, "isabus", pc_isa_onboard, "lpt", true); + ISA16_SLOT(config, "board1", "isabus", pc_isa_onboard, "fdcsmc", true); // FIXME: determine ISA bus clock + ISA16_SLOT(config, "board2", "isabus", pc_isa_onboard, "comat", true); + ISA16_SLOT(config, "board3", "isabus", pc_isa_onboard, "lpt", true); } -southbridge_extended_device::southbridge_extended_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +southbridge_extended_device::southbridge_extended_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : southbridge_device(mconfig, type, tag, owner, clock), m_keybc(*this, "keybc"), m_ds12885(*this, "rtc"), diff --git a/src/devices/bus/lpci/southbridge.h b/src/devices/bus/lpci/southbridge.h index 92953a5df0f..d4871ba1651 100644 --- a/src/devices/bus/lpci/southbridge.h +++ b/src/devices/bus/lpci/southbridge.h @@ -42,7 +42,7 @@ public: protected: // construction/destruction - southbridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + southbridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; @@ -146,7 +146,7 @@ public: protected: // construction/destruction - southbridge_extended_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + southbridge_extended_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/lpci/vt82c505.cpp b/src/devices/bus/lpci/vt82c505.cpp index a7bad9cc0a2..6de6e9b7cf0 100644 --- a/src/devices/bus/lpci/vt82c505.cpp +++ b/src/devices/bus/lpci/vt82c505.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(VT82C505, vt82c505_device, "vt82c505_device", "VIA VT82C505 PCI bridge") -vt82c505_device::vt82c505_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vt82c505_device::vt82c505_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VT82C505, tag, owner, clock) , pci_device_interface(mconfig, *this) { diff --git a/src/devices/bus/lpci/vt82c505.h b/src/devices/bus/lpci/vt82c505.h index bbe790781d2..28138781f92 100644 --- a/src/devices/bus/lpci/vt82c505.h +++ b/src/devices/bus/lpci/vt82c505.h @@ -15,7 +15,7 @@ class vt82c505_device : public device_t, public pci_device_interface { public: // construction/destruction - vt82c505_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vt82c505_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint32_t pci_read(pci_bus_device *pcibus, int function, int offset, uint32_t mem_mask) override; virtual void pci_write(pci_bus_device *pcibus, int function, int offset, uint32_t data, uint32_t mem_mask) override; diff --git a/src/devices/bus/m5/rom.cpp b/src/devices/bus/m5/rom.cpp index fbf80f5ce29..f619e912b20 100644 --- a/src/devices/bus/m5/rom.cpp +++ b/src/devices/bus/m5/rom.cpp @@ -21,19 +21,19 @@ DEFINE_DEVICE_TYPE(M5_ROM_STD, m5_rom_device, "m5_rom", "M5 Standard ROM Carts") DEFINE_DEVICE_TYPE(M5_ROM_RAM, m5_ram_device, "m5_ram", "M5 Expansion memory cart") -m5_rom_device::m5_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +m5_rom_device::m5_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_m5_cart_interface(mconfig, *this) { } -m5_rom_device::m5_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m5_rom_device::m5_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m5_rom_device(mconfig, M5_ROM_STD, tag, owner, clock) { } -m5_ram_device::m5_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m5_ram_device::m5_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m5_rom_device(mconfig, M5_ROM_RAM, tag, owner, clock) { } diff --git a/src/devices/bus/m5/rom.h b/src/devices/bus/m5/rom.h index 890f111cca8..27e537f6735 100644 --- a/src/devices/bus/m5/rom.h +++ b/src/devices/bus/m5/rom.h @@ -15,7 +15,7 @@ class m5_rom_device : public device_t, { public: // construction/destruction - m5_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m5_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override {} @@ -25,7 +25,7 @@ public: virtual uint8_t read_rom(offs_t offset) override; protected: - m5_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m5_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> m5_ram_device @@ -34,7 +34,7 @@ class m5_ram_device : public m5_rom_device { public: // construction/destruction - m5_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m5_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_ram(offs_t offset) override; diff --git a/src/devices/bus/m5/slot.cpp b/src/devices/bus/m5/slot.cpp index f82ba409d1e..0a84e25e320 100644 --- a/src/devices/bus/m5/slot.cpp +++ b/src/devices/bus/m5/slot.cpp @@ -71,7 +71,7 @@ void device_m5_cart_interface::ram_alloc(uint32_t size) //------------------------------------------------- // m5_cart_slot_device - constructor //------------------------------------------------- -m5_cart_slot_device::m5_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m5_cart_slot_device::m5_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, M5_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface(mconfig, *this), diff --git a/src/devices/bus/m5/slot.h b/src/devices/bus/m5/slot.h index 4f0d578cf1b..7518065470c 100644 --- a/src/devices/bus/m5/slot.h +++ b/src/devices/bus/m5/slot.h @@ -68,7 +68,7 @@ public: // construction/destruction template <typename T> m5_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : m5_cart_slot_device(mconfig, tag, owner, 0) + : m5_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -76,7 +76,7 @@ public: set_fixed(false); } - m5_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + m5_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~m5_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/mackbd/keyboard.cpp b/src/devices/bus/mackbd/keyboard.cpp index bda86980a05..8186b13dec6 100644 --- a/src/devices/bus/mackbd/keyboard.cpp +++ b/src/devices/bus/mackbd/keyboard.cpp @@ -256,7 +256,7 @@ public: } protected: - peripheral_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) + peripheral_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_mac_keyboard_interface(mconfig, *this) , m_mpu{ *this, "mpu" } @@ -271,7 +271,7 @@ protected: virtual void device_add_mconfig(machine_config &config) override { - I8021(config, m_mpu, 3'000'000); // 100µH inductor gives approximately 3MHz + I8021(config, m_mpu, XTAL::u(3'000'000)); // 100µH inductor gives approximately 3MHz m_mpu->p0_out_cb().set(FUNC(peripheral_base::host_clock_w)).bit(7); m_mpu->p2_out_cb().set(FUNC(peripheral_base::host_data_w)).bit(0); } @@ -383,7 +383,7 @@ private: class keyboard_base : public peripheral_base<9> { protected: - keyboard_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) + keyboard_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : peripheral_base<9>(mconfig, type, tag, owner, clock) { } @@ -416,7 +416,7 @@ public: } protected: - keypad_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) + keypad_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : peripheral_base<3>(mconfig, type, tag, owner, clock) , m_keyboard_port(*this, "kbd") { @@ -722,7 +722,7 @@ INPUT_PORTS_END class m0110_device : public keyboard_base { public: - m0110_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + m0110_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : keyboard_base(mconfig, MACKBD_M0110, tag, owner, clock) { } @@ -737,7 +737,7 @@ protected: class m0110b_device : public keyboard_base { public: - m0110b_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + m0110b_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : keyboard_base(mconfig, MACKBD_M0110B, tag, owner, clock) { } @@ -754,7 +754,7 @@ protected: class m0110f_device : public keyboard_base { public: - m0110f_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + m0110f_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : keyboard_base(mconfig, MACKBD_M0110F, tag, owner, clock) { } @@ -771,7 +771,7 @@ protected: class m0110t_device : public keyboard_base { public: - m0110t_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + m0110t_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : keyboard_base(mconfig, MACKBD_M0110T, tag, owner, clock) { } @@ -840,7 +840,7 @@ INPUT_PORTS_END class m0120_device : public keypad_base { public: - m0120_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + m0120_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : keypad_base(mconfig, MACKBD_M0120, tag, owner, clock) { } @@ -857,7 +857,7 @@ protected: class m0120p_device : public keypad_base { public: - m0120p_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + m0120p_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : keypad_base(mconfig, MACKBD_M0120P, tag, owner, clock) { } diff --git a/src/devices/bus/mackbd/mackbd.cpp b/src/devices/bus/mackbd/mackbd.cpp index 0e13787c9cf..853fbac9a6d 100644 --- a/src/devices/bus/mackbd/mackbd.cpp +++ b/src/devices/bus/mackbd/mackbd.cpp @@ -99,7 +99,7 @@ DEFINE_DEVICE_TYPE(MAC_KEYBOARD_PORT, mac_keyboard_port_device, "mackbd_port", " // HOST PORT //************************************************************************** -mac_keyboard_port_device::mac_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +mac_keyboard_port_device::mac_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MAC_KEYBOARD_PORT, tag, owner, clock) , device_single_card_slot_interface<device_mac_keyboard_interface>(mconfig, *this) , m_clock_cb{ *this } diff --git a/src/devices/bus/mackbd/mackbd.h b/src/devices/bus/mackbd/mackbd.h index 29be2d6e4ea..f436cca402d 100644 --- a/src/devices/bus/mackbd/mackbd.h +++ b/src/devices/bus/mackbd/mackbd.h @@ -33,14 +33,14 @@ class mac_keyboard_port_device : public device_t, public device_single_card_slot public: template <typename T> mac_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : mac_keyboard_port_device(mconfig, tag, owner, 0U) + : mac_keyboard_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - mac_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0U); + mac_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~mac_keyboard_port_device() override; auto clock_cb() { return m_clock_cb.bind(); } diff --git a/src/devices/bus/mackbd/pluskbd.cpp b/src/devices/bus/mackbd/pluskbd.cpp index de744f9219b..a477b1b3205 100644 --- a/src/devices/bus/mackbd/pluskbd.cpp +++ b/src/devices/bus/mackbd/pluskbd.cpp @@ -114,7 +114,7 @@ public: } protected: - keyboard_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) + keyboard_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_mac_keyboard_interface(mconfig, *this) , m_mpu{ *this, "mpu" } @@ -455,7 +455,7 @@ INPUT_PORTS_END class m0110a_device : public keyboard_base { public: - m0110a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + m0110a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : keyboard_base(mconfig, MACKBD_M0110A, tag, owner, clock) { } @@ -470,7 +470,7 @@ protected: class m0110a_f_device : public keyboard_base { public: - m0110a_f_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + m0110a_f_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : keyboard_base(mconfig, MACKBD_M0110A_F, tag, owner, clock) { } @@ -487,7 +487,7 @@ protected: class m0110a_j_device : public keyboard_base { public: - m0110a_j_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + m0110a_j_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : keyboard_base(mconfig, MACKBD_M0110A_J, tag, owner, clock) { } diff --git a/src/devices/bus/macpds/hyperdrive.cpp b/src/devices/bus/macpds/hyperdrive.cpp index ac688a1a620..329ac587efa 100644 --- a/src/devices/bus/macpds/hyperdrive.cpp +++ b/src/devices/bus/macpds/hyperdrive.cpp @@ -106,7 +106,7 @@ DEFINE_DEVICE_TYPE(PDS_HYPERDRIVE, macpds_hyperdrive_device, "pds_hyper", "GCC H void macpds_hyperdrive_device::device_add_mconfig(machine_config &config) { - WD2010(config, m_hdc, 5000000); + WD2010(config, m_hdc, XTAL::u(5000000)); // m_hdc->out_bcr_callback().set(FUNC(macpds_hyperdrive_device::clct_w)); m_hdc->in_bcs_callback().set(FUNC(macpds_hyperdrive_device::hdd_r)); m_hdc->out_bcs_callback().set(FUNC(macpds_hyperdrive_device::hdd_w)); @@ -116,7 +116,7 @@ void macpds_hyperdrive_device::device_add_mconfig(machine_config &config) m_hdc->in_tk000_callback().set_constant(1); m_hdc->in_sc_callback().set_constant(1); - HARDDISK(config, "hard0", 0); + HARDDISK(config, "hard0"); } //------------------------------------------------- @@ -136,12 +136,12 @@ const tiny_rom_entry *macpds_hyperdrive_device::device_rom_region() const // macpds_hyperdrive_device - constructor //------------------------------------------------- -macpds_hyperdrive_device::macpds_hyperdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +macpds_hyperdrive_device::macpds_hyperdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : macpds_hyperdrive_device(mconfig, PDS_HYPERDRIVE, tag, owner, clock) { } -macpds_hyperdrive_device::macpds_hyperdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +macpds_hyperdrive_device::macpds_hyperdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_macpds_card_interface(mconfig, *this), m_hdc(*this, "wd2010") diff --git a/src/devices/bus/macpds/hyperdrive.h b/src/devices/bus/macpds/hyperdrive.h index d8bc4bc5883..fd6e4635872 100644 --- a/src/devices/bus/macpds/hyperdrive.h +++ b/src/devices/bus/macpds/hyperdrive.h @@ -21,12 +21,12 @@ class macpds_hyperdrive_device : { public: // construction/destruction - macpds_hyperdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + macpds_hyperdrive_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type imperfect_features() { return feature::DISK; } protected: - macpds_hyperdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + macpds_hyperdrive_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/macpds/macpds.cpp b/src/devices/bus/macpds/macpds.cpp index 036cb51bf1f..bf9e3ccb724 100644 --- a/src/devices/bus/macpds/macpds.cpp +++ b/src/devices/bus/macpds/macpds.cpp @@ -25,12 +25,12 @@ DEFINE_DEVICE_TYPE(MACPDS_SLOT, macpds_slot_device, "macpds_slot", "Mac 68000 Pr //------------------------------------------------- // macpds_slot_device - constructor //------------------------------------------------- -macpds_slot_device::macpds_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +macpds_slot_device::macpds_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : macpds_slot_device(mconfig, MACPDS_SLOT, tag, owner, clock) { } -macpds_slot_device::macpds_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +macpds_slot_device::macpds_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_slot_interface(mconfig, *this), m_macpds(*this, finder_base::DUMMY_TAG) @@ -62,12 +62,12 @@ DEFINE_DEVICE_TYPE(MACPDS, macpds_device, "macpds", "Mac 68000 Processor-Direct // macpds_device - constructor //------------------------------------------------- -macpds_device::macpds_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +macpds_device::macpds_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : macpds_device(mconfig, MACPDS, tag, owner, clock) { } -macpds_device::macpds_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +macpds_device::macpds_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_maincpu(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/bus/macpds/macpds.h b/src/devices/bus/macpds/macpds.h index ad0ce6a2416..a2627706eff 100644 --- a/src/devices/bus/macpds/macpds.h +++ b/src/devices/bus/macpds/macpds.h @@ -26,7 +26,7 @@ public: // construction/destruction template <typename T> macpds_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *nbtag, T &&opts, const char *dflt) - : macpds_slot_device(mconfig, tag, owner, (uint32_t)0) + : macpds_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -34,14 +34,14 @@ public: set_macpds_slot(nbtag); } - macpds_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + macpds_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration template <typename T> void set_macpds_slot(T &&tag) { m_macpds.set_tag(std::forward<T>(tag));} protected: - macpds_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + macpds_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -62,12 +62,12 @@ class macpds_device : public device_t public: // construction/destruction macpds_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *cputag) - : macpds_device(mconfig, tag, owner, (uint32_t)0) + : macpds_device(mconfig, tag, owner) { set_cputag(cputag); } - macpds_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + macpds_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); ~macpds_device() { m_device_list.detach_all(); } // inline configuration @@ -81,7 +81,7 @@ public: void set_irq_line(int line, int state); protected: - macpds_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + macpds_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/macpds/pds_tpdfpd.cpp b/src/devices/bus/macpds/pds_tpdfpd.cpp index c6eeb68c466..babde5b808a 100644 --- a/src/devices/bus/macpds/pds_tpdfpd.cpp +++ b/src/devices/bus/macpds/pds_tpdfpd.cpp @@ -82,12 +82,12 @@ const tiny_rom_entry *macpds_sedisplay_device::device_rom_region() const // macpds_sedisplay_device - constructor //------------------------------------------------- -macpds_sedisplay_device::macpds_sedisplay_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +macpds_sedisplay_device::macpds_sedisplay_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : macpds_sedisplay_device(mconfig, PDS_SEDISPLAY, tag, owner, clock) { } -macpds_sedisplay_device::macpds_sedisplay_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +macpds_sedisplay_device::macpds_sedisplay_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), device_macpds_card_interface(mconfig, *this), diff --git a/src/devices/bus/macpds/pds_tpdfpd.h b/src/devices/bus/macpds/pds_tpdfpd.h index 3b9fd803c7e..5380a2d8568 100644 --- a/src/devices/bus/macpds/pds_tpdfpd.h +++ b/src/devices/bus/macpds/pds_tpdfpd.h @@ -20,10 +20,10 @@ class macpds_sedisplay_device : { public: // construction/destruction - macpds_sedisplay_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + macpds_sedisplay_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - macpds_sedisplay_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + macpds_sedisplay_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/mc10/mc10_cart.cpp b/src/devices/bus/mc10/mc10_cart.cpp index cd10e800410..f36e8af44d5 100644 --- a/src/devices/bus/mc10/mc10_cart.cpp +++ b/src/devices/bus/mc10/mc10_cart.cpp @@ -55,7 +55,7 @@ DEFINE_DEVICE_TYPE(MC10CART_SLOT, mc10cart_slot_device, "mc10cart_slot", "MC-10 //------------------------------------------------- // mc10cart_slot_device - constructor //------------------------------------------------- -mc10cart_slot_device::mc10cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mc10cart_slot_device::mc10cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC10CART_SLOT, tag, owner, clock), device_single_card_slot_interface<device_mc10cart_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/mc10/mc10_cart.h b/src/devices/bus/mc10/mc10_cart.h index 4a4fc02df7c..6d2bfdaf586 100644 --- a/src/devices/bus/mc10/mc10_cart.h +++ b/src/devices/bus/mc10/mc10_cart.h @@ -31,7 +31,7 @@ public: // construction/destruction template <typename T> - mc10cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&opts, const char *dflt) + mc10cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : mc10cart_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -40,7 +40,7 @@ public: set_fixed(false); } - mc10cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mc10cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration template <typename T> void set_memspace(T &&tag, int spacenum) { m_memspace.set_tag(std::forward<T>(tag), spacenum); } diff --git a/src/devices/bus/mc10/mcx128.cpp b/src/devices/bus/mc10/mcx128.cpp index d507ad612c5..2245c4544cf 100644 --- a/src/devices/bus/mc10/mcx128.cpp +++ b/src/devices/bus/mc10/mcx128.cpp @@ -66,11 +66,11 @@ class mc10_pak_mcx128_device : { public: // construction/destruction - mc10_pak_mcx128_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mc10_pak_mcx128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // construction/destruction - mc10_pak_mcx128_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + mc10_pak_mcx128_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -114,12 +114,12 @@ DEFINE_DEVICE_TYPE_PRIVATE(MC10_PAK_MCX128, device_mc10cart_interface, mc10_pak_ // mc10_pak_device - constructor //------------------------------------------------- -mc10_pak_mcx128_device::mc10_pak_mcx128_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mc10_pak_mcx128_device::mc10_pak_mcx128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) :mc10_pak_mcx128_device(mconfig, MC10_PAK_MCX128, tag, owner, clock) { } -mc10_pak_mcx128_device::mc10_pak_mcx128_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +mc10_pak_mcx128_device::mc10_pak_mcx128_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_mc10cart_interface(mconfig, *this) , m_share(*this, "ext_ram", 1024*128, ENDIANNESS_BIG) @@ -349,7 +349,7 @@ class alice_pak_mcx128_device : public mc10_pak_mcx128_device { public: // construction/destruction - alice_pak_mcx128_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + alice_pak_mcx128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -363,7 +363,7 @@ protected: // mc10_pak_device - constructor //------------------------------------------------- -alice_pak_mcx128_device::alice_pak_mcx128_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +alice_pak_mcx128_device::alice_pak_mcx128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc10_pak_mcx128_device(mconfig, ALICE_PAK_MCX128, tag, owner, clock) { } diff --git a/src/devices/bus/mc10/pak.cpp b/src/devices/bus/mc10/pak.cpp index 8e27d58ab8b..6f85e0a186d 100644 --- a/src/devices/bus/mc10/pak.cpp +++ b/src/devices/bus/mc10/pak.cpp @@ -24,13 +24,13 @@ DEFINE_DEVICE_TYPE(MC10_PAK, mc10_pak_device, "mc10pak", "MC-10 Program PAK") //------------------------------------------------- // mc10_pak_device - constructor //------------------------------------------------- -mc10_pak_device::mc10_pak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +mc10_pak_device::mc10_pak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_mc10cart_interface(mconfig, *this) { } -mc10_pak_device::mc10_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mc10_pak_device::mc10_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc10_pak_device(mconfig, MC10_PAK, tag, owner, clock) { } diff --git a/src/devices/bus/mc10/pak.h b/src/devices/bus/mc10/pak.h index 797cea2f691..9d7782c36e1 100644 --- a/src/devices/bus/mc10/pak.h +++ b/src/devices/bus/mc10/pak.h @@ -19,13 +19,13 @@ class mc10_pak_device : { public: // construction/destruction - mc10_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mc10_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual int max_rom_length() const override; virtual image_init_result load() override; protected: - mc10_pak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + mc10_pak_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/mc10/ram.cpp b/src/devices/bus/mc10/ram.cpp index f6a6f488955..a73ee28e832 100644 --- a/src/devices/bus/mc10/ram.cpp +++ b/src/devices/bus/mc10/ram.cpp @@ -31,7 +31,7 @@ namespace { public: // construction/destruction - mc10_pak_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mc10_pak_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -55,7 +55,7 @@ DEFINE_DEVICE_TYPE_PRIVATE(MC10_PAK_RAM, device_mc10cart_interface, mc10_pak_ram // mc10_pak_device - constructor //------------------------------------------------- -mc10_pak_ram_device::mc10_pak_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mc10_pak_ram_device::mc10_pak_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC10_PAK_RAM, tag, owner, clock) , device_mc10cart_interface(mconfig, *this) , m_share(*this, "ext_ram", 1024*16, ENDIANNESS_BIG) diff --git a/src/devices/bus/megadrive/eeprom.cpp b/src/devices/bus/megadrive/eeprom.cpp index 533d5d540fa..ceebbdc0449 100644 --- a/src/devices/bus/megadrive/eeprom.cpp +++ b/src/devices/bus/megadrive/eeprom.cpp @@ -62,49 +62,49 @@ DEFINE_DEVICE_TYPE(MD_EEPROM_BLARA, md_eeprom_blara_device, "md_eeprom_bla DEFINE_DEVICE_TYPE(MD_EEPROM_MODE1, md_eeprom_mode1_device, "md_eeprom_mode1", "MD Serial EEPROM Mode 1") -md_std_eeprom_device::md_std_eeprom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +md_std_eeprom_device::md_std_eeprom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_md_cart_interface(mconfig, *this) , m_i2cmem(*this, "i2cmem"), m_i2c_mem(0), m_i2c_clk(0) { } -md_std_eeprom_device::md_std_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_std_eeprom_device::md_std_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_eeprom_device(mconfig, MD_STD_EEPROM, tag, owner, clock) { } -md_eeprom_nbajam_device::md_eeprom_nbajam_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_eeprom_nbajam_device::md_eeprom_nbajam_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_eeprom_device(mconfig, MD_EEPROM_NBAJAM, tag, owner, clock) { } -md_eeprom_nbajamte_device::md_eeprom_nbajamte_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_eeprom_nbajamte_device::md_eeprom_nbajamte_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_eeprom_device(mconfig, MD_EEPROM_NBAJAMTE, tag, owner, clock) { } -md_eeprom_nflqb_device::md_eeprom_nflqb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_eeprom_nflqb_device::md_eeprom_nflqb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_eeprom_device(mconfig, MD_EEPROM_NFLQB, tag, owner, clock) { } -md_eeprom_cslam_device::md_eeprom_cslam_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_eeprom_cslam_device::md_eeprom_cslam_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_eeprom_device(mconfig, MD_EEPROM_CSLAM, tag, owner, clock) { } -md_eeprom_nhlpa_device::md_eeprom_nhlpa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_eeprom_nhlpa_device::md_eeprom_nhlpa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_eeprom_device(mconfig, MD_EEPROM_NHLPA, tag, owner, clock) { } -md_eeprom_blara_device::md_eeprom_blara_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_eeprom_blara_device::md_eeprom_blara_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_eeprom_device(mconfig, MD_EEPROM_BLARA, tag, owner, clock) { } -md_eeprom_mode1_device::md_eeprom_mode1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_eeprom_mode1_device::md_eeprom_mode1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_eeprom_device(mconfig, MD_EEPROM_MODE1, tag, owner, clock) { } @@ -363,7 +363,7 @@ void md_eeprom_blara_device::write(offs_t offset, uint16_t data, uint16_t mem_ma DEFINE_DEVICE_TYPE(MD_EEPROM_NBAJAM_ALT, md_eeprom_nbajam_alt_device, "md_eeprom_nbajama", "MD NBA Jam (Alt)") -md_eeprom_nbajam_alt_device::md_eeprom_nbajam_alt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_eeprom_nbajam_alt_device::md_eeprom_nbajam_alt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_eeprom_device(mconfig, MD_EEPROM_NBAJAM_ALT, tag, owner, clock) { } diff --git a/src/devices/bus/megadrive/eeprom.h b/src/devices/bus/megadrive/eeprom.h index 7f5b0e450a4..9c0fe1dc10d 100644 --- a/src/devices/bus/megadrive/eeprom.h +++ b/src/devices/bus/megadrive/eeprom.h @@ -20,10 +20,10 @@ class md_std_eeprom_device : public device_t, { public: // construction/destruction - md_std_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_std_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - md_std_eeprom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + md_std_eeprom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -44,7 +44,7 @@ class md_eeprom_nbajam_device : public md_std_eeprom_device { public: // construction/destruction - md_eeprom_nbajam_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_eeprom_nbajam_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -61,7 +61,7 @@ class md_eeprom_nbajamte_device : public md_std_eeprom_device { public: // construction/destruction - md_eeprom_nbajamte_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_eeprom_nbajamte_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -78,7 +78,7 @@ class md_eeprom_cslam_device : public md_std_eeprom_device { public: // construction/destruction - md_eeprom_cslam_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_eeprom_cslam_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -95,7 +95,7 @@ class md_eeprom_nflqb_device : public md_std_eeprom_device { public: // construction/destruction - md_eeprom_nflqb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_eeprom_nflqb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -112,7 +112,7 @@ class md_eeprom_nhlpa_device : public md_std_eeprom_device { public: // construction/destruction - md_eeprom_nhlpa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_eeprom_nhlpa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -129,7 +129,7 @@ class md_eeprom_blara_device : public md_std_eeprom_device { public: // construction/destruction - md_eeprom_blara_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_eeprom_blara_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -146,7 +146,7 @@ class md_eeprom_mode1_device : public md_std_eeprom_device { public: // construction/destruction - md_eeprom_mode1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_eeprom_mode1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -185,7 +185,7 @@ class md_eeprom_nbajam_alt_device : public md_std_eeprom_device { public: // construction/destruction - md_eeprom_nbajam_alt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_eeprom_nbajam_alt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; diff --git a/src/devices/bus/megadrive/ggenie.cpp b/src/devices/bus/megadrive/ggenie.cpp index e4df6f8ef29..87ab9b8aaa4 100644 --- a/src/devices/bus/megadrive/ggenie.cpp +++ b/src/devices/bus/megadrive/ggenie.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(MD_ROM_GAMEGENIE, md_rom_ggenie_device, "md_ggenie", "MD Game Genie") -md_rom_ggenie_device::md_rom_ggenie_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_ggenie_device::md_rom_ggenie_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MD_ROM_GAMEGENIE, tag, owner, clock) , device_md_cart_interface(mconfig, *this) , m_exp(*this, "subslot") diff --git a/src/devices/bus/megadrive/ggenie.h b/src/devices/bus/megadrive/ggenie.h index 025f97fac7f..65d0cf518c2 100644 --- a/src/devices/bus/megadrive/ggenie.h +++ b/src/devices/bus/megadrive/ggenie.h @@ -15,7 +15,7 @@ class md_rom_ggenie_device : public device_t, { public: // construction/destruction - md_rom_ggenie_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_ggenie_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/megadrive/jcart.cpp b/src/devices/bus/megadrive/jcart.cpp index d41116d762e..4cb3ca75876 100644 --- a/src/devices/bus/megadrive/jcart.cpp +++ b/src/devices/bus/megadrive/jcart.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(MD_SEPROM_CODEMAST, md_seprom_codemast_device, "md_seprom_cod DEFINE_DEVICE_TYPE(MD_SEPROM_MM96, md_seprom_mm96_device, "md_seprom_mm96", "MD Micro Machine 96") // Sampras, Super Skidmarks? -md_jcart_device::md_jcart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +md_jcart_device::md_jcart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_md_cart_interface(mconfig, *this) , m_jcart3(*this, "JCART3") @@ -43,25 +43,25 @@ md_jcart_device::md_jcart_device(const machine_config &mconfig, device_type type { } -md_jcart_device::md_jcart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_jcart_device::md_jcart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_jcart_device(mconfig, MD_JCART, tag, owner, clock) { } // Micro Machines 2, Micro Machines Military -md_seprom_codemast_device::md_seprom_codemast_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +md_seprom_codemast_device::md_seprom_codemast_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : md_jcart_device(mconfig, type, tag, owner, clock) , m_i2cmem(*this, "i2cmem"), m_i2c_mem(0), m_i2c_clk(0) { } -md_seprom_codemast_device::md_seprom_codemast_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_seprom_codemast_device::md_seprom_codemast_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_seprom_codemast_device(mconfig, MD_SEPROM_CODEMAST, tag, owner, clock) { } // Micro Machines 96 -md_seprom_mm96_device::md_seprom_mm96_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_seprom_mm96_device::md_seprom_mm96_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_seprom_codemast_device(mconfig, MD_SEPROM_MM96, tag, owner, clock) { } diff --git a/src/devices/bus/megadrive/jcart.h b/src/devices/bus/megadrive/jcart.h index 473c6ec2ce3..94c891c3429 100644 --- a/src/devices/bus/megadrive/jcart.h +++ b/src/devices/bus/megadrive/jcart.h @@ -18,7 +18,7 @@ class md_jcart_device : public device_t, { public: // construction/destruction - md_jcart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_jcart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; @@ -28,7 +28,7 @@ public: virtual void write(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override; protected: - md_jcart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + md_jcart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -46,10 +46,10 @@ class md_seprom_codemast_device : public md_jcart_device { public: // construction/destruction - md_seprom_codemast_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_seprom_codemast_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - md_seprom_codemast_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + md_seprom_codemast_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -74,7 +74,7 @@ class md_seprom_mm96_device : public md_seprom_codemast_device { public: // construction/destruction - md_seprom_mm96_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_seprom_mm96_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/megadrive/md_slot.cpp b/src/devices/bus/megadrive/md_slot.cpp index b62209d549e..f9a4ce65c1b 100644 --- a/src/devices/bus/megadrive/md_slot.cpp +++ b/src/devices/bus/megadrive/md_slot.cpp @@ -159,7 +159,7 @@ uint32_t device_md_cart_interface::get_padded_size(uint32_t size) //------------------------------------------------- // base_md_cart_slot_device - constructor //------------------------------------------------- -base_md_cart_slot_device::base_md_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +base_md_cart_slot_device::base_md_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_md_cart_interface>(mconfig, *this), @@ -167,17 +167,17 @@ base_md_cart_slot_device::base_md_cart_slot_device(const machine_config &mconfig { } -md_cart_slot_device::md_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +md_cart_slot_device::md_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : base_md_cart_slot_device(mconfig, MD_CART_SLOT, tag, owner, clock) { } -pico_cart_slot_device::pico_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pico_cart_slot_device::pico_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : base_md_cart_slot_device(mconfig, PICO_CART_SLOT, tag, owner, clock) { } -copera_cart_slot_device::copera_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +copera_cart_slot_device::copera_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : base_md_cart_slot_device(mconfig, COPERA_CART_SLOT, tag, owner, clock) { } diff --git a/src/devices/bus/megadrive/md_slot.h b/src/devices/bus/megadrive/md_slot.h index ede1a032c2e..0c6c1e54655 100644 --- a/src/devices/bus/megadrive/md_slot.h +++ b/src/devices/bus/megadrive/md_slot.h @@ -195,7 +195,7 @@ public: device_md_cart_interface* m_cart; protected: - base_md_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + base_md_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -209,7 +209,7 @@ public: // construction/destruction template <typename T> md_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : md_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : md_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -217,7 +217,7 @@ public: set_fixed(false); } - md_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "megadriv_cart"; } virtual const char *file_extensions() const noexcept override { return "smd,bin,md,gen"; } }; @@ -230,14 +230,14 @@ public: // construction/destruction template <typename T> pico_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : pico_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : pico_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - pico_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pico_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "pico_cart"; } virtual const char *file_extensions() const noexcept override { return "bin,md"; } }; @@ -250,14 +250,14 @@ public: // construction/destruction template <typename T> copera_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : copera_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : copera_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - copera_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + copera_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "copera_cart"; } virtual const char *file_extensions() const noexcept override { return "bin,md"; } }; diff --git a/src/devices/bus/megadrive/rom.cpp b/src/devices/bus/megadrive/rom.cpp index 6c624f2b515..8f2019088ec 100644 --- a/src/devices/bus/megadrive/rom.cpp +++ b/src/devices/bus/megadrive/rom.cpp @@ -67,199 +67,199 @@ DEFINE_DEVICE_TYPE(MD_ROM_STARODYS, md_rom_starodys_device, "md_rom_starodys", " DEFINE_DEVICE_TYPE(MD_ROM_SRAM_ARG96, md_rom_sram_arg96_device, "md_rom_sram_arg96", "MD Futbol Argentino 96") -md_std_rom_device::md_std_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +md_std_rom_device::md_std_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_md_cart_interface(mconfig, *this) { } -md_std_rom_device::md_std_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_std_rom_device::md_std_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_STD_ROM, tag, owner, clock) { } -md_rom_sram_device::md_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_sram_device::md_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_rom_sram_device(mconfig, MD_ROM_SRAM, tag, owner, clock) { } -md_rom_sram_device::md_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +md_rom_sram_device::md_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, type, tag, owner, clock) { } -md_rom_sram_arg96_device::md_rom_sram_arg96_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_sram_arg96_device::md_rom_sram_arg96_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_rom_sram_device(mconfig, MD_ROM_SRAM_ARG96, tag, owner, clock) { } -md_rom_fram_device::md_rom_fram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_fram_device::md_rom_fram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_FRAM, tag, owner, clock) { } -md_rom_cm2in1_device::md_rom_cm2in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_cm2in1_device::md_rom_cm2in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_CM2IN1, tag, owner, clock), m_base(0) { } -md_rom_ssf2_device::md_rom_ssf2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_ssf2_device::md_rom_ssf2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_SSF2, tag, owner, clock), m_lastoff(0), m_lastdata(0) { } -md_rom_bugslife_device::md_rom_bugslife_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_bugslife_device::md_rom_bugslife_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_BUGSLIFE, tag, owner, clock) { } -md_rom_smouse_device::md_rom_smouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_smouse_device::md_rom_smouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_SMOUSE, tag, owner, clock) { } -md_rom_smw64_device::md_rom_smw64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_smw64_device::md_rom_smw64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_SMW64, tag, owner, clock), m_latch0(0), m_latch1(0) { } -md_rom_smb_device::md_rom_smb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_smb_device::md_rom_smb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_SMB, tag, owner, clock) { } -md_rom_smb2_device::md_rom_smb2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_smb2_device::md_rom_smb2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_SMB2, tag, owner, clock) { } -md_rom_sbubl_device::md_rom_sbubl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_sbubl_device::md_rom_sbubl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_SBUBL, tag, owner, clock) { } -md_rom_rx3_device::md_rom_rx3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_rx3_device::md_rom_rx3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_RX3, tag, owner, clock) { } -md_rom_mjlov_device::md_rom_mjlov_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_mjlov_device::md_rom_mjlov_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_MJLOV, tag, owner, clock) { } -md_rom_cjmjclub_device::md_rom_cjmjclub_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_cjmjclub_device::md_rom_cjmjclub_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_CJMJCLUB, tag, owner, clock) { } -md_rom_kof98_device::md_rom_kof98_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_kof98_device::md_rom_kof98_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_KOF98, tag, owner, clock) { } -md_rom_kof99_device::md_rom_kof99_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_kof99_device::md_rom_kof99_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_KOF99, tag, owner, clock) { } -md_rom_soulb_device::md_rom_soulb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_soulb_device::md_rom_soulb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_SOULB, tag, owner, clock) { } -md_rom_chinf3_device::md_rom_chinf3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_chinf3_device::md_rom_chinf3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_CHINF3, tag, owner, clock), m_bank(0) { } -md_rom_16mj2_device::md_rom_16mj2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_16mj2_device::md_rom_16mj2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_16MJ2, tag, owner, clock) { } -md_rom_elfwor_device::md_rom_elfwor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_elfwor_device::md_rom_elfwor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_ELFWOR, tag, owner, clock) { } -md_rom_yasech_device::md_rom_yasech_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_yasech_device::md_rom_yasech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_YASECH, tag, owner, clock) { } -md_rom_lion2_device::md_rom_lion2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_lion2_device::md_rom_lion2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_LION2, tag, owner, clock), m_prot1_data(0), m_prot2_data(0) { } -md_rom_lion3_device::md_rom_lion3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_lion3_device::md_rom_lion3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_LION3, tag, owner, clock), m_bank(0) { } -md_rom_mcpirate_device::md_rom_mcpirate_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_mcpirate_device::md_rom_mcpirate_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_MCPIR, tag, owner, clock), m_bank(0) { } -md_rom_pokea_device::md_rom_pokea_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_pokea_device::md_rom_pokea_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_POKEA, tag, owner, clock) { } -md_rom_pokestad_device::md_rom_pokestad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_pokestad_device::md_rom_pokestad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_POKESTAD, tag, owner, clock), m_bank(0) { } -md_rom_realtec_device::md_rom_realtec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_realtec_device::md_rom_realtec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_REALTEC, tag, owner, clock), m_bank_addr(0), m_bank_size(0), m_old_bank_addr(0) { } -md_rom_redcl_device::md_rom_redcl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_redcl_device::md_rom_redcl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_REDCL, tag, owner, clock) { } -md_rom_squir_device::md_rom_squir_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_squir_device::md_rom_squir_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_SQUIR, tag, owner, clock), m_latch(0) { } -md_rom_tc2000_device::md_rom_tc2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_tc2000_device::md_rom_tc2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_TC2000, tag, owner, clock) { } -md_rom_tekkensp_device::md_rom_tekkensp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_tekkensp_device::md_rom_tekkensp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_TEKKENSP, tag, owner, clock), m_reg(0) { } -md_rom_topf_device::md_rom_topf_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_topf_device::md_rom_topf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_TOPF, tag, owner, clock), m_latch(0) { } -md_rom_radica_device::md_rom_radica_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_radica_device::md_rom_radica_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_RADICA, tag, owner, clock), m_bank(0) { } -md_rom_beggarp_device::md_rom_beggarp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_beggarp_device::md_rom_beggarp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_BEGGARP, tag, owner, clock), m_mode(0), m_lock(0) { } -md_rom_wukong_device::md_rom_wukong_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_wukong_device::md_rom_wukong_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_WUKONG, tag, owner, clock), m_mode(0) { } -md_rom_starodys_device::md_rom_starodys_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_starodys_device::md_rom_starodys_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_std_rom_device(mconfig, MD_ROM_STARODYS, tag, owner, clock), m_mode(0), m_lock(0), m_ram_enable(0), m_base(0) { } diff --git a/src/devices/bus/megadrive/rom.h b/src/devices/bus/megadrive/rom.h index 0acf73061ee..6b4915eda80 100644 --- a/src/devices/bus/megadrive/rom.h +++ b/src/devices/bus/megadrive/rom.h @@ -18,14 +18,14 @@ class md_std_rom_device : public device_t, { public: // construction/destruction - md_std_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_std_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override { if (offset < 0x400000/2) return m_rom[MD_ADDR(offset)]; else return 0xffff; } virtual void write(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override { } protected: - md_std_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + md_std_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -37,10 +37,10 @@ class md_rom_sram_device : public md_std_rom_device { public: // construction/destruction - md_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - md_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + md_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); public: // reading and writing @@ -54,7 +54,7 @@ public: class md_rom_sram_arg96_device : public md_rom_sram_device { public: - md_rom_sram_arg96_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_sram_arg96_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint16_t read(offs_t offset) override; virtual void write(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override; @@ -66,7 +66,7 @@ class md_rom_fram_device : public md_std_rom_device { public: // construction/destruction - md_rom_fram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_fram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -81,7 +81,7 @@ class md_rom_ssf2_device : public md_std_rom_device { public: // construction/destruction - md_rom_ssf2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_ssf2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -103,7 +103,7 @@ class md_rom_cm2in1_device : public md_std_rom_device { public: // construction/destruction - md_rom_cm2in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_cm2in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -124,7 +124,7 @@ class md_rom_mcpirate_device : public md_std_rom_device { public: // construction/destruction - md_rom_mcpirate_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_mcpirate_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -146,7 +146,7 @@ class md_rom_bugslife_device : public md_std_rom_device { public: // construction/destruction - md_rom_bugslife_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_bugslife_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_a13(offs_t offset) override; @@ -158,7 +158,7 @@ class md_rom_chinf3_device : public md_std_rom_device { public: // construction/destruction - md_rom_chinf3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_chinf3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -179,7 +179,7 @@ class md_rom_16mj2_device : public md_std_rom_device { public: // construction/destruction - md_rom_16mj2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_16mj2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -191,7 +191,7 @@ class md_rom_elfwor_device : public md_std_rom_device { public: // construction/destruction - md_rom_elfwor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_elfwor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -203,7 +203,7 @@ class md_rom_yasech_device : public md_std_rom_device { public: // construction/destruction - md_rom_yasech_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_yasech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -215,7 +215,7 @@ class md_rom_kof98_device : public md_std_rom_device { public: // construction/destruction - md_rom_kof98_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_kof98_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -227,7 +227,7 @@ class md_rom_kof99_device : public md_std_rom_device { public: // construction/destruction - md_rom_kof99_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_kof99_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_a13(offs_t offset) override; @@ -239,7 +239,7 @@ class md_rom_lion2_device : public md_std_rom_device { public: // construction/destruction - md_rom_lion2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_lion2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -260,7 +260,7 @@ class md_rom_lion3_device : public md_std_rom_device { public: // construction/destruction - md_rom_lion3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_lion3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -282,7 +282,7 @@ class md_rom_mjlov_device : public md_std_rom_device { public: // construction/destruction - md_rom_mjlov_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_mjlov_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -294,7 +294,7 @@ class md_rom_cjmjclub_device : public md_std_rom_device { public: // construction/destruction - md_rom_cjmjclub_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_cjmjclub_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -306,7 +306,7 @@ class md_rom_pokea_device : public md_std_rom_device { public: // construction/destruction - md_rom_pokea_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_pokea_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_a13(offs_t offset) override; @@ -318,7 +318,7 @@ class md_rom_pokestad_device : public md_std_rom_device { public: // construction/destruction - md_rom_pokestad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_pokestad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -339,7 +339,7 @@ class md_rom_realtec_device : public md_std_rom_device { public: // construction/destruction - md_rom_realtec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_realtec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -360,7 +360,7 @@ class md_rom_redcl_device : public md_std_rom_device { public: // construction/destruction - md_rom_redcl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_redcl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -372,7 +372,7 @@ class md_rom_rx3_device : public md_std_rom_device { public: // construction/destruction - md_rom_rx3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_rx3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_a13(offs_t offset) override; @@ -384,7 +384,7 @@ class md_rom_sbubl_device : public md_std_rom_device { public: // construction/destruction - md_rom_sbubl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_sbubl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -396,7 +396,7 @@ class md_rom_smb_device : public md_std_rom_device { public: // construction/destruction - md_rom_smb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_smb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_a13(offs_t offset) override; @@ -408,7 +408,7 @@ class md_rom_smb2_device : public md_std_rom_device { public: // construction/destruction - md_rom_smb2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_smb2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read_a13(offs_t offset) override; @@ -420,7 +420,7 @@ class md_rom_smw64_device : public md_std_rom_device { public: // construction/destruction - md_rom_smw64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_smw64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -443,7 +443,7 @@ class md_rom_smouse_device : public md_std_rom_device { public: // construction/destruction - md_rom_smouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_smouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -456,7 +456,7 @@ class md_rom_soulb_device : public md_std_rom_device { public: // construction/destruction - md_rom_soulb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_soulb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -468,7 +468,7 @@ class md_rom_squir_device : public md_std_rom_device { public: // construction/destruction - md_rom_squir_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_squir_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -489,7 +489,7 @@ class md_rom_tc2000_device : public md_std_rom_device { public: // construction/destruction - md_rom_tc2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_tc2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -511,7 +511,7 @@ class md_rom_tekkensp_device : public md_std_rom_device { public: // construction/destruction - md_rom_tekkensp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_tekkensp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -532,7 +532,7 @@ class md_rom_topf_device : public md_std_rom_device { public: // construction/destruction - md_rom_topf_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_topf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -554,7 +554,7 @@ class md_rom_radica_device : public md_std_rom_device { public: // construction/destruction - md_rom_radica_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_radica_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -575,7 +575,7 @@ class md_rom_beggarp_device : public md_std_rom_device { public: // construction/destruction - md_rom_beggarp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_beggarp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -597,7 +597,7 @@ class md_rom_wukong_device : public md_std_rom_device { public: // construction/destruction - md_rom_wukong_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_wukong_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -619,7 +619,7 @@ class md_rom_starodys_device : public md_std_rom_device { public: // construction/destruction - md_rom_starodys_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_starodys_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; diff --git a/src/devices/bus/megadrive/sk.cpp b/src/devices/bus/megadrive/sk.cpp index 5e0a970c320..9f4c355a17e 100644 --- a/src/devices/bus/megadrive/sk.cpp +++ b/src/devices/bus/megadrive/sk.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(MD_ROM_SK, md_rom_sk_device, "md_rom_sk", "MD Sonic & Knuckles") -md_rom_sk_device::md_rom_sk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +md_rom_sk_device::md_rom_sk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_md_cart_interface(mconfig, *this) , m_exp(*this, "subslot") @@ -31,7 +31,7 @@ md_rom_sk_device::md_rom_sk_device(const machine_config &mconfig, device_type ty { } -md_rom_sk_device::md_rom_sk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_sk_device::md_rom_sk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_rom_sk_device(mconfig, MD_ROM_SK, tag, owner, clock) { } diff --git a/src/devices/bus/megadrive/sk.h b/src/devices/bus/megadrive/sk.h index c51abce9430..eb78ba872da 100644 --- a/src/devices/bus/megadrive/sk.h +++ b/src/devices/bus/megadrive/sk.h @@ -15,10 +15,10 @@ class md_rom_sk_device : public device_t, { public: // construction/destruction - md_rom_sk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_sk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - md_rom_sk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + md_rom_sk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/megadrive/stm95.cpp b/src/devices/bus/megadrive/stm95.cpp index e3fca0bbffe..088baae65df 100644 --- a/src/devices/bus/megadrive/stm95.cpp +++ b/src/devices/bus/megadrive/stm95.cpp @@ -175,14 +175,14 @@ void stm95_eeprom_device::set_sck_line(int state) DEFINE_DEVICE_TYPE(MD_EEPROM_STM95, md_eeprom_stm95_device, "md_eeprom_stm95", "MD Cart + EEPROM STM95") -md_eeprom_stm95_device::md_eeprom_stm95_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +md_eeprom_stm95_device::md_eeprom_stm95_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_md_cart_interface(mconfig, *this) , m_rdcnt(0) { } -md_eeprom_stm95_device::md_eeprom_stm95_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_eeprom_stm95_device::md_eeprom_stm95_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_eeprom_stm95_device(mconfig, MD_EEPROM_STM95, tag, owner, clock) { } diff --git a/src/devices/bus/megadrive/stm95.h b/src/devices/bus/megadrive/stm95.h index c04651d742c..03ce6f2a248 100644 --- a/src/devices/bus/megadrive/stm95.h +++ b/src/devices/bus/megadrive/stm95.h @@ -61,7 +61,7 @@ class md_eeprom_stm95_device : public device_t, public device_md_cart_interface { public: // construction/destruction - md_eeprom_stm95_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_eeprom_stm95_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t read(offs_t offset) override; @@ -69,7 +69,7 @@ public: virtual void write_a13(offs_t offset, uint16_t data) override; protected: - md_eeprom_stm95_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + md_eeprom_stm95_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/megadrive/svp.cpp b/src/devices/bus/megadrive/svp.cpp index 7850f9d3a80..0c8ef145d0e 100644 --- a/src/devices/bus/megadrive/svp.cpp +++ b/src/devices/bus/megadrive/svp.cpp @@ -58,7 +58,7 @@ DEFINE_DEVICE_TYPE(MD_ROM_SVP, md_rom_svp_device, "md_rom_svp", "MD Virtua Racing") -md_rom_svp_device::md_rom_svp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +md_rom_svp_device::md_rom_svp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_md_cart_interface(mconfig, *this) , m_svp(*this, "svp") @@ -67,7 +67,7 @@ md_rom_svp_device::md_rom_svp_device(const machine_config &mconfig, device_type { } -md_rom_svp_device::md_rom_svp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +md_rom_svp_device::md_rom_svp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md_rom_svp_device(mconfig, MD_ROM_SVP, tag, owner, clock) { } @@ -86,7 +86,7 @@ tiny_rom_entry const *md_rom_svp_device::device_rom_region() const #define SSP_PMC_HAVE_ADDR 1 // address written to PMAC, waiting for mode #define SSP_PMC_SET 2 // PMAC is set, PMx can be programmed -#define MASTER_CLOCK_NTSC 53693175 +#define MASTER_CLOCK_NTSC XTAL::u(53693175) // HELPERS diff --git a/src/devices/bus/megadrive/svp.h b/src/devices/bus/megadrive/svp.h index 84d65b90a33..f74171635b8 100644 --- a/src/devices/bus/megadrive/svp.h +++ b/src/devices/bus/megadrive/svp.h @@ -17,10 +17,10 @@ class md_rom_svp_device : public device_t, { public: // construction/destruction - md_rom_svp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + md_rom_svp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - md_rom_svp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + md_rom_svp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; diff --git a/src/devices/bus/midi/midi.cpp b/src/devices/bus/midi/midi.cpp index cff94bfe159..a9161323b5f 100644 --- a/src/devices/bus/midi/midi.cpp +++ b/src/devices/bus/midi/midi.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(MIDI_PORT, midi_port_device, "midi_port", "MIDI port") -midi_port_device::midi_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +midi_port_device::midi_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MIDI_PORT, tag, owner, clock), device_single_card_slot_interface<device_midi_port_interface>(mconfig, *this), m_rxd(0), diff --git a/src/devices/bus/midi/midi.h b/src/devices/bus/midi/midi.h index cdd89a84b6d..0b323314904 100644 --- a/src/devices/bus/midi/midi.h +++ b/src/devices/bus/midi/midi.h @@ -15,14 +15,14 @@ class midi_port_device : public device_t, public device_single_card_slot_interfa public: template <typename T> midi_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : midi_port_device(mconfig, tag, owner, (uint32_t)0) + : midi_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - midi_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + midi_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~midi_port_device(); // static configuration helpers diff --git a/src/devices/bus/midi/midiinport.cpp b/src/devices/bus/midi/midiinport.cpp index bad75b6959e..97b46965d4b 100644 --- a/src/devices/bus/midi/midiinport.cpp +++ b/src/devices/bus/midi/midiinport.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(MIDIIN_PORT, midiin_port_device, "midiin_port", "MIDI In port") -midiin_port_device::midiin_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +midiin_port_device::midiin_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MIDIIN_PORT, tag, owner, clock), device_midi_port_interface(mconfig, *this), m_midiin(*this, "midiinimg") @@ -22,6 +22,6 @@ midiin_port_device::midiin_port_device(const machine_config &mconfig, const char void midiin_port_device::device_add_mconfig(machine_config &config) { - MIDIIN(config, m_midiin, 0); + MIDIIN(config, m_midiin); m_midiin->input_callback().set(FUNC(midiin_port_device::read)); } diff --git a/src/devices/bus/midi/midiinport.h b/src/devices/bus/midi/midiinport.h index 526af88bb2a..9777c72e95f 100644 --- a/src/devices/bus/midi/midiinport.h +++ b/src/devices/bus/midi/midiinport.h @@ -20,7 +20,7 @@ class midiin_port_device : public device_t, public device_midi_port_interface { public: - midiin_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + midiin_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/midi/midioutport.cpp b/src/devices/bus/midi/midioutport.cpp index 7f15c79fc70..5f00e87e636 100644 --- a/src/devices/bus/midi/midioutport.cpp +++ b/src/devices/bus/midi/midioutport.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(MIDIOUT_PORT, midiout_port_device, "midiout_port", "MIDI Out port") -midiout_port_device::midiout_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +midiout_port_device::midiout_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MIDIOUT_PORT, tag, owner, clock), device_midi_port_interface(mconfig, *this), m_midiout(*this, "midioutimg") @@ -22,5 +22,5 @@ midiout_port_device::midiout_port_device(const machine_config &mconfig, const ch void midiout_port_device::device_add_mconfig(machine_config &config) { - MIDIOUT(config, m_midiout, 0); + MIDIOUT(config, m_midiout); } diff --git a/src/devices/bus/midi/midioutport.h b/src/devices/bus/midi/midioutport.h index 2cc33ae922f..7c75d3714ba 100644 --- a/src/devices/bus/midi/midioutport.h +++ b/src/devices/bus/midi/midioutport.h @@ -20,7 +20,7 @@ class midiout_port_device : public device_t, public device_midi_port_interface { public: - midiout_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + midiout_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER( input_txd ) override { if (started()) m_midiout->tx(state); } diff --git a/src/devices/bus/msx_cart/arc.cpp b/src/devices/bus/msx_cart/arc.cpp index 6f5af572bd1..342cdbd3c11 100644 --- a/src/devices/bus/msx_cart/arc.cpp +++ b/src/devices/bus/msx_cart/arc.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_ARC, msx_cart_arc_device, "msx_cart_arc", "MSX Cartridge - Arc") -msx_cart_arc_device::msx_cart_arc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_arc_device::msx_cart_arc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_ARC, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_7f(0) diff --git a/src/devices/bus/msx_cart/arc.h b/src/devices/bus/msx_cart/arc.h index 69f4427a01f..53fa28a016b 100644 --- a/src/devices/bus/msx_cart/arc.h +++ b/src/devices/bus/msx_cart/arc.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_ARC, msx_cart_arc_device) class msx_cart_arc_device : public device_t, public msx_cart_interface { public: - msx_cart_arc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_arc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/ascii.cpp b/src/devices/bus/msx_cart/ascii.cpp index 7d1b354b404..7c198b1a77e 100644 --- a/src/devices/bus/msx_cart/ascii.cpp +++ b/src/devices/bus/msx_cart/ascii.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_ASCII16_SRAM, msx_cart_ascii16_sram_device, "msx_car DEFINE_DEVICE_TYPE(MSX_CART_MSXWRITE, msx_cart_msxwrite_device, "msx_cart_msxwrite", "MSX Cartridge - MSXWRITE") -msx_cart_ascii8_device::msx_cart_ascii8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_ascii8_device::msx_cart_ascii8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_ASCII8, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bank_mask(0) @@ -99,7 +99,7 @@ void msx_cart_ascii8_device::write_cart(offs_t offset, uint8_t data) -msx_cart_ascii16_device::msx_cart_ascii16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_ascii16_device::msx_cart_ascii16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_ASCII16, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bank_mask(0) @@ -193,7 +193,7 @@ void msx_cart_ascii16_device::write_cart(offs_t offset, uint8_t data) -msx_cart_ascii8_sram_device::msx_cart_ascii8_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_ascii8_sram_device::msx_cart_ascii8_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_ASCII8_SRAM, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bank_mask(0) @@ -322,7 +322,7 @@ void msx_cart_ascii8_sram_device::write_cart(offs_t offset, uint8_t data) -msx_cart_ascii16_sram_device::msx_cart_ascii16_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_ascii16_sram_device::msx_cart_ascii16_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_ASCII16_SRAM, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bank_mask(0) @@ -461,7 +461,7 @@ void msx_cart_ascii16_sram_device::write_cart(offs_t offset, uint8_t data) -msx_cart_msxwrite_device::msx_cart_msxwrite_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_msxwrite_device::msx_cart_msxwrite_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_MSXWRITE, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bank_mask(0) diff --git a/src/devices/bus/msx_cart/ascii.h b/src/devices/bus/msx_cart/ascii.h index 0c5898fed40..e040a08e37a 100644 --- a/src/devices/bus/msx_cart/ascii.h +++ b/src/devices/bus/msx_cart/ascii.h @@ -18,7 +18,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_MSXWRITE, msx_cart_msxwrite_device) class msx_cart_ascii8_device : public device_t, public msx_cart_interface { public: - msx_cart_ascii8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_ascii8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -43,7 +43,7 @@ private: class msx_cart_ascii16_device : public device_t, public msx_cart_interface { public: - msx_cart_ascii16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_ascii16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -68,7 +68,7 @@ private: class msx_cart_ascii8_sram_device : public device_t, public msx_cart_interface { public: - msx_cart_ascii8_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_ascii8_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -96,7 +96,7 @@ private: class msx_cart_ascii16_sram_device : public device_t, public msx_cart_interface { public: - msx_cart_ascii16_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_ascii16_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -124,7 +124,7 @@ private: class msx_cart_msxwrite_device : public device_t, public msx_cart_interface { public: - msx_cart_msxwrite_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_msxwrite_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/bm_012.cpp b/src/devices/bus/msx_cart/bm_012.cpp index 020348dd843..1f5b566c961 100644 --- a/src/devices/bus/msx_cart/bm_012.cpp +++ b/src/devices/bus/msx_cart/bm_012.cpp @@ -22,7 +22,7 @@ TODO: DEFINE_DEVICE_TYPE(MSX_CART_BM_012, msx_cart_bm_012_device, "msx_cart_bm_012", "MSX Cartridge - BM-012") -msx_cart_bm_012_device::msx_cart_bm_012_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_bm_012_device::msx_cart_bm_012_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_BM_012, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_tmpz84c015af(*this, "tmpz84c015af") diff --git a/src/devices/bus/msx_cart/bm_012.h b/src/devices/bus/msx_cart/bm_012.h index e54213e8e75..1d66139dc2b 100644 --- a/src/devices/bus/msx_cart/bm_012.h +++ b/src/devices/bus/msx_cart/bm_012.h @@ -16,7 +16,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_BM_012, msx_cart_bm_012_device) class msx_cart_bm_012_device : public device_t, public msx_cart_interface { public: - msx_cart_bm_012_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_bm_012_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/msx_cart/crossblaim.cpp b/src/devices/bus/msx_cart/crossblaim.cpp index 6494e492f5b..c9d8e95f785 100644 --- a/src/devices/bus/msx_cart/crossblaim.cpp +++ b/src/devices/bus/msx_cart/crossblaim.cpp @@ -6,7 +6,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_CROSSBLAIM, msx_cart_crossblaim_device, "msx_cart_crossblaim", "MSX Cartridge Cross Blaim") -msx_cart_crossblaim_device::msx_cart_crossblaim_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_crossblaim_device::msx_cart_crossblaim_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_CROSSBLAIM, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_selected_bank(1) diff --git a/src/devices/bus/msx_cart/crossblaim.h b/src/devices/bus/msx_cart/crossblaim.h index 04a44c1d905..365d7a06737 100644 --- a/src/devices/bus/msx_cart/crossblaim.h +++ b/src/devices/bus/msx_cart/crossblaim.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_CROSSBLAIM, msx_cart_crossblaim_device) class msx_cart_crossblaim_device : public device_t, public msx_cart_interface { public: - msx_cart_crossblaim_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_crossblaim_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/disk.cpp b/src/devices/bus/msx_cart/disk.cpp index b07d9dd6dc0..0c0b5e0d779 100644 --- a/src/devices/bus/msx_cart/disk.cpp +++ b/src/devices/bus/msx_cart/disk.cpp @@ -125,7 +125,7 @@ static void msx_floppies(device_slot_interface &device) } -msx_cart_disk_device::msx_cart_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_cart_disk_device::msx_cart_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_floppy0(*this, "fdc:0") @@ -135,14 +135,14 @@ msx_cart_disk_device::msx_cart_disk_device(const machine_config &mconfig, device } -msx_cart_disk_wd_device::msx_cart_disk_wd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_cart_disk_wd_device::msx_cart_disk_wd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_disk_device(mconfig, type, tag, owner, clock) , m_fdc(*this, "fdc") { } -msx_cart_disk_type1_device::msx_cart_disk_type1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_cart_disk_type1_device::msx_cart_disk_type1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_disk_wd_device(mconfig, type, tag, owner, clock) , m_led(*this, "led0") , m_side_control(0) @@ -151,7 +151,7 @@ msx_cart_disk_type1_device::msx_cart_disk_type1_device(const machine_config &mco } -msx_cart_disk_type2_device::msx_cart_disk_type2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_cart_disk_type2_device::msx_cart_disk_type2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_disk_wd_device(mconfig, type, tag, owner, clock) , m_led(*this, "led0") , m_control(0) @@ -159,32 +159,32 @@ msx_cart_disk_type2_device::msx_cart_disk_type2_device(const machine_config &mco } -msx_cart_vy0010_device::msx_cart_vy0010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_vy0010_device::msx_cart_vy0010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_disk_type1_device(mconfig, MSX_CART_VY0010, tag, owner, clock) { } -msx_cart_fsfd1_device::msx_cart_fsfd1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_fsfd1_device::msx_cart_fsfd1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_disk_type1_device(mconfig, MSX_CART_FSFD1, tag, owner, clock) { } -msx_cart_fscf351_device::msx_cart_fscf351_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_fscf351_device::msx_cart_fscf351_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_disk_type2_device(mconfig, MSX_CART_FSCF351, tag, owner, clock) { } -msx_cart_disk_tc8566_device::msx_cart_disk_tc8566_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_cart_disk_tc8566_device::msx_cart_disk_tc8566_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_disk_device(mconfig, type, tag, owner, clock) , m_fdc(*this, "fdc") { } -msx_cart_fsfd1a_device::msx_cart_fsfd1a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_fsfd1a_device::msx_cart_fsfd1a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_disk_tc8566_device(mconfig, MSX_CART_FSFD1A, tag, owner, clock) { } @@ -237,7 +237,7 @@ void msx_cart_fsfd1_device::device_add_mconfig(machine_config &config) void msx_cart_fsfd1a_device::device_add_mconfig(machine_config &config) { - TC8566AF(config, m_fdc, 16'000'000); + TC8566AF(config, m_fdc, XTAL::u(16'000'000)); // Double sided 3.5" floppy drive FLOPPY_CONNECTOR(config, "fdc:0", msx_floppies, "35dd", msx_cart_disk_device::floppy_formats); diff --git a/src/devices/bus/msx_cart/disk.h b/src/devices/bus/msx_cart/disk.h index fd8d640157f..46845526847 100644 --- a/src/devices/bus/msx_cart/disk.h +++ b/src/devices/bus/msx_cart/disk.h @@ -23,7 +23,7 @@ public: virtual void initialize_cartridge() override; protected: - msx_cart_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_cart_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); required_device<floppy_connector> m_floppy0; optional_device<floppy_connector> m_floppy1; @@ -36,7 +36,7 @@ protected: class msx_cart_disk_wd_device : public msx_cart_disk_device { protected: - msx_cart_disk_wd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_cart_disk_wd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); required_device<wd_fdc_analog_device_base> m_fdc; }; @@ -49,7 +49,7 @@ public: virtual void write_cart(offs_t offset, uint8_t data) override; protected: - msx_cart_disk_type1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_cart_disk_type1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -72,7 +72,7 @@ public: virtual void write_cart(offs_t offset, uint8_t data) override; protected: - msx_cart_disk_type2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_cart_disk_type2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -89,7 +89,7 @@ protected: class msx_cart_vy0010_device : public msx_cart_disk_type1_device { public: - msx_cart_vy0010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_vy0010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -99,7 +99,7 @@ protected: class msx_cart_fsfd1_device : public msx_cart_disk_type1_device { public: - msx_cart_fsfd1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_fsfd1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -109,7 +109,7 @@ protected: class msx_cart_fscf351_device : public msx_cart_disk_type2_device { public: - msx_cart_fscf351_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_fscf351_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -119,7 +119,7 @@ protected: class msx_cart_disk_tc8566_device : public msx_cart_disk_device { protected: - msx_cart_disk_tc8566_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_cart_disk_tc8566_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); required_device<tc8566af_device> m_fdc; }; @@ -128,7 +128,7 @@ protected: class msx_cart_fsfd1a_device : public msx_cart_disk_tc8566_device { public: - msx_cart_fsfd1a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_fsfd1a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/msx_cart/dooly.cpp b/src/devices/bus/msx_cart/dooly.cpp index a0c4c7b4f83..01cf43fb41a 100644 --- a/src/devices/bus/msx_cart/dooly.cpp +++ b/src/devices/bus/msx_cart/dooly.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_DOOLY, msx_cart_dooly_device, "msx_cart_dooly", "MSX Cartridge - Dooly") -msx_cart_dooly_device::msx_cart_dooly_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_dooly_device::msx_cart_dooly_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_DOOLY, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_prot(0) diff --git a/src/devices/bus/msx_cart/dooly.h b/src/devices/bus/msx_cart/dooly.h index 76f58ae762d..fbfcedd8a63 100644 --- a/src/devices/bus/msx_cart/dooly.h +++ b/src/devices/bus/msx_cart/dooly.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_DOOLY, msx_cart_dooly_device) class msx_cart_dooly_device : public device_t, public msx_cart_interface { public: - msx_cart_dooly_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_dooly_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/easi_speech.cpp b/src/devices/bus/msx_cart/easi_speech.cpp index 0a9d2d5551d..402b0b7aedc 100644 --- a/src/devices/bus/msx_cart/easi_speech.cpp +++ b/src/devices/bus/msx_cart/easi_speech.cpp @@ -17,7 +17,7 @@ a$=usr0("hello") DEFINE_DEVICE_TYPE(MSX_CART_EASISPEECH, msx_cart_easispeech_device, "msx_cart_easispeech", "MSX Cartridge - Easi-Speech") -msx_cart_easispeech_device::msx_cart_easispeech_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_easispeech_device::msx_cart_easispeech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_EASISPEECH, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_speech(*this, "speech") @@ -36,7 +36,7 @@ const tiny_rom_entry *msx_cart_easispeech_device::device_rom_region() const void msx_cart_easispeech_device::device_add_mconfig(machine_config &config) { - SP0256(config, m_speech, 3120000); // frequency unknown + SP0256(config, m_speech, XTAL::u(3120000)); // frequency unknown m_speech->add_route(ALL_OUTPUTS, ":speaker", 1.00); } diff --git a/src/devices/bus/msx_cart/easi_speech.h b/src/devices/bus/msx_cart/easi_speech.h index 2aba350c4c7..5d285ebd1e4 100644 --- a/src/devices/bus/msx_cart/easi_speech.h +++ b/src/devices/bus/msx_cart/easi_speech.h @@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_EASISPEECH, msx_cart_easispeech_device) class msx_cart_easispeech_device : public device_t, public msx_cart_interface { public: - msx_cart_easispeech_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_easispeech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_cart(offs_t offset) override; virtual void write_cart(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/msx_cart/fmpac.cpp b/src/devices/bus/msx_cart/fmpac.cpp index 75af22353dc..66e8b77f282 100644 --- a/src/devices/bus/msx_cart/fmpac.cpp +++ b/src/devices/bus/msx_cart/fmpac.cpp @@ -14,7 +14,7 @@ with: PAC2 BACKUP DATA. We only store the raw sram contents. DEFINE_DEVICE_TYPE(MSX_CART_FMPAC, msx_cart_fmpac_device, "msx_cart_fmpac", "MSX Cartridge - FM-PAC") -msx_cart_fmpac_device::msx_cart_fmpac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_fmpac_device::msx_cart_fmpac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_FMPAC, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_ym2413(*this, "ym2413") diff --git a/src/devices/bus/msx_cart/fmpac.h b/src/devices/bus/msx_cart/fmpac.h index 9175849eaba..b64275c71c0 100644 --- a/src/devices/bus/msx_cart/fmpac.h +++ b/src/devices/bus/msx_cart/fmpac.h @@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_FMPAC, msx_cart_fmpac_device) class msx_cart_fmpac_device : public device_t, public msx_cart_interface { public: - msx_cart_fmpac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_fmpac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/fs_sr022.cpp b/src/devices/bus/msx_cart/fs_sr022.cpp index bb84a759214..7233daa30f7 100644 --- a/src/devices/bus/msx_cart/fs_sr022.cpp +++ b/src/devices/bus/msx_cart/fs_sr022.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_FS_SR022, msx_cart_fs_sr022_device, "msx_cart_fs_sr022", "MSX Cartridge - FS-SR022") -msx_cart_fs_sr022_device::msx_cart_fs_sr022_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_fs_sr022_device::msx_cart_fs_sr022_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_FS_SR022, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bunsetsu_rom(nullptr) diff --git a/src/devices/bus/msx_cart/fs_sr022.h b/src/devices/bus/msx_cart/fs_sr022.h index 2456b90a101..321677f974d 100644 --- a/src/devices/bus/msx_cart/fs_sr022.h +++ b/src/devices/bus/msx_cart/fs_sr022.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_FS_SR022, msx_cart_fs_sr022_device) class msx_cart_fs_sr022_device : public device_t, public msx_cart_interface { public: - msx_cart_fs_sr022_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_fs_sr022_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/halnote.cpp b/src/devices/bus/msx_cart/halnote.cpp index 43f7947ec2c..3aa4fe821bb 100644 --- a/src/devices/bus/msx_cart/halnote.cpp +++ b/src/devices/bus/msx_cart/halnote.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_HALNOTE, msx_cart_halnote_device, "msx_cart_halnote", "MSX Cartridge - Halnote") -msx_cart_halnote_device::msx_cart_halnote_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_halnote_device::msx_cart_halnote_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_HALNOTE, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_selected_bank{ 0, 0, 0, 0, 0, 0, 0, 0 } diff --git a/src/devices/bus/msx_cart/halnote.h b/src/devices/bus/msx_cart/halnote.h index a9c1972afeb..90974031c9a 100644 --- a/src/devices/bus/msx_cart/halnote.h +++ b/src/devices/bus/msx_cart/halnote.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_HALNOTE, msx_cart_halnote_device) class msx_cart_halnote_device : public device_t, public msx_cart_interface { public: - msx_cart_halnote_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_halnote_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/hfox.cpp b/src/devices/bus/msx_cart/hfox.cpp index 007155b6e5b..a8e0e995e5b 100644 --- a/src/devices/bus/msx_cart/hfox.cpp +++ b/src/devices/bus/msx_cart/hfox.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_HFOX, msx_cart_hfox_device, "msx_cart_hfox", "MSX Cartridge - Hurry Fox") -msx_cart_hfox_device::msx_cart_hfox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_hfox_device::msx_cart_hfox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_HFOX, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_selected_bank{ 0, 0 } diff --git a/src/devices/bus/msx_cart/hfox.h b/src/devices/bus/msx_cart/hfox.h index 6254bae3610..bd18fe47bac 100644 --- a/src/devices/bus/msx_cart/hfox.h +++ b/src/devices/bus/msx_cart/hfox.h @@ -12,7 +12,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_HFOX, msx_cart_hfox_device) class msx_cart_hfox_device : public device_t, public msx_cart_interface { public: - msx_cart_hfox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_hfox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/holy_quran.cpp b/src/devices/bus/msx_cart/holy_quran.cpp index fbfb799fad5..47c7a8881f7 100644 --- a/src/devices/bus/msx_cart/holy_quran.cpp +++ b/src/devices/bus/msx_cart/holy_quran.cpp @@ -16,7 +16,7 @@ GCMK-16X PCB, 2 ROM chips, Yamaha XE297A0 mapper chip. DEFINE_DEVICE_TYPE(MSX_CART_HOLY_QURAN, msx_cart_holy_quran_device, "msx_cart_holy_quran", "MSX Cartridge - Holy Quran") -msx_cart_holy_quran_device::msx_cart_holy_quran_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_holy_quran_device::msx_cart_holy_quran_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_HOLY_QURAN, tag, owner, clock) , msx_cart_interface(mconfig, *this) { diff --git a/src/devices/bus/msx_cart/holy_quran.h b/src/devices/bus/msx_cart/holy_quran.h index 25b1ddf8f50..4c7cdb02b00 100644 --- a/src/devices/bus/msx_cart/holy_quran.h +++ b/src/devices/bus/msx_cart/holy_quran.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_HOLY_QURAN, msx_cart_holy_quran_device) class msx_cart_holy_quran_device : public device_t, public msx_cart_interface { public: - msx_cart_holy_quran_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_holy_quran_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/ink.cpp b/src/devices/bus/msx_cart/ink.cpp index e3053a5da7d..90968afafa2 100644 --- a/src/devices/bus/msx_cart/ink.cpp +++ b/src/devices/bus/msx_cart/ink.cpp @@ -15,7 +15,7 @@ for protection. DEFINE_DEVICE_TYPE(MSX_CART_INK, msx_cart_ink_device, "msx_cart_ink", "MSX Cartridge - Ink") -msx_cart_ink_device::msx_cart_ink_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_ink_device::msx_cart_ink_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_INK, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_flash(*this, "flash") diff --git a/src/devices/bus/msx_cart/ink.h b/src/devices/bus/msx_cart/ink.h index 933385c575d..cfd4d46b266 100644 --- a/src/devices/bus/msx_cart/ink.h +++ b/src/devices/bus/msx_cart/ink.h @@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_INK, msx_cart_ink_device) class msx_cart_ink_device : public device_t, public msx_cart_interface { public: - msx_cart_ink_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_ink_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/konami.cpp b/src/devices/bus/msx_cart/konami.cpp index 5954cb95091..b3c7b6f7fb2 100644 --- a/src/devices/bus/msx_cart/konami.cpp +++ b/src/devices/bus/msx_cart/konami.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_SOUND_SDSNATCHER, msx_cart_konami_sound_sdsnatcher_d DEFINE_DEVICE_TYPE(MSX_CART_KEYBOARD_MASTER, msx_cart_keyboard_master_device, "msx_cart_keyboard_master", "MSX Cartridge - Keyboard Master") -msx_cart_konami_device::msx_cart_konami_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_konami_device::msx_cart_konami_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_KONAMI, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bank_mask(0) @@ -126,7 +126,7 @@ void msx_cart_konami_device::write_cart(offs_t offset, uint8_t data) -msx_cart_konami_scc_device::msx_cart_konami_scc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_konami_scc_device::msx_cart_konami_scc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_KONAMI_SCC, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_k051649(*this, "k051649") @@ -300,7 +300,7 @@ void msx_cart_konami_scc_device::write_cart(offs_t offset, uint8_t data) -msx_cart_gamemaster2_device::msx_cart_gamemaster2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_gamemaster2_device::msx_cart_gamemaster2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_GAMEMASTER2, tag, owner, clock) , msx_cart_interface(mconfig, *this) { @@ -474,7 +474,7 @@ void msx_cart_gamemaster2_device::write_cart(offs_t offset, uint8_t data) -msx_cart_synthesizer_device::msx_cart_synthesizer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_synthesizer_device::msx_cart_synthesizer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_SYNTHESIZER, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bank_base(nullptr) @@ -487,7 +487,7 @@ void msx_cart_synthesizer_device::device_add_mconfig(machine_config &config) { // This is actually incorrect. The sound output is passed back into the MSX machine where it is mixed internally and output through the system 'speaker'. SPEAKER(config, "speaker").front_center(); - DAC_8BIT_R2R(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.1); // unknown DAC + DAC_8BIT_R2R(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.1); // unknown DAC } @@ -528,7 +528,7 @@ void msx_cart_synthesizer_device::write_cart(offs_t offset, uint8_t data) -msx_cart_konami_sound_device::msx_cart_konami_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_cart_konami_sound_device::msx_cart_konami_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_k052539(*this, "k052539") @@ -822,7 +822,7 @@ void msx_cart_konami_sound_device::write_cart(offs_t offset, uint8_t data) } -msx_cart_konami_sound_snatcher_device::msx_cart_konami_sound_snatcher_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_konami_sound_snatcher_device::msx_cart_konami_sound_snatcher_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_konami_sound_device(mconfig, MSX_CART_SOUND_SNATCHER, tag, owner, clock) { } @@ -846,7 +846,7 @@ void msx_cart_konami_sound_snatcher_device::initialize_cartridge() } -msx_cart_konami_sound_sdsnatcher_device::msx_cart_konami_sound_sdsnatcher_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_konami_sound_sdsnatcher_device::msx_cart_konami_sound_sdsnatcher_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_konami_sound_device(mconfig, MSX_CART_SOUND_SDSNATCHER, tag, owner, clock) { } @@ -872,7 +872,7 @@ void msx_cart_konami_sound_sdsnatcher_device::initialize_cartridge() -msx_cart_keyboard_master_device::msx_cart_keyboard_master_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_keyboard_master_device::msx_cart_keyboard_master_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_KEYBOARD_MASTER, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_vlm5030(*this, "vlm5030") diff --git a/src/devices/bus/msx_cart/konami.h b/src/devices/bus/msx_cart/konami.h index 58ad4f3cfb7..fa5860a1040 100644 --- a/src/devices/bus/msx_cart/konami.h +++ b/src/devices/bus/msx_cart/konami.h @@ -21,7 +21,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_KEYBOARD_MASTER, msx_cart_keyboard_master_device) class msx_cart_konami_device : public device_t, public msx_cart_interface { public: - msx_cart_konami_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_konami_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -46,7 +46,7 @@ private: class msx_cart_konami_scc_device : public device_t, public msx_cart_interface { public: - msx_cart_konami_scc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_konami_scc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -76,7 +76,7 @@ private: class msx_cart_gamemaster2_device : public device_t, public msx_cart_interface { public: - msx_cart_gamemaster2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_gamemaster2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -102,7 +102,7 @@ private: class msx_cart_synthesizer_device : public device_t, public msx_cart_interface { public: - msx_cart_synthesizer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_synthesizer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -130,7 +130,7 @@ public: virtual void write_cart(offs_t offset, uint8_t data) override; protected: - msx_cart_konami_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_cart_konami_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -161,7 +161,7 @@ private: class msx_cart_konami_sound_snatcher_device : public msx_cart_konami_sound_device { public: - msx_cart_konami_sound_snatcher_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_konami_sound_snatcher_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; }; @@ -170,7 +170,7 @@ public: class msx_cart_konami_sound_sdsnatcher_device : public msx_cart_konami_sound_device { public: - msx_cart_konami_sound_sdsnatcher_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_konami_sound_sdsnatcher_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; }; @@ -180,7 +180,7 @@ public: class msx_cart_keyboard_master_device : public device_t, public msx_cart_interface { public: - msx_cart_keyboard_master_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_keyboard_master_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/msx_cart/korean.cpp b/src/devices/bus/msx_cart/korean.cpp index e12f15bd43d..92f4469bd00 100644 --- a/src/devices/bus/msx_cart/korean.cpp +++ b/src/devices/bus/msx_cart/korean.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_KOREAN_90IN1, msx_cart_korean_90in1_device, "msx_c DEFINE_DEVICE_TYPE(MSX_CART_KOREAN_126IN1, msx_cart_korean_126in1_device, "msx_cart_korean_126in1", "MSX Cartridge - Korean 126-in-1") -msx_cart_korean_80in1_device::msx_cart_korean_80in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_korean_80in1_device::msx_cart_korean_80in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_KOREAN_80IN1, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bank_mask(0) @@ -102,7 +102,7 @@ void msx_cart_korean_80in1_device::write_cart(offs_t offset, uint8_t data) -msx_cart_korean_90in1_device::msx_cart_korean_90in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_korean_90in1_device::msx_cart_korean_90in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_KOREAN_90IN1, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bank_mask(0) @@ -209,7 +209,7 @@ void msx_cart_korean_90in1_device::banking(uint8_t data) -msx_cart_korean_126in1_device::msx_cart_korean_126in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_korean_126in1_device::msx_cart_korean_126in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_KOREAN_126IN1, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_bank_mask(0) diff --git a/src/devices/bus/msx_cart/korean.h b/src/devices/bus/msx_cart/korean.h index 62c5a6ba82b..4e4ac8dfea8 100644 --- a/src/devices/bus/msx_cart/korean.h +++ b/src/devices/bus/msx_cart/korean.h @@ -16,7 +16,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_KOREAN_126IN1, msx_cart_korean_126in1_device) class msx_cart_korean_80in1_device : public device_t, public msx_cart_interface { public: - msx_cart_korean_80in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_korean_80in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -42,7 +42,7 @@ private: class msx_cart_korean_90in1_device : public device_t, public msx_cart_interface { public: - msx_cart_korean_90in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_korean_90in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -68,7 +68,7 @@ private: class msx_cart_korean_126in1_device : public device_t, public msx_cart_interface { public: - msx_cart_korean_126in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_korean_126in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/majutsushi.cpp b/src/devices/bus/msx_cart/majutsushi.cpp index c94f5a00dc5..0d3611d7499 100644 --- a/src/devices/bus/msx_cart/majutsushi.cpp +++ b/src/devices/bus/msx_cart/majutsushi.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_MAJUTSUSHI, msx_cart_majutsushi_device, "msx_cart_majutsushi", "MSX Cartridge - Majutsushi") -msx_cart_majutsushi_device::msx_cart_majutsushi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_majutsushi_device::msx_cart_majutsushi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_MAJUTSUSHI, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_dac(*this, "dac") @@ -29,7 +29,7 @@ void msx_cart_majutsushi_device::device_add_mconfig(machine_config &config) { // This is actually incorrect. The sound output is passed back into the MSX machine where it is mixed internally and output through the system 'speaker'. SPEAKER(config, "speaker").front_center(); - DAC_8BIT_R2R(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.05); // unknown DAC + DAC_8BIT_R2R(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.05); // unknown DAC } diff --git a/src/devices/bus/msx_cart/majutsushi.h b/src/devices/bus/msx_cart/majutsushi.h index ebdf549272e..6856a206d2d 100644 --- a/src/devices/bus/msx_cart/majutsushi.h +++ b/src/devices/bus/msx_cart/majutsushi.h @@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_MAJUTSUSHI, msx_cart_majutsushi_device) class msx_cart_majutsushi_device : public device_t, public msx_cart_interface { public: - msx_cart_majutsushi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_majutsushi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/moonsound.cpp b/src/devices/bus/msx_cart/moonsound.cpp index 07ae53f6fca..075d97cfc0e 100644 --- a/src/devices/bus/msx_cart/moonsound.cpp +++ b/src/devices/bus/msx_cart/moonsound.cpp @@ -21,7 +21,7 @@ TODO: DEFINE_DEVICE_TYPE(MSX_CART_MOONSOUND, msx_cart_moonsound_device, "msx_moonsound", "MSX Cartridge - MoonSound") -msx_cart_moonsound_device::msx_cart_moonsound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_moonsound_device::msx_cart_moonsound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_MOONSOUND, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_ymf278b(*this, "ymf278b") diff --git a/src/devices/bus/msx_cart/moonsound.h b/src/devices/bus/msx_cart/moonsound.h index 62f614ae729..174f0a1850f 100644 --- a/src/devices/bus/msx_cart/moonsound.h +++ b/src/devices/bus/msx_cart/moonsound.h @@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_MOONSOUND, msx_cart_moonsound_device) class msx_cart_moonsound_device : public device_t, public msx_cart_interface { public: - msx_cart_moonsound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_moonsound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/msx_cart/msx_audio.cpp b/src/devices/bus/msx_cart/msx_audio.cpp index 3f8fd1fd772..381cd3dd891 100644 --- a/src/devices/bus/msx_cart/msx_audio.cpp +++ b/src/devices/bus/msx_cart/msx_audio.cpp @@ -72,7 +72,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_MSX_AUDIO_NMS1205, msx_cart_msx_audio_nms1205_device DEFINE_DEVICE_TYPE(MSX_CART_MSX_AUDIO_FSCA1, msx_cart_msx_audio_fsca1_device, "msx_audio_fsca1", "MSX Cartridge - MSX-AUDIO FS-CA1") -msx_cart_msx_audio_hxmu900_device::msx_cart_msx_audio_hxmu900_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_msx_audio_hxmu900_device::msx_cart_msx_audio_hxmu900_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_MSX_AUDIO_HXMU900, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_y8950(*this, "y8950") @@ -134,7 +134,7 @@ const tiny_rom_entry *msx_cart_msx_audio_hxmu900_device::device_rom_region() con -msx_cart_msx_audio_nms1205_device::msx_cart_msx_audio_nms1205_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_msx_audio_nms1205_device::msx_cart_msx_audio_nms1205_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_MSX_AUDIO_NMS1205, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_y8950(*this, "y8950") @@ -159,7 +159,7 @@ void msx_cart_msx_audio_nms1205_device::device_add_mconfig(machine_config &confi MSX_AUDIO_KBDC_PORT(config, "kbdc", msx_audio_keyboards, nullptr); // There is a 2 MHz crystal on the PCB, the 6850 TX and RX clocks are derived from it - ACIA6850(config, m_acia6850, 0); + ACIA6850(config, m_acia6850); m_acia6850->txd_handler().set("mdout", FUNC(midi_port_device::write_txd)); MIDI_PORT(config, "mdin", midiin_slot, "midiin").rxd_handler().set(FUNC(msx_cart_msx_audio_nms1205_device::midi_in)); @@ -231,7 +231,7 @@ uint8_t msx_cart_msx_audio_nms1205_device::read_cart(offs_t offset) -msx_cart_msx_audio_fsca1_device::msx_cart_msx_audio_fsca1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_msx_audio_fsca1_device::msx_cart_msx_audio_fsca1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_MSX_AUDIO_FSCA1, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_y8950(*this, "y8950") diff --git a/src/devices/bus/msx_cart/msx_audio.h b/src/devices/bus/msx_cart/msx_audio.h index 490169244af..dd58e93fb69 100644 --- a/src/devices/bus/msx_cart/msx_audio.h +++ b/src/devices/bus/msx_cart/msx_audio.h @@ -19,7 +19,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_MSX_AUDIO_FSCA1, msx_cart_msx_audio_fsca1_device) class msx_cart_msx_audio_hxmu900_device : public device_t, public msx_cart_interface { public: - msx_cart_msx_audio_hxmu900_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_msx_audio_hxmu900_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -40,7 +40,7 @@ private: class msx_cart_msx_audio_nms1205_device : public device_t, public msx_cart_interface { public: - msx_cart_msx_audio_nms1205_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_msx_audio_nms1205_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; @@ -67,7 +67,7 @@ private: class msx_cart_msx_audio_fsca1_device : public device_t, public msx_cart_interface { public: - msx_cart_msx_audio_fsca1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_msx_audio_fsca1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/msx_audio_kb.cpp b/src/devices/bus/msx_cart/msx_audio_kb.cpp index aba915ed718..ff931a2df5f 100644 --- a/src/devices/bus/msx_cart/msx_audio_kb.cpp +++ b/src/devices/bus/msx_cart/msx_audio_kb.cpp @@ -13,7 +13,7 @@ msx_audio_kb_port_interface::msx_audio_kb_port_interface(machine_config const &m } -msx_audio_kbdc_port_device::msx_audio_kbdc_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_audio_kbdc_port_device::msx_audio_kbdc_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_AUDIO_KBDC_PORT, tag, owner, clock) , device_single_card_slot_interface<msx_audio_kb_port_interface>(mconfig, *this) , m_keyboard(nullptr) @@ -50,7 +50,7 @@ DECLARE_DEVICE_TYPE(MSX_AUDIO_KB_NMS1160, msx_nms1160_device) class msx_hxmu901_device : public device_t, public msx_audio_kb_port_interface { public: - msx_hxmu901_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + msx_hxmu901_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_AUDIO_KB_HXMU901, tag, owner, clock) , msx_audio_kb_port_interface(mconfig, *this) , m_row(0) @@ -180,7 +180,7 @@ ioport_constructor msx_hxmu901_device::device_input_ports() const class msx_nms1160_device : public device_t, public msx_audio_kb_port_interface { public: - msx_nms1160_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + msx_nms1160_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_AUDIO_KB_NMS1160, tag, owner, clock) , msx_audio_kb_port_interface(mconfig, *this) , m_row(0) diff --git a/src/devices/bus/msx_cart/msx_audio_kb.h b/src/devices/bus/msx_cart/msx_audio_kb.h index ecab5732c98..04f6c1eb18f 100644 --- a/src/devices/bus/msx_cart/msx_audio_kb.h +++ b/src/devices/bus/msx_cart/msx_audio_kb.h @@ -25,14 +25,14 @@ public: // construction/destruction template <typename T> msx_audio_kbdc_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : msx_audio_kbdc_port_device(mconfig, tag, owner, (uint32_t)0) + : msx_audio_kbdc_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - msx_audio_kbdc_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_audio_kbdc_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Physical connection simply consists of 8 input and 8 output lines split across 2 connectors void write(uint8_t data); diff --git a/src/devices/bus/msx_cart/msxdos2.cpp b/src/devices/bus/msx_cart/msxdos2.cpp index 7f3e506b007..d39bb0aed42 100644 --- a/src/devices/bus/msx_cart/msxdos2.cpp +++ b/src/devices/bus/msx_cart/msxdos2.cpp @@ -6,7 +6,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_MSXDOS2, msx_cart_msxdos2_device, "msx_cart_msxdos2", "MSX Cartridge - MSXDOS2") -msx_cart_msxdos2_device::msx_cart_msxdos2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_msxdos2_device::msx_cart_msxdos2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_MSXDOS2, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_selected_bank(0) diff --git a/src/devices/bus/msx_cart/msxdos2.h b/src/devices/bus/msx_cart/msxdos2.h index dd5eb51d245..be703c19e5d 100644 --- a/src/devices/bus/msx_cart/msxdos2.h +++ b/src/devices/bus/msx_cart/msxdos2.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_MSXDOS2, msx_cart_msxdos2_device) class msx_cart_msxdos2_device : public device_t, public msx_cart_interface { public: - msx_cart_msxdos2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_msxdos2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/nomapper.cpp b/src/devices/bus/msx_cart/nomapper.cpp index 24ebbb38e0d..af3b97c17b5 100644 --- a/src/devices/bus/msx_cart/nomapper.cpp +++ b/src/devices/bus/msx_cart/nomapper.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_NOMAPPER, msx_cart_nomapper_device, "msx_cart_nomapper", "MSX Cartridge - ROM") -msx_cart_nomapper_device::msx_cart_nomapper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_nomapper_device::msx_cart_nomapper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_NOMAPPER, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_start_address(0) diff --git a/src/devices/bus/msx_cart/nomapper.h b/src/devices/bus/msx_cart/nomapper.h index eb5e40e1d08..09f410018a0 100644 --- a/src/devices/bus/msx_cart/nomapper.h +++ b/src/devices/bus/msx_cart/nomapper.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_NOMAPPER, msx_cart_nomapper_device) class msx_cart_nomapper_device : public device_t, public msx_cart_interface { public: - msx_cart_nomapper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_nomapper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/msx_cart/rtype.cpp b/src/devices/bus/msx_cart/rtype.cpp index 6cda0efb4e8..74549401b46 100644 --- a/src/devices/bus/msx_cart/rtype.cpp +++ b/src/devices/bus/msx_cart/rtype.cpp @@ -6,7 +6,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_RTYPE, msx_cart_rtype_device, "msx_cart_rtype", "MSX Cartridge - R-Type") -msx_cart_rtype_device::msx_cart_rtype_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_rtype_device::msx_cart_rtype_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_RTYPE, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_selected_bank(0) diff --git a/src/devices/bus/msx_cart/rtype.h b/src/devices/bus/msx_cart/rtype.h index 31583455a0a..937534c2277 100644 --- a/src/devices/bus/msx_cart/rtype.h +++ b/src/devices/bus/msx_cart/rtype.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_RTYPE, msx_cart_rtype_device) class msx_cart_rtype_device : public device_t, public msx_cart_interface { public: - msx_cart_rtype_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_rtype_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/super_swangi.cpp b/src/devices/bus/msx_cart/super_swangi.cpp index b3385f96e29..0ac5847a368 100644 --- a/src/devices/bus/msx_cart/super_swangi.cpp +++ b/src/devices/bus/msx_cart/super_swangi.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_SUPER_SWANGI, msx_cart_super_swangi_device, "msx_cart_super_swangi", "MSX Cartridge - Super Swangi") -msx_cart_super_swangi_device::msx_cart_super_swangi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_super_swangi_device::msx_cart_super_swangi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_SUPER_SWANGI, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_selected_bank(0) diff --git a/src/devices/bus/msx_cart/super_swangi.h b/src/devices/bus/msx_cart/super_swangi.h index f0f5ee216bd..16f7a21e6de 100644 --- a/src/devices/bus/msx_cart/super_swangi.h +++ b/src/devices/bus/msx_cart/super_swangi.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_SUPER_SWANGI, msx_cart_super_swangi_device) class msx_cart_super_swangi_device : public device_t, public msx_cart_interface { public: - msx_cart_super_swangi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_super_swangi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/superloderunner.cpp b/src/devices/bus/msx_cart/superloderunner.cpp index 168f9187f8d..e853f677c05 100644 --- a/src/devices/bus/msx_cart/superloderunner.cpp +++ b/src/devices/bus/msx_cart/superloderunner.cpp @@ -6,7 +6,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_SUPERLODERUNNER, msx_cart_superloderunner_device, "msx_cart_superloderunner", "MSX Cartridge - Super Lode Runner") -msx_cart_superloderunner_device::msx_cart_superloderunner_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_superloderunner_device::msx_cart_superloderunner_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_CART_SUPERLODERUNNER, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_selected_bank(0) diff --git a/src/devices/bus/msx_cart/superloderunner.h b/src/devices/bus/msx_cart/superloderunner.h index bd763ca2c08..79c56d374a5 100644 --- a/src/devices/bus/msx_cart/superloderunner.h +++ b/src/devices/bus/msx_cart/superloderunner.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(MSX_CART_SUPERLODERUNNER, msx_cart_superloderunner_device) class msx_cart_superloderunner_device : public device_t, public msx_cart_interface { public: - msx_cart_superloderunner_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_superloderunner_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void initialize_cartridge() override; diff --git a/src/devices/bus/msx_cart/yamaha.cpp b/src/devices/bus/msx_cart/yamaha.cpp index b2cb15a37b0..72a44a59d1c 100644 --- a/src/devices/bus/msx_cart/yamaha.cpp +++ b/src/devices/bus/msx_cart/yamaha.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(MSX_CART_SFG01, msx_cart_sfg01_device, "msx_cart_sfg01", "MSX DEFINE_DEVICE_TYPE(MSX_CART_SFG05, msx_cart_sfg05_device, "msx_cart_sfg05", "MSX Cartridge - SFG05") -msx_cart_sfg_device::msx_cart_sfg_device(const machine_config &mconfig, const device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_cart_sfg_device::msx_cart_sfg_device(const machine_config &mconfig, const device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , msx_cart_interface(mconfig, *this) , m_region_sfg(*this, "sfg") @@ -31,13 +31,13 @@ msx_cart_sfg_device::msx_cart_sfg_device(const machine_config &mconfig, const de } -msx_cart_sfg01_device::msx_cart_sfg01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_sfg01_device::msx_cart_sfg01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_sfg_device(mconfig, MSX_CART_SFG01, tag, owner, clock) { } -msx_cart_sfg05_device::msx_cart_sfg05_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_cart_sfg05_device::msx_cart_sfg05_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_cart_sfg_device(mconfig, MSX_CART_SFG05, tag, owner, clock) { } diff --git a/src/devices/bus/msx_cart/yamaha.h b/src/devices/bus/msx_cart/yamaha.h index cd4c036cab8..f865bb980aa 100644 --- a/src/devices/bus/msx_cart/yamaha.h +++ b/src/devices/bus/msx_cart/yamaha.h @@ -22,7 +22,7 @@ public: virtual void write_cart(offs_t offset, uint8_t data) override; protected: - msx_cart_sfg_device(const machine_config &mconfig, const device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_cart_sfg_device(const machine_config &mconfig, const device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -49,7 +49,7 @@ protected: class msx_cart_sfg01_device : public msx_cart_sfg_device { public: - msx_cart_sfg01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_sfg01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; @@ -58,7 +58,7 @@ public: class msx_cart_sfg05_device : public msx_cart_sfg_device { public: - msx_cart_sfg05_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_cart_sfg05_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/msx_slot/bunsetsu.cpp b/src/devices/bus/msx_slot/bunsetsu.cpp index 9c73a37dbd8..caaa0d62eec 100644 --- a/src/devices/bus/msx_slot/bunsetsu.cpp +++ b/src/devices/bus/msx_slot/bunsetsu.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(MSX_SLOT_BUNSETSU, msx_slot_bunsetsu_device, "msx_slot_bunsetsu", "MSX Internal BUNSETSU") -msx_slot_bunsetsu_device::msx_slot_bunsetsu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_bunsetsu_device::msx_slot_bunsetsu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_rom_device(mconfig, MSX_SLOT_BUNSETSU, tag, owner, clock) , m_bunsetsu_region(*this, finder_base::DUMMY_TAG) , m_bunsetsu_address(0) diff --git a/src/devices/bus/msx_slot/bunsetsu.h b/src/devices/bus/msx_slot/bunsetsu.h index df0bcedb32f..c11492a7156 100644 --- a/src/devices/bus/msx_slot/bunsetsu.h +++ b/src/devices/bus/msx_slot/bunsetsu.h @@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_BUNSETSU, msx_slot_bunsetsu_device) class msx_slot_bunsetsu_device : public msx_slot_rom_device { public: - msx_slot_bunsetsu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_bunsetsu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers void set_bunsetsu_region_tag(const char *tag) { m_bunsetsu_region.set_tag(tag); } diff --git a/src/devices/bus/msx_slot/cartridge.cpp b/src/devices/bus/msx_slot/cartridge.cpp index 667bbaf3cc7..793882e2211 100644 --- a/src/devices/bus/msx_slot/cartridge.cpp +++ b/src/devices/bus/msx_slot/cartridge.cpp @@ -33,13 +33,13 @@ DEFINE_DEVICE_TYPE(MSX_SLOT_CARTRIDGE, msx_slot_cartridge_device, DEFINE_DEVICE_TYPE(MSX_SLOT_YAMAHA_EXPANSION, msx_slot_yamaha_expansion_device, "msx_slot_yamaha_expansion", "MSX Yamaha Expansion slot") -msx_slot_cartridge_device::msx_slot_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_cartridge_device::msx_slot_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_cartridge_device(mconfig, MSX_SLOT_CARTRIDGE, tag, owner, clock) { } -msx_slot_cartridge_device::msx_slot_cartridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_slot_cartridge_device::msx_slot_cartridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_slot_interface(mconfig, *this) @@ -361,7 +361,7 @@ void msx_slot_cartridge_device::write(offs_t offset, uint8_t data) -msx_slot_yamaha_expansion_device::msx_slot_yamaha_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_yamaha_expansion_device::msx_slot_yamaha_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_cartridge_device(mconfig, MSX_SLOT_YAMAHA_EXPANSION, tag, owner, clock) { } diff --git a/src/devices/bus/msx_slot/cartridge.h b/src/devices/bus/msx_slot/cartridge.h index 68d827edc93..ad1944a091b 100644 --- a/src/devices/bus/msx_slot/cartridge.h +++ b/src/devices/bus/msx_slot/cartridge.h @@ -21,7 +21,7 @@ class msx_slot_cartridge_device : public device_t { public: // construction/destruction - msx_slot_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq_handler() { return m_irq_handler.bind(); } @@ -43,7 +43,7 @@ public: DECLARE_WRITE_LINE_MEMBER(irq_out); protected: - msx_slot_cartridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_slot_cartridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -60,7 +60,7 @@ class msx_slot_yamaha_expansion_device : public msx_slot_cartridge_device { public: // construction/destruction - msx_slot_yamaha_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_yamaha_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "msx_yamaha_60pin"; } virtual const char *image_type_name() const noexcept override { return "cartridge60pin"; } diff --git a/src/devices/bus/msx_slot/disk.cpp b/src/devices/bus/msx_slot/disk.cpp index 78a15b7d841..3c894fdc500 100644 --- a/src/devices/bus/msx_slot/disk.cpp +++ b/src/devices/bus/msx_slot/disk.cpp @@ -43,7 +43,7 @@ DEFINE_DEVICE_TYPE(MSX_SLOT_DISK5, msx_slot_disk5_device, "msx_slot_disk5", "MSX DEFINE_DEVICE_TYPE(MSX_SLOT_DISK6, msx_slot_disk6_device, "msx_slot_disk6", "MSX Internal floppy type 6") -msx_slot_disk_device::msx_slot_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_slot_disk_device::msx_slot_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_rom_device(mconfig, type, tag, owner, clock) , m_floppy0(nullptr) , m_floppy1(nullptr) @@ -80,7 +80,7 @@ void msx_slot_disk_device::device_start() } -msx_slot_wd_disk_device::msx_slot_wd_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_slot_wd_disk_device::msx_slot_wd_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_disk_device(mconfig, type, tag, owner, clock) , m_fdc(nullptr) , m_led(*this, "led0") @@ -102,7 +102,7 @@ void msx_slot_wd_disk_device::device_start() } -msx_slot_tc8566_disk_device::msx_slot_tc8566_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_slot_tc8566_disk_device::msx_slot_tc8566_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_disk_device(mconfig, type, tag, owner, clock) , m_fdc(nullptr) { @@ -123,7 +123,7 @@ void msx_slot_tc8566_disk_device::device_start() -msx_slot_disk1_device::msx_slot_disk1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_disk1_device::msx_slot_disk1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_wd_disk_device(mconfig, MSX_SLOT_DISK1, tag, owner, clock) , m_side_control(0) , m_control(0) @@ -284,7 +284,7 @@ void msx_slot_disk1_device::write(offs_t offset, uint8_t data) } -msx_slot_disk2_device::msx_slot_disk2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_disk2_device::msx_slot_disk2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_wd_disk_device(mconfig, MSX_SLOT_DISK2, tag, owner, clock) , m_control(0) { @@ -421,7 +421,7 @@ void msx_slot_disk2_device::write(offs_t offset, uint8_t data) -msx_slot_disk3_device::msx_slot_disk3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_disk3_device::msx_slot_disk3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_tc8566_disk_device(mconfig, MSX_SLOT_DISK3, tag, owner, clock) { } @@ -467,7 +467,7 @@ uint8_t msx_slot_disk3_device::read(offs_t offset) -msx_slot_disk4_device::msx_slot_disk4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_disk4_device::msx_slot_disk4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_tc8566_disk_device(mconfig, MSX_SLOT_DISK4, tag, owner, clock) { } @@ -519,7 +519,7 @@ uint8_t msx_slot_disk4_device::read(offs_t offset) -msx_slot_disk5_device::msx_slot_disk5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_disk5_device::msx_slot_disk5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_wd_disk_device(mconfig, MSX_SLOT_DISK5, tag, owner, clock) , m_control(0) { @@ -639,7 +639,7 @@ void msx_slot_disk5_device::io_write(offs_t offset, uint8_t data) -msx_slot_disk6_device::msx_slot_disk6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_disk6_device::msx_slot_disk6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_wd_disk_device(mconfig, MSX_SLOT_DISK6, tag, owner, clock) , m_side_motor(0) , m_drive_select0(0) diff --git a/src/devices/bus/msx_slot/disk.h b/src/devices/bus/msx_slot/disk.h index 184ea2caf66..f2dc88f1184 100644 --- a/src/devices/bus/msx_slot/disk.h +++ b/src/devices/bus/msx_slot/disk.h @@ -52,7 +52,7 @@ public: } protected: - msx_slot_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_slot_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -73,7 +73,7 @@ protected: class msx_slot_wd_disk_device : public msx_slot_disk_device { protected: - msx_slot_wd_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_slot_wd_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual void device_start() override; @@ -85,7 +85,7 @@ protected: class msx_slot_tc8566_disk_device : public msx_slot_disk_device { protected: - msx_slot_tc8566_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_slot_tc8566_disk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual void device_start() override; @@ -96,7 +96,7 @@ protected: class msx_slot_disk1_device : public msx_slot_wd_disk_device { public: - msx_slot_disk1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_disk1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; @@ -118,7 +118,7 @@ private: class msx_slot_disk2_device : public msx_slot_wd_disk_device { public: - msx_slot_disk2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_disk2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; @@ -138,7 +138,7 @@ private: class msx_slot_disk3_device : public msx_slot_tc8566_disk_device { public: - msx_slot_disk3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_disk3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; @@ -148,7 +148,7 @@ public: class msx_slot_disk4_device : public msx_slot_tc8566_disk_device { public: - msx_slot_disk4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_disk4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; @@ -158,7 +158,7 @@ public: class msx_slot_disk5_device : public msx_slot_wd_disk_device { public: - msx_slot_disk5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_disk5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void device_start() override; @@ -178,7 +178,7 @@ private: class msx_slot_disk6_device : public msx_slot_wd_disk_device { public: - msx_slot_disk6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_disk6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/msx_slot/fs4600.cpp b/src/devices/bus/msx_slot/fs4600.cpp index 0f328985f6f..be7a3ab0996 100644 --- a/src/devices/bus/msx_slot/fs4600.cpp +++ b/src/devices/bus/msx_slot/fs4600.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(MSX_SLOT_FS4600, msx_slot_fs4600_device, "msx_slot_fs4600", "MSX Internal FS4600 Firmware") -msx_slot_fs4600_device::msx_slot_fs4600_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_fs4600_device::msx_slot_fs4600_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_SLOT_FS4600, tag, owner, clock) , msx_internal_slot_interface(mconfig, *this) , m_nvram(*this, "nvram") diff --git a/src/devices/bus/msx_slot/fs4600.h b/src/devices/bus/msx_slot/fs4600.h index 4b571c2ef56..9eb6949ce03 100644 --- a/src/devices/bus/msx_slot/fs4600.h +++ b/src/devices/bus/msx_slot/fs4600.h @@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_FS4600, msx_slot_fs4600_device) class msx_slot_fs4600_device : public device_t, public msx_internal_slot_interface { public: - msx_slot_fs4600_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_fs4600_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers void set_rom_start(const char *region, uint32_t offset) { m_rom_region.set_tag(region); m_region_offset = offset; } diff --git a/src/devices/bus/msx_slot/music.cpp b/src/devices/bus/msx_slot/music.cpp index 1c5daf86b67..01dec988016 100644 --- a/src/devices/bus/msx_slot/music.cpp +++ b/src/devices/bus/msx_slot/music.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(MSX_SLOT_MUSIC, msx_slot_music_device, "msx_slot_music", "MSX Internal MSX-MUSIC") -msx_slot_music_device::msx_slot_music_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_music_device::msx_slot_music_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_rom_device(mconfig, MSX_SLOT_MUSIC, tag, owner, clock) , m_ym2413(nullptr) , m_ym2413_tag(nullptr) diff --git a/src/devices/bus/msx_slot/music.h b/src/devices/bus/msx_slot/music.h index 0d9240079ab..732855c0f54 100644 --- a/src/devices/bus/msx_slot/music.h +++ b/src/devices/bus/msx_slot/music.h @@ -16,7 +16,7 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_MUSIC, msx_slot_music_device) class msx_slot_music_device : public msx_slot_rom_device { public: - msx_slot_music_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_music_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers void set_ym2413_tag(const char *tag) { m_ym2413_tag = tag; } diff --git a/src/devices/bus/msx_slot/panasonic08.cpp b/src/devices/bus/msx_slot/panasonic08.cpp index 0c46350051e..74785572927 100644 --- a/src/devices/bus/msx_slot/panasonic08.cpp +++ b/src/devices/bus/msx_slot/panasonic08.cpp @@ -16,7 +16,7 @@ Todo: DEFINE_DEVICE_TYPE(MSX_SLOT_PANASONIC08, msx_slot_panasonic08_device, "msx_slot_panasonic08", "MSX Internal Panasonic08") -msx_slot_panasonic08_device::msx_slot_panasonic08_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_panasonic08_device::msx_slot_panasonic08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_SLOT_PANASONIC08, tag, owner, clock) , msx_internal_slot_interface(mconfig, *this) , m_nvram(*this, "nvram") diff --git a/src/devices/bus/msx_slot/panasonic08.h b/src/devices/bus/msx_slot/panasonic08.h index b21a4964e3b..547a17a779d 100644 --- a/src/devices/bus/msx_slot/panasonic08.h +++ b/src/devices/bus/msx_slot/panasonic08.h @@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_PANASONIC08, msx_slot_panasonic08_device) class msx_slot_panasonic08_device : public device_t, public msx_internal_slot_interface { public: - msx_slot_panasonic08_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_panasonic08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers void set_rom_start(const char *region, uint32_t offset) { m_rom_region.set_tag(region); m_region_offset = offset; } diff --git a/src/devices/bus/msx_slot/ram.cpp b/src/devices/bus/msx_slot/ram.cpp index 835a5551b92..3f1c52c0d95 100644 --- a/src/devices/bus/msx_slot/ram.cpp +++ b/src/devices/bus/msx_slot/ram.cpp @@ -6,7 +6,7 @@ DEFINE_DEVICE_TYPE(MSX_SLOT_RAM, msx_slot_ram_device, "msx_slot_ram", "MSX Internal RAM") -msx_slot_ram_device::msx_slot_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_ram_device::msx_slot_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_SLOT_RAM, tag, owner, clock) , msx_internal_slot_interface(mconfig, *this) { diff --git a/src/devices/bus/msx_slot/ram.h b/src/devices/bus/msx_slot/ram.h index f96271ad066..30c6219151c 100644 --- a/src/devices/bus/msx_slot/ram.h +++ b/src/devices/bus/msx_slot/ram.h @@ -9,7 +9,7 @@ class msx_slot_ram_device : public device_t, public msx_internal_slot_interface { public: - msx_slot_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Set to 0xe000 for 8KB RAM void force_start_address(uint16_t start) { m_start_address = start; } diff --git a/src/devices/bus/msx_slot/ram_mm.cpp b/src/devices/bus/msx_slot/ram_mm.cpp index 84498f9afe1..91b10920bcf 100644 --- a/src/devices/bus/msx_slot/ram_mm.cpp +++ b/src/devices/bus/msx_slot/ram_mm.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(MSX_SLOT_RAM_MM, msx_slot_ram_mm_device, "msx_slot_ram_mm", "MSX Internal Memory Mapped RAM") -msx_slot_ram_mm_device::msx_slot_ram_mm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_ram_mm_device::msx_slot_ram_mm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_SLOT_RAM_MM, tag, owner, clock) , msx_internal_slot_interface(mconfig, *this) , m_total_size(0) diff --git a/src/devices/bus/msx_slot/ram_mm.h b/src/devices/bus/msx_slot/ram_mm.h index 55f13659a4c..6de3c795f05 100644 --- a/src/devices/bus/msx_slot/ram_mm.h +++ b/src/devices/bus/msx_slot/ram_mm.h @@ -8,7 +8,7 @@ class msx_slot_ram_mm_device : public device_t, public msx_internal_slot_interface { public: - msx_slot_ram_mm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_ram_mm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); msx_slot_ram_mm_device &set_total_size(uint32_t total_size) { m_total_size = total_size; return *this; } msx_slot_ram_mm_device &set_ramio_bits(uint8_t ramio_set_bits) { m_ramio_set_bits = ramio_set_bits; return *this; } diff --git a/src/devices/bus/msx_slot/rom.cpp b/src/devices/bus/msx_slot/rom.cpp index aafc37b345b..fdf56673e6e 100644 --- a/src/devices/bus/msx_slot/rom.cpp +++ b/src/devices/bus/msx_slot/rom.cpp @@ -7,13 +7,13 @@ DEFINE_DEVICE_TYPE(MSX_SLOT_ROM, msx_slot_rom_device, "msx_slot_rom", "MSX Internal ROM") -msx_slot_rom_device::msx_slot_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_rom_device::msx_slot_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msx_slot_rom_device(mconfig, MSX_SLOT_ROM, tag, owner, clock) { } -msx_slot_rom_device::msx_slot_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +msx_slot_rom_device::msx_slot_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , msx_internal_slot_interface(mconfig, *this) , m_rom_region(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/bus/msx_slot/rom.h b/src/devices/bus/msx_slot/rom.h index 6bcd480a5a3..6ff46ff5ddb 100644 --- a/src/devices/bus/msx_slot/rom.h +++ b/src/devices/bus/msx_slot/rom.h @@ -11,7 +11,7 @@ class msx_slot_rom_device : public device_t, public msx_internal_slot_interface { public: - msx_slot_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers void set_rom_start(const char *region, uint32_t offset) { m_rom_region.set_tag(region); m_region_offset = offset; } @@ -19,7 +19,7 @@ public: virtual uint8_t read(offs_t offset) override; protected: - msx_slot_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msx_slot_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; diff --git a/src/devices/bus/msx_slot/sony08.cpp b/src/devices/bus/msx_slot/sony08.cpp index 652ed134457..e8a0fa60d75 100644 --- a/src/devices/bus/msx_slot/sony08.cpp +++ b/src/devices/bus/msx_slot/sony08.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(MSX_SLOT_SONY08, msx_slot_sony08_device, "msx_slot_sony08", "MSX Internal SONY08") -msx_slot_sony08_device::msx_slot_sony08_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msx_slot_sony08_device::msx_slot_sony08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSX_SLOT_SONY08, tag, owner, clock) , msx_internal_slot_interface(mconfig, *this) , m_nvram(*this, "nvram") diff --git a/src/devices/bus/msx_slot/sony08.h b/src/devices/bus/msx_slot/sony08.h index 74c8fd95f35..19920bbe1d9 100644 --- a/src/devices/bus/msx_slot/sony08.h +++ b/src/devices/bus/msx_slot/sony08.h @@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(MSX_SLOT_SONY08, msx_slot_sony08_device) class msx_slot_sony08_device : public device_t, public msx_internal_slot_interface { public: - msx_slot_sony08_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msx_slot_sony08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers void set_rom_start(const char *region, uint32_t offset) { m_rom_region.set_tag(region); m_region_offset = offset; } diff --git a/src/devices/bus/mtx/cfx.cpp b/src/devices/bus/mtx/cfx.cpp index d80290606c9..4cc4e953761 100644 --- a/src/devices/bus/mtx/cfx.cpp +++ b/src/devices/bus/mtx/cfx.cpp @@ -70,7 +70,7 @@ const tiny_rom_entry *mtx_cfx_device::device_rom_region() const // mtx_cfx_device - constructor //------------------------------------------------- -mtx_cfx_device::mtx_cfx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mtx_cfx_device::mtx_cfx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MTX_CFX, tag, owner, clock) , device_mtx_exp_interface(mconfig, *this) , m_flash(*this, "flash") diff --git a/src/devices/bus/mtx/cfx.h b/src/devices/bus/mtx/cfx.h index 1f19fd5648f..113d6917a63 100644 --- a/src/devices/bus/mtx/cfx.h +++ b/src/devices/bus/mtx/cfx.h @@ -23,7 +23,7 @@ class mtx_cfx_device : public device_t, public device_mtx_exp_interface { public: // construction/destruction - mtx_cfx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mtx_cfx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/mtx/exp.cpp b/src/devices/bus/mtx/exp.cpp index e2a4f9c8ed0..6175e562399 100644 --- a/src/devices/bus/mtx/exp.cpp +++ b/src/devices/bus/mtx/exp.cpp @@ -56,7 +56,7 @@ void device_mtx_exp_interface::rom_alloc(uint32_t size, const char *tag) // mtx_exp_slot_device - constructor //------------------------------------------------- -mtx_exp_slot_device::mtx_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mtx_exp_slot_device::mtx_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MTX_EXP_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_mtx_exp_interface>(mconfig, *this) , device_cartrom_image_interface(mconfig, *this) diff --git a/src/devices/bus/mtx/exp.h b/src/devices/bus/mtx/exp.h index dd23586c05e..1e93a4852f8 100644 --- a/src/devices/bus/mtx/exp.h +++ b/src/devices/bus/mtx/exp.h @@ -38,7 +38,7 @@ public: set_fixed(false); } - mtx_exp_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + mtx_exp_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> void set_program_space(T &&tag, int spacenum) { m_program.set_tag(std::forward<T>(tag), spacenum); } template <typename T> void set_io_space(T &&tag, int spacenum) { m_io.set_tag(std::forward<T>(tag), spacenum); } diff --git a/src/devices/bus/mtx/magrom.cpp b/src/devices/bus/mtx/magrom.cpp index 5b75a9d4f1e..f9b8b82e5e1 100644 --- a/src/devices/bus/mtx/magrom.cpp +++ b/src/devices/bus/mtx/magrom.cpp @@ -52,7 +52,7 @@ ioport_constructor mtx_magrom_device::device_input_ports() const // mtx_magrom_device - constructor //------------------------------------------------- -mtx_magrom_device::mtx_magrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mtx_magrom_device::mtx_magrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MTX_MAGROM, tag, owner, clock) , device_mtx_exp_interface(mconfig, *this) , m_bank(*this, "bank") diff --git a/src/devices/bus/mtx/magrom.h b/src/devices/bus/mtx/magrom.h index a4868024150..ce5375e60c9 100644 --- a/src/devices/bus/mtx/magrom.h +++ b/src/devices/bus/mtx/magrom.h @@ -23,7 +23,7 @@ class mtx_magrom_device : public device_t, public device_mtx_exp_interface { public: // construction/destruction - mtx_magrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mtx_magrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/mtx/rompak.cpp b/src/devices/bus/mtx/rompak.cpp index 6f870c540ce..83c49ab2766 100644 --- a/src/devices/bus/mtx/rompak.cpp +++ b/src/devices/bus/mtx/rompak.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(MTX_ROMPAK, mtx_rompak_device, "rompak", "MTX ROMPAK") // mtx_rompak_device - constructor //------------------------------------------------- -mtx_rompak_device::mtx_rompak_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mtx_rompak_device::mtx_rompak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MTX_ROMPAK, tag, owner, clock) , device_mtx_exp_interface(mconfig, *this) { diff --git a/src/devices/bus/mtx/rompak.h b/src/devices/bus/mtx/rompak.h index f26af1fbe34..1ca658d96ba 100644 --- a/src/devices/bus/mtx/rompak.h +++ b/src/devices/bus/mtx/rompak.h @@ -24,7 +24,7 @@ class mtx_rompak_device : public device_t, public device_mtx_exp_interface { public: // construction/destruction - mtx_rompak_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mtx_rompak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/mtx/sdx.cpp b/src/devices/bus/mtx/sdx.cpp index 0a27e48f309..8754fc99f48 100644 --- a/src/devices/bus/mtx/sdx.cpp +++ b/src/devices/bus/mtx/sdx.cpp @@ -184,7 +184,7 @@ const tiny_rom_entry *mtx_sdxcpm_device::device_rom_region() const // mtx_sdx_device - constructor //------------------------------------------------- -mtx_sdx_device::mtx_sdx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mtx_sdx_device::mtx_sdx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_mtx_exp_interface(mconfig, *this) , m_sdx_rom(*this, "sdx_rom") @@ -195,12 +195,12 @@ mtx_sdx_device::mtx_sdx_device(const machine_config &mconfig, device_type type, { } -mtx_sdxbas_device::mtx_sdxbas_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mtx_sdxbas_device::mtx_sdxbas_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mtx_sdx_device(mconfig, MTX_SDXBAS, tag, owner, clock) { } -mtx_sdxcpm_device::mtx_sdxcpm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mtx_sdxcpm_device::mtx_sdxcpm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mtx_sdx_device(mconfig, MTX_SDXCPM, tag, owner, clock) , m_screen(*this, "screen") , m_palette(*this, "palette") diff --git a/src/devices/bus/mtx/sdx.h b/src/devices/bus/mtx/sdx.h index 5bed06258aa..0bff7f117a2 100644 --- a/src/devices/bus/mtx/sdx.h +++ b/src/devices/bus/mtx/sdx.h @@ -38,7 +38,7 @@ public: protected: // construction/destruction - mtx_sdx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mtx_sdx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); required_memory_region m_sdx_rom; required_device<mb8877_device> m_fdc; @@ -53,7 +53,7 @@ class mtx_sdxbas_device : public mtx_sdx_device { public: // construction/destruction - mtx_sdxbas_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mtx_sdxbas_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -69,7 +69,7 @@ class mtx_sdxcpm_device : public mtx_sdx_device { public: // construction/destruction - mtx_sdxcpm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mtx_sdxcpm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/multibus/cpuap.cpp b/src/devices/bus/multibus/cpuap.cpp index 7e271be8114..015ee83650f 100644 --- a/src/devices/bus/multibus/cpuap.cpp +++ b/src/devices/bus/multibus/cpuap.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(CPUAP, cpuap_device, "cpuap", "Siemens S26361-D333 CPUAP") -cpuap_device::cpuap_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +cpuap_device::cpuap_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CPUAP, tag, owner, clock) , device_multibus_interface(mconfig, *this) , m_cpu(*this, "cpu") diff --git a/src/devices/bus/multibus/cpuap.h b/src/devices/bus/multibus/cpuap.h index cc4d2ae5a5f..8065483e47d 100644 --- a/src/devices/bus/multibus/cpuap.h +++ b/src/devices/bus/multibus/cpuap.h @@ -20,7 +20,7 @@ class cpuap_device , public device_multibus_interface { public: - cpuap_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + cpuap_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/multibus/isbc202.cpp b/src/devices/bus/multibus/isbc202.cpp index 502737837d1..b33c2c3c904 100644 --- a/src/devices/bus/multibus/isbc202.cpp +++ b/src/devices/bus/multibus/isbc202.cpp @@ -206,7 +206,7 @@ offs_t isbc202_disassembler::disassemble(std::ostream &stream, offs_t pc, const } // isbc202_device -isbc202_device::isbc202_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +isbc202_device::isbc202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig , ISBC202 , tag , owner , DERIVED_CLOCK(1, 4)) , device_multibus_interface(mconfig , *this) , m_mcu(*this , "mcu") diff --git a/src/devices/bus/multibus/isbc202.h b/src/devices/bus/multibus/isbc202.h index 6fc94179364..86f120e6694 100644 --- a/src/devices/bus/multibus/isbc202.h +++ b/src/devices/bus/multibus/isbc202.h @@ -24,7 +24,7 @@ class isbc202_device : public cpu_device, { public: // Construction/destruction - isbc202_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + isbc202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~isbc202_device(); // Access to I/O space by CPU diff --git a/src/devices/bus/multibus/isbc8024.cpp b/src/devices/bus/multibus/isbc8024.cpp index b61ae56db45..0f264c932e5 100644 --- a/src/devices/bus/multibus/isbc8024.cpp +++ b/src/devices/bus/multibus/isbc8024.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(ISBC8024, isbc8024_device, "isbc8024", "Intel iSBC 80/24 Single Board Computer") -isbc8024_device::isbc8024_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +isbc8024_device::isbc8024_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ISBC8024, tag, owner, clock) , device_multibus_interface(mconfig, *this) , m_cpu(*this, "cpu") @@ -108,10 +108,10 @@ void isbc8024_device::device_add_mconfig(machine_config &config) m_pit->out_handler<2>().append(m_pci, FUNC(i8251_device::write_rxc)); m_pit->out_handler<2>().append(m_pci, FUNC(i8251_device::write_txc)); - I8251(config, m_pci, 0); + I8251(config, m_pci); - I8255(config, m_ppi[0], 0); // j1 - I8255(config, m_ppi[1], 0); // j2 + I8255(config, m_ppi[0]); // j1 + I8255(config, m_ppi[1]); // j2 PIC8259(config, m_pic); m_pic->out_int_callback().set_inputline(m_cpu, I8085_INTR_LINE); diff --git a/src/devices/bus/multibus/isbc8024.h b/src/devices/bus/multibus/isbc8024.h index 4827c20bbe6..7f3ea05c1aa 100644 --- a/src/devices/bus/multibus/isbc8024.h +++ b/src/devices/bus/multibus/isbc8024.h @@ -21,7 +21,7 @@ class isbc8024_device , public device_multibus_interface { public: - isbc8024_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + isbc8024_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/multibus/labtam_3232.cpp b/src/devices/bus/multibus/labtam_3232.cpp index 35181ea4a78..5a47602e4c3 100644 --- a/src/devices/bus/multibus/labtam_3232.cpp +++ b/src/devices/bus/multibus/labtam_3232.cpp @@ -20,7 +20,7 @@ DEFINE_DEVICE_TYPE(LABTAM_3232, labtam_3232_device, "labtam_3232", "Labtam 3232") -labtam_3232_device::labtam_3232_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +labtam_3232_device::labtam_3232_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LABTAM_3232, tag, owner, clock) , device_multibus_interface(mconfig, *this) , m_cpu(*this, "cpu") diff --git a/src/devices/bus/multibus/labtam_3232.h b/src/devices/bus/multibus/labtam_3232.h index 4cd89999778..ed75fd54dee 100644 --- a/src/devices/bus/multibus/labtam_3232.h +++ b/src/devices/bus/multibus/labtam_3232.h @@ -18,7 +18,7 @@ class labtam_3232_device , public device_multibus_interface { public: - labtam_3232_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + labtam_3232_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/multibus/labtam_vducom.cpp b/src/devices/bus/multibus/labtam_vducom.cpp index 3ea3647ad5b..cad6ac0bd81 100644 --- a/src/devices/bus/multibus/labtam_vducom.cpp +++ b/src/devices/bus/multibus/labtam_vducom.cpp @@ -30,7 +30,7 @@ enum u7_mask : u8 DEFINE_DEVICE_TYPE(LABTAM_VDUCOM, labtam_vducom_device, "labtam_vducom", "Labtam 8086 VDU COMM") -labtam_vducom_device::labtam_vducom_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +labtam_vducom_device::labtam_vducom_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LABTAM_VDUCOM, tag, owner, clock) , device_multibus_interface(mconfig, *this) , m_cpu(*this, "cpu") @@ -144,12 +144,12 @@ void labtam_vducom_device::device_add_mconfig(machine_config &config) m_cpu->set_addrmap(AS_IO, &labtam_vducom_device::cpu_pio); m_cpu->set_irq_acknowledge_callback(m_pic, FUNC(pic8259_device::inta_cb)); - AM9513(config, m_ctc[0], 4'000'000); + AM9513(config, m_ctc[0], XTAL::u(4'000'000)); //m_ctc[0]->out1_cb().set(m_pic, FUNC(pic8259_device::ir0_w)); m_ctc[0]->out4_cb().set(m_ctc[0], FUNC(am9513_device::gate5_w)); // ? m_ctc[0]->out5_cb().set(m_ctc[0], FUNC(am9513_device::source4_w)); // ? - AM9513(config, m_ctc[1], 4'000'000); + AM9513(config, m_ctc[1], XTAL::u(4'000'000)); m_ctc[1]->out1_cb().set(m_com[1], FUNC(upd7201_device::txcb_w)); m_ctc[1]->out2_cb().set(m_com[1], FUNC(upd7201_device::rxcb_w)); m_ctc[1]->out3_cb().set(m_com[1], FUNC(upd7201_device::rxca_w)); @@ -161,15 +161,15 @@ void labtam_vducom_device::device_add_mconfig(machine_config &config) PIC8259(config, m_pic); m_pic->out_int_callback().set_inputline(m_cpu, INPUT_LINE_INT0); - UPD7201(config, m_com[0], 4'000'000); + UPD7201(config, m_com[0], XTAL::u(4'000'000)); m_com[0]->out_int_callback().set(m_pic, FUNC(pic8259_device::ir3_w)); - UPD7201(config, m_com[1], 4'000'000); + UPD7201(config, m_com[1], XTAL::u(4'000'000)); m_com[1]->out_int_callback().set(m_pic, FUNC(pic8259_device::ir2_w)); X2212(config, m_nvram[0]); X2212(config, m_nvram[1]); - MC6845(config, m_crtc, 1'000'000); + MC6845(config, m_crtc, XTAL::u(1'000'000)); m_crtc->set_show_border_area(false); m_crtc->set_hpixels_per_column(16); m_crtc->set_update_row_callback(FUNC(labtam_vducom_device::update_row)); @@ -179,7 +179,7 @@ void labtam_vducom_device::device_add_mconfig(machine_config &config) PALETTE(config, m_palette, FUNC(labtam_vducom_device::palette_init), 4); SCREEN(config, m_screen, SCREEN_TYPE_RASTER); - m_screen->set_raw(1'000'000, 62*16, 2*16, 52*16, 78*4, 3*4, 75*4); + m_screen->set_raw(XTAL::u(1'000'000), 62*16, 2*16, 52*16, 78*4, 3*4, 75*4); m_screen->set_screen_update(m_crtc, FUNC(mc6845_device::screen_update)); // gfxdecode is only to show the font data in the tile viewer diff --git a/src/devices/bus/multibus/labtam_vducom.h b/src/devices/bus/multibus/labtam_vducom.h index 9db27d05fdd..d497c2a107f 100644 --- a/src/devices/bus/multibus/labtam_vducom.h +++ b/src/devices/bus/multibus/labtam_vducom.h @@ -26,7 +26,7 @@ class labtam_vducom_device , public device_multibus_interface { public: - labtam_vducom_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + labtam_vducom_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/multibus/labtam_z80sbc.cpp b/src/devices/bus/multibus/labtam_z80sbc.cpp index 013add4f7e8..5c4f0e50cc4 100644 --- a/src/devices/bus/multibus/labtam_z80sbc.cpp +++ b/src/devices/bus/multibus/labtam_z80sbc.cpp @@ -68,7 +68,7 @@ enum drvstatus_mask : u8 DEFINE_DEVICE_TYPE(LABTAM_Z80SBC, labtam_z80sbc_device, "labtam_z80sbc", "Labtam Z80 SBC") -labtam_z80sbc_device::labtam_z80sbc_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +labtam_z80sbc_device::labtam_z80sbc_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LABTAM_Z80SBC, tag, owner, clock) , device_multibus_interface(mconfig, *this) , m_cpu(*this, "cpu") @@ -332,13 +332,13 @@ void labtam_z80sbc_device::device_add_mconfig(machine_config &config) AM9519(config, m_uic); m_uic->out_int_callback().set(m_int, FUNC(input_merger_any_high_device::in_w<3>)); - WD2793(config, m_fdc, 2'000'000); + WD2793(config, m_fdc, XTAL::u(2'000'000)); m_fdc->intrq_wr_callback().set(FUNC(labtam_z80sbc_device::fdcint_w)); m_fdc->drq_wr_callback().set(m_dma[0], FUNC(z80dma_device::rdy_w)); // WD1002 irq -> Am9519 ireq3 - AM9513(config, m_stc, 4'000'000); + AM9513(config, m_stc, XTAL::u(4'000'000)); m_stc->out4_cb().set(m_uic, FUNC(am9519_device::ireq5_w)); MM58167(config, m_rtc, 32.768_kHz_XTAL); diff --git a/src/devices/bus/multibus/labtam_z80sbc.h b/src/devices/bus/multibus/labtam_z80sbc.h index 2e20d6cd7ca..20c307f3049 100644 --- a/src/devices/bus/multibus/labtam_z80sbc.h +++ b/src/devices/bus/multibus/labtam_z80sbc.h @@ -25,7 +25,7 @@ class labtam_z80sbc_device , public device_multibus_interface { public: - labtam_z80sbc_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + labtam_z80sbc_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/multibus/multibus.cpp b/src/devices/bus/multibus/multibus.cpp index f8c64ac0d08..2ccc2042153 100644 --- a/src/devices/bus/multibus/multibus.cpp +++ b/src/devices/bus/multibus/multibus.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(MULTIBUS, multibus_device, "multibus", "Intel Multibus") DEFINE_DEVICE_TYPE(MULTIBUS_SLOT, multibus_slot_device, "multibus_slot", "Intel Multibus slot") -multibus_device::multibus_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +multibus_device::multibus_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MULTIBUS, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_mem_config("mem", ENDIANNESS_LITTLE, 16, 24) @@ -45,7 +45,7 @@ void multibus_device::device_start() m_xack_cb.resolve_safe(); } -multibus_slot_device::multibus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +multibus_slot_device::multibus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MULTIBUS_SLOT, tag, owner, clock) , device_slot_interface(mconfig, *this) , m_bus(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/bus/multibus/multibus.h b/src/devices/bus/multibus/multibus.h index d753db25778..f07dbaa7982 100644 --- a/src/devices/bus/multibus/multibus.h +++ b/src/devices/bus/multibus/multibus.h @@ -81,7 +81,7 @@ class multibus_device , public device_memory_interface { public: - multibus_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + multibus_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // interrupt interface template <unsigned I> auto int_callback() { return m_int_cb[I].bind(); } @@ -113,7 +113,7 @@ class multibus_slot_device , public device_slot_interface { public: - multibus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + multibus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); template <typename T, typename U> multibus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bus_tag, U &&slot_options, char const *default_option, bool const fixed) diff --git a/src/devices/bus/multibus/serad.cpp b/src/devices/bus/multibus/serad.cpp index f4fa2346a6c..cbbf5c86f26 100644 --- a/src/devices/bus/multibus/serad.cpp +++ b/src/devices/bus/multibus/serad.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(SERAD, serad_device, "serad", "Siemens S26361-D279 SERAD") -serad_device::serad_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +serad_device::serad_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SERAD, tag, owner, clock) , device_multibus_interface(mconfig, *this) , m_cpu(*this, "cpu") diff --git a/src/devices/bus/multibus/serad.h b/src/devices/bus/multibus/serad.h index 5f82e1c0ec7..4db17508a1d 100644 --- a/src/devices/bus/multibus/serad.h +++ b/src/devices/bus/multibus/serad.h @@ -18,7 +18,7 @@ class serad_device , public device_multibus_interface { public: - serad_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + serad_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/nasbus/avc.cpp b/src/devices/bus/nasbus/avc.cpp index f4590b2ac3f..1f20ec2d9a9 100644 --- a/src/devices/bus/nasbus/avc.cpp +++ b/src/devices/bus/nasbus/avc.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(NASCOM_AVC, nascom_avc_device, "nascom_avc", "Nascom Advanced void nascom_avc_device::device_add_mconfig(machine_config &config) { screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_RASTER)); - screen.set_raw(16250000, 1024, 0, 768, 320, 0, 256); + screen.set_raw(XTAL::u(16250000), 1024, 0, 768, 320, 0, 256); screen.set_screen_update("mc6845", FUNC(mc6845_device::screen_update)); PALETTE(config, m_palette, palette_device::RGB_3BIT); @@ -46,7 +46,7 @@ void nascom_avc_device::device_add_mconfig(machine_config &config) // nascom_avc_device - constructor //------------------------------------------------- -nascom_avc_device::nascom_avc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nascom_avc_device::nascom_avc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NASCOM_AVC, tag, owner, clock), device_nasbus_card_interface(mconfig, *this), m_crtc(*this, "mc6845"), diff --git a/src/devices/bus/nasbus/avc.h b/src/devices/bus/nasbus/avc.h index 58eaaa44626..7bf49486be7 100644 --- a/src/devices/bus/nasbus/avc.h +++ b/src/devices/bus/nasbus/avc.h @@ -26,7 +26,7 @@ class nascom_avc_device : public device_t, public device_nasbus_card_interface { public: // construction/destruction - nascom_avc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nascom_avc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void control_w(uint8_t data); uint8_t vram_r(offs_t offset); diff --git a/src/devices/bus/nasbus/floppy.cpp b/src/devices/bus/nasbus/floppy.cpp index 905f5eef087..c117ae19417 100644 --- a/src/devices/bus/nasbus/floppy.cpp +++ b/src/devices/bus/nasbus/floppy.cpp @@ -59,7 +59,7 @@ void nascom_fdc_device::device_add_mconfig(machine_config &config) // wordpro_device - constructor //------------------------------------------------- -nascom_fdc_device::nascom_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nascom_fdc_device::nascom_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NASCOM_FDC, tag, owner, clock), device_nasbus_card_interface(mconfig, *this), m_fdc(*this, "fd1793"), diff --git a/src/devices/bus/nasbus/floppy.h b/src/devices/bus/nasbus/floppy.h index abf623e5e10..b85f901c1ac 100644 --- a/src/devices/bus/nasbus/floppy.h +++ b/src/devices/bus/nasbus/floppy.h @@ -26,7 +26,7 @@ class nascom_fdc_device : public device_t, public device_nasbus_card_interface { public: // construction/destruction - nascom_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nascom_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t select_r(); void select_w(uint8_t data); diff --git a/src/devices/bus/nasbus/nasbus.cpp b/src/devices/bus/nasbus/nasbus.cpp index 29fff032d39..96b94155e24 100644 --- a/src/devices/bus/nasbus/nasbus.cpp +++ b/src/devices/bus/nasbus/nasbus.cpp @@ -22,12 +22,12 @@ DEFINE_DEVICE_TYPE(NASBUS_SLOT, nasbus_slot_device, "nasbus_slot", "NASBUS Slot" // nasbus_slot_device - constructor //------------------------------------------------- -nasbus_slot_device::nasbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nasbus_slot_device::nasbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nasbus_slot_device(mconfig, NASBUS_SLOT, tag, owner, clock) { } -nasbus_slot_device::nasbus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nasbus_slot_device::nasbus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_single_card_slot_interface<device_nasbus_card_interface>(mconfig, *this) , m_bus(*this, finder_base::DUMMY_TAG) @@ -56,7 +56,7 @@ DEFINE_DEVICE_TYPE(NASBUS, nasbus_device, "nasbus", "NASBUS Backplane") // nasbus_device - constructor //------------------------------------------------- -nasbus_device::nasbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nasbus_device::nasbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NASBUS, tag, owner, clock), m_program(*this, finder_base::DUMMY_TAG, -1), m_io(*this, finder_base::DUMMY_TAG, -1), diff --git a/src/devices/bus/nasbus/nasbus.h b/src/devices/bus/nasbus/nasbus.h index 04e1c3942f7..2bdc1a082be 100644 --- a/src/devices/bus/nasbus/nasbus.h +++ b/src/devices/bus/nasbus/nasbus.h @@ -110,7 +110,7 @@ public: // construction/destruction template <typename T, typename U> nasbus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bus, U &&opts, char const *dflt) - : nasbus_slot_device(mconfig, tag, owner, (uint32_t)0) + : nasbus_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -118,12 +118,12 @@ public: set_fixed(false); set_bus(std::forward<T>(bus)); } - nasbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nasbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_bus(T &&tag) { m_bus.set_tag(std::forward<T>(tag)); } protected: - nasbus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nasbus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -142,7 +142,7 @@ class nasbus_device : public device_t friend class device_nasbus_card_interface; public: // construction/destruction - nasbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nasbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~nasbus_device(); auto ram_disable() { return m_ram_disable_handler.bind(); } diff --git a/src/devices/bus/neogeo/boot_cthd.cpp b/src/devices/bus/neogeo/boot_cthd.cpp index 70c4d891ad5..c14608fb574 100644 --- a/src/devices/bus/neogeo/boot_cthd.cpp +++ b/src/devices/bus/neogeo/boot_cthd.cpp @@ -73,7 +73,7 @@ void neogeo_cthd2k3_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CT2K3SP_CART, neogeo_ct2k3sp_cart_device, "neocart_ct2k3sp", "Neo Geo CTHD 2003 Sp Cart") -neogeo_ct2k3sp_cart_device::neogeo_ct2k3sp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_ct2k3sp_cart_device::neogeo_ct2k3sp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cthd2k3_cart_device(mconfig, NEOGEO_CT2K3SP_CART, tag, owner, clock) { } @@ -90,7 +90,7 @@ void neogeo_ct2k3sp_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CT2K3SA_CART, neogeo_ct2k3sa_cart_device, "neocart_ct2k3sa", "Neo Geo CTHD 2003 Sp Alt Cart") -neogeo_ct2k3sa_cart_device::neogeo_ct2k3sa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_ct2k3sa_cart_device::neogeo_ct2k3sa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cthd2k3_cart_device(mconfig, NEOGEO_CT2K3SA_CART, tag, owner, clock) { } @@ -108,7 +108,7 @@ void neogeo_ct2k3sa_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_MATRIMBL_CART, neogeo_matrimbl_cart_device, "neocart_matrimbl", "Neo Geo Matrimelee Bootleg Cart") -neogeo_matrimbl_cart_device::neogeo_matrimbl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_matrimbl_cart_device::neogeo_matrimbl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cthd2k3_cart_device(mconfig, NEOGEO_MATRIMBL_CART, tag, owner, clock), m_cmc_prot(*this, "cmc_prot"), m_kof2k2_prot(*this, "kof2k2_prot") diff --git a/src/devices/bus/neogeo/boot_cthd.h b/src/devices/bus/neogeo/boot_cthd.h index d99eeaea941..8e63e214e24 100644 --- a/src/devices/bus/neogeo/boot_cthd.h +++ b/src/devices/bus/neogeo/boot_cthd.h @@ -49,7 +49,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CTHD2K3_CART, neogeo_cthd2k3_cart_device) class neogeo_ct2k3sp_cart_device : public neogeo_cthd2k3_cart_device { public: - neogeo_ct2k3sp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_ct2k3sp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -64,7 +64,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CT2K3SP_CART, neogeo_ct2k3sp_cart_device) class neogeo_ct2k3sa_cart_device : public neogeo_cthd2k3_cart_device { public: - neogeo_ct2k3sa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_ct2k3sa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -79,7 +79,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CT2K3SA_CART, neogeo_ct2k3sa_cart_device) class neogeo_matrimbl_cart_device : public neogeo_cthd2k3_cart_device { public: - neogeo_matrimbl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_matrimbl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 2; } diff --git a/src/devices/bus/neogeo/boot_kof2k2.cpp b/src/devices/bus/neogeo/boot_kof2k2.cpp index 8bbf3ab0962..64aec4370ef 100644 --- a/src/devices/bus/neogeo/boot_kof2k2.cpp +++ b/src/devices/bus/neogeo/boot_kof2k2.cpp @@ -40,7 +40,7 @@ void neogeo_kf2k2mp2_cart_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NEOGEO_KOF2002B_CART, neogeo_kof2002b_cart_device, "neocart_kof2002b", "Neo Geo KoF 2002 Bootleg Cart") -neogeo_kof2002b_cart_device::neogeo_kof2002b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kof2002b_cart_device::neogeo_kof2002b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KOF2002B_CART, tag, owner, clock), m_cmc_prot(*this, "cmc_prot"), m_pcm2_prot(*this, "pcm2_prot"), @@ -64,7 +64,7 @@ void neogeo_kof2002b_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_KF2K2MP_CART, neogeo_kf2k2mp_cart_device, "neocart_kf2k2mp", "Neo Geo KoF 2002 MP Cart") -neogeo_kf2k2mp_cart_device::neogeo_kf2k2mp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kf2k2mp_cart_device::neogeo_kf2k2mp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KF2K2MP_CART, tag, owner, clock), m_cmc_prot(*this, "cmc_prot"), m_pcm2_prot(*this, "pcm2_prot") @@ -87,7 +87,7 @@ void neogeo_kf2k2mp_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_KF2K2MP2_CART, neogeo_kf2k2mp2_cart_device, "neocart_kf2k2mp2", "Neo Geo KoF 2002 MP2 Cart") -neogeo_kf2k2mp2_cart_device::neogeo_kf2k2mp2_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kf2k2mp2_cart_device::neogeo_kf2k2mp2_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KF2K2MP2_CART, tag, owner, clock), m_cmc_prot(*this, "cmc_prot"), m_pcm2_prot(*this, "pcm2_prot") diff --git a/src/devices/bus/neogeo/boot_kof2k2.h b/src/devices/bus/neogeo/boot_kof2k2.h index f7b926a4a2a..61d84e1fc80 100644 --- a/src/devices/bus/neogeo/boot_kof2k2.h +++ b/src/devices/bus/neogeo/boot_kof2k2.h @@ -20,7 +20,7 @@ class neogeo_kof2002b_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kof2002b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kof2002b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } @@ -44,7 +44,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_KOF2002B_CART, neogeo_kof2002b_cart_device) class neogeo_kf2k2mp_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kf2k2mp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kf2k2mp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } @@ -67,7 +67,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_KF2K2MP_CART, neogeo_kf2k2mp_cart_device) class neogeo_kf2k2mp2_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kf2k2mp2_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kf2k2mp2_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } diff --git a/src/devices/bus/neogeo/boot_kof2k3.cpp b/src/devices/bus/neogeo/boot_kof2k3.cpp index 172a0ad56db..266549edce1 100644 --- a/src/devices/bus/neogeo/boot_kof2k3.cpp +++ b/src/devices/bus/neogeo/boot_kof2k3.cpp @@ -42,7 +42,7 @@ void neogeo_kf2k3upl_cart_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NEOGEO_KF2K3BL_CART, neogeo_kf2k3bl_cart_device, "neocart_kf2k3bl", "Neo Geo KoF 2003 Bootleg Cart") -neogeo_kf2k3bl_cart_device::neogeo_kf2k3bl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kf2k3bl_cart_device::neogeo_kf2k3bl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KF2K3BL_CART, tag, owner, clock), m_cmc_prot(*this, "cmc_prot"), m_pcm2_prot(*this, "pcm2_prot"), @@ -64,7 +64,7 @@ void neogeo_kf2k3bl_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_KF2K3PL_CART, neogeo_kf2k3pl_cart_device, "neocart_kf2k3pl", "Neo Geo KoF 2003 PL Cart") -neogeo_kf2k3pl_cart_device::neogeo_kf2k3pl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kf2k3pl_cart_device::neogeo_kf2k3pl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KF2K3PL_CART, tag, owner, clock), m_cmc_prot(*this, "cmc_prot"), m_pcm2_prot(*this, "pcm2_prot"), @@ -87,7 +87,7 @@ void neogeo_kf2k3pl_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_KF2K3UPL_CART, neogeo_kf2k3upl_cart_device, "neocart_kf2k3upl", "Neo Geo KoF 2003 UPL Cart") -neogeo_kf2k3upl_cart_device::neogeo_kf2k3upl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kf2k3upl_cart_device::neogeo_kf2k3upl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KF2K3UPL_CART, tag, owner, clock), m_cmc_prot(*this, "cmc_prot"), m_pcm2_prot(*this, "pcm2_prot"), diff --git a/src/devices/bus/neogeo/boot_kof2k3.h b/src/devices/bus/neogeo/boot_kof2k3.h index a8e3efc5721..620b7b52dbc 100644 --- a/src/devices/bus/neogeo/boot_kof2k3.h +++ b/src/devices/bus/neogeo/boot_kof2k3.h @@ -17,7 +17,7 @@ class neogeo_kf2k3bl_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kf2k3bl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kf2k3bl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } @@ -45,7 +45,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_KF2K3BL_CART, neogeo_kf2k3bl_cart_device) class neogeo_kf2k3pl_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kf2k3pl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kf2k3pl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } @@ -72,7 +72,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_KF2K3PL_CART, neogeo_kf2k3pl_cart_device) class neogeo_kf2k3upl_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kf2k3upl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kf2k3upl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } diff --git a/src/devices/bus/neogeo/boot_misc.cpp b/src/devices/bus/neogeo/boot_misc.cpp index 8476123fbc7..8a7749384d3 100644 --- a/src/devices/bus/neogeo/boot_misc.cpp +++ b/src/devices/bus/neogeo/boot_misc.cpp @@ -60,7 +60,7 @@ void neogeo_bootleg_cart_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NEOGEO_GAROUBL_CART, neogeo_garoubl_cart_device, "neocart_garoubl", "Neo Geo Garou Bootleg Cart") -neogeo_garoubl_cart_device::neogeo_garoubl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_garoubl_cart_device::neogeo_garoubl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_GAROUBL_CART, tag, owner, clock) { } @@ -79,7 +79,7 @@ void neogeo_garoubl_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_KOF97ORO_CART, neogeo_kof97oro_cart_device, "neocart_kof97oro", "Neo Geo KoF 97 Orochi Bootleg Cart") -neogeo_kof97oro_cart_device::neogeo_kof97oro_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kof97oro_cart_device::neogeo_kof97oro_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KOF97ORO_CART, tag, owner, clock) { } @@ -99,7 +99,7 @@ void neogeo_kof97oro_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_KF10THEP_CART, neogeo_kf10thep_cart_device, "neocart_kf10thep", "Neo Geo KoF 10th Ann. EP Bootleg Cart") -neogeo_kf10thep_cart_device::neogeo_kf10thep_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kf10thep_cart_device::neogeo_kf10thep_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KF10THEP_CART, tag, owner, clock) { } @@ -118,7 +118,7 @@ void neogeo_kf10thep_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_KF2K5UNI_CART, neogeo_kf2k5uni_cart_device, "neocart_kf2k5uni", "Neo Geo KoF 2005 Unique Bootleg Cart") -neogeo_kf2k5uni_cart_device::neogeo_kf2k5uni_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kf2k5uni_cart_device::neogeo_kf2k5uni_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KF2K5UNI_CART, tag, owner, clock) { } @@ -138,7 +138,7 @@ void neogeo_kf2k5uni_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_KF2K4SE_CART, neogeo_kf2k4se_cart_device, "neocart_kf2k4se", "Neo Geo KoF 2004 SE Bootleg Cart") -neogeo_kf2k4se_cart_device::neogeo_kf2k4se_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kf2k4se_cart_device::neogeo_kf2k4se_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KF2K4SE_CART, tag, owner, clock) { } @@ -156,7 +156,7 @@ void neogeo_kf2k4se_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_LANS2004_CART, neogeo_lans2004_cart_device, "neocart_lans2004", "Neo Geo Lansquenet 2004 Bootleg Cart") -neogeo_lans2004_cart_device::neogeo_lans2004_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_lans2004_cart_device::neogeo_lans2004_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_LANS2004_CART, tag, owner, clock) { } @@ -176,7 +176,7 @@ void neogeo_lans2004_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_SAMSHO5B_CART, neogeo_samsho5b_cart_device, "neocart_samsho5b", "Neo Geo Samurai Shodown 5 Bootleg Cart") -neogeo_samsho5b_cart_device::neogeo_samsho5b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_samsho5b_cart_device::neogeo_samsho5b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_SAMSHO5B_CART, tag, owner, clock) { } @@ -196,7 +196,7 @@ void neogeo_samsho5b_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_MSLUG3B6_CART, neogeo_mslug3b6_cart_device, "neocart_mslug3b6", "Neo Geo Metal Slug 6 Bootleg Cart") -neogeo_mslug3b6_cart_device::neogeo_mslug3b6_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_mslug3b6_cart_device::neogeo_mslug3b6_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_MSLUG3B6_CART, tag, owner, clock), m_cmc_prot(*this, "cmc_prot") { @@ -221,7 +221,7 @@ void neogeo_mslug3b6_cart_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NEOGEO_MS5PLUS_CART, neogeo_ms5plus_cart_device, "neocart_ms5plus", "Neo Geo Metal Slug 5 Plus Bootleg Cart") -neogeo_ms5plus_cart_device::neogeo_ms5plus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_ms5plus_cart_device::neogeo_ms5plus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_MS5PLUS_CART, tag, owner, clock), m_cmc_prot(*this, "cmc_prot"), m_pcm2_prot(*this, "pcm2_prot") @@ -250,7 +250,7 @@ void neogeo_ms5plus_cart_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NEOGEO_MSLUG5B_CART, neogeo_mslug5b_cart_device, "neocart_mslug5b", "Neo Geo Metal Slug 5 Bootleg Cart") -neogeo_mslug5b_cart_device::neogeo_mslug5b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_mslug5b_cart_device::neogeo_mslug5b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_MSLUG5B_CART, tag, owner, clock) { } @@ -269,7 +269,7 @@ void neogeo_mslug5b_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_KOG_CART, neogeo_kog_cart_device, "neocart_kog", "Neo Geo King of Gladiators Bootleg Cart") -neogeo_kog_cart_device::neogeo_kog_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kog_cart_device::neogeo_kog_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_KOG_CART, tag, owner, clock), m_jumper(*this, "JUMPER") { diff --git a/src/devices/bus/neogeo/boot_misc.h b/src/devices/bus/neogeo/boot_misc.h index cf07a67e774..e77d0c6c483 100644 --- a/src/devices/bus/neogeo/boot_misc.h +++ b/src/devices/bus/neogeo/boot_misc.h @@ -44,7 +44,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_BOOTLEG_CART, neogeo_bootleg_cart_device) class neogeo_garoubl_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_garoubl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_garoubl_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -59,7 +59,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_GAROUBL_CART, neogeo_garoubl_cart_device) class neogeo_kof97oro_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kof97oro_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kof97oro_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -74,7 +74,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_KOF97ORO_CART, neogeo_kof97oro_cart_device) class neogeo_kf10thep_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kf10thep_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kf10thep_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -89,7 +89,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_KF10THEP_CART, neogeo_kf10thep_cart_device) class neogeo_kf2k5uni_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kf2k5uni_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kf2k5uni_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -103,7 +103,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_KF2K5UNI_CART, neogeo_kf2k5uni_cart_device) class neogeo_kf2k4se_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kf2k4se_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kf2k4se_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -118,7 +118,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_KF2K4SE_CART, neogeo_kf2k4se_cart_device) class neogeo_lans2004_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_lans2004_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_lans2004_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -133,7 +133,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_LANS2004_CART, neogeo_lans2004_cart_device) class neogeo_samsho5b_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_samsho5b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_samsho5b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -148,7 +148,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_SAMSHO5B_CART, neogeo_samsho5b_cart_device) class neogeo_mslug3b6_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_mslug3b6_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_mslug3b6_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } @@ -169,7 +169,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_MSLUG3B6_CART, neogeo_mslug3b6_cart_device) class neogeo_ms5plus_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_ms5plus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_ms5plus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } @@ -194,7 +194,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_MS5PLUS_CART, neogeo_ms5plus_cart_device) class neogeo_mslug5b_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_mslug5b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_mslug5b_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -209,7 +209,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_MSLUG5B_CART, neogeo_mslug5b_cart_device) class neogeo_kog_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_kog_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kog_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/neogeo/boot_svc.cpp b/src/devices/bus/neogeo/boot_svc.cpp index aac306be5ce..bfcbeaca3a8 100644 --- a/src/devices/bus/neogeo/boot_svc.cpp +++ b/src/devices/bus/neogeo/boot_svc.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(NEOGEO_SVCBOOT_CART, neogeo_svcboot_cart_device, "neocart_svcboot", "Neo Geo SVC Bootleg Cart") -neogeo_svcboot_cart_device::neogeo_svcboot_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_svcboot_cart_device::neogeo_svcboot_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_SVCBOOT_CART, tag, owner, clock), m_pvc_prot(*this, "pvc_prot") { @@ -43,7 +43,7 @@ void neogeo_svcboot_cart_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NEOGEO_SVCPLUS_CART, neogeo_svcplus_cart_device, "neocart_svcplus", "Neo Geo SVC Plus Bootleg Cart") -neogeo_svcplus_cart_device::neogeo_svcplus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_svcplus_cart_device::neogeo_svcplus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_SVCPLUS_CART, tag, owner, clock) { } @@ -63,7 +63,7 @@ void neogeo_svcplus_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_SVCPLUSA_CART, neogeo_svcplusa_cart_device, "neocart_svcplusa", "Neo Geo SVC Plus Alt Bootleg Cart") -neogeo_svcplusa_cart_device::neogeo_svcplusa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_svcplusa_cart_device::neogeo_svcplusa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_SVCPLUSA_CART, tag, owner, clock) { } @@ -82,7 +82,7 @@ void neogeo_svcplusa_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_SVCSPLUS_CART, neogeo_svcsplus_cart_device, "neocart_svcsplus", "Neo Geo SVC S.Plus Bootleg Cart") -neogeo_svcsplus_cart_device::neogeo_svcsplus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_svcsplus_cart_device::neogeo_svcsplus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_bootleg_cart_device(mconfig, NEOGEO_SVCSPLUS_CART, tag, owner, clock), m_pvc_prot(*this, "pvc_prot") { diff --git a/src/devices/bus/neogeo/boot_svc.h b/src/devices/bus/neogeo/boot_svc.h index 74a064500e3..64ab27081a0 100644 --- a/src/devices/bus/neogeo/boot_svc.h +++ b/src/devices/bus/neogeo/boot_svc.h @@ -17,7 +17,7 @@ class neogeo_svcboot_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_svcboot_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_svcboot_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint32_t get_bank_base(uint16_t sel) override { return m_pvc_prot->get_bank_base(); } virtual uint16_t protection_r(address_space &space, offs_t offset) override { return m_pvc_prot->protection_r(offset); } @@ -41,7 +41,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_SVCBOOT_CART, neogeo_svcboot_cart_device) class neogeo_svcplus_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_svcplus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_svcplus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -56,7 +56,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_SVCPLUS_CART, neogeo_svcplus_cart_device) class neogeo_svcplusa_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_svcplusa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_svcplusa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -71,7 +71,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_SVCPLUSA_CART, neogeo_svcplusa_cart_device) class neogeo_svcsplus_cart_device : public neogeo_bootleg_cart_device { public: - neogeo_svcsplus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_svcsplus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint32_t get_bank_base(uint16_t sel) override { return m_pvc_prot->get_bank_base(); } virtual uint16_t protection_r(address_space &space, offs_t offset) override { return m_pvc_prot->protection_r(offset); } diff --git a/src/devices/bus/neogeo/cmc.cpp b/src/devices/bus/neogeo/cmc.cpp index d1fb1b699f8..736a1a6d042 100644 --- a/src/devices/bus/neogeo/cmc.cpp +++ b/src/devices/bus/neogeo/cmc.cpp @@ -56,7 +56,7 @@ void neogeo_cmc_cart_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NEOGEO_CMC_ZUPAPA_CART, neogeo_cmc_zupapa_cart_device, "neocart_zupapa", "Neo Geo Zupapa CMC42 Cart") -neogeo_cmc_zupapa_cart_device::neogeo_cmc_zupapa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_zupapa_cart_device::neogeo_cmc_zupapa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_ZUPAPA_CART, tag, owner, clock) { } @@ -74,7 +74,7 @@ void neogeo_cmc_zupapa_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_MSLUG3H_CART, neogeo_cmc_mslug3h_cart_device, "neocart_mslug3h", "Neo Geo Metal Slug 3 AES CMC42 Cart") -neogeo_cmc_mslug3h_cart_device::neogeo_cmc_mslug3h_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_mslug3h_cart_device::neogeo_cmc_mslug3h_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_MSLUG3H_CART, tag, owner, clock) { } @@ -92,7 +92,7 @@ void neogeo_cmc_mslug3h_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_GANRYU_CART, neogeo_cmc_ganryu_cart_device, "neocart_ganryu", "Neo Geo Ganryu CMC42 Cart") -neogeo_cmc_ganryu_cart_device::neogeo_cmc_ganryu_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_ganryu_cart_device::neogeo_cmc_ganryu_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_GANRYU_CART, tag, owner, clock) { } @@ -110,7 +110,7 @@ void neogeo_cmc_ganryu_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_S1945P_CART, neogeo_cmc_s1945p_cart_device, "neocart_s1945p", "Neo Geo Strikers 1945 Plus CMC42 Cart") -neogeo_cmc_s1945p_cart_device::neogeo_cmc_s1945p_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_s1945p_cart_device::neogeo_cmc_s1945p_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_S1945P_CART, tag, owner, clock) { } @@ -127,7 +127,7 @@ void neogeo_cmc_s1945p_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_PREISLE2_CART, neogeo_cmc_preisle2_cart_device, "neocart_preisle2", "Neo Geo Prehistoric Isle 2 CMC42 Cart") -neogeo_cmc_preisle2_cart_device::neogeo_cmc_preisle2_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_preisle2_cart_device::neogeo_cmc_preisle2_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_PREISLE2_CART, tag, owner, clock) { } @@ -144,7 +144,7 @@ void neogeo_cmc_preisle2_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_BANGBEAD_CART, neogeo_cmc_bangbead_cart_device, "neocart_bangbead", "Neo Geo Bangbead CMC42 Cart") -neogeo_cmc_bangbead_cart_device::neogeo_cmc_bangbead_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_bangbead_cart_device::neogeo_cmc_bangbead_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_BANGBEAD_CART, tag, owner, clock) { } @@ -161,7 +161,7 @@ void neogeo_cmc_bangbead_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_NITD_CART, neogeo_cmc_nitd_cart_device, "neocart_nitd", "Neo Geo NITD CMC42 Cart") -neogeo_cmc_nitd_cart_device::neogeo_cmc_nitd_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_nitd_cart_device::neogeo_cmc_nitd_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_NITD_CART, tag, owner, clock) { } @@ -179,7 +179,7 @@ void neogeo_cmc_nitd_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_SENGOKU3_CART, neogeo_cmc_sengoku3_cart_device, "neocart_sengoku3", "Neo Geo Sengoku 3 CMC42 Cart") -neogeo_cmc_sengoku3_cart_device::neogeo_cmc_sengoku3_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_sengoku3_cart_device::neogeo_cmc_sengoku3_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_SENGOKU3_CART, tag, owner, clock) { } @@ -196,7 +196,7 @@ void neogeo_cmc_sengoku3_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_KOF99K_CART, neogeo_cmc_kof99k_cart_device, "neocart_kof99k", "Neo Geo KoF 99 Korea CMC42 Cart") -neogeo_cmc_kof99k_cart_device::neogeo_cmc_kof99k_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_kof99k_cart_device::neogeo_cmc_kof99k_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_KOF99K_CART, tag, owner, clock) { } @@ -214,7 +214,7 @@ void neogeo_cmc_kof99k_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_KOF2001_CART, neogeo_cmc_kof2001_cart_device, "neocart_kof2001", "Neo Geo KoF 2001 CMC50 Cart") -neogeo_cmc_kof2001_cart_device::neogeo_cmc_kof2001_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_kof2001_cart_device::neogeo_cmc_kof2001_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_KOF2001_CART, tag, owner, clock) { } @@ -232,7 +232,7 @@ void neogeo_cmc_kof2001_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_KOF2000N_CART, neogeo_cmc_kof2000n_cart_device, "neocart_kof2000n", "Neo Geo KoF 2000 CMC50 Cart") -neogeo_cmc_kof2000n_cart_device::neogeo_cmc_kof2000n_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_kof2000n_cart_device::neogeo_cmc_kof2000n_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_KOF2000N_CART, tag, owner, clock) { } @@ -251,7 +251,7 @@ void neogeo_cmc_kof2000n_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_CMC_JOCKEYGP_CART, neogeo_cmc_jockeygp_cart_device, "neocart_jockeygp", "Neo Geo Jockey GP CMC50 Cart") -neogeo_cmc_jockeygp_cart_device::neogeo_cmc_jockeygp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_cmc_jockeygp_cart_device::neogeo_cmc_jockeygp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_cmc_cart_device(mconfig, NEOGEO_CMC_JOCKEYGP_CART, tag, owner, clock), m_nvram(*this, "nvram") { diff --git a/src/devices/bus/neogeo/cmc.h b/src/devices/bus/neogeo/cmc.h index 0852574c9f8..871f0163967 100644 --- a/src/devices/bus/neogeo/cmc.h +++ b/src/devices/bus/neogeo/cmc.h @@ -45,7 +45,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_CART, neogeo_cmc_cart_device) class neogeo_cmc_zupapa_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_zupapa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_zupapa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -60,7 +60,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_ZUPAPA_CART, neogeo_cmc_zupapa_cart_device) class neogeo_cmc_mslug3h_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_mslug3h_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_mslug3h_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -75,7 +75,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_MSLUG3H_CART, neogeo_cmc_mslug3h_cart_device) class neogeo_cmc_ganryu_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_ganryu_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_ganryu_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -90,7 +90,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_GANRYU_CART, neogeo_cmc_ganryu_cart_device) class neogeo_cmc_s1945p_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_s1945p_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_s1945p_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -105,7 +105,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_S1945P_CART, neogeo_cmc_s1945p_cart_device) class neogeo_cmc_preisle2_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_preisle2_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_preisle2_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -120,7 +120,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_PREISLE2_CART, neogeo_cmc_preisle2_cart_device) class neogeo_cmc_bangbead_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_bangbead_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_bangbead_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -135,7 +135,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_BANGBEAD_CART, neogeo_cmc_bangbead_cart_device) class neogeo_cmc_nitd_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_nitd_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_nitd_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -150,7 +150,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_NITD_CART, neogeo_cmc_nitd_cart_device) class neogeo_cmc_sengoku3_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_sengoku3_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_sengoku3_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -165,7 +165,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_SENGOKU3_CART, neogeo_cmc_sengoku3_cart_device) class neogeo_cmc_kof99k_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_kof99k_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_kof99k_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -180,7 +180,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_KOF99K_CART, neogeo_cmc_kof99k_cart_device) class neogeo_cmc_kof2001_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_kof2001_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_kof2001_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -195,7 +195,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_KOF2001_CART, neogeo_cmc_kof2001_cart_device) class neogeo_cmc_kof2000n_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_kof2000n_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_kof2000n_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 2; } }; @@ -210,7 +210,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_CMC_KOF2000N_CART, neogeo_cmc_kof2000n_cart_device) class neogeo_cmc_jockeygp_cart_device : public neogeo_cmc_cart_device { public: - neogeo_cmc_jockeygp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_cmc_jockeygp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } diff --git a/src/devices/bus/neogeo/kof2k2.cpp b/src/devices/bus/neogeo/kof2k2.cpp index 8ff5f040d3a..98b3e428604 100644 --- a/src/devices/bus/neogeo/kof2k2.cpp +++ b/src/devices/bus/neogeo/kof2k2.cpp @@ -64,7 +64,7 @@ void neogeo_kof2k2type_cart_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NEOGEO_K2K2_KOF2002_CART, neogeo_kof2002_cart_device, "neocart_kof2002", "Neo Geo KoF 2002 Cart") -neogeo_kof2002_cart_device::neogeo_kof2002_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kof2002_cart_device::neogeo_kof2002_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_kof2k2type_cart_device(mconfig, NEOGEO_K2K2_KOF2002_CART, tag, owner, clock) { } @@ -84,7 +84,7 @@ void neogeo_kof2002_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_K2K2_KF2K2PLS_CART, neogeo_kf2k2pls_cart_device, "neocart_kf2k2pls", "Neo Geo KoF 2002 Plus Cart") -neogeo_kf2k2pls_cart_device::neogeo_kf2k2pls_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kf2k2pls_cart_device::neogeo_kf2k2pls_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_kof2k2type_cart_device(mconfig, NEOGEO_K2K2_KF2K2PLS_CART, tag, owner, clock) { } @@ -104,7 +104,7 @@ void neogeo_kf2k2pls_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_K2K2_MATRIM_CART, neogeo_matrim_cart_device, "neocart_matrim", "Neo Geo Matrimelee Cart") -neogeo_matrim_cart_device::neogeo_matrim_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_matrim_cart_device::neogeo_matrim_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_kof2k2type_cart_device(mconfig, NEOGEO_K2K2_MATRIM_CART, tag, owner, clock) { } @@ -124,7 +124,7 @@ void neogeo_matrim_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_K2K2_SAMSHO5_CART, neogeo_samsho5_cart_device, "neocart_samsho5", "Neo Geo Samurai Shodown 5 Cart") -neogeo_samsho5_cart_device::neogeo_samsho5_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_samsho5_cart_device::neogeo_samsho5_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_kof2k2type_cart_device(mconfig, NEOGEO_K2K2_SAMSHO5_CART, tag, owner, clock) { } @@ -144,7 +144,7 @@ void neogeo_samsho5_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_K2K2_SAMSHO5SP_CART, neogeo_samsho5sp_cart_device, "neocart_samsh5sp", "Neo Geo Samurai Shodown 5 Special Cart") -neogeo_samsho5sp_cart_device::neogeo_samsho5sp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_samsho5sp_cart_device::neogeo_samsho5sp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_kof2k2type_cart_device(mconfig, NEOGEO_K2K2_SAMSHO5SP_CART, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/kof2k2.h b/src/devices/bus/neogeo/kof2k2.h index f5ade4c4444..f0db84a6adc 100644 --- a/src/devices/bus/neogeo/kof2k2.h +++ b/src/devices/bus/neogeo/kof2k2.h @@ -49,7 +49,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_K2K2_CART, neogeo_kof2k2type_cart_device) class neogeo_kof2002_cart_device : public neogeo_kof2k2type_cart_device { public: - neogeo_kof2002_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kof2002_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -61,7 +61,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_K2K2_KOF2002_CART, neogeo_kof2002_cart_device) class neogeo_kf2k2pls_cart_device : public neogeo_kof2k2type_cart_device { public: - neogeo_kf2k2pls_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kf2k2pls_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -76,7 +76,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_K2K2_KF2K2PLS_CART, neogeo_kf2k2pls_cart_device) class neogeo_matrim_cart_device : public neogeo_kof2k2type_cart_device { public: - neogeo_matrim_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_matrim_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 2; } }; @@ -91,7 +91,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_K2K2_MATRIM_CART, neogeo_matrim_cart_device) class neogeo_samsho5_cart_device : public neogeo_kof2k2type_cart_device { public: - neogeo_samsho5_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_samsho5_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -106,7 +106,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_K2K2_SAMSHO5_CART, neogeo_samsho5_cart_device) class neogeo_samsho5sp_cart_device : public neogeo_kof2k2type_cart_device { public: - neogeo_samsho5sp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_samsho5sp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; diff --git a/src/devices/bus/neogeo/pcm2.cpp b/src/devices/bus/neogeo/pcm2.cpp index 521c796d59a..9b28ed8164c 100644 --- a/src/devices/bus/neogeo/pcm2.cpp +++ b/src/devices/bus/neogeo/pcm2.cpp @@ -62,7 +62,7 @@ void neogeo_pcm2_cart_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NEOGEO_PCM2_MSLUG4_CART, neogeo_pcm2_mslug4_cart_device, "neocart_mslug4", "Neo Geo Metal Slug 3 PCM2 Cart") -neogeo_pcm2_mslug4_cart_device::neogeo_pcm2_mslug4_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_pcm2_mslug4_cart_device::neogeo_pcm2_mslug4_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_pcm2_cart_device(mconfig, NEOGEO_PCM2_MSLUG4_CART, tag, owner, clock) { } @@ -82,7 +82,7 @@ void neogeo_pcm2_mslug4_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_PCM2_MS4PLUS_CART, neogeo_pcm2_ms4plus_cart_device, "neocart_ms4plus", "Neo Geo Metal Slug 4 Plus PCM2 Cart") -neogeo_pcm2_ms4plus_cart_device::neogeo_pcm2_ms4plus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_pcm2_ms4plus_cart_device::neogeo_pcm2_ms4plus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_pcm2_cart_device(mconfig, NEOGEO_PCM2_MS4PLUS_CART, tag, owner, clock) { } @@ -101,7 +101,7 @@ void neogeo_pcm2_ms4plus_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_PCM2_ROTD_CART, neogeo_pcm2_rotd_cart_device, "neocart_rotd", "Neo Geo Rage of the Dragon PCM2 Cart") -neogeo_pcm2_rotd_cart_device::neogeo_pcm2_rotd_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_pcm2_rotd_cart_device::neogeo_pcm2_rotd_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_pcm2_cart_device(mconfig, NEOGEO_PCM2_ROTD_CART, tag, owner, clock) { } @@ -120,7 +120,7 @@ void neogeo_pcm2_rotd_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_PCM2_PNYAA_CART, neogeo_pcm2_pnyaa_cart_device, "neocart_pnyaa", "Neo Geo Pnyaa PCM2 Cart") -neogeo_pcm2_pnyaa_cart_device::neogeo_pcm2_pnyaa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_pcm2_pnyaa_cart_device::neogeo_pcm2_pnyaa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_pcm2_cart_device(mconfig, NEOGEO_PCM2_PNYAA_CART, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/pcm2.h b/src/devices/bus/neogeo/pcm2.h index a088d9b0172..5832e1b4955 100644 --- a/src/devices/bus/neogeo/pcm2.h +++ b/src/devices/bus/neogeo/pcm2.h @@ -43,7 +43,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_PCM2_CART, neogeo_pcm2_cart_device) class neogeo_pcm2_mslug4_cart_device : public neogeo_pcm2_cart_device { public: - neogeo_pcm2_mslug4_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_pcm2_mslug4_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -58,7 +58,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_PCM2_MSLUG4_CART, neogeo_pcm2_mslug4_cart_device) class neogeo_pcm2_ms4plus_cart_device : public neogeo_pcm2_cart_device { public: - neogeo_pcm2_ms4plus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_pcm2_ms4plus_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 0; } }; @@ -73,7 +73,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_PCM2_MS4PLUS_CART, neogeo_pcm2_ms4plus_cart_device) class neogeo_pcm2_rotd_cart_device : public neogeo_pcm2_cart_device { public: - neogeo_pcm2_rotd_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_pcm2_rotd_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -88,7 +88,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_PCM2_ROTD_CART, neogeo_pcm2_rotd_cart_device) class neogeo_pcm2_pnyaa_cart_device : public neogeo_pcm2_cart_device { public: - neogeo_pcm2_pnyaa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_pcm2_pnyaa_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; diff --git a/src/devices/bus/neogeo/prot_cmc.cpp b/src/devices/bus/neogeo/prot_cmc.cpp index 77591827f54..73f61c7e449 100644 --- a/src/devices/bus/neogeo/prot_cmc.cpp +++ b/src/devices/bus/neogeo/prot_cmc.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(NG_CMC_PROT, cmc_prot_device, "ng_cmc_prot", "Neo Geo CMC42/CMC40 Protection") -cmc_prot_device::cmc_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cmc_prot_device::cmc_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NG_CMC_PROT, tag, owner, clock), type0_t03(nullptr), type0_t12(nullptr), diff --git a/src/devices/bus/neogeo/prot_cmc.h b/src/devices/bus/neogeo/prot_cmc.h index 2853c71aa8f..fd2c46cdd93 100644 --- a/src/devices/bus/neogeo/prot_cmc.h +++ b/src/devices/bus/neogeo/prot_cmc.h @@ -41,7 +41,7 @@ class cmc_prot_device : public device_t { public: // construction/destruction - cmc_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + cmc_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void decrypt(uint8_t *r0, uint8_t *r1, uint8_t c0, uint8_t c1, diff --git a/src/devices/bus/neogeo/prot_cthd.cpp b/src/devices/bus/neogeo/prot_cthd.cpp index d4cbc5c2a79..9c3310ba0ea 100644 --- a/src/devices/bus/neogeo/prot_cthd.cpp +++ b/src/devices/bus/neogeo/prot_cthd.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(NG_CTHD_PROT, cthd_prot_device, "ng_cthd_prot", "Neo Geo CTHD Protection (bootleg)") -cthd_prot_device::cthd_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cthd_prot_device::cthd_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NG_CTHD_PROT, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/prot_cthd.h b/src/devices/bus/neogeo/prot_cthd.h index a331742da4f..add29bd214f 100644 --- a/src/devices/bus/neogeo/prot_cthd.h +++ b/src/devices/bus/neogeo/prot_cthd.h @@ -12,7 +12,7 @@ class cthd_prot_device : public device_t { public: // construction/destruction - cthd_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + cthd_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void fix_do(uint8_t* sprrom, uint32_t sprrom_size, int start, int end, int bit3shift, int bit2shift, int bit1shift, int bit0shift); void gfx_address_fix(uint8_t* sprrom, uint32_t sprrom_size, int start, int end); diff --git a/src/devices/bus/neogeo/prot_fatfury2.cpp b/src/devices/bus/neogeo/prot_fatfury2.cpp index d28b417b33d..c88e23fe5e3 100644 --- a/src/devices/bus/neogeo/prot_fatfury2.cpp +++ b/src/devices/bus/neogeo/prot_fatfury2.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(NG_FATFURY2_PROT, fatfury2_prot_device, "ng_fatfury_prot", "Neo Geo Fatal Fury 2 Protection") -fatfury2_prot_device::fatfury2_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +fatfury2_prot_device::fatfury2_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NG_FATFURY2_PROT, tag, owner, clock), m_pro_ct0(*this, "pro_ct0") { @@ -18,7 +18,7 @@ fatfury2_prot_device::fatfury2_prot_device(const machine_config &mconfig, const void fatfury2_prot_device::device_add_mconfig(machine_config &config) { - ALPHA_8921(config, m_pro_ct0, 0); // PRO-CT0 or SNK-9201 + ALPHA_8921(config, m_pro_ct0); // PRO-CT0 or SNK-9201 } void fatfury2_prot_device::device_start() diff --git a/src/devices/bus/neogeo/prot_fatfury2.h b/src/devices/bus/neogeo/prot_fatfury2.h index 1cab87cb26a..7057e37d4d7 100644 --- a/src/devices/bus/neogeo/prot_fatfury2.h +++ b/src/devices/bus/neogeo/prot_fatfury2.h @@ -15,7 +15,7 @@ class fatfury2_prot_device : public device_t { public: // construction/destruction - fatfury2_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + fatfury2_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint16_t protection_r(offs_t offset); void protection_w(offs_t offset, uint16_t data); diff --git a/src/devices/bus/neogeo/prot_kof2k2.cpp b/src/devices/bus/neogeo/prot_kof2k2.cpp index 75b79172d29..69b7f59ce36 100644 --- a/src/devices/bus/neogeo/prot_kof2k2.cpp +++ b/src/devices/bus/neogeo/prot_kof2k2.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(NG_KOF2002_PROT, kof2002_prot_device, "ng_kof2002_prot", "Neo Geo KoF 2002 Protection") -kof2002_prot_device::kof2002_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kof2002_prot_device::kof2002_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NG_KOF2002_PROT, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/prot_kof2k2.h b/src/devices/bus/neogeo/prot_kof2k2.h index 324da5a8918..2cf38c13b77 100644 --- a/src/devices/bus/neogeo/prot_kof2k2.h +++ b/src/devices/bus/neogeo/prot_kof2k2.h @@ -14,7 +14,7 @@ class kof2002_prot_device : public device_t { public: // construction/destruction - kof2002_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + kof2002_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void kof2002_decrypt_68k(uint8_t* cpurom, uint32_t cpurom_size); void matrim_decrypt_68k(uint8_t* cpurom, uint32_t cpurom_size); diff --git a/src/devices/bus/neogeo/prot_kof2k3bl.cpp b/src/devices/bus/neogeo/prot_kof2k3bl.cpp index 67262d15bc8..298e100612e 100644 --- a/src/devices/bus/neogeo/prot_kof2k3bl.cpp +++ b/src/devices/bus/neogeo/prot_kof2k3bl.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(NG_KOF2K3BL_PROT, kof2k3bl_prot_device, "ng_kof2k3bl_prot", "Neo Geo KoF 2003 Bootleg Protection") -kof2k3bl_prot_device::kof2k3bl_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +kof2k3bl_prot_device::kof2k3bl_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NG_KOF2K3BL_PROT, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/prot_kof2k3bl.h b/src/devices/bus/neogeo/prot_kof2k3bl.h index c4c83d30e5d..0e42c2240ed 100644 --- a/src/devices/bus/neogeo/prot_kof2k3bl.h +++ b/src/devices/bus/neogeo/prot_kof2k3bl.h @@ -13,7 +13,7 @@ class kof2k3bl_prot_device : public device_t { public: // construction/destruction - kof2k3bl_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + kof2k3bl_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint16_t protection_r(offs_t offset); void kof2003_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/bus/neogeo/prot_kof98.cpp b/src/devices/bus/neogeo/prot_kof98.cpp index 528bb2bf691..b3c95e377db 100644 --- a/src/devices/bus/neogeo/prot_kof98.cpp +++ b/src/devices/bus/neogeo/prot_kof98.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(NG_KOF98_PROT, kof98_prot_device, "ng_kof98_prot", "Neo Geo KoF 98 Protection") -kof98_prot_device::kof98_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +kof98_prot_device::kof98_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NG_KOF98_PROT, tag, owner, clock), m_prot_state(0) { diff --git a/src/devices/bus/neogeo/prot_kof98.h b/src/devices/bus/neogeo/prot_kof98.h index eef9fa47a7e..df0e9a3d788 100644 --- a/src/devices/bus/neogeo/prot_kof98.h +++ b/src/devices/bus/neogeo/prot_kof98.h @@ -14,7 +14,7 @@ class kof98_prot_device : public device_t { public: // construction/destruction - kof98_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + kof98_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void decrypt_68k(uint8_t* cpurom, uint32_t cpurom_size); void protection_w(uint16_t data); diff --git a/src/devices/bus/neogeo/prot_misc.cpp b/src/devices/bus/neogeo/prot_misc.cpp index 3cd4b6db75c..d1eb29d3abb 100644 --- a/src/devices/bus/neogeo/prot_misc.cpp +++ b/src/devices/bus/neogeo/prot_misc.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(NEOBOOT_PROT, neoboot_prot_device, "ngboot_prot", "Neo Geo Bootleg Protection(s)") -neoboot_prot_device::neoboot_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neoboot_prot_device::neoboot_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEOBOOT_PROT, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/prot_misc.h b/src/devices/bus/neogeo/prot_misc.h index b7e89224573..3974a9a4ebb 100644 --- a/src/devices/bus/neogeo/prot_misc.h +++ b/src/devices/bus/neogeo/prot_misc.h @@ -13,7 +13,7 @@ class neoboot_prot_device : public device_t { public: // construction/destruction - neoboot_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + neoboot_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void cx_decrypt(uint8_t* sprrom, uint32_t sprrom_size); void sx_decrypt(uint8_t* fixed, uint32_t fixed_size, int value); diff --git a/src/devices/bus/neogeo/prot_mslugx.cpp b/src/devices/bus/neogeo/prot_mslugx.cpp index 38cbb0b436b..e6913ad785e 100644 --- a/src/devices/bus/neogeo/prot_mslugx.cpp +++ b/src/devices/bus/neogeo/prot_mslugx.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(NG_MSLUGX_PROT, mslugx_prot_device, "ng_mslugx_prot", "Neo Geo Metal Slug X Protection") -mslugx_prot_device::mslugx_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mslugx_prot_device::mslugx_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NG_MSLUGX_PROT, tag, owner, clock), m_counter(0), m_command(0) diff --git a/src/devices/bus/neogeo/prot_mslugx.h b/src/devices/bus/neogeo/prot_mslugx.h index 0280ad1bbe5..9efcf1501b3 100644 --- a/src/devices/bus/neogeo/prot_mslugx.h +++ b/src/devices/bus/neogeo/prot_mslugx.h @@ -14,7 +14,7 @@ class mslugx_prot_device : public device_t { public: // construction/destruction - mslugx_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mslugx_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void protection_w(offs_t offset, uint16_t data); uint16_t protection_r(address_space &space, offs_t offset); diff --git a/src/devices/bus/neogeo/prot_pcm2.cpp b/src/devices/bus/neogeo/prot_pcm2.cpp index 82f3175eb8b..7e70be9cd15 100644 --- a/src/devices/bus/neogeo/prot_pcm2.cpp +++ b/src/devices/bus/neogeo/prot_pcm2.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(NG_PCM2_PROT, pcm2_prot_device, "ng_pcm2_prot", "Neo Geo NEOPCM2 Protection") -pcm2_prot_device::pcm2_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pcm2_prot_device::pcm2_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NG_PCM2_PROT, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/prot_pcm2.h b/src/devices/bus/neogeo/prot_pcm2.h index 707e9ab94b4..69f321a0751 100644 --- a/src/devices/bus/neogeo/prot_pcm2.h +++ b/src/devices/bus/neogeo/prot_pcm2.h @@ -14,7 +14,7 @@ class pcm2_prot_device : public device_t { public: // construction/destruction - pcm2_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pcm2_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void decrypt(uint8_t* ymrom, uint32_t ymsize, int value); void swap(uint8_t* ymrom, uint32_t ymsize, int value); diff --git a/src/devices/bus/neogeo/prot_pvc.cpp b/src/devices/bus/neogeo/prot_pvc.cpp index 1f0d734e732..5a8cd625b73 100644 --- a/src/devices/bus/neogeo/prot_pvc.cpp +++ b/src/devices/bus/neogeo/prot_pvc.cpp @@ -10,7 +10,7 @@ DEFINE_DEVICE_TYPE(NG_PVC_PROT, pvc_prot_device, "ng_pvc_prot", "Neo Geo PVC Protection") -pvc_prot_device::pvc_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pvc_prot_device::pvc_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NG_PVC_PROT, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/prot_pvc.h b/src/devices/bus/neogeo/prot_pvc.h index f133424c2fa..bc1a0545c36 100644 --- a/src/devices/bus/neogeo/prot_pvc.h +++ b/src/devices/bus/neogeo/prot_pvc.h @@ -13,7 +13,7 @@ class pvc_prot_device : public device_t { public: // construction/destruction - pvc_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pvc_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void pvc_write_unpack_color(); void pvc_write_pack_color(); diff --git a/src/devices/bus/neogeo/prot_sma.cpp b/src/devices/bus/neogeo/prot_sma.cpp index ccb569fec6e..b6877be8d76 100644 --- a/src/devices/bus/neogeo/prot_sma.cpp +++ b/src/devices/bus/neogeo/prot_sma.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(NG_SMA_PROT, sma_prot_device, "ng_sma_prot", "Neo Geo SMA Protection") -sma_prot_device::sma_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sma_prot_device::sma_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NG_SMA_PROT, tag, owner, clock), m_sma_rng(0) { diff --git a/src/devices/bus/neogeo/prot_sma.h b/src/devices/bus/neogeo/prot_sma.h index bb19fe43f40..554c05a24b9 100644 --- a/src/devices/bus/neogeo/prot_sma.h +++ b/src/devices/bus/neogeo/prot_sma.h @@ -14,7 +14,7 @@ class sma_prot_device : public device_t { public: // construction/destruction - sma_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sma_prot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); //void kof99_bankswitch_w(uint16_t data); //void garou_bankswitch_w(uint16_t data); diff --git a/src/devices/bus/neogeo/pvc.cpp b/src/devices/bus/neogeo/pvc.cpp index 26987ab33dc..909b9ff41af 100644 --- a/src/devices/bus/neogeo/pvc.cpp +++ b/src/devices/bus/neogeo/pvc.cpp @@ -64,7 +64,7 @@ void neogeo_pvc_cart_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NEOGEO_PVC_MSLUG5_CART, neogeo_pvc_mslug5_cart_device, "neocart_mslug5", "Neo Geo Metal Slug 5 PVC Cart") -neogeo_pvc_mslug5_cart_device::neogeo_pvc_mslug5_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_pvc_mslug5_cart_device::neogeo_pvc_mslug5_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_pvc_cart_device(mconfig, NEOGEO_PVC_MSLUG5_CART, tag, owner, clock) { } @@ -84,7 +84,7 @@ void neogeo_pvc_mslug5_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_PVC_SVC_CART, neogeo_pvc_svc_cart_device, "neocart_svc", "Neo Geo SNK vs Capcom PVC Cart") -neogeo_pvc_svc_cart_device::neogeo_pvc_svc_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_pvc_svc_cart_device::neogeo_pvc_svc_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_pvc_cart_device(mconfig, NEOGEO_PVC_SVC_CART, tag, owner, clock) { } @@ -105,7 +105,7 @@ void neogeo_pvc_svc_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_PVC_KOF2003_CART, neogeo_pvc_kof2003_cart_device, "neocart_kof2003", "Neo Geo KoF 2003 PVC Cart") -neogeo_pvc_kof2003_cart_device::neogeo_pvc_kof2003_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_pvc_kof2003_cart_device::neogeo_pvc_kof2003_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_pvc_cart_device(mconfig, NEOGEO_PVC_KOF2003_CART, tag, owner, clock) { } @@ -125,7 +125,7 @@ void neogeo_pvc_kof2003_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) DEFINE_DEVICE_TYPE(NEOGEO_PVC_KOF2003H_CART, neogeo_pvc_kof2003h_cart_device, "neocart_kof2003h", "Neo Geo KoF 2003 AES PVC Cart") -neogeo_pvc_kof2003h_cart_device::neogeo_pvc_kof2003h_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_pvc_kof2003h_cart_device::neogeo_pvc_kof2003h_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_pvc_cart_device(mconfig, NEOGEO_PVC_KOF2003H_CART, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/pvc.h b/src/devices/bus/neogeo/pvc.h index 23f1bbfede5..79ebb4931c0 100644 --- a/src/devices/bus/neogeo/pvc.h +++ b/src/devices/bus/neogeo/pvc.h @@ -53,7 +53,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_PVC_CART, neogeo_pvc_cart_device) class neogeo_pvc_mslug5_cart_device : public neogeo_pvc_cart_device { public: - neogeo_pvc_mslug5_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_pvc_mslug5_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } }; @@ -68,7 +68,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_PVC_MSLUG5_CART, neogeo_pvc_mslug5_cart_device) class neogeo_pvc_svc_cart_device : public neogeo_pvc_cart_device { public: - neogeo_pvc_svc_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_pvc_svc_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 2; } }; @@ -83,7 +83,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_PVC_SVC_CART, neogeo_pvc_svc_cart_device) class neogeo_pvc_kof2003_cart_device : public neogeo_pvc_cart_device { public: - neogeo_pvc_kof2003_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_pvc_kof2003_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 2; } }; @@ -98,7 +98,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_PVC_KOF2003_CART, neogeo_pvc_kof2003_cart_device) class neogeo_pvc_kof2003h_cart_device : public neogeo_pvc_cart_device { public: - neogeo_pvc_kof2003h_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_pvc_kof2003h_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 2; } }; diff --git a/src/devices/bus/neogeo/rom.cpp b/src/devices/bus/neogeo/rom.cpp index 290ea9f3a5d..a4a31bf1ab9 100644 --- a/src/devices/bus/neogeo/rom.cpp +++ b/src/devices/bus/neogeo/rom.cpp @@ -72,7 +72,7 @@ void neogeo_rom_device::banksel_w(uint16_t data) DEFINE_DEVICE_TYPE(NEOGEO_VLINER_CART, neogeo_vliner_cart_device, "neocart_vliner", "Neo Geo V-Liner Cart") -neogeo_vliner_cart_device::neogeo_vliner_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_vliner_cart_device::neogeo_vliner_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_rom_device(mconfig, NEOGEO_VLINER_CART, tag, owner, clock), m_nvram(*this, "nvram") { diff --git a/src/devices/bus/neogeo/rom.h b/src/devices/bus/neogeo/rom.h index 638154d919a..8394c3c4315 100644 --- a/src/devices/bus/neogeo/rom.h +++ b/src/devices/bus/neogeo/rom.h @@ -42,7 +42,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_ROM, neogeo_rom_device) class neogeo_vliner_cart_device : public neogeo_rom_device { public: - neogeo_vliner_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_vliner_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint16_t ram_r(offs_t offset) override { return m_cart_ram[offset]; } virtual void ram_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override { COMBINE_DATA(&m_cart_ram[offset]); } diff --git a/src/devices/bus/neogeo/sbp.cpp b/src/devices/bus/neogeo/sbp.cpp index 0ce1d179248..9c17cb635a9 100644 --- a/src/devices/bus/neogeo/sbp.cpp +++ b/src/devices/bus/neogeo/sbp.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(NEOGEO_SBP_CART, neogeo_sbp_cart_device, "neocart_sbp", "Neo Geo Super Bubble Pop Cart") -neogeo_sbp_cart_device::neogeo_sbp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_sbp_cart_device::neogeo_sbp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_rom_device(mconfig, NEOGEO_SBP_CART, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/sbp.h b/src/devices/bus/neogeo/sbp.h index 25fd920f281..a424e8b6030 100644 --- a/src/devices/bus/neogeo/sbp.h +++ b/src/devices/bus/neogeo/sbp.h @@ -15,7 +15,7 @@ class neogeo_sbp_cart_device : public neogeo_rom_device { public: - neogeo_sbp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_sbp_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void protection_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override; virtual uint16_t protection_r(address_space &space, offs_t offset) override; diff --git a/src/devices/bus/neogeo/sma.cpp b/src/devices/bus/neogeo/sma.cpp index ee031e4f44f..83aea5c185c 100644 --- a/src/devices/bus/neogeo/sma.cpp +++ b/src/devices/bus/neogeo/sma.cpp @@ -66,7 +66,7 @@ void neogeo_sma_cart_device::device_add_mconfig(machine_config &config) kof99 **************************************************/ -neogeo_sma_kof99_cart_device::neogeo_sma_kof99_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_sma_kof99_cart_device::neogeo_sma_kof99_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_sma_cart_device(mconfig, NEOGEO_SMA_KOF99_CART, tag, owner, clock) { } @@ -83,7 +83,7 @@ void neogeo_sma_kof99_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) garou **************************************************/ -neogeo_sma_garou_cart_device::neogeo_sma_garou_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_sma_garou_cart_device::neogeo_sma_garou_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_sma_cart_device(mconfig, NEOGEO_SMA_GAROU_CART, tag, owner, clock) { } @@ -100,7 +100,7 @@ void neogeo_sma_garou_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) garouh **************************************************/ -neogeo_sma_garouh_cart_device::neogeo_sma_garouh_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_sma_garouh_cart_device::neogeo_sma_garouh_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_sma_cart_device(mconfig, NEOGEO_SMA_GAROUH_CART, tag, owner, clock) { } @@ -117,7 +117,7 @@ void neogeo_sma_garouh_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) mslug3 **************************************************/ -neogeo_sma_mslug3_cart_device::neogeo_sma_mslug3_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_sma_mslug3_cart_device::neogeo_sma_mslug3_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_sma_cart_device(mconfig, NEOGEO_SMA_MSLUG3_CART, tag, owner, clock) { } @@ -129,7 +129,7 @@ void neogeo_sma_mslug3_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) m_cmc_prot->sfix_decrypt(spr_region, spr_region_size, fix_region, fix_region_size); } -neogeo_sma_mslug3a_cart_device::neogeo_sma_mslug3a_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_sma_mslug3a_cart_device::neogeo_sma_mslug3a_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_sma_cart_device(mconfig, NEOGEO_SMA_MSLUG3A_CART, tag, owner, clock) { } @@ -146,7 +146,7 @@ void neogeo_sma_mslug3a_cart_device::decrypt_all(DECRYPT_ALL_PARAMS) kof2000 **************************************************/ -neogeo_sma_kof2000_cart_device::neogeo_sma_kof2000_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_sma_kof2000_cart_device::neogeo_sma_kof2000_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_sma_cart_device(mconfig, NEOGEO_SMA_KOF2000_CART, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo/sma.h b/src/devices/bus/neogeo/sma.h index 1eb1a05e6ba..8c3cfc6ea47 100644 --- a/src/devices/bus/neogeo/sma.h +++ b/src/devices/bus/neogeo/sma.h @@ -48,7 +48,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_SMA_CART, neogeo_sma_cart_device) class neogeo_sma_kof99_cart_device : public neogeo_sma_cart_device { public: - neogeo_sma_kof99_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_sma_kof99_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } virtual uint32_t get_bank_base(uint16_t sel) override { return m_sma_prot->kof99_bank_base(sel); } @@ -64,7 +64,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_SMA_KOF99_CART, neogeo_sma_kof99_cart_device) class neogeo_sma_garou_cart_device : public neogeo_sma_cart_device { public: - neogeo_sma_garou_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_sma_garou_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } virtual uint32_t get_bank_base(uint16_t sel) override { return m_sma_prot->garou_bank_base(sel); } @@ -80,7 +80,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_SMA_GAROU_CART, neogeo_sma_garou_cart_device) class neogeo_sma_garouh_cart_device : public neogeo_sma_cart_device { public: - neogeo_sma_garouh_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_sma_garouh_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } virtual uint32_t get_bank_base(uint16_t sel) override { return m_sma_prot->garouh_bank_base(sel); } @@ -96,7 +96,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_SMA_GAROUH_CART, neogeo_sma_garouh_cart_device) class neogeo_sma_mslug3_cart_device : public neogeo_sma_cart_device { public: - neogeo_sma_mslug3_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_sma_mslug3_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } virtual uint32_t get_bank_base(uint16_t sel) override { return m_sma_prot->mslug3_bank_base(sel); } @@ -107,7 +107,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_SMA_MSLUG3_CART, neogeo_sma_mslug3_cart_device) class neogeo_sma_mslug3a_cart_device : public neogeo_sma_cart_device { public: - neogeo_sma_mslug3a_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_sma_mslug3a_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 1; } virtual uint32_t get_bank_base(uint16_t sel) override { return m_sma_prot->mslug3a_bank_base(sel); } @@ -123,7 +123,7 @@ DECLARE_DEVICE_TYPE(NEOGEO_SMA_MSLUG3A_CART, neogeo_sma_mslug3a_cart_device) class neogeo_sma_kof2000_cart_device : public neogeo_sma_cart_device { public: - neogeo_sma_kof2000_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_sma_kof2000_cart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void decrypt_all(DECRYPT_ALL_PARAMS) override; virtual int get_fixed_bank_type() override { return 2; } virtual uint32_t get_bank_base(uint16_t sel) override { return m_sma_prot->kof2000_bank_base(sel); } diff --git a/src/devices/bus/neogeo_ctrl/ctrl.cpp b/src/devices/bus/neogeo_ctrl/ctrl.cpp index 93ff26640f8..df2338aec20 100644 --- a/src/devices/bus/neogeo_ctrl/ctrl.cpp +++ b/src/devices/bus/neogeo_ctrl/ctrl.cpp @@ -86,7 +86,7 @@ device_neogeo_ctrl_edge_interface::~device_neogeo_ctrl_edge_interface() // neogeo_control_port_device - constructor //------------------------------------------------- -neogeo_control_port_device::neogeo_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_control_port_device::neogeo_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEOGEO_CONTROL_PORT, tag, owner, clock), device_single_card_slot_interface<device_neogeo_control_port_interface>(mconfig, *this), m_device(nullptr) @@ -135,7 +135,7 @@ void neogeo_control_port_device::write_ctrlsel(uint8_t data) // neogeo_ctrl_edge_port_device - constructor //------------------------------------------------- -neogeo_ctrl_edge_port_device::neogeo_ctrl_edge_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_ctrl_edge_port_device::neogeo_ctrl_edge_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEOGEO_CTRL_EDGE_CONNECTOR, tag, owner, clock), device_single_card_slot_interface<device_neogeo_ctrl_edge_interface>(mconfig, *this), m_device(nullptr) diff --git a/src/devices/bus/neogeo_ctrl/ctrl.h b/src/devices/bus/neogeo_ctrl/ctrl.h index 552f80eced4..16828f58cf4 100644 --- a/src/devices/bus/neogeo_ctrl/ctrl.h +++ b/src/devices/bus/neogeo_ctrl/ctrl.h @@ -42,14 +42,14 @@ public: // construction/destruction template <typename T> neogeo_control_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt, bool const fixed) - : neogeo_control_port_device(mconfig, tag, owner, (uint32_t)0) + : neogeo_control_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(fixed); } - neogeo_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~neogeo_control_port_device(); uint8_t read_ctrl(); @@ -88,14 +88,14 @@ public: // construction/destruction template <typename T> neogeo_ctrl_edge_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt, bool const fixed) - : neogeo_ctrl_edge_port_device(mconfig, tag, owner, (uint32_t)0) + : neogeo_ctrl_edge_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(fixed); } - neogeo_ctrl_edge_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_ctrl_edge_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~neogeo_ctrl_edge_port_device(); uint8_t read_start_sel(); diff --git a/src/devices/bus/neogeo_ctrl/dial.cpp b/src/devices/bus/neogeo_ctrl/dial.cpp index 6ee2a75840c..564562c784f 100644 --- a/src/devices/bus/neogeo_ctrl/dial.cpp +++ b/src/devices/bus/neogeo_ctrl/dial.cpp @@ -66,7 +66,7 @@ ioport_constructor neogeo_dial_device::device_input_ports() const // neogeo_dial_device - constructor //------------------------------------------------- -neogeo_dial_device::neogeo_dial_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_dial_device::neogeo_dial_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEOGEO_DIAL, tag, owner, clock), device_neogeo_ctrl_edge_interface(mconfig, *this), m_joy1(*this, "JOY1"), diff --git a/src/devices/bus/neogeo_ctrl/dial.h b/src/devices/bus/neogeo_ctrl/dial.h index 676e1b51316..56abc6b9241 100644 --- a/src/devices/bus/neogeo_ctrl/dial.h +++ b/src/devices/bus/neogeo_ctrl/dial.h @@ -24,7 +24,7 @@ class neogeo_dial_device : public device_t, public device_neogeo_ctrl_edge_inter { public: // construction/destruction - neogeo_dial_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_dial_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/neogeo_ctrl/irrmaze.cpp b/src/devices/bus/neogeo_ctrl/irrmaze.cpp index 59374e6f99a..94e143bf1a0 100644 --- a/src/devices/bus/neogeo_ctrl/irrmaze.cpp +++ b/src/devices/bus/neogeo_ctrl/irrmaze.cpp @@ -45,7 +45,7 @@ INPUT_PORTS_END // neogeo_irrmaze_device - constructor //------------------------------------------------- -neogeo_irrmaze_device::neogeo_irrmaze_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_irrmaze_device::neogeo_irrmaze_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEOGEO_IRRMAZE, tag, owner, clock), device_neogeo_ctrl_edge_interface(mconfig, *this), m_tx(*this, "TRACK_X"), diff --git a/src/devices/bus/neogeo_ctrl/irrmaze.h b/src/devices/bus/neogeo_ctrl/irrmaze.h index 78a00801f8c..8cc9ef2e9fa 100644 --- a/src/devices/bus/neogeo_ctrl/irrmaze.h +++ b/src/devices/bus/neogeo_ctrl/irrmaze.h @@ -23,7 +23,7 @@ class neogeo_irrmaze_device : public device_t, public device_neogeo_ctrl_edge_in { public: // construction/destruction - neogeo_irrmaze_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_irrmaze_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/neogeo_ctrl/joystick.cpp b/src/devices/bus/neogeo_ctrl/joystick.cpp index fe2712d00a8..c81b81fdc3f 100644 --- a/src/devices/bus/neogeo_ctrl/joystick.cpp +++ b/src/devices/bus/neogeo_ctrl/joystick.cpp @@ -61,7 +61,7 @@ ioport_constructor neogeo_joystick_device::device_input_ports() const // neogeo_joystick_device - constructor //------------------------------------------------- -neogeo_joystick_device::neogeo_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_joystick_device::neogeo_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEOGEO_JOY, tag, owner, clock), device_neogeo_control_port_interface(mconfig, *this), m_joy(*this, "JOY"), @@ -169,7 +169,7 @@ ioport_constructor neogeo_joy_ac_device::device_input_ports() const // neogeo_joy_ac_device / neogeo_joystick_device - constructor //------------------------------------------------- -neogeo_joy_ac_device::neogeo_joy_ac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_joy_ac_device::neogeo_joy_ac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEOGEO_JOY_AC, tag, owner, clock), device_neogeo_ctrl_edge_interface(mconfig, *this), m_joy(*this, "JOY%u", 1U), diff --git a/src/devices/bus/neogeo_ctrl/joystick.h b/src/devices/bus/neogeo_ctrl/joystick.h index b817e672ca3..33a9c554e68 100644 --- a/src/devices/bus/neogeo_ctrl/joystick.h +++ b/src/devices/bus/neogeo_ctrl/joystick.h @@ -23,7 +23,7 @@ class neogeo_joystick_device : public device_t, public device_neogeo_control_por { public: // construction/destruction - neogeo_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -48,7 +48,7 @@ class neogeo_joy_ac_device : public device_t, public device_neogeo_ctrl_edge_int { public: // construction/destruction - neogeo_joy_ac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_joy_ac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/neogeo_ctrl/kizuna4p.cpp b/src/devices/bus/neogeo_ctrl/kizuna4p.cpp index ccc08ef61ed..269d00f309c 100644 --- a/src/devices/bus/neogeo_ctrl/kizuna4p.cpp +++ b/src/devices/bus/neogeo_ctrl/kizuna4p.cpp @@ -95,7 +95,7 @@ ioport_constructor neogeo_kizuna4p_device::device_input_ports() const // neogeo_kizuna4p_device - constructor //------------------------------------------------- -neogeo_kizuna4p_device::neogeo_kizuna4p_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +neogeo_kizuna4p_device::neogeo_kizuna4p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEOGEO_KIZ4P, tag, owner, clock), device_neogeo_ctrl_edge_interface(mconfig, *this), m_joy(*this, "JOY%u", 1U), diff --git a/src/devices/bus/neogeo_ctrl/kizuna4p.h b/src/devices/bus/neogeo_ctrl/kizuna4p.h index 404055cdec6..0a909edb868 100644 --- a/src/devices/bus/neogeo_ctrl/kizuna4p.h +++ b/src/devices/bus/neogeo_ctrl/kizuna4p.h @@ -24,7 +24,7 @@ class neogeo_kizuna4p_device : public device_t, public device_neogeo_ctrl_edge_i { public: // construction/destruction - neogeo_kizuna4p_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_kizuna4p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/neogeo_ctrl/mahjong.cpp b/src/devices/bus/neogeo_ctrl/mahjong.cpp index 1ac8d1e2d20..bb28903e36a 100644 --- a/src/devices/bus/neogeo_ctrl/mahjong.cpp +++ b/src/devices/bus/neogeo_ctrl/mahjong.cpp @@ -85,7 +85,7 @@ ioport_constructor neogeo_mjctrl_device::device_input_ports() const // neogeo_joystick_device - constructor //------------------------------------------------- -neogeo_mjctrl_ac_device::neogeo_mjctrl_ac_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +neogeo_mjctrl_ac_device::neogeo_mjctrl_ac_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_neogeo_control_port_interface(mconfig, *this) , m_ctrl_sel(0x00) @@ -94,12 +94,12 @@ neogeo_mjctrl_ac_device::neogeo_mjctrl_ac_device(const machine_config &mconfig, { } -neogeo_mjctrl_ac_device::neogeo_mjctrl_ac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +neogeo_mjctrl_ac_device::neogeo_mjctrl_ac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_mjctrl_ac_device(mconfig, NEOGEO_MJCTRL_AC, tag, owner, clock) { } -neogeo_mjctrl_device::neogeo_mjctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +neogeo_mjctrl_device::neogeo_mjctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : neogeo_mjctrl_ac_device(mconfig, NEOGEO_MJCTRL, tag, owner, clock) { } diff --git a/src/devices/bus/neogeo_ctrl/mahjong.h b/src/devices/bus/neogeo_ctrl/mahjong.h index d4fd1646ece..5e9085b72d1 100644 --- a/src/devices/bus/neogeo_ctrl/mahjong.h +++ b/src/devices/bus/neogeo_ctrl/mahjong.h @@ -23,10 +23,10 @@ class neogeo_mjctrl_ac_device : public device_t, public device_neogeo_control_po { public: // construction/destruction - neogeo_mjctrl_ac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_mjctrl_ac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - neogeo_mjctrl_ac_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + neogeo_mjctrl_ac_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; @@ -50,7 +50,7 @@ class neogeo_mjctrl_device : public neogeo_mjctrl_ac_device { public: // construction/destruction - neogeo_mjctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + neogeo_mjctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/nes/2a03pur.cpp b/src/devices/bus/nes/2a03pur.cpp index 9105c518844..40e71fea88c 100644 --- a/src/devices/bus/nes/2a03pur.cpp +++ b/src/devices/bus/nes/2a03pur.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(NES_2A03PURITANS, nes_2a03pur_device, "nes_2a03pur", "NES Cart 2A03 Puritans Album PCB") -nes_2a03pur_device::nes_2a03pur_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_2a03pur_device::nes_2a03pur_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_2A03PURITANS, tag, owner, clock) { } diff --git a/src/devices/bus/nes/2a03pur.h b/src/devices/bus/nes/2a03pur.h index 27b4127b5f1..0284000c5dd 100644 --- a/src/devices/bus/nes/2a03pur.h +++ b/src/devices/bus/nes/2a03pur.h @@ -14,7 +14,7 @@ class nes_2a03pur_device : public nes_nrom_device { public: // construction/destruction - nes_2a03pur_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_2a03pur_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/act53.cpp b/src/devices/bus/nes/act53.cpp index 9fd4ced2a6b..94cb7f4adf3 100644 --- a/src/devices/bus/nes/act53.cpp +++ b/src/devices/bus/nes/act53.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(NES_ACTION53, nes_action53_device, "nes_action53", "NES Cart Action 53 PCB") -nes_action53_device::nes_action53_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_action53_device::nes_action53_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_ACTION53, tag, owner, clock) , m_sel(0) { diff --git a/src/devices/bus/nes/act53.h b/src/devices/bus/nes/act53.h index ead18a54ad6..5e101217b40 100644 --- a/src/devices/bus/nes/act53.h +++ b/src/devices/bus/nes/act53.h @@ -12,7 +12,7 @@ class nes_action53_device : public nes_nrom_device { public: // construction/destruction - nes_action53_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_action53_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/aladdin.cpp b/src/devices/bus/nes/aladdin.cpp index 00b444cd395..2bac94c91e3 100644 --- a/src/devices/bus/nes/aladdin.cpp +++ b/src/devices/bus/nes/aladdin.cpp @@ -66,7 +66,7 @@ uint8_t aladdin_cart_interface::read(offs_t offset) DEFINE_DEVICE_TYPE(NES_ALADDIN_SLOT, nes_aladdin_slot_device, "nes_ade_slot", "NES Aladdin Deck Enhancer Cartridge Slot") -nes_aladdin_slot_device::nes_aladdin_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_aladdin_slot_device::nes_aladdin_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_ALADDIN_SLOT, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_single_card_slot_interface<aladdin_cart_interface>(mconfig, *this) @@ -176,18 +176,18 @@ ROM_END DEFINE_DEVICE_TYPE(NES_ALGN_ROM, nes_algn_rom_device, "nes_algn_rom", "NES Aladdin Deck Enhancer ALGN ROM") DEFINE_DEVICE_TYPE(NES_ALGQ_ROM, nes_algq_rom_device, "nes_algq_rom", "NES Aladdin Deck Enhancer ALGQ ROM") -nes_algn_rom_device::nes_algn_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_algn_rom_device::nes_algn_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , aladdin_cart_interface(mconfig, *this) { } -nes_algn_rom_device::nes_algn_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_algn_rom_device::nes_algn_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_algn_rom_device(mconfig, NES_ALGN_ROM, tag, owner, clock) { } -nes_algq_rom_device::nes_algq_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_algq_rom_device::nes_algq_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_algn_rom_device(mconfig, NES_ALGQ_ROM, tag, owner, clock) , m_bank_base(0) { @@ -263,7 +263,7 @@ void nes_algq_rom_device::write_prg(uint32_t offset, uint8_t data) DEFINE_DEVICE_TYPE(NES_ALADDIN, nes_aladdin_device, "nes_aladdin", "NES Cart Camerica Aladdin PCB") -nes_aladdin_device::nes_aladdin_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_aladdin_device::nes_aladdin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_ALADDIN, tag, owner, clock) , m_subslot(*this, "ade_slot") { diff --git a/src/devices/bus/nes/aladdin.h b/src/devices/bus/nes/aladdin.h index 170649fdd30..f9891c5700a 100644 --- a/src/devices/bus/nes/aladdin.h +++ b/src/devices/bus/nes/aladdin.h @@ -52,7 +52,7 @@ public: // construction/destruction template <typename T> nes_aladdin_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts) - : nes_aladdin_slot_device(mconfig, tag, owner, (uint32_t)0) + : nes_aladdin_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -60,7 +60,7 @@ public: set_fixed(false); } - nes_aladdin_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_aladdin_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~nes_aladdin_slot_device(); // image-level overrides @@ -100,7 +100,7 @@ class nes_algn_rom_device : public device_t, { public: // construction/destruction - nes_algn_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_algn_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -108,7 +108,7 @@ public: virtual void write_prg(uint32_t offset, uint8_t data) override; protected: - nes_algn_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_algn_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -122,7 +122,7 @@ class nes_algq_rom_device : public nes_algn_rom_device { public: // construction/destruction - nes_algq_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_algq_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void write_prg(uint32_t offset, uint8_t data) override; @@ -152,7 +152,7 @@ class nes_aladdin_device : public nes_nrom_device { public: // construction/destruction - nes_aladdin_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_aladdin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_h(offs_t offset) override; virtual void write_h(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/nes/ave.cpp b/src/devices/bus/nes/ave.cpp index f0f1196191c..d88468f2767 100644 --- a/src/devices/bus/nes/ave.cpp +++ b/src/devices/bus/nes/ave.cpp @@ -38,17 +38,17 @@ DEFINE_DEVICE_TYPE(NES_NINA006, nes_nina006_device, "nes_nina006", "NES Cart AVE DEFINE_DEVICE_TYPE(NES_MAXI15, nes_maxi15_device, "nes_maxi15", "NES Cart AVE Maxi 15 PCB") -nes_nina001_device::nes_nina001_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_nina001_device::nes_nina001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NINA001, tag, owner, clock) { } -nes_nina006_device::nes_nina006_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_nina006_device::nes_nina006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NINA006, tag, owner, clock) { } -nes_maxi15_device::nes_maxi15_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_maxi15_device::nes_maxi15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_MAXI15, tag, owner, clock) { } diff --git a/src/devices/bus/nes/ave.h b/src/devices/bus/nes/ave.h index b21a99ac4f2..3e447d15d7b 100644 --- a/src/devices/bus/nes/ave.h +++ b/src/devices/bus/nes/ave.h @@ -14,7 +14,7 @@ class nes_nina001_device : public nes_nrom_device { public: // construction/destruction - nes_nina001_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_nina001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; }; @@ -26,7 +26,7 @@ class nes_nina006_device : public nes_nrom_device { public: // construction/destruction - nes_nina006_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_nina006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; }; @@ -38,7 +38,7 @@ class nes_maxi15_device : public nes_nrom_device { public: // construction/destruction - nes_maxi15_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_maxi15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; diff --git a/src/devices/bus/nes/bandai.cpp b/src/devices/bus/nes/bandai.cpp index 5954aacff62..26e6c5c6489 100644 --- a/src/devices/bus/nes/bandai.cpp +++ b/src/devices/bus/nes/bandai.cpp @@ -56,47 +56,47 @@ DEFINE_DEVICE_TYPE(NES_LZ93D50_24C02, nes_lz93d50_24c02_device, "nes_lz93d50_ep2 DEFINE_DEVICE_TYPE(NES_FJUMP2, nes_fjump2_device, "nes_fjump2", "NES Cart Bandai Famicom Jump II PCB") -nes_oekakids_device::nes_oekakids_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_oekakids_device::nes_oekakids_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_OEKAKIDS, tag, owner, clock), m_reg(0), m_latch(0) { } -nes_fcg_device::nes_fcg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_fcg_device::nes_fcg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr) { } -nes_fcg_device::nes_fcg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_fcg_device::nes_fcg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_fcg_device(mconfig, NES_FCG, tag, owner, clock) { } -nes_lz93d50_device::nes_lz93d50_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_lz93d50_device::nes_lz93d50_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_fcg_device(mconfig, type, tag, owner, clock) { } -nes_lz93d50_device::nes_lz93d50_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_lz93d50_device::nes_lz93d50_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_lz93d50_device(mconfig, NES_LZ93D50, tag, owner, clock) { } -nes_lz93d50_24c01_device::nes_lz93d50_24c01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_lz93d50_24c01_device::nes_lz93d50_24c01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_lz93d50_device(mconfig, type, tag, owner, clock), m_i2cmem(*this, "i2cmem"), m_i2c_dir(0) { } -nes_lz93d50_24c01_device::nes_lz93d50_24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_lz93d50_24c01_device::nes_lz93d50_24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_lz93d50_24c01_device(mconfig, NES_LZ93D50_24C01, tag, owner, clock) { } -nes_lz93d50_24c02_device::nes_lz93d50_24c02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_lz93d50_24c02_device::nes_lz93d50_24c02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_lz93d50_24c01_device(mconfig, NES_LZ93D50_24C02, tag, owner, clock) { } -nes_fjump2_device::nes_fjump2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_fjump2_device::nes_fjump2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_lz93d50_device(mconfig, NES_FJUMP2, tag, owner, clock) { } diff --git a/src/devices/bus/nes/bandai.h b/src/devices/bus/nes/bandai.h index 1a21f8a3052..6e5308fd158 100644 --- a/src/devices/bus/nes/bandai.h +++ b/src/devices/bus/nes/bandai.h @@ -15,7 +15,7 @@ class nes_oekakids_device : public nes_nrom_device { public: // construction/destruction - nes_oekakids_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_oekakids_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; virtual uint8_t nt_r(offs_t offset) override; @@ -43,7 +43,7 @@ class nes_fcg_device : public nes_nrom_device { public: // construction/destruction - nes_fcg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_fcg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void fcg_write(offs_t offset, uint8_t data); virtual void write_m(offs_t offset, uint8_t data) override; @@ -51,7 +51,7 @@ public: virtual void pcb_reset() override; protected: - nes_fcg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_fcg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -71,12 +71,12 @@ class nes_lz93d50_device : public nes_fcg_device { public: // construction/destruction - nes_lz93d50_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_lz93d50_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override { fcg_write(offset, data); } protected: - nes_lz93d50_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_lz93d50_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -86,7 +86,7 @@ class nes_lz93d50_24c01_device : public nes_lz93d50_device { public: // construction/destruction - nes_lz93d50_24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_lz93d50_24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_h(offs_t offset, uint8_t data) override; @@ -94,7 +94,7 @@ public: virtual void pcb_reset() override; protected: - nes_lz93d50_24c01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_lz93d50_24c01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -113,7 +113,7 @@ class nes_lz93d50_24c02_device : public nes_lz93d50_24c01_device { public: // construction/destruction - nes_lz93d50_24c02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_lz93d50_24c02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -127,7 +127,7 @@ class nes_fjump2_device : public nes_lz93d50_device { public: // construction/destruction - nes_fjump2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_fjump2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_m(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/nes/batlab.cpp b/src/devices/bus/nes/batlab.cpp index e117e6fbf5e..ae4643effca 100644 --- a/src/devices/bus/nes/batlab.cpp +++ b/src/devices/bus/nes/batlab.cpp @@ -37,12 +37,12 @@ DEFINE_DEVICE_TYPE(NES_BATMAP_000, nes_batmap_000_device, "nes_batmap_000", " DEFINE_DEVICE_TYPE(NES_BATMAP_SRRX, nes_batmap_srrx_device, "nes_batmap_srrx", "NES Cart Batlab BATMAP-SRR-X PCB") -nes_batmap_000_device::nes_batmap_000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_batmap_000_device::nes_batmap_000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BATMAP_000, tag, owner, clock) { } -nes_batmap_srrx_device::nes_batmap_srrx_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_batmap_srrx_device::nes_batmap_srrx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BATMAP_SRRX, tag, owner, clock), m_reg(0), m_dpcm_addr(0), m_dpcm_ctrl(0), m_irq_count(0), m_irq_count_latch(0), m_irq_enable(0) { } diff --git a/src/devices/bus/nes/batlab.h b/src/devices/bus/nes/batlab.h index 9861afe8a87..2a5e2f09ea1 100644 --- a/src/devices/bus/nes/batlab.h +++ b/src/devices/bus/nes/batlab.h @@ -14,7 +14,7 @@ class nes_batmap_000_device : public nes_txrom_device { public: // construction/destruction - nes_batmap_000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_batmap_000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -28,7 +28,7 @@ class nes_batmap_srrx_device : public nes_nrom_device { public: // construction/destruction - nes_batmap_srrx_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_batmap_srrx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual u8 read_m(offs_t offset) override; diff --git a/src/devices/bus/nes/benshieng.cpp b/src/devices/bus/nes/benshieng.cpp index 9fadad83386..5284b8a45a9 100644 --- a/src/devices/bus/nes/benshieng.cpp +++ b/src/devices/bus/nes/benshieng.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(NES_BENSHIENG, nes_benshieng_device, "nes_benshieng", "NES Cart Benshieng PCB") -nes_benshieng_device::nes_benshieng_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_benshieng_device::nes_benshieng_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BENSHIENG, tag, owner, clock), m_dipsetting(0) { } diff --git a/src/devices/bus/nes/benshieng.h b/src/devices/bus/nes/benshieng.h index 2292b57a270..92d5bdfe11e 100644 --- a/src/devices/bus/nes/benshieng.h +++ b/src/devices/bus/nes/benshieng.h @@ -14,7 +14,7 @@ class nes_benshieng_device : public nes_nrom_device { public: // construction/destruction - nes_benshieng_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_benshieng_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/bootleg.cpp b/src/devices/bus/nes/bootleg.cpp index c0ac3e1a35c..5ae2aa88406 100644 --- a/src/devices/bus/nes/bootleg.cpp +++ b/src/devices/bus/nes/bootleg.cpp @@ -72,167 +72,167 @@ DEFINE_DEVICE_TYPE(NES_RT01, nes_rt01_device, "nes_rt01", "N DEFINE_DEVICE_TYPE(NES_YUNG08, nes_yung08_device, "nes_yung08", "NES Cart Super Mario Bros. 2 YUNG-08 PCB") -nes_sc127_device::nes_sc127_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sc127_device::nes_sc127_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SC127, tag, owner, clock), m_irq_count(0), m_irq_enable(0) { } -nes_mbaby_device::nes_mbaby_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_mbaby_device::nes_mbaby_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_MARIOBABY, tag, owner, clock), m_irq_count(0), m_irq_enable(0), m_latch(0), irq_timer(nullptr) { } -nes_asn_device::nes_asn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_asn_device::nes_asn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_ASN, tag, owner, clock), m_latch(0) { } -nes_smb3p_device::nes_smb3p_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_smb3p_device::nes_smb3p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SMB3PIRATE, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr) { } -nes_btl_cj_device::nes_btl_cj_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_btl_cj_device::nes_btl_cj_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BTL_CONTRAJ, tag, owner, clock) { } -nes_btl_dn_device::nes_btl_dn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_btl_dn_device::nes_btl_dn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BTL_DNINJA, tag, owner, clock), m_irq_count(0) { } -nes_smb2j_device::nes_smb2j_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_smb2j_device::nes_smb2j_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SMB2J, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr) { } -nes_smb2ja_device::nes_smb2ja_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_smb2ja_device::nes_smb2ja_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SMB2JA, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr) { } -nes_smb2jb_device::nes_smb2jb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 bank67) +nes_smb2jb_device::nes_smb2jb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 bank67) : nes_nrom_device(mconfig, type, tag, owner, clock), m_irq_count(0), m_irq_enable(0), m_reg(0), m_bank67(bank67), irq_timer(nullptr) { } -nes_smb2jb_device::nes_smb2jb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_smb2jb_device::nes_smb2jb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_smb2jb_device(mconfig, NES_SMB2JB, tag, owner, clock, 0x0f) { } -nes_n32_4in1_device::nes_n32_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_n32_4in1_device::nes_n32_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_smb2jb_device(mconfig, NES_N32_4IN1, tag, owner, clock, 0x07) { } -nes_0353_device::nes_0353_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_0353_device::nes_0353_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_0353, tag, owner, clock), m_reg(0) { } -nes_09034a_device::nes_09034a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_09034a_device::nes_09034a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_09034A, tag, owner, clock), m_irq_count(0), m_irq_enable(0), m_reg(0), irq_timer(nullptr) { } -nes_l001_device::nes_l001_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_l001_device::nes_l001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_L001, tag, owner, clock), m_irq_count(0), irq_timer(nullptr) { } -nes_batmanfs_device::nes_batmanfs_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_batmanfs_device::nes_batmanfs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BATMANFS, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr) { } -nes_palthena_device::nes_palthena_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_palthena_device::nes_palthena_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_PALTHENA, tag, owner, clock), m_reg(0) { } -nes_tobidase_device::nes_tobidase_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_tobidase_device::nes_tobidase_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_TOBIDASE, tag, owner, clock), m_latch(0) { } -nes_whirlwind_device::nes_whirlwind_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_whirlwind_device::nes_whirlwind_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_reg(0) { } -nes_dh08_device::nes_dh08_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_dh08_device::nes_dh08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_whirlwind_device(mconfig, NES_DH08, tag, owner, clock) { } -nes_le05_device::nes_le05_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_le05_device::nes_le05_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_whirlwind_device(mconfig, NES_LE05, tag, owner, clock) { } -nes_lh28_lh54_device::nes_lh28_lh54_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_lh28_lh54_device::nes_lh28_lh54_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_whirlwind_device(mconfig, NES_LH28_LH54, tag, owner, clock) { } -nes_lh31_device::nes_lh31_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_lh31_device::nes_lh31_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_whirlwind_device(mconfig, NES_LH31, tag, owner, clock) { } -nes_lh32_device::nes_lh32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_lh32_device::nes_lh32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_LH32, tag, owner, clock), m_latch(0) { } -nes_lh42_device::nes_lh42_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_lh42_device::nes_lh42_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_LH42, tag, owner, clock), m_latch(0) { } -nes_lg25_device::nes_lg25_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_lg25_device::nes_lg25_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_LG25, tag, owner, clock), m_latch(0) { } -nes_lh10_device::nes_lh10_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_lh10_device::nes_lh10_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_LH10, tag, owner, clock), m_latch(0) { } -nes_lh51_device::nes_lh51_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_lh51_device::nes_lh51_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_LH51, tag, owner, clock) { } -nes_lh53_device::nes_lh53_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_lh53_device::nes_lh53_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_LH53, tag, owner, clock), m_irq_count(0), m_irq_enable(0), m_reg(0), irq_timer(nullptr) { } -nes_2708_device::nes_2708_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_2708_device::nes_2708_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_2708, tag, owner, clock) { } -nes_ac08_device::nes_ac08_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_ac08_device::nes_ac08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_AC08, tag, owner, clock), m_latch(0) { } -nes_mmalee_device::nes_mmalee_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_mmalee_device::nes_mmalee_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_MMALEE, tag, owner, clock) { } -nes_rt01_device::nes_rt01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_rt01_device::nes_rt01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_RT01, tag, owner, clock) { } -nes_yung08_device::nes_yung08_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_yung08_device::nes_yung08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_YUNG08, tag, owner, clock), m_irq_count(0), m_irq_latch(0), irq_timer(nullptr) { } diff --git a/src/devices/bus/nes/bootleg.h b/src/devices/bus/nes/bootleg.h index 93cdaa2ec6f..0fbcef72aa0 100644 --- a/src/devices/bus/nes/bootleg.h +++ b/src/devices/bus/nes/bootleg.h @@ -12,7 +12,7 @@ class nes_sc127_device : public nes_nrom_device { public: // construction/destruction - nes_sc127_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sc127_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; virtual void hblank_irq(int scanline, bool vblank, bool blanked) override; @@ -34,7 +34,7 @@ class nes_mbaby_device : public nes_nrom_device { public: // construction/destruction - nes_mbaby_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_mbaby_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -62,7 +62,7 @@ class nes_asn_device : public nes_nrom_device { public: // construction/destruction - nes_asn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_asn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_h(offs_t offset, uint8_t data) override; @@ -84,7 +84,7 @@ class nes_smb3p_device : public nes_nrom_device { public: // construction/destruction - nes_smb3p_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_smb3p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -111,7 +111,7 @@ class nes_btl_cj_device : public nes_nrom_device { public: // construction/destruction - nes_btl_cj_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_btl_cj_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; virtual void pcb_reset() override; @@ -124,7 +124,7 @@ class nes_btl_dn_device : public nes_nrom_device { public: // construction/destruction - nes_btl_dn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_btl_dn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; virtual void hblank_irq(int scanline, bool vblank, bool blanked) override; @@ -145,7 +145,7 @@ class nes_smb2j_device : public nes_nrom_device { public: // construction/destruction - nes_smb2j_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_smb2j_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual u8 read_m(offs_t offset) override; @@ -177,7 +177,7 @@ class nes_smb2ja_device : public nes_nrom_device { public: // construction/destruction - nes_smb2ja_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_smb2ja_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -204,7 +204,7 @@ class nes_smb2jb_device : public nes_nrom_device { public: // construction/destruction - nes_smb2jb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_smb2jb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; @@ -213,7 +213,7 @@ public: virtual void pcb_reset() override; protected: - nes_smb2jb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 bank67); + nes_smb2jb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 bank67); // device-level overrides virtual void device_start() override; @@ -238,7 +238,7 @@ class nes_n32_4in1_device : public nes_smb2jb_device { public: // construction/destruction - nes_n32_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_n32_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -252,7 +252,7 @@ class nes_0353_device : public nes_nrom_device { public: // construction/destruction - nes_0353_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_0353_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -274,7 +274,7 @@ class nes_09034a_device : public nes_nrom_device { public: // construction/destruction - nes_09034a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_09034a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_ex(offs_t offset, u8 data) override; virtual u8 read_ex(offs_t offset) override; @@ -303,7 +303,7 @@ class nes_l001_device : public nes_nrom_device { public: // construction/destruction - nes_l001_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_l001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -328,7 +328,7 @@ class nes_batmanfs_device : public nes_nrom_device { public: // construction/destruction - nes_batmanfs_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_batmanfs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -354,7 +354,7 @@ class nes_palthena_device : public nes_nrom_device { public: // construction/destruction - nes_palthena_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_palthena_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual u8 read_h(offs_t offset) override; @@ -378,7 +378,7 @@ class nes_tobidase_device : public nes_nrom_device { public: // construction/destruction - nes_tobidase_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_tobidase_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_l(offs_t offset, uint8_t data) override; @@ -405,7 +405,7 @@ public: protected: // construction/destruction - nes_whirlwind_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_whirlwind_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -420,7 +420,7 @@ class nes_dh08_device : public nes_whirlwind_device { public: // construction/destruction - nes_dh08_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_dh08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -432,7 +432,7 @@ class nes_le05_device : public nes_whirlwind_device { public: // construction/destruction - nes_le05_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_le05_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -444,7 +444,7 @@ class nes_lh28_lh54_device : public nes_whirlwind_device { public: // construction/destruction - nes_lh28_lh54_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_lh28_lh54_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -456,7 +456,7 @@ class nes_lh31_device : public nes_whirlwind_device { public: // construction/destruction - nes_lh31_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_lh31_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -468,7 +468,7 @@ class nes_lh32_device : public nes_nrom_device { public: // construction/destruction - nes_lh32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_lh32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual uint8_t read_h(offs_t offset) override; @@ -492,7 +492,7 @@ class nes_lh42_device : public nes_nrom_device { public: // construction/destruction - nes_lh42_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_lh42_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -513,7 +513,7 @@ class nes_lg25_device : public nes_nrom_device { public: // construction/destruction - nes_lg25_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_lg25_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -534,7 +534,7 @@ class nes_lh10_device : public nes_nrom_device { public: // construction/destruction - nes_lh10_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_lh10_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual u8 read_m(offs_t offset) override; @@ -557,7 +557,7 @@ class nes_lh51_device : public nes_nrom_device { public: // construction/destruction - nes_lh51_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_lh51_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -571,7 +571,7 @@ class nes_lh53_device : public nes_nrom_device { public: // construction/destruction - nes_lh53_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_lh53_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual uint8_t read_h(offs_t offset) override; @@ -602,7 +602,7 @@ class nes_2708_device : public nes_nrom_device { public: // construction/destruction - nes_2708_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_2708_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual uint8_t read_h(offs_t offset) override; @@ -626,7 +626,7 @@ class nes_ac08_device : public nes_nrom_device { public: // nes_ac08_device/destruction - nes_ac08_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_ac08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_ex(offs_t offset, uint8_t data) override; @@ -649,7 +649,7 @@ class nes_mmalee_device : public nes_nrom_device { public: // construction/destruction - nes_mmalee_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_mmalee_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_m(offs_t offset, uint8_t data) override; @@ -662,7 +662,7 @@ class nes_rt01_device : public nes_nrom_device { public: // construction/destruction - nes_rt01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_rt01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_h(offs_t offset) override; @@ -676,7 +676,7 @@ class nes_yung08_device : public nes_nrom_device { public: // construction/destruction - nes_yung08_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_yung08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual u8 read_m(offs_t offset) override; diff --git a/src/devices/bus/nes/camerica.cpp b/src/devices/bus/nes/camerica.cpp index fd80dca08b0..577f2bce2aa 100644 --- a/src/devices/bus/nes/camerica.cpp +++ b/src/devices/bus/nes/camerica.cpp @@ -46,27 +46,27 @@ DEFINE_DEVICE_TYPE(NES_BF9096A, nes_bf9096a_device, "nes_bf9096a", "NES Cart Cam DEFINE_DEVICE_TYPE(NES_GOLDEN5, nes_golden5_device, "nes_golden5", "NES Cart Camerica Golden 5 PCB") -nes_bf9093_device::nes_bf9093_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bf9093_device::nes_bf9093_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BF9093, tag, owner, clock) { } -nes_bf9096_device::nes_bf9096_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool page_swap) +nes_bf9096_device::nes_bf9096_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool page_swap) : nes_nrom_device(mconfig, type, tag, owner, clock), m_reg(0), m_page_swap(page_swap) { } -nes_bf9096_device::nes_bf9096_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bf9096_device::nes_bf9096_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bf9096_device(mconfig, NES_BF9096, tag, owner, clock, false) { } -nes_bf9096a_device::nes_bf9096a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bf9096a_device::nes_bf9096a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bf9096_device(mconfig, NES_BF9096A, tag, owner, clock, true) { } -nes_golden5_device::nes_golden5_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_golden5_device::nes_golden5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_GOLDEN5, tag, owner, clock), m_lock(0), m_reg(0) { } diff --git a/src/devices/bus/nes/camerica.h b/src/devices/bus/nes/camerica.h index 0c2c2487361..9a060383dff 100644 --- a/src/devices/bus/nes/camerica.h +++ b/src/devices/bus/nes/camerica.h @@ -14,7 +14,7 @@ class nes_bf9093_device : public nes_nrom_device { public: // construction/destruction - nes_bf9093_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bf9093_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -28,14 +28,14 @@ class nes_bf9096_device : public nes_nrom_device { public: // construction/destruction - nes_bf9096_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bf9096_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; virtual void pcb_reset() override; protected: - nes_bf9096_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool page_swap); + nes_bf9096_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool page_swap); // device-level overrides virtual void device_start() override; @@ -52,7 +52,7 @@ class nes_bf9096a_device : public nes_bf9096_device { public: // construction/destruction - nes_bf9096a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bf9096a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -62,7 +62,7 @@ class nes_golden5_device : public nes_nrom_device { public: // construction/destruction - nes_golden5_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_golden5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/cne.cpp b/src/devices/bus/nes/cne.cpp index 8300c56928c..f78c69ad698 100644 --- a/src/devices/bus/nes/cne.cpp +++ b/src/devices/bus/nes/cne.cpp @@ -37,17 +37,17 @@ DEFINE_DEVICE_TYPE(NES_CNE_FSB, nes_cne_fsb_device, "nes_cne_fsb", "NES DEFINE_DEVICE_TYPE(NES_CNE_SHLZ, nes_cne_shlz_device, "nes_cne_shlz", "NES Cart C&E Sheng Huo Lie Zhuan PCB") -nes_cne_decathl_device::nes_cne_decathl_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_cne_decathl_device::nes_cne_decathl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_CNE_DECATHL, tag, owner, clock) { } -nes_cne_fsb_device::nes_cne_fsb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_cne_fsb_device::nes_cne_fsb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_CNE_FSB, tag, owner, clock) { } -nes_cne_shlz_device::nes_cne_shlz_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_cne_shlz_device::nes_cne_shlz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_CNE_SHLZ, tag, owner, clock) { } diff --git a/src/devices/bus/nes/cne.h b/src/devices/bus/nes/cne.h index 9e704443503..be3765c88e0 100644 --- a/src/devices/bus/nes/cne.h +++ b/src/devices/bus/nes/cne.h @@ -14,7 +14,7 @@ class nes_cne_decathl_device : public nes_nrom_device { public: // construction/destruction - nes_cne_decathl_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_cne_decathl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -26,7 +26,7 @@ class nes_cne_fsb_device : public nes_nrom_device { public: // construction/destruction - nes_cne_fsb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_cne_fsb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -41,7 +41,7 @@ class nes_cne_shlz_device : public nes_nrom_device { public: // construction/destruction - nes_cne_shlz_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_cne_shlz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; }; diff --git a/src/devices/bus/nes/cony.cpp b/src/devices/bus/nes/cony.cpp index 3e73f35a4bf..d174cf8406b 100644 --- a/src/devices/bus/nes/cony.cpp +++ b/src/devices/bus/nes/cony.cpp @@ -36,22 +36,22 @@ DEFINE_DEVICE_TYPE(NES_CONY1K, nes_cony1k_device, "nes_cony1k", "NES Cart Cony 1 DEFINE_DEVICE_TYPE(NES_YOKO, nes_yoko_device, "nes_yoko", "NES Cart Yoko PCB") -nes_cony_device::nes_cony_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 extra_addr, u8 mask) +nes_cony_device::nes_cony_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 extra_addr, u8 mask) : nes_nrom_device(mconfig, type, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr), m_extra_addr(extra_addr), m_mask(mask), m_mode_reg(0), m_outer_reg(0) { } -nes_cony_device::nes_cony_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_cony_device::nes_cony_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_cony_device(mconfig, NES_CONY, tag, owner, clock, 0x1100, 0x1f) { } -nes_cony1k_device::nes_cony1k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_cony1k_device::nes_cony1k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_cony_device(mconfig, NES_CONY1K, tag, owner, clock, 0x1100, 0x1f) { } -nes_yoko_device::nes_yoko_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_yoko_device::nes_yoko_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_cony_device(mconfig, NES_YOKO, tag, owner, clock, 0x1400, 0x0f) { } diff --git a/src/devices/bus/nes/cony.h b/src/devices/bus/nes/cony.h index 8f2faea4a40..ebdfb615526 100644 --- a/src/devices/bus/nes/cony.h +++ b/src/devices/bus/nes/cony.h @@ -14,7 +14,7 @@ class nes_cony_device : public nes_nrom_device { public: // construction/destruction - nes_cony_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_cony_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual u8 read_m(offs_t offset) override; @@ -26,7 +26,7 @@ public: protected: // construction/destruction - nes_cony_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 extra_addr, u8 mask); + nes_cony_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 extra_addr, u8 mask); // device-level overrides virtual void device_start() override; @@ -57,7 +57,7 @@ class nes_cony1k_device : public nes_cony_device { public: // construction/destruction - nes_cony1k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_cony1k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void set_chr() override; }; @@ -69,7 +69,7 @@ class nes_yoko_device : public nes_cony_device { public: // construction/destruction - nes_yoko_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_yoko_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; diff --git a/src/devices/bus/nes/datach.cpp b/src/devices/bus/nes/datach.cpp index 5e71e0af6bc..a99de3a4063 100644 --- a/src/devices/bus/nes/datach.cpp +++ b/src/devices/bus/nes/datach.cpp @@ -66,7 +66,7 @@ uint8_t datach_cart_interface::read(offs_t offset) DEFINE_DEVICE_TYPE(NES_DATACH_SLOT, nes_datach_slot_device, "nes_datach_slot", "NES Datach Cartridge Slot") -nes_datach_slot_device::nes_datach_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_datach_slot_device::nes_datach_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_DATACH_SLOT, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_single_card_slot_interface<datach_cart_interface>(mconfig, *this) @@ -162,18 +162,18 @@ ROM_END DEFINE_DEVICE_TYPE(NES_DATACH_ROM, nes_datach_rom_device, "nes_datach_rom", "NES Datach ROM") DEFINE_DEVICE_TYPE(NES_DATACH_24C01, nes_datach_24c01_device, "nes_datach_ep1", "NES Datach + 24C01 PCB") -nes_datach_rom_device::nes_datach_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_datach_rom_device::nes_datach_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , datach_cart_interface(mconfig, *this) { } -nes_datach_rom_device::nes_datach_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_datach_rom_device::nes_datach_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_datach_rom_device(mconfig, NES_DATACH_ROM, tag, owner, clock) { } -nes_datach_24c01_device::nes_datach_24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_datach_24c01_device::nes_datach_24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_datach_rom_device(mconfig, NES_DATACH_24C01, tag, owner, clock) { } @@ -216,7 +216,7 @@ void nes_datach_24c01_device::device_add_mconfig(machine_config &config) DEFINE_DEVICE_TYPE(NES_DATACH, nes_datach_device, "nes_datach", "NES Cart Bandai Datach PCB") -nes_datach_device::nes_datach_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_datach_device::nes_datach_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_lz93d50_device(mconfig, NES_DATACH, tag, owner, clock) , m_datach_latch(0) , m_i2cmem(*this, "i2cmem") @@ -370,7 +370,7 @@ static void datach_cart(device_slot_interface &device) void nes_datach_device::device_add_mconfig(machine_config &config) { - BARCODE_READER(config, m_reader, 0); + BARCODE_READER(config, m_reader); NES_DATACH_SLOT(config, m_subslot, 0, datach_cart); I2C_24C02(config, m_i2cmem); } diff --git a/src/devices/bus/nes/datach.h b/src/devices/bus/nes/datach.h index 80770904596..362654708ca 100644 --- a/src/devices/bus/nes/datach.h +++ b/src/devices/bus/nes/datach.h @@ -53,7 +53,7 @@ class nes_datach_slot_device : public device_t, public: // construction/destruction template <typename T> - nes_datach_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts) + nes_datach_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts) : nes_datach_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -61,7 +61,7 @@ public: set_default_option(nullptr); set_fixed(false); } - nes_datach_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_datach_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~nes_datach_slot_device(); // image-level overrides @@ -100,14 +100,14 @@ class nes_datach_rom_device : public device_t, public datach_cart_interface { public: // construction/destruction - nes_datach_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_datach_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; virtual uint8_t* get_cart_base(); protected: - nes_datach_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_datach_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -120,7 +120,7 @@ class nes_datach_24c01_device : public nes_datach_rom_device { public: // construction/destruction - nes_datach_24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_datach_24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -144,7 +144,7 @@ class nes_datach_device : public nes_lz93d50_device { public: // construction/destruction - nes_datach_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_datach_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual uint8_t read_h(offs_t offset) override; diff --git a/src/devices/bus/nes/discrete.cpp b/src/devices/bus/nes/discrete.cpp index 5b047a2daad..19b23431d45 100644 --- a/src/devices/bus/nes/discrete.cpp +++ b/src/devices/bus/nes/discrete.cpp @@ -38,22 +38,22 @@ DEFINE_DEVICE_TYPE(NES_74X377, nes_74x377_device, "nes_74x377", DEFINE_DEVICE_TYPE(NES_74X161X138, nes_74x161x138_device, "nes_bitcorp_dis", "NES Cart Discrete Logic (74*161/138) PCB") -nes_74x161x161x32_device::nes_74x161x161x32_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_74x161x161x32_device::nes_74x161x161x32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_74X161X161X32, tag, owner, clock) { } -nes_74x139x74_device::nes_74x139x74_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_74x139x74_device::nes_74x139x74_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_74X139X74, tag, owner, clock) { } -nes_74x377_device::nes_74x377_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_74x377_device::nes_74x377_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_74X377, tag, owner, clock) { } -nes_74x161x138_device::nes_74x161x138_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_74x161x138_device::nes_74x161x138_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_74X161X138, tag, owner, clock) { } diff --git a/src/devices/bus/nes/discrete.h b/src/devices/bus/nes/discrete.h index ec3ad88d824..4d99f881856 100644 --- a/src/devices/bus/nes/discrete.h +++ b/src/devices/bus/nes/discrete.h @@ -14,7 +14,7 @@ class nes_74x161x161x32_device : public nes_nrom_device { public: // construction/destruction - nes_74x161x161x32_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_74x161x161x32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -28,7 +28,7 @@ class nes_74x139x74_device : public nes_nrom_device { public: // construction/destruction - nes_74x139x74_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_74x139x74_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; }; @@ -40,7 +40,7 @@ class nes_74x377_device : public nes_nrom_device { public: // construction/destruction - nes_74x377_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_74x377_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -52,7 +52,7 @@ class nes_74x161x138_device : public nes_nrom_device { public: // construction/destruction - nes_74x161x138_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_74x161x138_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; }; diff --git a/src/devices/bus/nes/disksys.cpp b/src/devices/bus/nes/disksys.cpp index d53a2be2aab..618fb0352fb 100644 --- a/src/devices/bus/nes/disksys.cpp +++ b/src/devices/bus/nes/disksys.cpp @@ -101,7 +101,7 @@ void nes_disksys_device::unload_proc(device_image_interface &image) DEFINE_DEVICE_TYPE(NES_DISKSYS, nes_disksys_device, "fc_disksys", "FC RAM Expansion + Disk System PCB") -nes_disksys_device::nes_disksys_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_disksys_device::nes_disksys_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_DISKSYS, tag, owner, clock) , m_2c33_rom(*this, "drive") , m_fds_data(nullptr) diff --git a/src/devices/bus/nes/disksys.h b/src/devices/bus/nes/disksys.h index 021be514029..99d8bff849c 100644 --- a/src/devices/bus/nes/disksys.h +++ b/src/devices/bus/nes/disksys.h @@ -16,7 +16,7 @@ class nes_disksys_device : public nes_nrom_device { public: // construction/destruction - nes_disksys_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_disksys_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_ex(offs_t offset) override; virtual uint8_t read_m(offs_t offset) override; diff --git a/src/devices/bus/nes/event.cpp b/src/devices/bus/nes/event.cpp index 70aee4b90e0..dd30b5a64d4 100644 --- a/src/devices/bus/nes/event.cpp +++ b/src/devices/bus/nes/event.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(NES_EVENT, nes_event_device, "nes_event", "NES Cart EVENT DEFINE_DEVICE_TYPE(NES_EVENT2, nes_event2_device, "nes_event2", "NES Cart EVENT2 PCB") -nes_event_device::nes_event_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_event_device::nes_event_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_EVENT, tag, owner, clock) , m_dsw(*this, "DIPSW") , m_nwc_init(0) @@ -46,7 +46,7 @@ nes_event_device::nes_event_device(const machine_config &mconfig, const char *ta { } -nes_event2_device::nes_event2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_event2_device::nes_event2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_tqrom_device(mconfig, NES_EVENT2, tag, owner, clock) , m_dsw(*this, "DIPSW") , m_tqrom_mode(false) diff --git a/src/devices/bus/nes/event.h b/src/devices/bus/nes/event.h index b10a3f95ee1..bb73beacd4f 100644 --- a/src/devices/bus/nes/event.h +++ b/src/devices/bus/nes/event.h @@ -15,7 +15,7 @@ class nes_event_device : public nes_sxrom_device { public: // construction/destruction - nes_event_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_event_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void pcb_reset() override; @@ -45,7 +45,7 @@ class nes_event2_device : public nes_tqrom_device { public: // construction/destruction - nes_event2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_event2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/ggenie.cpp b/src/devices/bus/nes/ggenie.cpp index bddebcad512..b925a5d35d2 100644 --- a/src/devices/bus/nes/ggenie.cpp +++ b/src/devices/bus/nes/ggenie.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(NES_GGENIE, nes_ggenie_device, "nes_ggenie", "NES Cart Game Genie PCB") -nes_ggenie_device::nes_ggenie_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ggenie_device::nes_ggenie_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_GGENIE, tag, owner, clock) , m_ggslot(*this, "gg_slot") , m_gg_bypass(false) diff --git a/src/devices/bus/nes/ggenie.h b/src/devices/bus/nes/ggenie.h index 6370301d19a..99b58770cc0 100644 --- a/src/devices/bus/nes/ggenie.h +++ b/src/devices/bus/nes/ggenie.h @@ -14,7 +14,7 @@ class nes_ggenie_device : public nes_nrom_device { public: // construction/destruction - nes_ggenie_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ggenie_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual u8 read_m(offs_t offset) override; diff --git a/src/devices/bus/nes/henggedianzi.cpp b/src/devices/bus/nes/henggedianzi.cpp index a8de6e93783..243a2d0ea24 100644 --- a/src/devices/bus/nes/henggedianzi.cpp +++ b/src/devices/bus/nes/henggedianzi.cpp @@ -39,12 +39,12 @@ DEFINE_DEVICE_TYPE(NES_HENGG_SRICH, nes_hengg_srich_device, "nes_hengg_srich", " DEFINE_DEVICE_TYPE(NES_HENGG_XHZS, nes_hengg_xhzs_device, "nes_hengg_xhzs", "NES Cart Henggedianzi Xing He Zhan Shi PCB") -nes_hengg_srich_device::nes_hengg_srich_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_hengg_srich_device::nes_hengg_srich_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_HENGG_SRICH, tag, owner, clock) { } -nes_hengg_xhzs_device::nes_hengg_xhzs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_hengg_xhzs_device::nes_hengg_xhzs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_HENGG_XHZS, tag, owner, clock) { } diff --git a/src/devices/bus/nes/henggedianzi.h b/src/devices/bus/nes/henggedianzi.h index fc5922a1c4e..3d5d8695dce 100644 --- a/src/devices/bus/nes/henggedianzi.h +++ b/src/devices/bus/nes/henggedianzi.h @@ -14,7 +14,7 @@ class nes_hengg_srich_device : public nes_nrom_device { public: // construction/destruction - nes_hengg_srich_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_hengg_srich_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -26,7 +26,7 @@ class nes_hengg_xhzs_device : public nes_nrom_device { public: // construction/destruction - nes_hengg_xhzs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_hengg_xhzs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; virtual void write_h(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/nes/hes.cpp b/src/devices/bus/nes/hes.cpp index b23ad6c9f74..9a6a3d3e630 100644 --- a/src/devices/bus/nes/hes.cpp +++ b/src/devices/bus/nes/hes.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(NES_HES, nes_hes_device, "nes_hes", "NES Cart HES PCB") -nes_hes_device::nes_hes_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_hes_device::nes_hes_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_HES, tag, owner, clock) { } diff --git a/src/devices/bus/nes/hes.h b/src/devices/bus/nes/hes.h index 24577f416cb..d0a36c5f4d4 100644 --- a/src/devices/bus/nes/hes.h +++ b/src/devices/bus/nes/hes.h @@ -14,7 +14,7 @@ class nes_hes_device : public nes_nrom_device { public: // construction/destruction - nes_hes_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_hes_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; }; diff --git a/src/devices/bus/nes/irem.cpp b/src/devices/bus/nes/irem.cpp index f90959825a9..ecd40733114 100644 --- a/src/devices/bus/nes/irem.cpp +++ b/src/devices/bus/nes/irem.cpp @@ -40,32 +40,32 @@ DEFINE_DEVICE_TYPE(NES_G101, nes_g101_device, "nes_g101", "NES Cart DEFINE_DEVICE_TYPE(NES_H3001, nes_h3001_device, "ns_h3001", "NES Cart Irem H-3001 PCB") -nes_lrog017_device::nes_lrog017_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_lrog017_device::nes_lrog017_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_LROG017, tag, owner, clock) { } -nes_holydivr_device::nes_holydivr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_holydivr_device::nes_holydivr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_HOLYDIVR, tag, owner, clock) { } -nes_tam_s1_device::nes_tam_s1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_tam_s1_device::nes_tam_s1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_TAM_S1, tag, owner, clock) { } -nes_g101_device::nes_g101_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 prg_mask) +nes_g101_device::nes_g101_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 prg_mask) : nes_nrom_device(mconfig, type, tag, owner, clock), m_latch(0), m_reg(0), m_prg_mask(prg_mask) { } -nes_g101_device::nes_g101_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_g101_device::nes_g101_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_g101_device(mconfig, NES_G101, tag, owner, clock, 0x1f) { } -nes_h3001_device::nes_h3001_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_h3001_device::nes_h3001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_g101_device(mconfig, NES_H3001, tag, owner, clock, 0x3f), m_irq_count(0), m_irq_count_latch(0), m_irq_enable(0), irq_timer(nullptr) { } diff --git a/src/devices/bus/nes/irem.h b/src/devices/bus/nes/irem.h index eef809ca7b5..088bf52239d 100644 --- a/src/devices/bus/nes/irem.h +++ b/src/devices/bus/nes/irem.h @@ -14,7 +14,7 @@ class nes_lrog017_device : public nes_nrom_device { public: // construction/destruction - nes_lrog017_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_lrog017_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -28,7 +28,7 @@ class nes_holydivr_device : public nes_nrom_device { public: // construction/destruction - nes_holydivr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_holydivr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -42,7 +42,7 @@ class nes_tam_s1_device : public nes_nrom_device { public: // construction/destruction - nes_tam_s1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_tam_s1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -56,7 +56,7 @@ class nes_g101_device : public nes_nrom_device { public: // construction/destruction - nes_g101_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_g101_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -64,7 +64,7 @@ public: protected: // construction/destruction - nes_g101_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 prg_mask); + nes_g101_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 prg_mask); // device-level overrides virtual void device_start() override; @@ -84,7 +84,7 @@ class nes_h3001_device : public nes_g101_device { public: // construction/destruction - nes_h3001_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_h3001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/jaleco.cpp b/src/devices/bus/nes/jaleco.cpp index a83ebfb5a04..6375e17615b 100644 --- a/src/devices/bus/nes/jaleco.cpp +++ b/src/devices/bus/nes/jaleco.cpp @@ -51,23 +51,23 @@ DEFINE_DEVICE_TYPE(NES_JF29, nes_jf29_device, "nes_jf29", "NES C DEFINE_DEVICE_TYPE(NES_JF33, nes_jf33_device, "nes_jf33", "NES Cart Jaleco JF-33 (Moe Pro! Saikyou-hen) PCB") -nes_jf11_device::nes_jf11_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf11_device::nes_jf11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_JF11, tag, owner, clock) { } -nes_jf13_device::nes_jf13_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf13_device::nes_jf13_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_JF13, tag, owner, clock) , m_samples(*this, "samples") { } -nes_jf16_device::nes_jf16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf16_device::nes_jf16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_JF16, tag, owner, clock) { } -nes_jf17_device::nes_jf17_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool prg_flip) +nes_jf17_device::nes_jf17_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool prg_flip) : nes_nrom_device(mconfig, type, tag, owner, clock) , m_samples(*this, "samples") , m_latch(0) @@ -75,27 +75,27 @@ nes_jf17_device::nes_jf17_device(const machine_config &mconfig, device_type type { } -nes_jf17_device::nes_jf17_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf17_device::nes_jf17_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_jf17_device(mconfig, NES_JF17, tag, owner, clock, false) { } -nes_jf17_adpcm_device::nes_jf17_adpcm_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf17_adpcm_device::nes_jf17_adpcm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_jf17_device(mconfig, NES_JF17_ADPCM, tag, owner, clock, false) { } -nes_jf19_device::nes_jf19_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf19_device::nes_jf19_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_jf17_device(mconfig, NES_JF19, tag, owner, clock, true) { } -nes_jf19_adpcm_device::nes_jf19_adpcm_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf19_adpcm_device::nes_jf19_adpcm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_jf17_device(mconfig, NES_JF19_ADPCM, tag, owner, clock, true) { } -nes_ss88006_device::nes_ss88006_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_ss88006_device::nes_ss88006_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock) , m_samples(*this, "samples") , m_irq_count(0) @@ -107,27 +107,27 @@ nes_ss88006_device::nes_ss88006_device(const machine_config &mconfig, device_typ { } -nes_ss88006_device::nes_ss88006_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ss88006_device::nes_ss88006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ss88006_device(mconfig, NES_SS88006, tag, owner, clock) { } -nes_jf23_device::nes_jf23_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf23_device::nes_jf23_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ss88006_device(mconfig, NES_JF23, tag, owner, clock) { } -nes_jf24_device::nes_jf24_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf24_device::nes_jf24_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ss88006_device(mconfig, NES_JF24, tag, owner, clock) { } -nes_jf29_device::nes_jf29_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf29_device::nes_jf29_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ss88006_device(mconfig, NES_JF29, tag, owner, clock) { } -nes_jf33_device::nes_jf33_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jf33_device::nes_jf33_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ss88006_device(mconfig, NES_JF33, tag, owner, clock) { } diff --git a/src/devices/bus/nes/jaleco.h b/src/devices/bus/nes/jaleco.h index 7ed1b13d25a..134af0bd4d5 100644 --- a/src/devices/bus/nes/jaleco.h +++ b/src/devices/bus/nes/jaleco.h @@ -15,7 +15,7 @@ class nes_jf11_device : public nes_nrom_device { public: // construction/destruction - nes_jf11_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; }; @@ -27,7 +27,7 @@ class nes_jf13_device : public nes_nrom_device { public: // construction/destruction - nes_jf13_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf13_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -46,7 +46,7 @@ class nes_jf16_device : public nes_nrom_device { public: // construction/destruction - nes_jf16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -60,14 +60,14 @@ class nes_jf17_device : public nes_nrom_device { public: // construction/destruction - nes_jf17_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf17_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; virtual void pcb_reset() override; protected: - nes_jf17_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool m_prg_flip); + nes_jf17_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool m_prg_flip); // device-level overrides virtual void device_start() override; @@ -86,7 +86,7 @@ class nes_jf17_adpcm_device : public nes_jf17_device { public: // construction/destruction - nes_jf17_adpcm_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf17_adpcm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -99,7 +99,7 @@ class nes_jf19_device : public nes_jf17_device { public: // construction/destruction - nes_jf19_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf19_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -109,7 +109,7 @@ class nes_jf19_adpcm_device : public nes_jf17_device { public: // construction/destruction - nes_jf19_adpcm_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf19_adpcm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -122,7 +122,7 @@ class nes_ss88006_device : public nes_nrom_device { public: // construction/destruction - nes_ss88006_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ss88006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -131,7 +131,7 @@ public: virtual void pcb_reset() override; protected: - nes_ss88006_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_ss88006_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -159,7 +159,7 @@ class nes_jf23_device : public nes_ss88006_device { public: // construction/destruction - nes_jf23_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf23_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -172,7 +172,7 @@ class nes_jf24_device : public nes_ss88006_device { public: // construction/destruction - nes_jf24_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf24_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -185,7 +185,7 @@ class nes_jf29_device : public nes_ss88006_device { public: // construction/destruction - nes_jf29_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf29_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -198,7 +198,7 @@ class nes_jf33_device : public nes_ss88006_device { public: // construction/destruction - nes_jf33_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jf33_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/nes/jncota.cpp b/src/devices/bus/nes/jncota.cpp index 1206a0dd79b..f81068b60ab 100644 --- a/src/devices/bus/nes/jncota.cpp +++ b/src/devices/bus/nes/jncota.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(NES_JNCOTA_KT1001, nes_jncota_kt1001_device, "nes_jncota_kt1001", "NES Cart Shenzhen Jncota KT-1001 PCB") -nes_jncota_kt1001_device::nes_jncota_kt1001_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jncota_kt1001_device::nes_jncota_kt1001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_JNCOTA_KT1001, tag, owner, clock) { } diff --git a/src/devices/bus/nes/jncota.h b/src/devices/bus/nes/jncota.h index 441e6723969..3e8af2e0257 100644 --- a/src/devices/bus/nes/jncota.h +++ b/src/devices/bus/nes/jncota.h @@ -14,7 +14,7 @@ class nes_jncota_kt1001_device : public nes_nrom_device { public: // construction/destruction - nes_jncota_kt1001_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jncota_kt1001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/jy.cpp b/src/devices/bus/nes/jy.cpp index 655634f22ef..2c8553a05c1 100644 --- a/src/devices/bus/nes/jy.cpp +++ b/src/devices/bus/nes/jy.cpp @@ -41,28 +41,28 @@ DEFINE_DEVICE_TYPE(NES_JY_TYPEB, nes_jy_typeb_device, "nes_jyb", "NES Cart JY Co DEFINE_DEVICE_TYPE(NES_JY_TYPEC, nes_jy_typec_device, "nes_jyc", "NES Cart JY Company Type C PCB") -nes_jy_typea_device::nes_jy_typea_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_jy_typea_device::nes_jy_typea_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_latch(0), m_extra_chr_bank(0), m_extra_chr_mask(0), m_bank_6000(0), m_irq_mode(0), m_irq_count(0), m_irq_prescale(0), m_irq_prescale_mask(0), m_irq_flip(0), m_irq_enable(0), m_irq_up(0), m_irq_down(0), irq_timer(nullptr) { } -nes_jy_typea_device::nes_jy_typea_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_jy_typea_device::nes_jy_typea_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_JY_TYPEA, tag, owner, clock) { } -nes_jy_typeb_device::nes_jy_typeb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_jy_typeb_device::nes_jy_typeb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_jy_typea_device(mconfig, type, tag, owner, clock) { } -nes_jy_typeb_device::nes_jy_typeb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_jy_typeb_device::nes_jy_typeb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_jy_typeb_device(mconfig, NES_JY_TYPEB, tag, owner, clock) { } -nes_jy_typec_device::nes_jy_typec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_jy_typec_device::nes_jy_typec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_jy_typeb_device(mconfig, NES_JY_TYPEC, tag, owner, clock) { } diff --git a/src/devices/bus/nes/jy.h b/src/devices/bus/nes/jy.h index 69c4ea8b04e..99db06bfe17 100644 --- a/src/devices/bus/nes/jy.h +++ b/src/devices/bus/nes/jy.h @@ -14,7 +14,7 @@ class nes_jy_typea_device : public nes_nrom_device { public: // construction/destruction - nes_jy_typea_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_jy_typea_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual uint8_t read_m(offs_t offset) override; @@ -28,7 +28,7 @@ public: virtual void pcb_reset() override; protected: - nes_jy_typea_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_jy_typea_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -73,10 +73,10 @@ class nes_jy_typeb_device : public nes_jy_typea_device { public: // construction/destruction - nes_jy_typeb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_jy_typeb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nes_jy_typeb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_jy_typeb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void update_mirror_typeb(); virtual void update_mirror() override { update_mirror_typeb(); } @@ -88,7 +88,7 @@ class nes_jy_typec_device : public nes_jy_typeb_device { public: // construction/destruction - nes_jy_typec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_jy_typec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t chr_r(offs_t offset) override; diff --git a/src/devices/bus/nes/kaiser.cpp b/src/devices/bus/nes/kaiser.cpp index 4635c699895..a69a058f304 100644 --- a/src/devices/bus/nes/kaiser.cpp +++ b/src/devices/bus/nes/kaiser.cpp @@ -63,92 +63,92 @@ DEFINE_DEVICE_TYPE(NES_KS7057, nes_ks7057_device, "nes_ks7057", "NES Cart Kai DEFINE_DEVICE_TYPE(NES_KS7058, nes_ks7058_device, "nes_ks7058", "NES Cart Kaiser KS-7058 PCB") -nes_ks106c_device::nes_ks106c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks106c_device::nes_ks106c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS106C, tag, owner, clock), m_latch(0) { } -nes_ks7058_device::nes_ks7058_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7058_device::nes_ks7058_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7058, tag, owner, clock) { } -nes_ks7022_device::nes_ks7022_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7022_device::nes_ks7022_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7022, tag, owner, clock), m_latch(0) { } -nes_ks7032_device::nes_ks7032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_ks7032_device::nes_ks7032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_latch(0), m_irq_count(0), m_irq_count_latch(0), m_irq_enable(0), irq_timer(nullptr) { } -nes_ks7032_device::nes_ks7032_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7032_device::nes_ks7032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ks7032_device(mconfig, NES_KS7032, tag, owner, clock) { } -nes_ks202_device::nes_ks202_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks202_device::nes_ks202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ks7032_device(mconfig, NES_KS202, tag, owner, clock) { } -nes_ks7016_device::nes_ks7016_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 a15_flip) +nes_ks7016_device::nes_ks7016_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 a15_flip) : nes_nrom_device(mconfig, type, tag, owner, clock), m_latch(0), m_a15_flip(a15_flip) { } -nes_ks7016_device::nes_ks7016_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7016_device::nes_ks7016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ks7016_device(mconfig, NES_KS7016, tag, owner, clock, 0x00) { } -nes_ks7016b_device::nes_ks7016b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7016b_device::nes_ks7016b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ks7016_device(mconfig, NES_KS7016B, tag, owner, clock, 0x04) { } -nes_ks7017_device::nes_ks7017_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7017_device::nes_ks7017_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7017, tag, owner, clock), m_latch(0), m_irq_count(0), m_irq_status(0), m_irq_enable(0), irq_timer(nullptr) { } -nes_ks7021a_device::nes_ks7021a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7021a_device::nes_ks7021a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7021A, tag, owner, clock) { } -nes_ks7010_device::nes_ks7010_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7010_device::nes_ks7010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7010, tag, owner, clock), m_latch(0) { } -nes_ks7012_device::nes_ks7012_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7012_device::nes_ks7012_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7012, tag, owner, clock) { } -nes_ks7013b_device::nes_ks7013b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7013b_device::nes_ks7013b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7013B, tag, owner, clock) { } -nes_ks7030_device::nes_ks7030_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7030_device::nes_ks7030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7030, tag, owner, clock) { } -nes_ks7031_device::nes_ks7031_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7031_device::nes_ks7031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7031, tag, owner, clock) { } -nes_ks7037_device::nes_ks7037_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7037_device::nes_ks7037_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7037, tag, owner, clock), m_reg(0) { } -nes_ks7057_device::nes_ks7057_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ks7057_device::nes_ks7057_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KS7057, tag, owner, clock) { } diff --git a/src/devices/bus/nes/kaiser.h b/src/devices/bus/nes/kaiser.h index bfed01f40f9..e01a8e51446 100644 --- a/src/devices/bus/nes/kaiser.h +++ b/src/devices/bus/nes/kaiser.h @@ -14,7 +14,7 @@ class nes_ks106c_device : public nes_nrom_device { public: // construction/destruction - nes_ks106c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks106c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void pcb_reset() override; @@ -33,7 +33,7 @@ class nes_ks7058_device : public nes_nrom_device { public: // construction/destruction - nes_ks7058_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7058_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -45,7 +45,7 @@ class nes_ks7022_device : public nes_nrom_device { public: // construction/destruction - nes_ks7022_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7022_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -67,7 +67,7 @@ class nes_ks7032_device : public nes_nrom_device { public: // construction/destruction - nes_ks7032_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -76,7 +76,7 @@ public: protected: // construction/destruction - nes_ks7032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_ks7032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -102,7 +102,7 @@ class nes_ks202_device : public nes_ks7032_device { public: // construction/destruction - nes_ks202_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -115,7 +115,7 @@ class nes_ks7016_device : public nes_nrom_device { public: // construction/destruction - nes_ks7016_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -124,7 +124,7 @@ public: protected: // construction/destruction - nes_ks7016_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 a15_flip); + nes_ks7016_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 a15_flip); // device-level overrides virtual void device_start() override; @@ -141,7 +141,7 @@ class nes_ks7016b_device : public nes_ks7016_device { public: // construction/destruction - nes_ks7016b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7016b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -151,7 +151,7 @@ class nes_ks7017_device : public nes_nrom_device { public: // construction/destruction - nes_ks7017_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7017_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_ex(offs_t offset) override; virtual void write_ex(offs_t offset, u8 data) override; @@ -182,7 +182,7 @@ class nes_ks7021a_device : public nes_nrom_device { public: // construction/destruction - nes_ks7021a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7021a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -196,7 +196,7 @@ class nes_ks7010_device : public nes_nrom_device { public: // construction/destruction - nes_ks7010_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual u8 read_h(offs_t offset) override; @@ -218,7 +218,7 @@ class nes_ks7012_device : public nes_nrom_device { public: // construction/destruction - nes_ks7012_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7012_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -232,7 +232,7 @@ class nes_ks7013b_device : public nes_nrom_device { public: // construction/destruction - nes_ks7013b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7013b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -247,7 +247,7 @@ class nes_ks7030_device : public nes_nrom_device { public: // construction/destruction - nes_ks7030_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual u8 read_h(offs_t offset) override; @@ -271,7 +271,7 @@ class nes_ks7031_device : public nes_nrom_device { public: // construction/destruction - nes_ks7031_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual u8 read_h(offs_t offset) override; @@ -294,7 +294,7 @@ class nes_ks7037_device : public nes_nrom_device { public: // construction/destruction - nes_ks7037_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7037_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual u8 read_h(offs_t offset) override; @@ -318,7 +318,7 @@ class nes_ks7057_device : public nes_nrom_device { public: // construction/destruction - nes_ks7057_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ks7057_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual u8 read_h(offs_t offset) override; diff --git a/src/devices/bus/nes/karastudio.cpp b/src/devices/bus/nes/karastudio.cpp index 3b8801bbf52..ce734a36183 100644 --- a/src/devices/bus/nes/karastudio.cpp +++ b/src/devices/bus/nes/karastudio.cpp @@ -70,7 +70,7 @@ uint8_t kstudio_cart_interface::read(offs_t offset) DEFINE_DEVICE_TYPE(NES_KSEXPANSION_SLOT, nes_kstudio_slot_device, "nes_ks_slot", "NES Karaoke Studio Expansion Slot") -nes_kstudio_slot_device::nes_kstudio_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_kstudio_slot_device::nes_kstudio_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_KSEXPANSION_SLOT, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_single_card_slot_interface<kstudio_cart_interface>(mconfig, *this) @@ -144,7 +144,7 @@ ROM_END DEFINE_DEVICE_TYPE(NES_KSEXPANSION_ROM, nes_kstudio_rom_device, "nes_ks_rom", "NES Karaoke Studio Expansion ROM") -nes_kstudio_rom_device::nes_kstudio_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_kstudio_rom_device::nes_kstudio_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_KSEXPANSION_ROM, tag, owner, clock) , kstudio_cart_interface( mconfig, *this ) { @@ -181,7 +181,7 @@ uint8_t *nes_kstudio_rom_device::get_cart_base() DEFINE_DEVICE_TYPE(NES_KARAOKESTUDIO, nes_karaokestudio_device, "nes_karaoke", "NES Cart Bandai Karaoke Studio PCB") -nes_karaokestudio_device::nes_karaokestudio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_karaokestudio_device::nes_karaokestudio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KARAOKESTUDIO, tag, owner, clock) , m_exp_active(0) , m_subslot(*this, "exp_slot") diff --git a/src/devices/bus/nes/karastudio.h b/src/devices/bus/nes/karastudio.h index 95ea9b14881..0b2219d7a96 100644 --- a/src/devices/bus/nes/karastudio.h +++ b/src/devices/bus/nes/karastudio.h @@ -51,7 +51,7 @@ public: // construction/destruction template <typename T> nes_kstudio_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts) - : nes_kstudio_slot_device(mconfig, tag, owner, (uint32_t)0) + : nes_kstudio_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -59,7 +59,7 @@ public: set_fixed(false); } - nes_kstudio_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_kstudio_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~nes_kstudio_slot_device(); // image-level overrides @@ -99,7 +99,7 @@ class nes_kstudio_rom_device : public device_t, { public: // construction/destruction - nes_kstudio_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_kstudio_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -127,7 +127,7 @@ class nes_karaokestudio_device : public nes_nrom_device { public: // construction/destruction - nes_karaokestudio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_karaokestudio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual uint8_t read_h(offs_t offset) override; diff --git a/src/devices/bus/nes/konami.cpp b/src/devices/bus/nes/konami.cpp index 64835930218..498c9cfcef9 100644 --- a/src/devices/bus/nes/konami.cpp +++ b/src/devices/bus/nes/konami.cpp @@ -45,42 +45,42 @@ DEFINE_DEVICE_TYPE(NES_VRC6, nes_konami_vrc6_device, "nes_vrc6", "NES Cart Konam DEFINE_DEVICE_TYPE(NES_VRC7, nes_konami_vrc7_device, "nes_vrc7", "NES Cart Konami VRC-7 PCB") -nes_konami_vrc1_device::nes_konami_vrc1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_konami_vrc1_device::nes_konami_vrc1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_VRC1, tag, owner, clock) { } -nes_konami_vrc2_device::nes_konami_vrc2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_konami_vrc2_device::nes_konami_vrc2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_latch(0) { } -nes_konami_vrc2_device::nes_konami_vrc2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_konami_vrc2_device::nes_konami_vrc2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc2_device(mconfig, NES_VRC2, tag, owner, clock) { } -nes_konami_vrc3_device::nes_konami_vrc3_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_konami_vrc3_device::nes_konami_vrc3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_VRC3, tag, owner, clock), m_irq_count(0), m_irq_count_latch(0), m_irq_enable(0), m_irq_enable_latch(0), m_irq_mode(0), irq_timer(nullptr) { } -nes_konami_vrc4_device::nes_konami_vrc4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_konami_vrc4_device::nes_konami_vrc4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_prg_flip(0), m_wram_enable(0), m_irq_count(0), m_irq_count_latch(0), m_irq_enable(0), m_irq_enable_latch(0), m_irq_mode(0), m_irq_prescale(0), irq_timer(nullptr) { } -nes_konami_vrc4_device::nes_konami_vrc4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_konami_vrc4_device::nes_konami_vrc4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_VRC4, tag, owner, clock) { } -nes_konami_vrc6_device::nes_konami_vrc6_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_konami_vrc6_device::nes_konami_vrc6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_VRC6, tag, owner, clock), m_vrc6snd(*this, "vrc6snd") { } -nes_konami_vrc7_device::nes_konami_vrc7_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_konami_vrc7_device::nes_konami_vrc7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_VRC7, tag, owner, clock), m_vrc7snd(*this, "vrc7snd") { } diff --git a/src/devices/bus/nes/konami.h b/src/devices/bus/nes/konami.h index ced0f7f4648..f7ec85929e2 100644 --- a/src/devices/bus/nes/konami.h +++ b/src/devices/bus/nes/konami.h @@ -16,7 +16,7 @@ class nes_konami_vrc1_device : public nes_nrom_device { public: // construction/destruction - nes_konami_vrc1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_konami_vrc1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -37,7 +37,7 @@ class nes_konami_vrc2_device : public nes_nrom_device { public: // construction/destruction - nes_konami_vrc2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_konami_vrc2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -47,7 +47,7 @@ public: protected: // construction/destruction - nes_konami_vrc2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_konami_vrc2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -64,7 +64,7 @@ class nes_konami_vrc3_device : public nes_nrom_device { public: // construction/destruction - nes_konami_vrc3_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_konami_vrc3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -91,7 +91,7 @@ class nes_konami_vrc4_device : public nes_nrom_device { public: // construction/destruction - nes_konami_vrc4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_konami_vrc4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -101,7 +101,7 @@ public: protected: // construction/destruction - nes_konami_vrc4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_konami_vrc4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -137,7 +137,7 @@ class nes_konami_vrc6_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_konami_vrc6_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_konami_vrc6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -156,7 +156,7 @@ class nes_konami_vrc7_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_konami_vrc7_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_konami_vrc7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/legacy.cpp b/src/devices/bus/nes/legacy.cpp index 8625c4fab97..12cc5178d45 100644 --- a/src/devices/bus/nes/legacy.cpp +++ b/src/devices/bus/nes/legacy.cpp @@ -37,22 +37,22 @@ DEFINE_DEVICE_TYPE(NES_FFE4, nes_ffe4_device, "nes_ff4", "NES Cart FFE-4 PCB") DEFINE_DEVICE_TYPE(NES_FFE8, nes_ffe8_device, "nes_ff8", "NES Cart FFE-8 PCB") -nes_ffe3_device::nes_ffe3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_ffe3_device::nes_ffe3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_FFE3, tag, owner, clock) { } -nes_ffe4_device::nes_ffe4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_ffe4_device::nes_ffe4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr), m_latch(0), m_exram_enabled(0), m_exram_bank(0) { } -nes_ffe4_device::nes_ffe4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_ffe4_device::nes_ffe4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ffe4_device(mconfig, NES_FFE4, tag, owner, clock) { } -nes_ffe8_device::nes_ffe8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_ffe8_device::nes_ffe8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_ffe4_device(mconfig, NES_FFE8, tag, owner, clock) { } diff --git a/src/devices/bus/nes/legacy.h b/src/devices/bus/nes/legacy.h index 191a718da45..be2b093f4f1 100644 --- a/src/devices/bus/nes/legacy.h +++ b/src/devices/bus/nes/legacy.h @@ -14,7 +14,7 @@ class nes_ffe3_device : public nes_nrom_device { public: // construction/destruction - nes_ffe3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_ffe3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -26,7 +26,7 @@ class nes_ffe4_device : public nes_nrom_device { public: // construction/destruction - nes_ffe4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_ffe4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; virtual void write_h(offs_t offset, uint8_t data) override; @@ -36,7 +36,7 @@ public: virtual void pcb_reset() override; protected: - nes_ffe4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_ffe4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -61,7 +61,7 @@ class nes_ffe8_device : public nes_ffe4_device { public: // construction/destruction - nes_ffe8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_ffe8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; virtual void write_h(offs_t offset, uint8_t data) override {} diff --git a/src/devices/bus/nes/mmc1.cpp b/src/devices/bus/nes/mmc1.cpp index 221b81e294e..722e879ceb2 100644 --- a/src/devices/bus/nes/mmc1.cpp +++ b/src/devices/bus/nes/mmc1.cpp @@ -45,22 +45,22 @@ DEFINE_DEVICE_TYPE(NES_SZROM, nes_szrom_device, "nes_szrom", "NES Cart SZROM (MM -nes_sxrom_device::nes_sxrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_sxrom_device::nes_sxrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_reg_write_enable(0), m_latch(0), m_count(0) { } -nes_sxrom_device::nes_sxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sxrom_device::nes_sxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_SXROM, tag, owner, clock) { } -nes_sorom_device::nes_sorom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sorom_device::nes_sorom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_SOROM, tag, owner, clock) { } -nes_szrom_device::nes_szrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_szrom_device::nes_szrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_SZROM, tag, owner, clock) { } diff --git a/src/devices/bus/nes/mmc1.h b/src/devices/bus/nes/mmc1.h index cdeee5056c6..665558997b0 100644 --- a/src/devices/bus/nes/mmc1.h +++ b/src/devices/bus/nes/mmc1.h @@ -14,7 +14,7 @@ class nes_sxrom_device : public nes_nrom_device { public: // construction/destruction - nes_sxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -23,7 +23,7 @@ public: virtual void pcb_reset() override; protected: - nes_sxrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_sxrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -53,7 +53,7 @@ class nes_sorom_device : public nes_sxrom_device { public: // construction/destruction - nes_sorom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sorom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -66,7 +66,7 @@ class nes_szrom_device : public nes_sxrom_device { public: // construction/destruction - nes_szrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_szrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/mmc1_clones.cpp b/src/devices/bus/nes/mmc1_clones.cpp index 58ee73330cd..c19ae14b802 100644 --- a/src/devices/bus/nes/mmc1_clones.cpp +++ b/src/devices/bus/nes/mmc1_clones.cpp @@ -37,37 +37,37 @@ DEFINE_DEVICE_TYPE(NES_SRPG_5IN1, nes_srpg5in1_device, "nes_srpg5in1", DEFINE_DEVICE_TYPE(NES_TXC_22110, nes_txc_22110_device, "nes_txc_22110", "NES Cart TXC 01-22110-000 PCB") -nes_bmc_jy012005_device::nes_bmc_jy012005_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_jy012005_device::nes_bmc_jy012005_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_BMC_JY012005, tag, owner, clock), m_latch0(0) { } -nes_bmc_jy820845c_device::nes_bmc_jy820845c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_jy820845c_device::nes_bmc_jy820845c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_BMC_JY820845C, tag, owner, clock), m_latch0(0), m_mode(0) { } -nes_farid_slrom_device::nes_farid_slrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_farid_slrom_device::nes_farid_slrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_FARID_SLROM, tag, owner, clock), m_outer(0) { } -nes_ninjaryu_device::nes_ninjaryu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ninjaryu_device::nes_ninjaryu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_NINJARYU, tag, owner, clock) { } -nes_resetsxrom_device::nes_resetsxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_resetsxrom_device::nes_resetsxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_RESETSXROM, tag, owner, clock), m_reset_count(-1) { } -nes_srpg5in1_device::nes_srpg5in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_srpg5in1_device::nes_srpg5in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_SRPG_5IN1, tag, owner, clock), m_outer(0), m_outer_count(0), m_outer_latch(0) { } -nes_txc_22110_device::nes_txc_22110_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_txc_22110_device::nes_txc_22110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sxrom_device(mconfig, NES_TXC_22110, tag, owner, clock), m_latch0(0), m_mode(0) { } diff --git a/src/devices/bus/nes/mmc1_clones.h b/src/devices/bus/nes/mmc1_clones.h index 993a0c1366d..35b4f1dfb2f 100644 --- a/src/devices/bus/nes/mmc1_clones.h +++ b/src/devices/bus/nes/mmc1_clones.h @@ -14,7 +14,7 @@ class nes_bmc_jy012005_device : public nes_sxrom_device { public: // construction/destruction - nes_bmc_jy012005_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_jy012005_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -38,7 +38,7 @@ class nes_bmc_jy820845c_device : public nes_sxrom_device { public: // construction/destruction - nes_bmc_jy820845c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_jy820845c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -64,7 +64,7 @@ class nes_farid_slrom_device : public nes_sxrom_device { public: // construction/destruction - nes_farid_slrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_farid_slrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -88,7 +88,7 @@ class nes_ninjaryu_device : public nes_sxrom_device { public: // construction/destruction - nes_ninjaryu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ninjaryu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -104,7 +104,7 @@ class nes_resetsxrom_device : public nes_sxrom_device { public: // construction/destruction - nes_resetsxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_resetsxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void pcb_reset() override; @@ -126,7 +126,7 @@ class nes_srpg5in1_device : public nes_sxrom_device { public: // construction/destruction - nes_srpg5in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_srpg5in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; @@ -152,7 +152,7 @@ class nes_txc_22110_device : public nes_sxrom_device { public: // construction/destruction - nes_txc_22110_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_txc_22110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/mmc2.cpp b/src/devices/bus/nes/mmc2.cpp index 02da59b7aad..4d2ab7556ca 100644 --- a/src/devices/bus/nes/mmc2.cpp +++ b/src/devices/bus/nes/mmc2.cpp @@ -32,17 +32,17 @@ DEFINE_DEVICE_TYPE(NES_PXROM, nes_pxrom_device, "nes_pxrom", "NES Cart PxROM (MM DEFINE_DEVICE_TYPE(NES_FXROM, nes_fxrom_device, "nes_fxrom", "NES Cart FxROM (MMC-2) PCB") -nes_pxrom_device::nes_pxrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_pxrom_device::nes_pxrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_latch1(0), m_latch2(0) { } -nes_pxrom_device::nes_pxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_pxrom_device::nes_pxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_pxrom_device(mconfig, NES_PXROM, tag, owner, clock) { } -nes_fxrom_device::nes_fxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_fxrom_device::nes_fxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_pxrom_device(mconfig, NES_FXROM, tag, owner, clock) { } diff --git a/src/devices/bus/nes/mmc2.h b/src/devices/bus/nes/mmc2.h index 1a6c8963826..4de5dc5d4a2 100644 --- a/src/devices/bus/nes/mmc2.h +++ b/src/devices/bus/nes/mmc2.h @@ -14,7 +14,7 @@ class nes_pxrom_device : public nes_nrom_device { public: // construction/destruction - nes_pxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_pxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void pxrom_write(offs_t offset, uint8_t data); virtual void write_h(offs_t offset, uint8_t data) override { pxrom_write(offset, data); } @@ -23,7 +23,7 @@ public: virtual void pcb_reset() override; protected: - nes_pxrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_pxrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -39,7 +39,7 @@ class nes_fxrom_device : public nes_pxrom_device { public: // construction/destruction - nes_fxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_fxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/nes/mmc3.cpp b/src/devices/bus/nes/mmc3.cpp index ff9774882fd..4a2201f84a0 100644 --- a/src/devices/bus/nes/mmc3.cpp +++ b/src/devices/bus/nes/mmc3.cpp @@ -51,48 +51,48 @@ DEFINE_DEVICE_TYPE(NES_QJ_PCB, nes_qj_device, "nes_qj", "NES Cart NES-QJ DEFINE_DEVICE_TYPE(NES_ZZ_PCB, nes_zz_device, "nes_zz", "NES Cart PAL-ZZ PCB") -nes_txrom_device::nes_txrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_txrom_device::nes_txrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_mmc_mirror(0), m_prg_base(0), m_prg_mask(0), m_chr_base(0), m_chr_mask(0) , m_latch(0), m_wram_protect(0), m_alt_irq(0), m_irq_count(0), m_irq_count_latch(0), m_irq_clear(0), m_irq_enable(0) { } -nes_txrom_device::nes_txrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_txrom_device::nes_txrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_TXROM, tag, owner, clock) { } -nes_hkrom_device::nes_hkrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_hkrom_device::nes_hkrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_HKROM, tag, owner, clock), m_wram_enable(0), m_mmc6_reg(0) { } -nes_txsrom_device::nes_txsrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_txsrom_device::nes_txsrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, type, tag, owner, clock) { } -nes_txsrom_device::nes_txsrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_txsrom_device::nes_txsrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txsrom_device(mconfig, NES_TXSROM, tag, owner, clock) { } -nes_tqrom_device::nes_tqrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_tqrom_device::nes_tqrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, type, tag, owner, clock) { } -nes_tqrom_device::nes_tqrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_tqrom_device::nes_tqrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_tqrom_device(mconfig, NES_TQROM, tag, owner, clock) { } -nes_qj_device::nes_qj_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_qj_device::nes_qj_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_QJ_PCB, tag, owner, clock) { } -nes_zz_device::nes_zz_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_zz_device::nes_zz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_ZZ_PCB, tag, owner, clock) { } diff --git a/src/devices/bus/nes/mmc3.h b/src/devices/bus/nes/mmc3.h index 1bc3cc0536c..fba36a9e2c7 100644 --- a/src/devices/bus/nes/mmc3.h +++ b/src/devices/bus/nes/mmc3.h @@ -14,7 +14,7 @@ class nes_txrom_device : public nes_nrom_device { public: // construction/destruction - nes_txrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_txrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_m(offs_t offset, uint8_t data) override; @@ -27,7 +27,7 @@ public: virtual void pcb_reset() override; protected: - nes_txrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_txrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { mmc3_start(); } @@ -61,7 +61,7 @@ class nes_hkrom_device : public nes_txrom_device { public: // construction/destruction - nes_hkrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_hkrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_m(offs_t offset, uint8_t data) override; @@ -87,13 +87,13 @@ class nes_txsrom_device : public nes_txrom_device { public: // construction/destruction - nes_txsrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_txsrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; protected: // construction/destruction - nes_txsrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_txsrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void set_chr(u8 chr, int chr_base, int chr_mask) override; }; @@ -105,13 +105,13 @@ class nes_tqrom_device : public nes_txrom_device { public: // construction/destruction - nes_tqrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_tqrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void chr_cb(int start, int bank, int source) override; protected: // construction/destruction - nes_tqrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_tqrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -121,7 +121,7 @@ class nes_qj_device : public nes_txrom_device { public: // construction/destruction - nes_qj_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_qj_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -135,7 +135,7 @@ class nes_zz_device : public nes_txrom_device { public: // construction/destruction - nes_zz_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_zz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/mmc3_clones.cpp b/src/devices/bus/nes/mmc3_clones.cpp index b74ec375e55..f8a9721e556 100644 --- a/src/devices/bus/nes/mmc3_clones.cpp +++ b/src/devices/bus/nes/mmc3_clones.cpp @@ -157,338 +157,338 @@ ioport_constructor nes_bmc_kc885_device::device_input_ports() const // LIVE DEVICE //************************************************************************** -nes_nitra_device::nes_nitra_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_nitra_device::nes_nitra_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_NITRA, tag, owner, clock) { } -nes_bmw8544_device::nes_bmw8544_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmw8544_device::nes_bmw8544_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMW8544, tag, owner, clock), m_reg(0) { } -nes_fs6_device::nes_fs6_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_fs6_device::nes_fs6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_FS6, tag, owner, clock) { } -nes_sbros11_device::nes_sbros11_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sbros11_device::nes_sbros11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_SBROS11, tag, owner, clock) { } -nes_malisb_device::nes_malisb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_malisb_device::nes_malisb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_MALISB, tag, owner, clock) { } -nes_family4646_device::nes_family4646_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_family4646_device::nes_family4646_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_FAMILY4646, tag, owner, clock) { } -nes_pikay2k_device::nes_pikay2k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_pikay2k_device::nes_pikay2k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_PIKAY2K, tag, owner, clock) { } -nes_8237_device::nes_8237_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 board) +nes_8237_device::nes_8237_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 board) : nes_txrom_device(mconfig, type, tag, owner, clock), m_board(board) { } -nes_8237_device::nes_8237_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_8237_device::nes_8237_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_8237_device(mconfig, NES_8237, tag, owner, clock, 0) { } -nes_8237a_device::nes_8237a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_8237a_device::nes_8237a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_8237_device(mconfig, NES_8237A, tag, owner, clock, 1) { } -nes_158b_device::nes_158b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_158b_device::nes_158b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_8237_device(mconfig, NES_158B, tag, owner, clock, 0) { } -nes_kasing_device::nes_kasing_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_kasing_device::nes_kasing_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, type, tag, owner, clock), m_mmc3_mode(true) { } -nes_kasing_device::nes_kasing_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_kasing_device::nes_kasing_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_kasing_device(mconfig, NES_KASING, tag, owner, clock) { } -nes_sglionk_device::nes_sglionk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 board) +nes_sglionk_device::nes_sglionk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 board) : nes_kasing_device(mconfig, type, tag, owner, clock), m_board(board) { } -nes_sglionk_device::nes_sglionk_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sglionk_device::nes_sglionk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sglionk_device(mconfig, NES_SG_LIONK, tag, owner, clock, 0) { } -nes_sgboog_device::nes_sgboog_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sgboog_device::nes_sgboog_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sglionk_device(mconfig, NES_SG_BOOG, tag, owner, clock, 1) { } -nes_kay_device::nes_kay_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_kay_device::nes_kay_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_KAY, tag, owner, clock), m_low_reg(0) { } -nes_h2288_device::nes_h2288_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_h2288_device::nes_h2288_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_H2288, tag, owner, clock), m_mmc3_mode(true) { } -nes_6035052_device::nes_6035052_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_6035052_device::nes_6035052_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_6035052, tag, owner, clock), m_prot(0) { } -nes_txc_tw_device::nes_txc_tw_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_txc_tw_device::nes_txc_tw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_TXC_TW, tag, owner, clock) { } -nes_kof97_device::nes_kof97_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_kof97_device::nes_kof97_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_KOF97, tag, owner, clock) { } -nes_kof96_device::nes_kof96_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_kof96_device::nes_kof96_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_KOF96, tag, owner, clock), m_mmc3_mode(true) { } -nes_sf3_device::nes_sf3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sf3_device::nes_sf3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_SF3, tag, owner, clock) { } -nes_cocoma_device::nes_cocoma_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_cocoma_device::nes_cocoma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_COCOMA, tag, owner, clock) { } -nes_gouder_device::nes_gouder_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_gouder_device::nes_gouder_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_GOUDER, tag, owner, clock) { } -nes_sa9602b_device::nes_sa9602b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sa9602b_device::nes_sa9602b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_SA9602B, tag, owner, clock), m_reg(0), m_prg_chip(0) { } -nes_sachen_shero_device::nes_sachen_shero_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sachen_shero_device::nes_sachen_shero_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_SACHEN_SHERO, tag, owner, clock) , m_jumper(*this, "JUMPER") , m_reg(0) { } -nes_sachen_zgdh_device::nes_sachen_zgdh_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sachen_zgdh_device::nes_sachen_zgdh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_SACHEN_ZGDH, tag, owner, clock), m_reg(0) { } -nes_a9746_device::nes_a9746_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_a9746_device::nes_a9746_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_A9746, tag, owner, clock) { } -nes_a88s1_device::nes_a88s1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_a88s1_device::nes_a88s1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_A88S1, tag, owner, clock) { } -nes_bmc_el86xc_device::nes_bmc_el86xc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_el86xc_device::nes_bmc_el86xc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_EL86XC, tag, owner, clock) { } -nes_fk23c_device::nes_fk23c_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_fk23c_device::nes_fk23c_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, type, tag, owner, clock), m_mmc_cmd1(0) { } -nes_fk23c_device::nes_fk23c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_fk23c_device::nes_fk23c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_fk23c_device(mconfig, NES_FK23C, tag, owner, clock) { } -nes_fk23ca_device::nes_fk23ca_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_fk23ca_device::nes_fk23ca_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_fk23c_device(mconfig, NES_FK23CA, tag, owner, clock) { } -nes_nt639_device::nes_nt639_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_nt639_device::nes_nt639_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_NT639, tag, owner, clock) { } -nes_resettxrom_device::nes_resettxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_resettxrom_device::nes_resettxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_RESETTXROM, tag, owner, clock), m_count(-1) { } -nes_s24in1sc03_device::nes_s24in1sc03_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_s24in1sc03_device::nes_s24in1sc03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_S24IN1SC03, tag, owner, clock) { } -nes_tech9in1_device::nes_tech9in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_tech9in1_device::nes_tech9in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_TECHLINE9IN1, tag, owner, clock) { } -nes_bmc_5in1_device::nes_bmc_5in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_5in1_device::nes_bmc_5in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_5IN1, tag, owner, clock) , m_jumper(*this, "JUMPER") { } -nes_bmc_8in1_device::nes_bmc_8in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_8in1_device::nes_bmc_8in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_8IN1, tag, owner, clock) { } -nes_bmc_15in1_device::nes_bmc_15in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_15in1_device::nes_bmc_15in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_15IN1, tag, owner, clock), m_jumper(0) { } -nes_bmc_sbig7_device::nes_bmc_sbig7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_bmc_sbig7_device::nes_bmc_sbig7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_SBIG7, tag, owner, clock) { } -nes_bmc_hik8_device::nes_bmc_hik8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_bmc_hik8_device::nes_bmc_hik8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, type, tag, owner, clock), m_count(0) { } -nes_bmc_hik8_device::nes_bmc_hik8_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_hik8_device::nes_bmc_hik8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_hik8_device(mconfig, NES_BMC_HIK8, tag, owner, clock) { } -nes_bmc_jy208_device::nes_bmc_jy208_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_jy208_device::nes_bmc_jy208_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_hik8_device(mconfig, NES_BMC_JY208, tag, owner, clock) { } -nes_bmc_jy302_device::nes_bmc_jy302_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_jy302_device::nes_bmc_jy302_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_hik8_device(mconfig, NES_BMC_JY302, tag, owner, clock) { } -nes_bmc_kc885_device::nes_bmc_kc885_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_kc885_device::nes_bmc_kc885_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_hik8_device(mconfig, NES_BMC_KC885, tag, owner, clock) , m_jumper(*this, "JUMPER") { } -nes_bmc_sfc12_device::nes_bmc_sfc12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_sfc12_device::nes_bmc_sfc12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_hik8_device(mconfig, NES_BMC_SFC12, tag, owner, clock) { } -nes_bmc_hik4_device::nes_bmc_hik4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_hik4_device::nes_bmc_hik4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_HIK4, tag, owner, clock), m_mmc3_mode(true) { } -nes_bmc_f15_device::nes_bmc_f15_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_f15_device::nes_bmc_f15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_F15, tag, owner, clock) { } -nes_bmc_f600_device::nes_bmc_f600_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_f600_device::nes_bmc_f600_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txsrom_device(mconfig, NES_BMC_F600, tag, owner, clock) , m_jumper(*this, "JUMPER") , m_reg(0) { } -nes_bmc_gn45_device::nes_bmc_gn45_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_gn45_device::nes_bmc_gn45_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_GN45, tag, owner, clock), m_lock(false) { } -nes_bmc_gold7in1_device::nes_bmc_gold7in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_gold7in1_device::nes_bmc_gold7in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_GOLD7IN1, tag, owner, clock), m_lock(false) { } -nes_bmc_k3006_device::nes_bmc_k3006_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_k3006_device::nes_bmc_k3006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_K3006, tag, owner, clock) { } -nes_bmc_k3033_device::nes_bmc_k3033_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_k3033_device::nes_bmc_k3033_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_K3033, tag, owner, clock), m_mmc3_mode(false) { } -nes_bmc_l6in1_device::nes_bmc_l6in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_l6in1_device::nes_bmc_l6in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_L6IN1, tag, owner, clock), m_reg(0) { } -nes_bmc_00202650_device::nes_bmc_00202650_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_00202650_device::nes_bmc_00202650_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_00202650, tag, owner, clock), m_mmc3_mode(false) { } -nes_bmc_411120c_device::nes_bmc_411120c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_411120c_device::nes_bmc_411120c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_411120C, tag, owner, clock), m_reg(0) { } -nes_bmc_810305c_device::nes_bmc_810305c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_810305c_device::nes_bmc_810305c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txsrom_device(mconfig, NES_BMC_810305C, tag, owner, clock), m_outer(0) { } -nes_bmc_820720c_device::nes_bmc_820720c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_820720c_device::nes_bmc_820720c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_820720C, tag, owner, clock), m_reg(0) { } -nes_bmc_830118c_device::nes_bmc_830118c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_830118c_device::nes_bmc_830118c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_830118C, tag, owner, clock) { } -nes_bmc_830832c_device::nes_bmc_830832c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_830832c_device::nes_bmc_830832c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_830832C, tag, owner, clock) { } -nes_bmc_yy841101c_device::nes_bmc_yy841101c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_yy841101c_device::nes_bmc_yy841101c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_YY841101C, tag, owner, clock) { } -nes_bmc_yy841155c_device::nes_bmc_yy841155c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_yy841155c_device::nes_bmc_yy841155c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_BMC_YY841155C, tag, owner, clock) { } -nes_pjoy84_device::nes_pjoy84_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_pjoy84_device::nes_pjoy84_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_PJOY84, tag, owner, clock) { } -nes_smd133_device::nes_smd133_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_smd133_device::nes_smd133_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_SMD133, tag, owner, clock) { } diff --git a/src/devices/bus/nes/mmc3_clones.h b/src/devices/bus/nes/mmc3_clones.h index 47f0d4cff5f..1f9d001d1a2 100644 --- a/src/devices/bus/nes/mmc3_clones.h +++ b/src/devices/bus/nes/mmc3_clones.h @@ -14,7 +14,7 @@ class nes_nitra_device : public nes_txrom_device { public: // construction/destruction - nes_nitra_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_nitra_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -26,7 +26,7 @@ class nes_bmw8544_device : public nes_txrom_device { public: // construction/destruction - nes_bmw8544_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmw8544_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -50,7 +50,7 @@ class nes_fs6_device : public nes_txrom_device { public: // construction/destruction - nes_fs6_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_fs6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -62,7 +62,7 @@ class nes_sbros11_device : public nes_txrom_device { public: // construction/destruction - nes_sbros11_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sbros11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -74,7 +74,7 @@ class nes_malisb_device : public nes_txrom_device { public: // construction/destruction - nes_malisb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_malisb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; virtual void prg_cb(int start, int bank) override; @@ -88,7 +88,7 @@ class nes_family4646_device : public nes_txrom_device { public: // construction/destruction - nes_family4646_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_family4646_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void prg_cb(int start, int bank) override; @@ -110,7 +110,7 @@ class nes_pikay2k_device : public nes_txrom_device { public: // construction/destruction - nes_pikay2k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_pikay2k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_m(offs_t offset, uint8_t data) override; @@ -133,7 +133,7 @@ class nes_8237_device : public nes_txrom_device { public: // construction/destruction - nes_8237_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_8237_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -143,7 +143,7 @@ public: protected: // construction/destruction - nes_8237_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 board); + nes_8237_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 board); // device-level overrides virtual void device_start() override; @@ -161,7 +161,7 @@ class nes_8237a_device : public nes_8237_device { public: // construction/destruction - nes_8237a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_8237a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -171,7 +171,7 @@ class nes_158b_device : public nes_8237_device { public: // construction/destruction - nes_158b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_158b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; @@ -193,7 +193,7 @@ class nes_kasing_device : public nes_txrom_device { public: // construction/destruction - nes_kasing_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_kasing_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void prg_cb(int start, int bank) override; @@ -202,7 +202,7 @@ public: protected: // construction/destruction - nes_kasing_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_kasing_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -218,13 +218,13 @@ class nes_sglionk_device : public nes_kasing_device { public: // construction/destruction - nes_sglionk_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sglionk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; protected: // construction/destruction - nes_sglionk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 board); + nes_sglionk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 board); private: const u8 m_board; @@ -237,7 +237,7 @@ class nes_sgboog_device : public nes_sglionk_device { public: // construction/destruction - nes_sgboog_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sgboog_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -247,7 +247,7 @@ class nes_kay_device : public nes_txrom_device { public: // construction/destruction - nes_kay_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_kay_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; @@ -274,7 +274,7 @@ class nes_h2288_device : public nes_txrom_device { public: // construction/destruction - nes_h2288_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_h2288_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // FIXME: This is a hack and should be removed once open bus behavior is properly working. UMK3 depends on an open bus read (F51F: lda $5f74) at bootup. virtual u8 read_l(offs_t offset) override { return 0x5f; } @@ -300,7 +300,7 @@ class nes_6035052_device : public nes_txrom_device { public: // construction/destruction - nes_6035052_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_6035052_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_ex(offs_t offset) override; virtual void write_ex(offs_t offset, uint8_t data) override; @@ -326,7 +326,7 @@ class nes_txc_tw_device : public nes_txrom_device { public: // construction/destruction - nes_txc_tw_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_txc_tw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; virtual void write_m(offs_t offset, uint8_t data) override { write_l(offset & 0xff, data); } // offset does not really count for this mapper } @@ -340,7 +340,7 @@ class nes_kof97_device : public nes_txrom_device { public: // construction/destruction - nes_kof97_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_kof97_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -352,7 +352,7 @@ class nes_kof96_device : public nes_txrom_device { public: // construction/destruction - nes_kof96_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_kof96_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; @@ -376,7 +376,7 @@ class nes_sf3_device : public nes_txrom_device { public: // construction/destruction - nes_sf3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sf3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -391,7 +391,7 @@ class nes_cocoma_device : public nes_txrom_device { public: // construction/destruction - nes_cocoma_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_cocoma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -405,7 +405,7 @@ class nes_gouder_device : public nes_txrom_device { public: // construction/destruction - nes_gouder_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_gouder_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual void write_l(offs_t offset, uint8_t data) override; @@ -428,7 +428,7 @@ class nes_sa9602b_device : public nes_txrom_device { public: // construction/destruction - nes_sa9602b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sa9602b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; virtual void prg_cb(int start, int bank) override; @@ -451,7 +451,7 @@ class nes_sachen_shero_device : public nes_txrom_device { public: // construction/destruction - nes_sachen_shero_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sachen_shero_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; @@ -475,7 +475,7 @@ class nes_sachen_zgdh_device : public nes_txrom_device { public: // construction/destruction - nes_sachen_zgdh_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sachen_zgdh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; virtual u8 nt_r(offs_t offset) override; @@ -499,7 +499,7 @@ class nes_a9746_device : public nes_txrom_device { public: // construction/destruction - nes_a9746_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_a9746_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -521,7 +521,7 @@ class nes_a88s1_device : public nes_txrom_device { public: // construction/destruction - nes_a88s1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_a88s1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; virtual void prg_cb(int start, int bank) override; @@ -544,7 +544,7 @@ class nes_bmc_el86xc_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_el86xc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_el86xc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -558,7 +558,7 @@ class nes_fk23c_device : public nes_txrom_device { public: // construction/destruction - nes_fk23c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_fk23c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; virtual void write_h(offs_t offset, uint8_t data) override; @@ -568,7 +568,7 @@ public: virtual void pcb_reset() override; protected: - nes_fk23c_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_fk23c_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -586,7 +586,7 @@ class nes_fk23ca_device : public nes_fk23c_device { public: // construction/destruction - nes_fk23ca_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_fk23ca_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void pcb_reset() override; }; @@ -598,7 +598,7 @@ class nes_nt639_device : public nes_txrom_device { public: // construction/destruction - nes_nt639_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_nt639_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -612,7 +612,7 @@ class nes_resettxrom_device : public nes_txrom_device { public: // construction/destruction - nes_resettxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_resettxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void pcb_reset() override; @@ -631,7 +631,7 @@ class nes_s24in1sc03_device : public nes_txrom_device { public: // construction/destruction - nes_s24in1sc03_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_s24in1sc03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; virtual void prg_cb(int start, int bank) override; @@ -654,7 +654,7 @@ class nes_tech9in1_device : public nes_txrom_device { public: // construction/destruction - nes_tech9in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_tech9in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; @@ -676,7 +676,7 @@ class nes_bmc_5in1_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_5in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_5in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -698,7 +698,7 @@ class nes_bmc_8in1_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_8in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_8in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -712,7 +712,7 @@ class nes_bmc_15in1_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_15in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_15in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -729,7 +729,7 @@ class nes_bmc_sbig7_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_sbig7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_bmc_sbig7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -743,7 +743,7 @@ class nes_bmc_hik8_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_hik8_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_hik8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -751,7 +751,7 @@ public: protected: // construction/destruction - nes_bmc_hik8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_bmc_hik8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -767,7 +767,7 @@ class nes_bmc_jy208_device : public nes_bmc_hik8_device { public: // construction/destruction - nes_bmc_jy208_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_jy208_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -782,7 +782,7 @@ class nes_bmc_jy302_device : public nes_bmc_hik8_device { public: // construction/destruction - nes_bmc_jy302_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_jy302_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void set_chr(u8 chr, int chr_base, int chr_mask) override; @@ -795,7 +795,7 @@ class nes_bmc_kc885_device : public nes_bmc_hik8_device { public: // construction/destruction - nes_bmc_kc885_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_kc885_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -817,7 +817,7 @@ class nes_bmc_sfc12_device : public nes_bmc_hik8_device { public: // construction/destruction - nes_bmc_sfc12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_sfc12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void set_chr(u8 chr, int chr_base, int chr_mask) override; @@ -830,7 +830,7 @@ class nes_bmc_hik4_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_hik4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_hik4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void prg_cb(int start, int bank) override; @@ -852,7 +852,7 @@ class nes_bmc_f15_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_f15_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_f15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void prg_cb(int start, int bank) override; @@ -867,7 +867,7 @@ class nes_bmc_f600_device : public nes_txsrom_device { public: // construction/destruction - nes_bmc_f600_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_f600_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; @@ -894,7 +894,7 @@ class nes_bmc_gn45_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_gn45_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_gn45_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -915,7 +915,7 @@ class nes_bmc_gold7in1_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_gold7in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_gold7in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -936,7 +936,7 @@ class nes_bmc_k3006_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_k3006_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_k3006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -950,7 +950,7 @@ class nes_bmc_k3033_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_k3033_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_k3033_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void prg_cb(int start, int bank) override; @@ -972,7 +972,7 @@ class nes_bmc_l6in1_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_l6in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_l6in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -997,7 +997,7 @@ class nes_bmc_00202650_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_00202650_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_00202650_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -1021,7 +1021,7 @@ class nes_bmc_411120c_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_411120c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_411120c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void prg_cb(int start, int bank) override; @@ -1043,7 +1043,7 @@ class nes_bmc_810305c_device : public nes_txsrom_device { public: // construction/destruction - nes_bmc_810305c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_810305c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -1067,7 +1067,7 @@ class nes_bmc_820720c_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_820720c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_820720c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -1092,7 +1092,7 @@ class nes_bmc_830118c_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_830118c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_830118c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void prg_cb(int start, int bank) override; @@ -1107,7 +1107,7 @@ class nes_bmc_830832c_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_830832c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_830832c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -1121,7 +1121,7 @@ class nes_bmc_yy841101c_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_yy841101c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_yy841101c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -1135,7 +1135,7 @@ class nes_bmc_yy841155c_device : public nes_txrom_device { public: // construction/destruction - nes_bmc_yy841155c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_yy841155c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -1156,7 +1156,7 @@ class nes_pjoy84_device : public nes_txrom_device { public: // construction/destruction - nes_pjoy84_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_pjoy84_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, uint8_t data) override; virtual void prg_cb(int start, int bank) override; @@ -1180,7 +1180,7 @@ class nes_smd133_device : public nes_txrom_device { public: // construction/destruction - nes_smd133_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_smd133_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; virtual void write_m(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/mmc5.cpp b/src/devices/bus/nes/mmc5.cpp index f15b1a7658b..a2ae5b61f87 100644 --- a/src/devices/bus/nes/mmc5.cpp +++ b/src/devices/bus/nes/mmc5.cpp @@ -41,7 +41,7 @@ static const int m_mmc5_attrib[4] = {0x00, 0x55, 0xaa, 0xff}; DEFINE_DEVICE_TYPE(NES_EXROM, nes_exrom_device, "nes_exrom", "NES Cart ExROM (MMC-5) PCB") -nes_exrom_device::nes_exrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_exrom_device::nes_exrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_EXROM, tag, owner, clock), m_irq_count(0) , m_irq_status(0), m_irq_enable(0), m_mult1(0), m_mult2(0), m_mmc5_scanline(0), m_vrom_page_a(0), m_vrom_page_b(0), m_floodtile(0), m_floodattr(0) , m_prg_mode(0), m_chr_mode(0), m_wram_protect_1(0), m_wram_protect_2(0), m_exram_control(0), m_wram_base(0), m_last_chr(0), m_ex1_chr(0) diff --git a/src/devices/bus/nes/mmc5.h b/src/devices/bus/nes/mmc5.h index a806c704883..1bdd4eaebe5 100644 --- a/src/devices/bus/nes/mmc5.h +++ b/src/devices/bus/nes/mmc5.h @@ -17,7 +17,7 @@ class nes_exrom_device : public nes_nrom_device { public: // construction/destruction - nes_exrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_exrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~nes_exrom_device(); virtual uint8_t read_l(offs_t offset) override; diff --git a/src/devices/bus/nes/multigame.cpp b/src/devices/bus/nes/multigame.cpp index 2e13e22a73e..8e2c0c13078 100644 --- a/src/devices/bus/nes/multigame.cpp +++ b/src/devices/bus/nes/multigame.cpp @@ -130,404 +130,404 @@ ioport_constructor nes_bmc_8157_device::device_input_ports() const // LIVE DEVICE //************************************************************************** -nes_action52_device::nes_action52_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_action52_device::nes_action52_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_ACTION52, tag, owner, clock) { } -nes_caltron6in1_device::nes_caltron6in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_caltron6in1_device::nes_caltron6in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_CALTRON6IN1, tag, owner, clock), m_latch(0), m_reg(0) { } -nes_caltron9in1_device::nes_caltron9in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_caltron9in1_device::nes_caltron9in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_CALTRON9IN1, tag, owner, clock) { } -nes_rumblestat_device::nes_rumblestat_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_rumblestat_device::nes_rumblestat_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_RUMBLESTATION, tag, owner, clock), m_prg(0), m_chr(0) { } -nes_svision16_device::nes_svision16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_svision16_device::nes_svision16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SVISION16, tag, owner, clock), m_latch1(0), m_latch2(0) { } -nes_farid_unrom_device::nes_farid_unrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_farid_unrom_device::nes_farid_unrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_FARID_UNROM, tag, owner, clock), m_reg(0) { } -nes_kn42_device::nes_kn42_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_kn42_device::nes_kn42_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_KN42, tag, owner, clock), m_latch(0) { } -nes_a65as_device::nes_a65as_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_a65as_device::nes_a65as_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_A65AS, tag, owner, clock) { } -nes_t262_device::nes_t262_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_t262_device::nes_t262_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_T262, tag, owner, clock), m_latch(0) { } -nes_studyngame_device::nes_studyngame_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_studyngame_device::nes_studyngame_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_STUDYNGAME, tag, owner, clock) { } -nes_sgun20in1_device::nes_sgun20in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_sgun20in1_device::nes_sgun20in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock) { } -nes_sgun20in1_device::nes_sgun20in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sgun20in1_device::nes_sgun20in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sgun20in1_device(mconfig, NES_SUPERGUN20IN1, tag, owner, clock) { } -nes_bmc_190in1_device::nes_bmc_190in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_190in1_device::nes_bmc_190in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sgun20in1_device(mconfig, NES_BMC_190IN1, tag, owner, clock) { } -nes_vt5201_device::nes_vt5201_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_vt5201_device::nes_vt5201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_VT5201, tag, owner, clock), m_latch(0), m_jumper(0) { } -nes_bmc_80013b_device::nes_bmc_80013b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_80013b_device::nes_bmc_80013b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_80013B, tag, owner, clock), m_latch(0) { } -nes_bmc_810544c_device::nes_bmc_810544c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_810544c_device::nes_bmc_810544c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_810544C, tag, owner, clock) { } -nes_bmc_830425c_device::nes_bmc_830425c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_830425c_device::nes_bmc_830425c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_830425C, tag, owner, clock), m_latch(0) { } -nes_bmc_830928c_device::nes_bmc_830928c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_830928c_device::nes_bmc_830928c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_830928C, tag, owner, clock), m_latch(0) { } -nes_bmc_850437c_device::nes_bmc_850437c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_850437c_device::nes_bmc_850437c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_850437C, tag, owner, clock) { } -nes_bmc_970630c_device::nes_bmc_970630c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_970630c_device::nes_bmc_970630c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_970630C, tag, owner, clock), m_latch(0) { } -nes_ntd03_device::nes_ntd03_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ntd03_device::nes_ntd03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NTD03, tag, owner, clock) { } -nes_bmc_ctc09_device::nes_bmc_ctc09_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_ctc09_device::nes_bmc_ctc09_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_CTC09, tag, owner, clock) { } -nes_bmc_ds927_device::nes_bmc_ds927_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_ds927_device::nes_bmc_ds927_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_DS927, tag, owner, clock), m_latch(0), m_mode(0) { } -nes_bmc_gka_device::nes_bmc_gka_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_gka_device::nes_bmc_gka_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_GKA, tag, owner, clock) { } -nes_bmc_gkb_device::nes_bmc_gkb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_gkb_device::nes_bmc_gkb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_GKB, tag, owner, clock) { } -nes_bmc_gkcxin1_device::nes_bmc_gkcxin1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_gkcxin1_device::nes_bmc_gkcxin1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_GKCXIN1, tag, owner, clock) { } -nes_bmc_gn91b_device::nes_bmc_gn91b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_gn91b_device::nes_bmc_gn91b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_GN91B, tag, owner, clock), m_latch(0) { } -nes_bmc_hp898f_device::nes_bmc_hp898f_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_hp898f_device::nes_bmc_hp898f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_HP898F, tag, owner, clock) { } -nes_bmc_k3036_device::nes_bmc_k3036_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_k3036_device::nes_bmc_k3036_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_K3036, tag, owner, clock) { } -nes_bmc_k3046_device::nes_bmc_k3046_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_k3046_device::nes_bmc_k3046_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_K3046, tag, owner, clock) { } -nes_bmc_k3071_device::nes_bmc_k3071_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_k3071_device::nes_bmc_k3071_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_K3071, tag, owner, clock) { } -nes_bmc_s009_device::nes_bmc_s009_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_s009_device::nes_bmc_s009_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_S009, tag, owner, clock), m_reg(0) { } -nes_bmc_sa005a_device::nes_bmc_sa005a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_sa005a_device::nes_bmc_sa005a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_SA005A, tag, owner, clock) { } -nes_bmc_tf2740_device::nes_bmc_tf2740_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_tf2740_device::nes_bmc_tf2740_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_TF2740, tag, owner, clock), m_jumper(0) { } -nes_bmc_th2348_device::nes_bmc_th2348_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_th2348_device::nes_bmc_th2348_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_TH2348, tag, owner, clock), m_latch(0) { } -nes_bmc_tj03_device::nes_bmc_tj03_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_tj03_device::nes_bmc_tj03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_TJ03, tag, owner, clock) { } -nes_bmc_ws_device::nes_bmc_ws_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_bmc_ws_device::nes_bmc_ws_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_WS, tag, owner, clock), m_latch(0) { } -nes_bmc_11160_device::nes_bmc_11160_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_11160_device::nes_bmc_11160_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_11160, tag, owner, clock) { } -nes_bmc_g146_device::nes_bmc_g146_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_g146_device::nes_bmc_g146_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_G146, tag, owner, clock) { } -nes_bmc_2751_device::nes_bmc_2751_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_2751_device::nes_bmc_2751_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_2751, tag, owner, clock) { } -nes_bmc_8157_device::nes_bmc_8157_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_8157_device::nes_bmc_8157_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_8157, tag, owner, clock) , m_jumper(*this, "JUMPER") , m_latch(0) { } -nes_bmc_hik300_device::nes_bmc_hik300_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_hik300_device::nes_bmc_hik300_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_HIK300, tag, owner, clock) { } -nes_bmc_s700_device::nes_bmc_s700_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_s700_device::nes_bmc_s700_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_S700, tag, owner, clock) { } -nes_bmc_ball11_device::nes_bmc_ball11_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_ball11_device::nes_bmc_ball11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_BALL11, tag, owner, clock) { } -nes_bmc_22games_device::nes_bmc_22games_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_22games_device::nes_bmc_22games_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_22GAMES, tag, owner, clock), m_latch(0), m_reset(0) { } -nes_bmc_64y2k_device::nes_bmc_64y2k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_64y2k_device::nes_bmc_64y2k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_64Y2K, tag, owner, clock), m_reg_mask(0) { } -nes_bmc_420y2k_device::nes_bmc_420y2k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_420y2k_device::nes_bmc_420y2k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_420Y2K, tag, owner, clock), m_latch(0), m_reg(0) { } -nes_bmc_12in1_device::nes_bmc_12in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_12in1_device::nes_bmc_12in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_12IN1, tag, owner, clock) { } -nes_bmc_20in1_device::nes_bmc_20in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_20in1_device::nes_bmc_20in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_20IN1, tag, owner, clock) { } -nes_bmc_21in1_device::nes_bmc_21in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_21in1_device::nes_bmc_21in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_21IN1, tag, owner, clock) { } -nes_bmc_31in1_device::nes_bmc_31in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_31in1_device::nes_bmc_31in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_31IN1, tag, owner, clock) { } -nes_bmc_35in1_device::nes_bmc_35in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_bmc_35in1_device::nes_bmc_35in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_35IN1, tag, owner, clock) { } -nes_bmc_36in1_device::nes_bmc_36in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_bmc_36in1_device::nes_bmc_36in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_36IN1, tag, owner, clock) { } -nes_bmc_64in1_device::nes_bmc_64in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_bmc_64in1_device::nes_bmc_64in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_64IN1, tag, owner, clock) { } -nes_bmc_70in1_device::nes_bmc_70in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_bmc_70in1_device::nes_bmc_70in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_jumper(type == NES_BMC_70IN1 ? 0x0d : 0x06) { } -nes_bmc_70in1_device::nes_bmc_70in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_70in1_device::nes_bmc_70in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_70in1_device(mconfig, NES_BMC_70IN1, tag, owner, clock) { } -nes_bmc_800in1_device::nes_bmc_800in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_800in1_device::nes_bmc_800in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_70in1_device(mconfig, NES_BMC_800IN1, tag, owner, clock) { } -nes_bmc_72in1_device::nes_bmc_72in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_72in1_device::nes_bmc_72in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_72IN1, tag, owner, clock) { } -nes_bmc_76in1_device::nes_bmc_76in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_76in1_device::nes_bmc_76in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_76IN1, tag, owner, clock) { } -nes_bmc_150in1_device::nes_bmc_150in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_150in1_device::nes_bmc_150in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_150IN1, tag, owner, clock) { } -nes_bmc_500in1_device::nes_bmc_500in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_500in1_device::nes_bmc_500in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_500IN1, tag, owner, clock) { } -nes_bmc_1200in1_device::nes_bmc_1200in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_bmc_1200in1_device::nes_bmc_1200in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_1200IN1, tag, owner, clock), m_vram_protect(0) { } -nes_bmc_gold260_device::nes_bmc_gold260_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_gold260_device::nes_bmc_gold260_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_GOLD260, tag, owner, clock) { } -nes_bmc_4in1reset_device::nes_bmc_4in1reset_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_4in1reset_device::nes_bmc_4in1reset_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_4IN1RESET, tag, owner, clock), m_latch(0) { } -nes_bmc_42in1reset_device::nes_bmc_42in1reset_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 mirror_flip) +nes_bmc_42in1reset_device::nes_bmc_42in1reset_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 mirror_flip) : nes_nrom_device(mconfig, type, tag, owner, clock), m_latch(0), m_mirror_flip(mirror_flip) { } -nes_bmc_42in1reset_device::nes_bmc_42in1reset_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_42in1reset_device::nes_bmc_42in1reset_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_42in1reset_device(mconfig, NES_BMC_42IN1RESET, tag, owner, clock, 0) { } -nes_bmc_nc20mb_device::nes_bmc_nc20mb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_nc20mb_device::nes_bmc_nc20mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_42in1reset_device(mconfig, NES_BMC_NC20MB, tag, owner, clock, 1) { } -nes_bmc_lc160_device::nes_bmc_lc160_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_lc160_device::nes_bmc_lc160_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BMC_LC160, tag, owner, clock) { } -nes_vram_protect_device::nes_vram_protect_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_vram_protect_device::nes_vram_protect_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_vram_protect(false) { } -nes_bmc_60311c_device::nes_bmc_60311c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_60311c_device::nes_bmc_60311c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_vram_protect_device(mconfig, NES_BMC_60311C, tag, owner, clock) { } -nes_bmc_ctc12in1_device::nes_bmc_ctc12in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_bmc_ctc12in1_device::nes_bmc_ctc12in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_vram_protect_device(mconfig, type, tag, owner, clock) { } -nes_bmc_ctc12in1_device::nes_bmc_ctc12in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_ctc12in1_device::nes_bmc_ctc12in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_ctc12in1_device(mconfig, NES_BMC_CTC12IN1, tag, owner, clock) { } -nes_bmc_891227_device::nes_bmc_891227_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_891227_device::nes_bmc_891227_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_ctc12in1_device(mconfig, NES_BMC_891227, tag, owner, clock) { } -nes_bmc_k1029_device::nes_bmc_k1029_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_bmc_k1029_device::nes_bmc_k1029_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_vram_protect_device(mconfig, type, tag, owner, clock) { } -nes_bmc_k1029_device::nes_bmc_k1029_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_k1029_device::nes_bmc_k1029_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_k1029_device(mconfig, NES_BMC_K1029, tag, owner, clock) { } -nes_bmc_fam250_device::nes_bmc_fam250_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_fam250_device::nes_bmc_fam250_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_k1029_device(mconfig, NES_BMC_FAM250, tag, owner, clock), m_latch(0), m_reg(0) { } -nes_n625092_device::nes_n625092_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_n625092_device::nes_n625092_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_vram_protect_device(mconfig, NES_N625092, tag, owner, clock) { } -nes_bmc_th22913_device::nes_bmc_th22913_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 vram_prot_bit) +nes_bmc_th22913_device::nes_bmc_th22913_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 vram_prot_bit) : nes_vram_protect_device(mconfig, type, tag, owner, clock), m_vram_prot_bit(vram_prot_bit) { } -nes_bmc_th22913_device::nes_bmc_th22913_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_th22913_device::nes_bmc_th22913_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_th22913_device(mconfig, NES_BMC_TH22913, tag, owner, clock, 10) { } -nes_bmc_82ab_device::nes_bmc_82ab_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_82ab_device::nes_bmc_82ab_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_bmc_th22913_device(mconfig, NES_BMC_82AB, tag, owner, clock, 9) { } diff --git a/src/devices/bus/nes/multigame.h b/src/devices/bus/nes/multigame.h index e7c401ee3ab..3612691eeb8 100644 --- a/src/devices/bus/nes/multigame.h +++ b/src/devices/bus/nes/multigame.h @@ -14,7 +14,7 @@ class nes_action52_device : public nes_nrom_device { public: // construction/destruction - nes_action52_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_action52_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -26,7 +26,7 @@ class nes_caltron6in1_device : public nes_nrom_device { public: // construction/destruction - nes_caltron6in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_caltron6in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -49,7 +49,7 @@ class nes_caltron9in1_device : public nes_nrom_device { public: // construction/destruction - nes_caltron9in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_caltron9in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -70,7 +70,7 @@ class nes_rumblestat_device : public nes_nrom_device { public: // construction/destruction - nes_rumblestat_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_rumblestat_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, uint8_t data) override; virtual void write_h(offs_t offset, uint8_t data) override; @@ -92,7 +92,7 @@ class nes_svision16_device : public nes_nrom_device { public: // construction/destruction - nes_svision16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_svision16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -116,7 +116,7 @@ class nes_farid_unrom_device : public nes_nrom_device { public: // construction/destruction - nes_farid_unrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_farid_unrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -137,7 +137,7 @@ class nes_kn42_device : public nes_nrom_device { public: // construction/destruction - nes_kn42_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_kn42_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -158,7 +158,7 @@ class nes_a65as_device : public nes_nrom_device { public: // construction/destruction - nes_a65as_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_a65as_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -172,7 +172,7 @@ class nes_t262_device : public nes_nrom_device { public: // construction/destruction - nes_t262_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_t262_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -193,7 +193,7 @@ class nes_studyngame_device : public nes_nrom_device { public: // construction/destruction - nes_studyngame_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_studyngame_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -205,14 +205,14 @@ class nes_sgun20in1_device : public nes_nrom_device { public: // construction/destruction - nes_sgun20in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sgun20in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; virtual void pcb_reset() override; protected: - nes_sgun20in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_sgun20in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -222,7 +222,7 @@ class nes_bmc_190in1_device : public nes_sgun20in1_device { public: // construction/destruction - nes_bmc_190in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_190in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -234,7 +234,7 @@ class nes_vt5201_device : public nes_nrom_device { public: // construction/destruction - nes_vt5201_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_vt5201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -256,7 +256,7 @@ class nes_bmc_80013b_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_80013b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_80013b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -278,7 +278,7 @@ class nes_bmc_810544c_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_810544c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_810544c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -292,7 +292,7 @@ class nes_bmc_830425c_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_830425c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_830425c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -313,7 +313,7 @@ class nes_bmc_830928c_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_830928c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_830928c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -334,7 +334,7 @@ class nes_bmc_850437c_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_850437c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_850437c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -355,7 +355,7 @@ class nes_bmc_970630c_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_970630c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_970630c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -377,7 +377,7 @@ class nes_ntd03_device : public nes_nrom_device { public: // construction/destruction - nes_ntd03_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ntd03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -389,7 +389,7 @@ class nes_bmc_ctc09_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_ctc09_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_ctc09_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -403,7 +403,7 @@ class nes_bmc_ds927_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_ds927_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_ds927_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -425,7 +425,7 @@ class nes_bmc_gka_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_gka_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_gka_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -447,7 +447,7 @@ class nes_bmc_gkb_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_gkb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_gkb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -459,7 +459,7 @@ class nes_bmc_gkcxin1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_gkcxin1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_gkcxin1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -471,7 +471,7 @@ class nes_bmc_gn91b_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_gn91b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_gn91b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -492,7 +492,7 @@ class nes_bmc_hp898f_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_hp898f_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_hp898f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -505,7 +505,7 @@ class nes_bmc_k3036_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_k3036_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_k3036_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -519,7 +519,7 @@ class nes_bmc_k3046_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_k3046_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_k3046_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -533,7 +533,7 @@ class nes_bmc_k3071_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_k3071_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_k3071_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -547,7 +547,7 @@ class nes_bmc_s009_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_s009_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_s009_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -569,7 +569,7 @@ class nes_bmc_sa005a_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_sa005a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_sa005a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -583,7 +583,7 @@ class nes_bmc_tf2740_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_tf2740_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_tf2740_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -608,7 +608,7 @@ class nes_bmc_th2348_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_th2348_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_th2348_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -630,7 +630,7 @@ class nes_bmc_tj03_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_tj03_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_tj03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -642,7 +642,7 @@ class nes_bmc_ws_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_ws_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_bmc_ws_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, uint8_t data) override; @@ -663,7 +663,7 @@ class nes_bmc_11160_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_11160_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_11160_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -675,7 +675,7 @@ class nes_bmc_g146_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_g146_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_g146_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -687,7 +687,7 @@ class nes_bmc_2751_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_2751_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_2751_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -702,7 +702,7 @@ class nes_bmc_8157_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_8157_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_8157_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -726,7 +726,7 @@ class nes_bmc_hik300_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_hik300_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_hik300_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -741,7 +741,7 @@ class nes_bmc_s700_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_s700_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_s700_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -753,7 +753,7 @@ class nes_bmc_ball11_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_ball11_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_ball11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -777,7 +777,7 @@ class nes_bmc_22games_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_22games_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_22games_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -798,7 +798,7 @@ class nes_bmc_64y2k_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_64y2k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_64y2k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -822,7 +822,7 @@ class nes_bmc_420y2k_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_420y2k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_420y2k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -844,7 +844,7 @@ class nes_bmc_12in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_12in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_12in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -866,7 +866,7 @@ class nes_bmc_20in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_20in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_20in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -878,7 +878,7 @@ class nes_bmc_21in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_21in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_21in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -890,7 +890,7 @@ class nes_bmc_31in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_31in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_31in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -902,7 +902,7 @@ class nes_bmc_35in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_35in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_bmc_35in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -916,7 +916,7 @@ class nes_bmc_36in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_36in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_bmc_36in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -930,7 +930,7 @@ class nes_bmc_64in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_64in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_bmc_64in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -944,7 +944,7 @@ class nes_bmc_70in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_70in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_70in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -953,7 +953,7 @@ public: protected: // construction/destruction - nes_bmc_70in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_bmc_70in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -974,7 +974,7 @@ class nes_bmc_800in1_device : public nes_bmc_70in1_device { public: // construction/destruction - nes_bmc_800in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_800in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void update_banks() override; @@ -987,7 +987,7 @@ class nes_bmc_72in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_72in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_72in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; @@ -1010,7 +1010,7 @@ class nes_bmc_76in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_76in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_76in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -1031,7 +1031,7 @@ class nes_bmc_150in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_150in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_150in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -1045,7 +1045,7 @@ class nes_bmc_500in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_500in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_500in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -1057,7 +1057,7 @@ class nes_bmc_1200in1_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_1200in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_bmc_1200in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; virtual void chr_w(offs_t offset, uint8_t data) override; @@ -1079,7 +1079,7 @@ class nes_bmc_gold260_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_gold260_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_gold260_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -1091,7 +1091,7 @@ class nes_bmc_4in1reset_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_4in1reset_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_4in1reset_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void pcb_reset() override; @@ -1110,7 +1110,7 @@ class nes_bmc_42in1reset_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_42in1reset_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_42in1reset_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -1118,7 +1118,7 @@ public: protected: // construction/destruction - nes_bmc_42in1reset_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 mirror_flip); + nes_bmc_42in1reset_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 mirror_flip); // device-level overrides virtual void device_start() override; @@ -1135,7 +1135,7 @@ class nes_bmc_nc20mb_device : public nes_bmc_42in1reset_device { public: // construction/destruction - nes_bmc_nc20mb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_nc20mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -1145,7 +1145,7 @@ class nes_bmc_lc160_device : public nes_nrom_device { public: // construction/destruction - nes_bmc_lc160_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_lc160_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -1162,7 +1162,7 @@ public: protected: // construction/destruction - nes_vram_protect_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_vram_protect_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -1177,7 +1177,7 @@ class nes_bmc_60311c_device : public nes_vram_protect_device { public: // construction/destruction - nes_bmc_60311c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_60311c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -1200,7 +1200,7 @@ class nes_bmc_ctc12in1_device : public nes_vram_protect_device { public: // construction/destruction - nes_bmc_ctc12in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_ctc12in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -1209,7 +1209,7 @@ public: protected: // construction/destruction - nes_bmc_ctc12in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_bmc_ctc12in1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -1224,7 +1224,7 @@ class nes_bmc_891227_device : public nes_bmc_ctc12in1_device { public: // construction/destruction - nes_bmc_891227_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_891227_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -1236,13 +1236,13 @@ class nes_bmc_k1029_device : public nes_vram_protect_device { public: // construction/destruction - nes_bmc_k1029_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_k1029_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; protected: // construction/destruction - nes_bmc_k1029_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_bmc_k1029_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -1252,7 +1252,7 @@ class nes_bmc_fam250_device : public nes_bmc_k1029_device { public: // construction/destruction - nes_bmc_fam250_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_fam250_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -1274,7 +1274,7 @@ class nes_n625092_device : public nes_vram_protect_device { public: // construction/destruction - nes_n625092_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_n625092_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -1295,7 +1295,7 @@ class nes_bmc_th22913_device : public nes_vram_protect_device { public: // construction/destruction - nes_bmc_th22913_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_th22913_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -1303,7 +1303,7 @@ public: protected: // construction/destruction - nes_bmc_th22913_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 vram_prot_bit); + nes_bmc_th22913_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 vram_prot_bit); private: const u8 m_vram_prot_bit; @@ -1316,7 +1316,7 @@ class nes_bmc_82ab_device : public nes_bmc_th22913_device { public: // construction/destruction - nes_bmc_82ab_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_82ab_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/nes/namcot.cpp b/src/devices/bus/nes/namcot.cpp index 31f72761751..ac04dfb6b07 100644 --- a/src/devices/bus/nes/namcot.cpp +++ b/src/devices/bus/nes/namcot.cpp @@ -48,42 +48,42 @@ DEFINE_DEVICE_TYPE(NES_NAMCOT175, nes_namcot175_device, "nes_namcot175", "NES DEFINE_DEVICE_TYPE(NES_NAMCOT163, nes_namcot163_device, "nes_namcot163", "NES Cart Namcot 163 PCB") -nes_namcot3433_device::nes_namcot3433_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_namcot3433_device::nes_namcot3433_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_latch(0) { } -nes_namcot3433_device::nes_namcot3433_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_namcot3433_device::nes_namcot3433_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NAMCOT3433, tag, owner, clock), m_latch(0) { } -nes_namcot3446_device::nes_namcot3446_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_namcot3446_device::nes_namcot3446_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NAMCOT3446, tag, owner, clock), m_latch(0) { } -nes_namcot3425_device::nes_namcot3425_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_namcot3425_device::nes_namcot3425_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NAMCOT3425, tag, owner, clock), m_latch(0) { } -nes_namcot340_device::nes_namcot340_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_namcot340_device::nes_namcot340_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr) { } -nes_namcot340_device::nes_namcot340_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_namcot340_device::nes_namcot340_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_namcot340_device(mconfig, NES_NAMCOT340, tag, owner, clock) { } -nes_namcot175_device::nes_namcot175_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_namcot175_device::nes_namcot175_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_namcot340_device(mconfig, NES_NAMCOT175, tag, owner, clock), m_wram_protect(0) { } -nes_namcot163_device::nes_namcot163_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_namcot163_device::nes_namcot163_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_namcot340_device(mconfig, NES_NAMCOT163, tag, owner, clock), m_wram_protect(0), m_latch(0), m_chr_bank(0), m_namco163snd(*this, "n163") { } diff --git a/src/devices/bus/nes/namcot.h b/src/devices/bus/nes/namcot.h index 13d30804b8a..2e1872a5cc7 100644 --- a/src/devices/bus/nes/namcot.h +++ b/src/devices/bus/nes/namcot.h @@ -15,7 +15,7 @@ class nes_namcot3433_device : public nes_nrom_device { public: // construction/destruction - nes_namcot3433_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_namcot3433_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void dxrom_write(offs_t offset, uint8_t data); virtual void write_h(offs_t offset, uint8_t data) override { dxrom_write(offset, data); } @@ -23,7 +23,7 @@ public: virtual void pcb_reset() override; protected: - nes_namcot3433_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_namcot3433_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -39,7 +39,7 @@ class nes_namcot3446_device : public nes_nrom_device { public: // construction/destruction - nes_namcot3446_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_namcot3446_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -60,7 +60,7 @@ class nes_namcot3425_device : public nes_nrom_device { public: // construction/destruction - nes_namcot3425_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_namcot3425_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -82,7 +82,7 @@ class nes_namcot340_device : public nes_nrom_device { public: // construction/destruction - nes_namcot340_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_namcot340_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t n340_loread(offs_t offset); void n340_lowrite(offs_t offset, uint8_t data); @@ -94,7 +94,7 @@ public: virtual void pcb_reset() override; protected: - nes_namcot340_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_namcot340_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -118,7 +118,7 @@ class nes_namcot175_device : public nes_namcot340_device { public: // construction/destruction - nes_namcot175_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_namcot175_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -139,7 +139,7 @@ class nes_namcot163_device : public nes_namcot340_device { public: // construction/destruction - nes_namcot163_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_namcot163_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual uint8_t read_m(offs_t offset) override; diff --git a/src/devices/bus/nes/nanjing.cpp b/src/devices/bus/nes/nanjing.cpp index 6a451b3c59d..71e9149b034 100644 --- a/src/devices/bus/nes/nanjing.cpp +++ b/src/devices/bus/nes/nanjing.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(NES_NANJING, nes_nanjing_device, "nes_nanjing", "NES Cart Nanjing PCB") -nes_nanjing_device::nes_nanjing_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_nanjing_device::nes_nanjing_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NANJING, tag, owner, clock) , m_count(0) , m_latch1(0) diff --git a/src/devices/bus/nes/nanjing.h b/src/devices/bus/nes/nanjing.h index 979fbb1e5ee..df84e5e0767 100644 --- a/src/devices/bus/nes/nanjing.h +++ b/src/devices/bus/nes/nanjing.h @@ -16,7 +16,7 @@ class nes_nanjing_device : public nes_nrom_device { public: // construction/destruction - nes_nanjing_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_nanjing_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~nes_nanjing_device(); virtual uint8_t read_l(offs_t offset) override; diff --git a/src/devices/bus/nes/nes_slot.cpp b/src/devices/bus/nes/nes_slot.cpp index aae391d27c9..aeddae28fd1 100644 --- a/src/devices/bus/nes/nes_slot.cpp +++ b/src/devices/bus/nes/nes_slot.cpp @@ -650,7 +650,7 @@ void device_nes_cart_interface::nes_banks_restore() //------------------------------------------------- // nes_cart_slot_device - constructor //------------------------------------------------- -nes_cart_slot_device::nes_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_cart_slot_device::nes_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_CART_SLOT, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_single_card_slot_interface<device_nes_cart_interface>(mconfig, *this) diff --git a/src/devices/bus/nes/nes_slot.h b/src/devices/bus/nes/nes_slot.h index b135f957afe..21441fa8a81 100644 --- a/src/devices/bus/nes/nes_slot.h +++ b/src/devices/bus/nes/nes_slot.h @@ -387,7 +387,7 @@ class nes_cart_slot_device : public device_t, public: // construction/destruction template <typename T> - nes_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + nes_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : nes_cart_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -395,7 +395,7 @@ public: set_default_option(dflt); set_fixed(false); } - nes_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~nes_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/nes/ntdec.cpp b/src/devices/bus/nes/ntdec.cpp index fd207f20a00..cfe96acc201 100644 --- a/src/devices/bus/nes/ntdec.cpp +++ b/src/devices/bus/nes/ntdec.cpp @@ -40,17 +40,17 @@ DEFINE_DEVICE_TYPE(NES_NTDEC_FH, nes_ntdec_fh_device, "nes_ntdec_fh", DEFINE_DEVICE_TYPE(NES_NTDEC_N715021, nes_ntdec_n715021_device, "nes_ntdec_n715021", "NES Cart NTDEC N715021 PCB") -nes_ntdec_asder_device::nes_ntdec_asder_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ntdec_asder_device::nes_ntdec_asder_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NTDEC_ASDER, tag, owner, clock), m_latch(0), m_chr_outer(0) { } -nes_ntdec_fh_device::nes_ntdec_fh_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ntdec_fh_device::nes_ntdec_fh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NTDEC_FH, tag, owner, clock) { } -nes_ntdec_n715021_device::nes_ntdec_n715021_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ntdec_n715021_device::nes_ntdec_n715021_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NTDEC_N715021, tag, owner, clock) { } diff --git a/src/devices/bus/nes/ntdec.h b/src/devices/bus/nes/ntdec.h index 160511a388a..1185ce6f832 100644 --- a/src/devices/bus/nes/ntdec.h +++ b/src/devices/bus/nes/ntdec.h @@ -14,7 +14,7 @@ class nes_ntdec_asder_device : public nes_nrom_device { public: // construction/destruction - nes_ntdec_asder_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ntdec_asder_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -35,7 +35,7 @@ class nes_ntdec_fh_device : public nes_nrom_device { public: // construction/destruction - nes_ntdec_fh_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ntdec_fh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -49,7 +49,7 @@ class nes_ntdec_n715021_device : public nes_nrom_device { public: // construction/destruction - nes_ntdec_n715021_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ntdec_n715021_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/nxrom.cpp b/src/devices/bus/nes/nxrom.cpp index 9f2e35aa0ed..0d02cc10cf2 100644 --- a/src/devices/bus/nes/nxrom.cpp +++ b/src/devices/bus/nes/nxrom.cpp @@ -57,72 +57,72 @@ DEFINE_DEVICE_TYPE(NES_UN1ROM, nes_un1rom_device, "nes_un1rom", "NES Cart DEFINE_DEVICE_TYPE(NES_NOCHR, nes_nochr_device, "nes_nochr", "NES Cart NoCash NOCHR PCB") -nes_nrom_device::nes_nrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_nrom_device::nes_nrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nes_cart_interface(mconfig, *this) { } -nes_nrom_device::nes_nrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_nrom_device::nes_nrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NROM, tag, owner, clock) { } -nes_nrom368_device::nes_nrom368_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_nrom368_device::nes_nrom368_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NROM368, tag, owner, clock) { } -nes_fcbasic_device::nes_fcbasic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_fcbasic_device::nes_fcbasic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_FCBASIC, tag, owner, clock) { } -nes_axrom_device::nes_axrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_axrom_device::nes_axrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_AXROM, tag, owner, clock) { } -nes_bxrom_device::nes_bxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_bxrom_device::nes_bxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_BXROM, tag, owner, clock) { } -nes_cnrom_device::nes_cnrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_cnrom_device::nes_cnrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_chr_open_bus(0) { } -nes_cnrom_device::nes_cnrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_cnrom_device::nes_cnrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_cnrom_device(mconfig, NES_CNROM, tag, owner, clock) { } -nes_cprom_device::nes_cprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_cprom_device::nes_cprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_CPROM, tag, owner, clock) { } -nes_gxrom_device::nes_gxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_gxrom_device::nes_gxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_GXROM, tag, owner, clock) { } -nes_uxrom_device::nes_uxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_uxrom_device::nes_uxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_UXROM, tag, owner, clock) { } -nes_uxrom_cc_device::nes_uxrom_cc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_uxrom_cc_device::nes_uxrom_cc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_UXROM_CC, tag, owner, clock) { } -nes_un1rom_device::nes_un1rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_un1rom_device::nes_un1rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_UN1ROM, tag, owner, clock) { } -nes_nochr_device::nes_nochr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_nochr_device::nes_nochr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_NOCHR, tag, owner, clock) { } diff --git a/src/devices/bus/nes/nxrom.h b/src/devices/bus/nes/nxrom.h index 7dedbdb0cad..b0a62e6cffe 100644 --- a/src/devices/bus/nes/nxrom.h +++ b/src/devices/bus/nes/nxrom.h @@ -14,12 +14,12 @@ class nes_nrom_device : public device_t, public device_nes_cart_interface { public: // construction/destruction - nes_nrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_nrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void pcb_reset() override; protected: - nes_nrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_nrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override { common_start(); } @@ -33,7 +33,7 @@ class nes_nrom368_device : public nes_nrom_device { public: // construction/destruction - nes_nrom368_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_nrom368_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual uint8_t read_m(offs_t offset) override; @@ -47,7 +47,7 @@ class nes_fcbasic_device : public nes_nrom_device { public: // construction/destruction - nes_fcbasic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_fcbasic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // emulate the additional WRAM }; @@ -59,7 +59,7 @@ class nes_axrom_device : public nes_nrom_device { public: // construction/destruction - nes_axrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_axrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -73,7 +73,7 @@ class nes_bxrom_device : public nes_nrom_device { public: // construction/destruction - nes_bxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_bxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -85,7 +85,7 @@ class nes_cnrom_device : public nes_nrom_device { public: // construction/destruction - nes_cnrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_cnrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t chr_r(offs_t offset) override; virtual void write_h(offs_t offset, uint8_t data) override; @@ -93,7 +93,7 @@ public: virtual void pcb_reset() override; protected: - nes_cnrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_cnrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -109,7 +109,7 @@ class nes_cprom_device : public nes_nrom_device { public: // construction/destruction - nes_cprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_cprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -123,7 +123,7 @@ class nes_gxrom_device : public nes_nrom_device { public: // construction/destruction - nes_gxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_gxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -135,7 +135,7 @@ class nes_uxrom_device : public nes_nrom_device { public: // construction/destruction - nes_uxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_uxrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -149,7 +149,7 @@ class nes_uxrom_cc_device : public nes_nrom_device { public: // construction/destruction - nes_uxrom_cc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_uxrom_cc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -161,7 +161,7 @@ class nes_un1rom_device : public nes_nrom_device { public: // construction/destruction - nes_un1rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_un1rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -175,7 +175,7 @@ class nes_nochr_device : public nes_nrom_device { public: // construction/destruction - nes_nochr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_nochr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 chr_r(offs_t offset) override; virtual void chr_w(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/pirate.cpp b/src/devices/bus/nes/pirate.cpp index 81a06c7d655..e8484eac863 100644 --- a/src/devices/bus/nes/pirate.cpp +++ b/src/devices/bus/nes/pirate.cpp @@ -47,62 +47,62 @@ DEFINE_DEVICE_TYPE(NES_43272, nes_43272_device, "nes_43272", " DEFINE_DEVICE_TYPE(NES_EH8813A, nes_eh8813a_device, "nes_eh8813a", "NES Cart UNL-EH8813A PCB") -nes_agci_device::nes_agci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_agci_device::nes_agci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_AGCI_50282, tag, owner, clock) { } -nes_dreamtech_device::nes_dreamtech_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_dreamtech_device::nes_dreamtech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_DREAMTECH01, tag, owner, clock) { } -nes_fukutake_device::nes_fukutake_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_fukutake_device::nes_fukutake_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_FUKUTAKE, tag, owner, clock), m_latch(0) { } -nes_futuremedia_device::nes_futuremedia_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_futuremedia_device::nes_futuremedia_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_FUTUREMEDIA, tag, owner, clock), m_irq_count(0), m_irq_count_latch(0), m_irq_enable(0) { } -nes_magseries_device::nes_magseries_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_magseries_device::nes_magseries_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_MAGSERIES, tag, owner, clock) { } -nes_daou306_device::nes_daou306_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_daou306_device::nes_daou306_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_DAOU306, tag, owner, clock) { } -nes_cc21_device::nes_cc21_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_cc21_device::nes_cc21_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_CC21, tag, owner, clock) { } -nes_xiaozy_device::nes_xiaozy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_xiaozy_device::nes_xiaozy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_XIAOZY, tag, owner, clock) { } -nes_edu2k_device::nes_edu2k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_edu2k_device::nes_edu2k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_EDU2K, tag, owner, clock) { } -nes_jy830623c_device::nes_jy830623c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_jy830623c_device::nes_jy830623c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_JY830623C, tag, owner, clock), m_latch(0), m_irq_count(0), m_irq_count_latch(0), m_irq_enable(0) { } -nes_43272_device::nes_43272_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_43272_device::nes_43272_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_43272, tag, owner, clock), m_latch(0) { } -nes_eh8813a_device::nes_eh8813a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_eh8813a_device::nes_eh8813a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_EH8813A, tag, owner, clock), m_jumper(0), m_latch(0), m_reg(0) { } diff --git a/src/devices/bus/nes/pirate.h b/src/devices/bus/nes/pirate.h index 9f7be76cc56..b70a8373bc9 100644 --- a/src/devices/bus/nes/pirate.h +++ b/src/devices/bus/nes/pirate.h @@ -14,7 +14,7 @@ class nes_agci_device : public nes_nrom_device { public: // construction/destruction - nes_agci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_agci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -26,7 +26,7 @@ class nes_dreamtech_device : public nes_nrom_device { public: // construction/destruction - nes_dreamtech_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_dreamtech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override; @@ -40,7 +40,7 @@ class nes_fukutake_device : public nes_nrom_device { public: // construction/destruction - nes_fukutake_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_fukutake_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual uint8_t read_m(offs_t offset) override; @@ -65,7 +65,7 @@ class nes_futuremedia_device : public nes_nrom_device { public: // construction/destruction - nes_futuremedia_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_futuremedia_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -88,7 +88,7 @@ class nes_magseries_device : public nes_nrom_device { public: // construction/destruction - nes_magseries_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_magseries_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -100,7 +100,7 @@ class nes_daou306_device : public nes_nrom_device { public: // construction/destruction - nes_daou306_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_daou306_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -121,7 +121,7 @@ class nes_cc21_device : public nes_nrom_device { public: // construction/destruction - nes_cc21_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_cc21_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -135,7 +135,7 @@ class nes_xiaozy_device : public nes_nrom_device { public: // construction/destruction - nes_xiaozy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_xiaozy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; @@ -149,7 +149,7 @@ class nes_edu2k_device : public nes_nrom_device { public: // construction/destruction - nes_edu2k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_edu2k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_m(offs_t offset, uint8_t data) override; @@ -172,7 +172,7 @@ class nes_jy830623c_device : public nes_nrom_device { public: // construction/destruction - nes_jy830623c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_jy830623c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; virtual void write_h(offs_t offset, u8 data) override; @@ -200,7 +200,7 @@ class nes_43272_device : public nes_nrom_device { public: // construction/destruction - nes_43272_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_43272_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_h(offs_t offset) override; virtual void write_h(offs_t offset, uint8_t data) override; @@ -222,7 +222,7 @@ class nes_eh8813a_device : public nes_nrom_device { public: // construction/destruction - nes_eh8813a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_eh8813a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -248,7 +248,7 @@ class nes_fujiya_device : public nes_nrom_device { public: // construction/destruction - nes_fujiya_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_fujiya_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_m(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/nes/pt554.cpp b/src/devices/bus/nes/pt554.cpp index 024da1655a5..f21471edf88 100644 --- a/src/devices/bus/nes/pt554.cpp +++ b/src/devices/bus/nes/pt554.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(NES_BANDAI_PT554, nes_bandai_pt554_device, "nes_bandai_pt554", "NES Cart Bandai PT-554 PCB") -nes_bandai_pt554_device::nes_bandai_pt554_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bandai_pt554_device::nes_bandai_pt554_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_cnrom_device(mconfig, NES_BANDAI_PT554, tag, owner, clock) , m_samples(*this, "samples") { diff --git a/src/devices/bus/nes/pt554.h b/src/devices/bus/nes/pt554.h index 51c2bdd9af3..44b1b0ce2c2 100644 --- a/src/devices/bus/nes/pt554.h +++ b/src/devices/bus/nes/pt554.h @@ -15,7 +15,7 @@ class nes_bandai_pt554_device : public nes_cnrom_device { public: // construction/destruction - nes_bandai_pt554_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bandai_pt554_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/racermate.cpp b/src/devices/bus/nes/racermate.cpp index 6ebc898721f..5bf55b9d151 100644 --- a/src/devices/bus/nes/racermate.cpp +++ b/src/devices/bus/nes/racermate.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(NES_RACERMATE, nes_racermate_device, "nes_racermate", "NES Cart Racermate PCB") -nes_racermate_device::nes_racermate_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_racermate_device::nes_racermate_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_RACERMATE, tag, owner, clock) , m_latch(0) { diff --git a/src/devices/bus/nes/racermate.h b/src/devices/bus/nes/racermate.h index cb74a06a6b0..70d8191406c 100644 --- a/src/devices/bus/nes/racermate.h +++ b/src/devices/bus/nes/racermate.h @@ -12,7 +12,7 @@ class nes_racermate_device : public nes_nrom_device { public: // construction/destruction - nes_racermate_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_racermate_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nes/rcm.cpp b/src/devices/bus/nes/rcm.cpp index 4378d65c4df..133d8eb1c34 100644 --- a/src/devices/bus/nes/rcm.cpp +++ b/src/devices/bus/nes/rcm.cpp @@ -42,32 +42,32 @@ DEFINE_DEVICE_TYPE(NES_TF9IN1, nes_tf9_device, "nes_tetrisfam", "NES Cart R DEFINE_DEVICE_TYPE(NES_3DBLOCK, nes_3dblock_device, "nes_3dblock", "NES Cart RCM 3D Block PCB") -nes_gs2015_device::nes_gs2015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_gs2015_device::nes_gs2015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_GS2015, tag, owner, clock) { } -nes_gs2004_device::nes_gs2004_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int bank) +nes_gs2004_device::nes_gs2004_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int bank) : nes_nrom_device(mconfig, type, tag, owner, clock), m_base(bank * 0x2000) { } -nes_gs2004_device::nes_gs2004_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_gs2004_device::nes_gs2004_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_gs2004_device(mconfig, NES_GS2004, tag, owner, clock, 0x20) { } -nes_gs2013_device::nes_gs2013_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_gs2013_device::nes_gs2013_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_gs2004_device(mconfig, NES_GS2013, tag, owner, clock, 0x1f) { } -nes_tf9_device::nes_tf9_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_tf9_device::nes_tf9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_TF9IN1, tag, owner, clock) { } -nes_3dblock_device::nes_3dblock_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_3dblock_device::nes_3dblock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_3DBLOCK, tag, owner, clock) { } diff --git a/src/devices/bus/nes/rcm.h b/src/devices/bus/nes/rcm.h index 2f60fafef42..8e9ed96a343 100644 --- a/src/devices/bus/nes/rcm.h +++ b/src/devices/bus/nes/rcm.h @@ -14,7 +14,7 @@ class nes_gs2015_device : public nes_nrom_device { public: // construction/destruction - nes_gs2015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_gs2015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override { return read_m(offset); } virtual uint8_t read_m(offs_t offset) override; @@ -28,14 +28,14 @@ class nes_gs2004_device : public nes_nrom_device { public: // construction/destruction - nes_gs2004_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_gs2004_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; protected: // construction/destruction - nes_gs2004_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int bank); + nes_gs2004_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int bank); private: const u32 m_base; @@ -48,7 +48,7 @@ class nes_gs2013_device : public nes_gs2004_device { public: // construction/destruction - nes_gs2013_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_gs2013_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -58,7 +58,7 @@ class nes_tf9_device : public nes_nrom_device { public: // construction/destruction - nes_tf9_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_tf9_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -70,7 +70,7 @@ class nes_3dblock_device : public nes_nrom_device { public: // construction/destruction - nes_3dblock_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_3dblock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/nes/rexsoft.cpp b/src/devices/bus/nes/rexsoft.cpp index fdab817e515..e9e055a25e4 100644 --- a/src/devices/bus/nes/rexsoft.cpp +++ b/src/devices/bus/nes/rexsoft.cpp @@ -38,12 +38,12 @@ DEFINE_DEVICE_TYPE(NES_REX_DBZ5, nes_rex_dbz5_device, "nes_rex_dbz5", "NES DEFINE_DEVICE_TYPE(NES_REX_SL1632, nes_rex_sl1632_device, "nes_rex_sl1632", "NES Cart Rex Soft SL-1632 PCB") -nes_rex_dbz5_device::nes_rex_dbz5_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_rex_dbz5_device::nes_rex_dbz5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_REX_DBZ5, tag, owner, clock), m_extra(0) { } -nes_rex_sl1632_device::nes_rex_sl1632_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_rex_sl1632_device::nes_rex_sl1632_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_REX_SL1632, tag, owner, clock), m_mode(0) { } diff --git a/src/devices/bus/nes/rexsoft.h b/src/devices/bus/nes/rexsoft.h index 205dffce4d1..687bb15ebda 100644 --- a/src/devices/bus/nes/rexsoft.h +++ b/src/devices/bus/nes/rexsoft.h @@ -14,7 +14,7 @@ class nes_rex_dbz5_device : public nes_txrom_device { public: // construction/destruction - nes_rex_dbz5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_rex_dbz5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual uint8_t read_m(offs_t offset) override { return read_l(offset); } @@ -38,7 +38,7 @@ class nes_rex_sl1632_device : public nes_txrom_device { public: // construction/destruction - nes_rex_sl1632_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_rex_sl1632_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; virtual void chr_cb(int start, int bank, int source) override; diff --git a/src/devices/bus/nes/sachen.cpp b/src/devices/bus/nes/sachen.cpp index 8e21943f97f..2c1ec1b4199 100644 --- a/src/devices/bus/nes/sachen.cpp +++ b/src/devices/bus/nes/sachen.cpp @@ -60,92 +60,92 @@ DEFINE_DEVICE_TYPE(NES_SACHEN_8259C, nes_sachen_8259c_device, "nes_s82 DEFINE_DEVICE_TYPE(NES_SACHEN_8259D, nes_sachen_8259d_device, "nes_s8259d", "NES Cart Sachen 8259D PCB") -nes_sachen_sa009_device::nes_sachen_sa009_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_sa009_device::nes_sachen_sa009_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SACHEN_SA009, tag, owner, clock) { } -nes_sachen_sa0036_device::nes_sachen_sa0036_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sachen_sa0036_device::nes_sachen_sa0036_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SACHEN_SA0036, tag, owner, clock) { } -nes_sachen_sa0037_device::nes_sachen_sa0037_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_sa0037_device::nes_sachen_sa0037_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SACHEN_SA0037, tag, owner, clock) { } -nes_sachen_sa72007_device::nes_sachen_sa72007_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_sa72007_device::nes_sachen_sa72007_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SACHEN_SA72007, tag, owner, clock) { } -nes_sachen_sa72008_device::nes_sachen_sa72008_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_sa72008_device::nes_sachen_sa72008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SACHEN_SA72008, tag, owner, clock) { } -nes_sachen_tca01_device::nes_sachen_tca01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_tca01_device::nes_sachen_tca01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SACHEN_TCA01, tag, owner, clock) { } -nes_sachen_tcu01_device::nes_sachen_tcu01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_tcu01_device::nes_sachen_tcu01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SACHEN_TCU01, tag, owner, clock) { } -nes_sachen_tcu02_device::nes_sachen_tcu02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_tcu02_device::nes_sachen_tcu02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SACHEN_TCU02, tag, owner, clock), m_latch(0) { } -nes_sachen_3013_device::nes_sachen_3013_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sachen_3013_device::nes_sachen_3013_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SACHEN_3013, tag, owner, clock) { } -nes_sachen_3014_device::nes_sachen_3014_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sachen_3014_device::nes_sachen_3014_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SACHEN_3014, tag, owner, clock), m_latch(0) { } -nes_sachen_74x374_device::nes_sachen_74x374_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_74x374_device::nes_sachen_74x374_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_latch(0), m_mmc_vrom_bank(0) { } -nes_sachen_74x374_device::nes_sachen_74x374_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_74x374_device::nes_sachen_74x374_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sachen_74x374_device(mconfig, NES_SACHEN_74X374, tag, owner, clock) { } -nes_sachen_74x374_alt_device::nes_sachen_74x374_alt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_74x374_alt_device::nes_sachen_74x374_alt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sachen_74x374_device(mconfig, NES_SACHEN_74X374_ALT, tag, owner, clock) { } -nes_sachen_8259a_device::nes_sachen_8259a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_8259a_device::nes_sachen_8259a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_sachen_74x374_device(mconfig, type, tag, owner, clock) { } -nes_sachen_8259a_device::nes_sachen_8259a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_8259a_device::nes_sachen_8259a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sachen_8259a_device(mconfig, NES_SACHEN_8259A, tag, owner, clock) { } -nes_sachen_8259b_device::nes_sachen_8259b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_8259b_device::nes_sachen_8259b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sachen_8259a_device(mconfig, NES_SACHEN_8259B, tag, owner, clock) { } -nes_sachen_8259c_device::nes_sachen_8259c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_8259c_device::nes_sachen_8259c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sachen_8259a_device(mconfig, NES_SACHEN_8259C, tag, owner, clock) { } -nes_sachen_8259d_device::nes_sachen_8259d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sachen_8259d_device::nes_sachen_8259d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sachen_8259a_device(mconfig, NES_SACHEN_8259D, tag, owner, clock) { } diff --git a/src/devices/bus/nes/sachen.h b/src/devices/bus/nes/sachen.h index 51d80966380..cb835737b3f 100644 --- a/src/devices/bus/nes/sachen.h +++ b/src/devices/bus/nes/sachen.h @@ -14,7 +14,7 @@ class nes_sachen_sa009_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_sa009_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_sa009_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; }; @@ -26,7 +26,7 @@ class nes_sachen_sa0036_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_sa0036_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sachen_sa0036_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -38,7 +38,7 @@ class nes_sachen_sa0037_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_sa0037_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sachen_sa0037_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; }; @@ -50,7 +50,7 @@ class nes_sachen_sa72007_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_sa72007_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_sa72007_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; }; @@ -62,7 +62,7 @@ class nes_sachen_sa72008_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_sa72008_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_sa72008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; }; @@ -74,7 +74,7 @@ class nes_sachen_tca01_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_tca01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_tca01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; @@ -88,7 +88,7 @@ class nes_sachen_tcu01_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_tcu01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_tcu01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; virtual void write_m(offs_t offset, uint8_t data) override { write_l((offset + 0x100) & 0xfff, data); } @@ -102,7 +102,7 @@ class nes_sachen_tcu02_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_tcu02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_tcu02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual void write_l(offs_t offset, uint8_t data) override; @@ -124,7 +124,7 @@ class nes_sachen_3013_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_3013_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sachen_3013_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; }; @@ -136,7 +136,7 @@ class nes_sachen_3014_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_3014_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sachen_3014_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_h(offs_t offset) override; virtual void write_h(offs_t offset, u8 data) override; @@ -158,7 +158,7 @@ class nes_sachen_74x374_device : public nes_nrom_device { public: // construction/destruction - nes_sachen_74x374_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_74x374_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual void write_l(offs_t offset, uint8_t data) override; @@ -166,7 +166,7 @@ public: virtual void pcb_reset() override; protected: - nes_sachen_74x374_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_74x374_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -182,7 +182,7 @@ class nes_sachen_74x374_alt_device : public nes_sachen_74x374_device { public: // construction/destruction - nes_sachen_74x374_alt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_74x374_alt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override { return 0xff; } // no read_l here virtual void write_l(offs_t offset, uint8_t data) override; @@ -195,7 +195,7 @@ class nes_sachen_8259a_device : public nes_sachen_74x374_device { public: // construction/destruction - nes_sachen_8259a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_8259a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; virtual void write_m(offs_t offset, uint8_t data) override { write_l((offset + 0x100) & 0xfff, data); } @@ -203,7 +203,7 @@ public: virtual void pcb_reset() override; protected: - nes_sachen_8259a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_8259a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -219,7 +219,7 @@ class nes_sachen_8259b_device : public nes_sachen_8259a_device { public: // construction/destruction - nes_sachen_8259b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_8259b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void chr_update() override; @@ -232,7 +232,7 @@ class nes_sachen_8259c_device : public nes_sachen_8259a_device { public: // construction/destruction - nes_sachen_8259c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_8259c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void chr_update() override; @@ -245,7 +245,7 @@ class nes_sachen_8259d_device : public nes_sachen_8259a_device { public: // construction/destruction - nes_sachen_8259d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sachen_8259d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void pcb_reset() override; diff --git a/src/devices/bus/nes/sealie.cpp b/src/devices/bus/nes/sealie.cpp index 32adda5680c..38f7af9ec3e 100644 --- a/src/devices/bus/nes/sealie.cpp +++ b/src/devices/bus/nes/sealie.cpp @@ -39,27 +39,27 @@ DEFINE_DEVICE_TYPE(NES_DPCMCART, nes_dpcmcart_device, "nes_dpcmcart", "NES Cart DEFINE_DEVICE_TYPE(NES_UNROM512, nes_unrom512_device, "nes_unrom512", "NES Cart Sealie UNROM 512 PCB") -nes_cufrom_device::nes_cufrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_cufrom_device::nes_cufrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_CUFROM, tag, owner, clock) { } -nes_dpcmcart_device::nes_dpcmcart_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_dpcmcart_device::nes_dpcmcart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_DPCMCART, tag, owner, clock) { } -nes_unrom512_device::nes_unrom512_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_unrom512_device::nes_unrom512_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock) { } -nes_unrom512_device::nes_unrom512_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_unrom512_device::nes_unrom512_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_unrom512_device(mconfig, NES_UNROM512, tag, owner, clock) { } -nes_8bitxmas_device::nes_8bitxmas_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_8bitxmas_device::nes_8bitxmas_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_unrom512_device(mconfig, NES_8BITXMAS, tag, owner, clock), m_led(0) { } diff --git a/src/devices/bus/nes/sealie.h b/src/devices/bus/nes/sealie.h index 734d69741c6..7827b9584e5 100644 --- a/src/devices/bus/nes/sealie.h +++ b/src/devices/bus/nes/sealie.h @@ -14,7 +14,7 @@ class nes_cufrom_device : public nes_nrom_device { public: // construction/destruction - nes_cufrom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_cufrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -28,7 +28,7 @@ class nes_dpcmcart_device : public nes_nrom_device { public: // construction/destruction - nes_dpcmcart_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_dpcmcart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -42,7 +42,7 @@ class nes_unrom512_device : public nes_nrom_device { public: // construction/destruction - nes_unrom512_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_unrom512_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -50,7 +50,7 @@ public: protected: // construction/destruction - nes_unrom512_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_unrom512_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -60,7 +60,7 @@ class nes_8bitxmas_device : public nes_unrom512_device { public: // construction/destruction - nes_8bitxmas_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_8bitxmas_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/somari.cpp b/src/devices/bus/nes/somari.cpp index bdf5b21b885..b31be0ca2ae 100644 --- a/src/devices/bus/nes/somari.cpp +++ b/src/devices/bus/nes/somari.cpp @@ -37,17 +37,17 @@ DEFINE_DEVICE_TYPE(NES_SOMARI, nes_somari_device, "nes_somari", "NES Cart Team S DEFINE_DEVICE_TYPE(NES_HUANG2, nes_huang2_device, "nes_huang2", "NES Cart Huang-2 PCB") -nes_somari_device::nes_somari_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 mmc1_prg_shift) +nes_somari_device::nes_somari_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 mmc1_prg_shift) : nes_txrom_device(mconfig, type, tag, owner, clock), m_board_mode(0), m_mmc1_count(0), m_mmc1_latch(0), m_mmc1_prg_shift(mmc1_prg_shift), m_vrc_mirror(0) { } -nes_somari_device::nes_somari_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_somari_device::nes_somari_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_somari_device(mconfig, NES_SOMARI, tag, owner, clock, 0) { } -nes_huang2_device::nes_huang2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_huang2_device::nes_huang2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_somari_device(mconfig, NES_HUANG2, tag, owner, clock, 1) { } diff --git a/src/devices/bus/nes/somari.h b/src/devices/bus/nes/somari.h index 2c566696242..f5d868aacfc 100644 --- a/src/devices/bus/nes/somari.h +++ b/src/devices/bus/nes/somari.h @@ -14,7 +14,7 @@ class nes_somari_device : public nes_txrom_device { public: // construction/destruction - nes_somari_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_somari_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, u8 data) override { write_m(offset + 0x100, data); } virtual void write_m(offs_t offset, u8 data) override; @@ -24,7 +24,7 @@ public: protected: // construction/destruction - nes_somari_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 mmc1_prg_shift); + nes_somari_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 mmc1_prg_shift); // device-level overrides virtual void device_start() override; @@ -59,7 +59,7 @@ class nes_huang2_device : public nes_somari_device { public: // construction/destruction - nes_huang2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_huang2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/nes/subor.cpp b/src/devices/bus/nes/subor.cpp index 2c9daf203ee..f04963767df 100644 --- a/src/devices/bus/nes/subor.cpp +++ b/src/devices/bus/nes/subor.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(NES_SUBOR2, nes_subor2_device, "nes_subor2", "NES Cart Subor // nes_subor0_device - constructor //------------------------------------------------- -nes_subor0_device::nes_subor0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_subor0_device::nes_subor0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SUBOR0, tag, owner, clock) { } @@ -49,7 +49,7 @@ nes_subor0_device::nes_subor0_device(const machine_config &mconfig, const char * // nes_subor1_device - constructor //------------------------------------------------- -nes_subor1_device::nes_subor1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_subor1_device::nes_subor1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SUBOR1, tag, owner, clock) { } @@ -58,7 +58,7 @@ nes_subor1_device::nes_subor1_device(const machine_config &mconfig, const char * // nes_subor2_device - constructor //------------------------------------------------- -nes_subor2_device::nes_subor2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_subor2_device::nes_subor2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SUBOR2, tag, owner, clock) , m_switch_reg(0) , m_bank_reg(0) diff --git a/src/devices/bus/nes/subor.h b/src/devices/bus/nes/subor.h index a4ffc13a553..3cbbf9db606 100644 --- a/src/devices/bus/nes/subor.h +++ b/src/devices/bus/nes/subor.h @@ -18,7 +18,7 @@ class nes_subor0_device : { public: // construction/destruction - nes_subor0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_subor0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -39,7 +39,7 @@ class nes_subor1_device : { public: // construction/destruction - nes_subor1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_subor1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -60,7 +60,7 @@ class nes_subor2_device : { public: // construction/destruction - nes_subor2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_subor2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t nt_r(offs_t offset) override; virtual void write_l(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/nes/sunsoft.cpp b/src/devices/bus/nes/sunsoft.cpp index ffe5aec9005..ae84d6f726f 100644 --- a/src/devices/bus/nes/sunsoft.cpp +++ b/src/devices/bus/nes/sunsoft.cpp @@ -49,42 +49,42 @@ DEFINE_DEVICE_TYPE(NES_SUNSOFT_FME7, nes_sunsoft_fme7_device, "nes_fme7", "NES C DEFINE_DEVICE_TYPE(NES_SUNSOFT_5, nes_sunsoft_5_device, "nes_sun5", "NES Cart Sunsoft 5A/5B PCB") -nes_sunsoft_1_device::nes_sunsoft_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sunsoft_1_device::nes_sunsoft_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SUNSOFT_1, tag, owner, clock) { } -nes_sunsoft_2_device::nes_sunsoft_2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sunsoft_2_device::nes_sunsoft_2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SUNSOFT_2, tag, owner, clock) { } -nes_sunsoft_3_device::nes_sunsoft_3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sunsoft_3_device::nes_sunsoft_3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_SUNSOFT_3, tag, owner, clock), m_irq_count(0), m_irq_enable(0), m_irq_toggle(0), irq_timer(nullptr) { } -nes_sunsoft_4_device::nes_sunsoft_4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_sunsoft_4_device::nes_sunsoft_4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_wram_enable(0) { } -nes_sunsoft_4_device::nes_sunsoft_4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_sunsoft_4_device::nes_sunsoft_4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sunsoft_4_device(mconfig, NES_SUNSOFT_4, tag, owner, clock) { } -nes_sunsoft_fme7_device::nes_sunsoft_fme7_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_sunsoft_fme7_device::nes_sunsoft_fme7_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr), m_latch(0), m_wram_bank(0) { } -nes_sunsoft_fme7_device::nes_sunsoft_fme7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sunsoft_fme7_device::nes_sunsoft_fme7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sunsoft_fme7_device(mconfig, NES_SUNSOFT_FME7, tag, owner, clock) { } -nes_sunsoft_5_device::nes_sunsoft_5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sunsoft_5_device::nes_sunsoft_5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sunsoft_fme7_device(mconfig, NES_SUNSOFT_5, tag, owner, clock) , m_ym2149(*this, "ay") { diff --git a/src/devices/bus/nes/sunsoft.h b/src/devices/bus/nes/sunsoft.h index 000150922c7..d2c4e41a622 100644 --- a/src/devices/bus/nes/sunsoft.h +++ b/src/devices/bus/nes/sunsoft.h @@ -15,7 +15,7 @@ class nes_sunsoft_1_device : public nes_nrom_device { public: // construction/destruction - nes_sunsoft_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sunsoft_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, uint8_t data) override; @@ -29,7 +29,7 @@ class nes_sunsoft_2_device : public nes_nrom_device { public: // construction/destruction - nes_sunsoft_2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sunsoft_2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -43,7 +43,7 @@ class nes_sunsoft_3_device : public nes_nrom_device { public: // construction/destruction - nes_sunsoft_3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sunsoft_3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -69,7 +69,7 @@ class nes_sunsoft_4_device : public nes_nrom_device { public: // construction/destruction - nes_sunsoft_4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_sunsoft_4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -79,7 +79,7 @@ public: virtual void pcb_reset() override; protected: - nes_sunsoft_4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_sunsoft_4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -99,7 +99,7 @@ class nes_sunsoft_fme7_device : public nes_nrom_device { public: // construction/destruction - nes_sunsoft_fme7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sunsoft_fme7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual void write_m(offs_t offset, uint8_t data) override; @@ -109,7 +109,7 @@ public: virtual void pcb_reset() override; protected: - nes_sunsoft_fme7_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_sunsoft_fme7_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -133,7 +133,7 @@ class nes_sunsoft_5_device : public nes_sunsoft_fme7_device { public: // construction/destruction - nes_sunsoft_5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sunsoft_5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/nes/sunsoft_dcs.cpp b/src/devices/bus/nes/sunsoft_dcs.cpp index 7f291e741ed..2b271d2dd9f 100644 --- a/src/devices/bus/nes/sunsoft_dcs.cpp +++ b/src/devices/bus/nes/sunsoft_dcs.cpp @@ -50,7 +50,7 @@ ntb_cart_interface::~ntb_cart_interface() DEFINE_DEVICE_TYPE(NES_NTB_SLOT, nes_ntb_slot_device, "nes_ntb_slot", "NES NTB Cartridge Slot") -nes_ntb_slot_device::nes_ntb_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_ntb_slot_device::nes_ntb_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_NTB_SLOT, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_single_card_slot_interface<ntb_cart_interface>(mconfig, *this) @@ -123,7 +123,7 @@ ROM_END DEFINE_DEVICE_TYPE(NES_NTB_ROM, nes_ntb_rom_device, "nes_ntbrom", "NES NTB ROM") -nes_ntb_rom_device::nes_ntb_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_ntb_rom_device::nes_ntb_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_NTB_ROM, tag, owner, clock) , ntb_cart_interface(mconfig, *this) { @@ -157,7 +157,7 @@ uint8_t *nes_ntb_rom_device::get_cart_base() DEFINE_DEVICE_TYPE(NES_SUNSOFT_DCS, nes_sunsoft_dcs_device, "nes_dcs", "NES Cart Sunsoft DCS PCB") -nes_sunsoft_dcs_device::nes_sunsoft_dcs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_sunsoft_dcs_device::nes_sunsoft_dcs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_sunsoft_4_device(mconfig, NES_SUNSOFT_DCS, tag, owner, clock), m_timer_on(0), m_exrom_enable(0) , m_subslot(*this, "ntb_slot"), ntb_enable_timer(nullptr) { diff --git a/src/devices/bus/nes/sunsoft_dcs.h b/src/devices/bus/nes/sunsoft_dcs.h index e9f6594a452..a3f90b4acfc 100644 --- a/src/devices/bus/nes/sunsoft_dcs.h +++ b/src/devices/bus/nes/sunsoft_dcs.h @@ -48,7 +48,7 @@ public: // construction/destruction template <typename T> nes_ntb_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts) - : nes_ntb_slot_device(mconfig, tag, owner, (uint32_t)0) + : nes_ntb_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -56,7 +56,7 @@ public: set_fixed(false); } - nes_ntb_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_ntb_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~nes_ntb_slot_device(); // image-level overrides @@ -95,7 +95,7 @@ class nes_ntb_rom_device : public device_t, { public: // construction/destruction - nes_ntb_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_ntb_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -125,7 +125,7 @@ class nes_sunsoft_dcs_device : public nes_sunsoft_4_device { public: // construction/destruction - nes_sunsoft_dcs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_sunsoft_dcs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_m(offs_t offset) override; virtual uint8_t read_h(offs_t offset) override; diff --git a/src/devices/bus/nes/taito.cpp b/src/devices/bus/nes/taito.cpp index a3689c8f4a7..47b0621f741 100644 --- a/src/devices/bus/nes/taito.cpp +++ b/src/devices/bus/nes/taito.cpp @@ -46,27 +46,27 @@ DEFINE_DEVICE_TYPE(NES_X1_005, nes_x1_005_device, "nes_x1_ DEFINE_DEVICE_TYPE(NES_X1_017, nes_x1_017_device, "nes_x1_017", "NES Cart Taito X1-017 PCB") -nes_tc0190fmc_device::nes_tc0190fmc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_tc0190fmc_device::nes_tc0190fmc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock) { } -nes_tc0190fmc_device::nes_tc0190fmc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_tc0190fmc_device::nes_tc0190fmc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_tc0190fmc_device(mconfig, NES_TC0190FMC, tag, owner, clock) { } -nes_tc0190fmc_pal16r4_device::nes_tc0190fmc_pal16r4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_tc0190fmc_pal16r4_device::nes_tc0190fmc_pal16r4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_tc0190fmc_device(mconfig, NES_TC0190FMC_PAL16R4, tag, owner, clock), m_irq_count(0), m_irq_count_latch(0), m_irq_enable(0) { } -nes_x1_005_device::nes_x1_005_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_x1_005_device::nes_x1_005_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_X1_005, tag, owner, clock), m_latch(0) { } -nes_x1_017_device::nes_x1_017_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_x1_017_device::nes_x1_017_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_X1_017, tag, owner, clock), m_latch(0), m_irq_count(0), m_irq_count_latch(0), m_irq_enable(0), irq_timer(nullptr) { } diff --git a/src/devices/bus/nes/taito.h b/src/devices/bus/nes/taito.h index 6f3981aa993..843f662edcf 100644 --- a/src/devices/bus/nes/taito.h +++ b/src/devices/bus/nes/taito.h @@ -14,14 +14,14 @@ class nes_tc0190fmc_device : public nes_nrom_device { public: // construction/destruction - nes_tc0190fmc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_tc0190fmc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; virtual void pcb_reset() override; protected: - nes_tc0190fmc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_tc0190fmc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -31,7 +31,7 @@ class nes_tc0190fmc_pal16r4_device : public nes_tc0190fmc_device { public: // construction/destruction - nes_tc0190fmc_pal16r4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_tc0190fmc_pal16r4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -54,7 +54,7 @@ class nes_x1_005_device : public nes_nrom_device { public: // construction/destruction - nes_x1_005_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_x1_005_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -78,7 +78,7 @@ class nes_x1_017_device : public nes_nrom_device { public: // construction/destruction - nes_x1_017_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_x1_017_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_ex(offs_t offset) override { return 0; } // no open bus virtual u8 read_l(offs_t offset) override { return 0; } // no open bus diff --git a/src/devices/bus/nes/tengen.cpp b/src/devices/bus/nes/tengen.cpp index 3b74a13f2cd..735dcc52c7a 100644 --- a/src/devices/bus/nes/tengen.cpp +++ b/src/devices/bus/nes/tengen.cpp @@ -39,17 +39,17 @@ DEFINE_DEVICE_TYPE(NES_TENGEN_800032, nes_tengen032_device, "nes_tengen032", "NE DEFINE_DEVICE_TYPE(NES_TENGEN_800037, nes_tengen037_device, "nes_tengen037", "NES Cart Tengen 800037 PCB") -nes_tengen032_device::nes_tengen032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_tengen032_device::nes_tengen032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock), m_latch(0), m_irq_count(0), m_irq_count_latch(0), m_irq_mode(0), m_irq_reset(0), m_irq_enable(0), m_irq_pending(0), irq_timer(nullptr) { } -nes_tengen032_device::nes_tengen032_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_tengen032_device::nes_tengen032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_tengen032_device(mconfig, NES_TENGEN_800032, tag, owner, clock) { } -nes_tengen037_device::nes_tengen037_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_tengen037_device::nes_tengen037_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_tengen032_device(mconfig, NES_TENGEN_800037, tag, owner, clock) { } diff --git a/src/devices/bus/nes/tengen.h b/src/devices/bus/nes/tengen.h index d5dbec1e88b..efa07c88332 100644 --- a/src/devices/bus/nes/tengen.h +++ b/src/devices/bus/nes/tengen.h @@ -12,7 +12,7 @@ class nes_tengen032_device : public nes_nrom_device { public: // construction/destruction - nes_tengen032_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_tengen032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -20,7 +20,7 @@ public: virtual void pcb_reset() override; protected: - nes_tengen032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_tengen032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -53,7 +53,7 @@ class nes_tengen037_device : public nes_tengen032_device { public: // construction/destruction - nes_tengen037_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_tengen037_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void write_h(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes/txc.cpp b/src/devices/bus/nes/txc.cpp index 398adbd17f3..1d4616b2775 100644 --- a/src/devices/bus/nes/txc.cpp +++ b/src/devices/bus/nes/txc.cpp @@ -44,32 +44,32 @@ DEFINE_DEVICE_TYPE(NES_TXC_STRIKEW, nes_txc_strikew_device, "nes_txc_strike DEFINE_DEVICE_TYPE(NES_TXC_COMMANDOS, nes_txc_commandos_device, "nes_txc_comm", "NES Cart TXC Cart Commandos PCB") // and others -nes_txc_22211_device::nes_txc_22211_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_txc_22211_device::nes_txc_22211_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, type, tag, owner, clock) { } -nes_txc_22211_device::nes_txc_22211_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_txc_22211_device::nes_txc_22211_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_TXC_22211, tag, owner, clock) { } -nes_txc_dumarc_device::nes_txc_dumarc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_txc_dumarc_device::nes_txc_dumarc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txc_22211_device(mconfig, NES_TXC_DUMARACING, tag, owner, clock) { } -nes_txc_mjblock_device::nes_txc_mjblock_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_txc_mjblock_device::nes_txc_mjblock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txc_22211_device(mconfig, NES_TXC_MJBLOCK, tag, owner, clock) { } -nes_txc_strikew_device::nes_txc_strikew_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_txc_strikew_device::nes_txc_strikew_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_TXC_STRIKEW, tag, owner, clock) { } -nes_txc_commandos_device::nes_txc_commandos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_txc_commandos_device::nes_txc_commandos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_TXC_COMMANDOS, tag, owner, clock) { } diff --git a/src/devices/bus/nes/txc.h b/src/devices/bus/nes/txc.h index 4e7f938c1a8..9e546f440dc 100644 --- a/src/devices/bus/nes/txc.h +++ b/src/devices/bus/nes/txc.h @@ -14,7 +14,7 @@ class nes_txc_22211_device : public nes_nrom_device { public: // construction/destruction - nes_txc_22211_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_txc_22211_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual void write_l(offs_t offset, uint8_t data) override; @@ -23,7 +23,7 @@ public: virtual void pcb_reset() override; protected: - nes_txc_22211_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_txc_22211_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -38,7 +38,7 @@ class nes_txc_dumarc_device : public nes_txc_22211_device { public: // construction/destruction - nes_txc_dumarc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_txc_dumarc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -50,7 +50,7 @@ class nes_txc_mjblock_device : public nes_txc_22211_device { public: // construction/destruction - nes_txc_mjblock_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_txc_mjblock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; }; @@ -62,7 +62,7 @@ class nes_txc_strikew_device : public nes_nrom_device { public: // construction/destruction - nes_txc_strikew_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_txc_strikew_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; @@ -84,7 +84,7 @@ class nes_txc_commandos_device : public nes_nrom_device { public: // construction/destruction - nes_txc_commandos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_txc_commandos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual void write_h(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/nes/vrc_clones.cpp b/src/devices/bus/nes/vrc_clones.cpp index 506857df85f..fa28b0a1b9b 100644 --- a/src/devices/bus/nes/vrc_clones.cpp +++ b/src/devices/bus/nes/vrc_clones.cpp @@ -44,77 +44,77 @@ DEFINE_DEVICE_TYPE(NES_WAIXING_SGZ, nes_waixing_sgz_device, "nes_waixing_sgz", " DEFINE_DEVICE_TYPE(NES_HENGG_SHJY3, nes_hengg_shjy3_device, "nes_hengg_shjy3", "NES Cart Henggedianzi Shen Hua Jian Yun III PCB") -nes_2yudb_device::nes_2yudb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_2yudb_device::nes_2yudb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_2YUDB, tag, owner, clock), m_outer(0) { } -nes_900218_device::nes_900218_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_900218_device::nes_900218_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc2_device(mconfig, NES_900218, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr) { } -nes_ax40g_device::nes_ax40g_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ax40g_device::nes_ax40g_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc2_device(mconfig, NES_AX40G, tag, owner, clock) { } -nes_ax5705_device::nes_ax5705_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ax5705_device::nes_ax5705_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_AX5705, tag, owner, clock) { } -nes_bmc_830506c_device::nes_bmc_830506c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_830506c_device::nes_bmc_830506c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_BMC_830506C, tag, owner, clock), m_outer(0) { } -nes_bmc_831128c_device::nes_bmc_831128c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_831128c_device::nes_bmc_831128c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_BMC_831128C, tag, owner, clock), m_reg(0) { } -nes_bmc_kl06_device::nes_bmc_kl06_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bmc_kl06_device::nes_bmc_kl06_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_BMC_KL06, tag, owner, clock), m_reg(0) { } -nes_cityfight_device::nes_cityfight_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_cityfight_device::nes_cityfight_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_CITYFIGHT, tag, owner, clock) { } -nes_shuiguan_device::nes_shuiguan_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_shuiguan_device::nes_shuiguan_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_SHUIGUAN, tag, owner, clock) { } -nes_t230_device::nes_t230_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_t230_device::nes_t230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_T230, tag, owner, clock) { } -nes_tf1201_device::nes_tf1201_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_tf1201_device::nes_tf1201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc4_device(mconfig, NES_TF1201, tag, owner, clock) { } -nes_th21311_device::nes_th21311_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_th21311_device::nes_th21311_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_konami_vrc2_device(mconfig, NES_TH21311, tag, owner, clock), m_irq_count(0), m_irq_enable(0), irq_timer(nullptr) { } -nes_waixing_sgz_device::nes_waixing_sgz_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 chr_match) +nes_waixing_sgz_device::nes_waixing_sgz_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 chr_match) : nes_konami_vrc4_device(mconfig, type, tag, owner, clock), m_chr_match(chr_match) { } -nes_waixing_sgz_device::nes_waixing_sgz_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_waixing_sgz_device::nes_waixing_sgz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_sgz_device(mconfig, NES_WAIXING_SGZ, tag, owner, clock, 0x06) { } -nes_hengg_shjy3_device::nes_hengg_shjy3_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_hengg_shjy3_device::nes_hengg_shjy3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_sgz_device(mconfig, NES_HENGG_SHJY3, tag, owner, clock, 0x04) { } diff --git a/src/devices/bus/nes/vrc_clones.h b/src/devices/bus/nes/vrc_clones.h index c6fe5b55550..c48e35c8216 100644 --- a/src/devices/bus/nes/vrc_clones.h +++ b/src/devices/bus/nes/vrc_clones.h @@ -14,7 +14,7 @@ class nes_2yudb_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_2yudb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_2yudb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -37,7 +37,7 @@ class nes_900218_device : public nes_konami_vrc2_device { public: // construction/destruction - nes_900218_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_900218_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -63,7 +63,7 @@ class nes_ax40g_device : public nes_konami_vrc2_device { public: // construction/destruction - nes_ax40g_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ax40g_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -79,7 +79,7 @@ class nes_ax5705_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_ax5705_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ax5705_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -95,7 +95,7 @@ class nes_bmc_830506c_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_bmc_830506c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_830506c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -119,7 +119,7 @@ class nes_bmc_831128c_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_bmc_831128c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_831128c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -142,7 +142,7 @@ class nes_bmc_kl06_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_bmc_kl06_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bmc_kl06_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_m(offs_t offset, u8 data) override; @@ -166,7 +166,7 @@ class nes_cityfight_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_cityfight_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_cityfight_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -182,7 +182,7 @@ class nes_shuiguan_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_shuiguan_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_shuiguan_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_m(offs_t offset) override; virtual void write_m(offs_t offset, u8 data) override; @@ -205,7 +205,7 @@ class nes_t230_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_t230_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_t230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -221,7 +221,7 @@ class nes_tf1201_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_tf1201_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_tf1201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -237,7 +237,7 @@ class nes_th21311_device : public nes_konami_vrc2_device { public: // construction/destruction - nes_th21311_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_th21311_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; @@ -264,14 +264,14 @@ class nes_waixing_sgz_device : public nes_konami_vrc4_device { public: // construction/destruction - nes_waixing_sgz_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_waixing_sgz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; virtual void chr_w(offs_t offset, u8 data) override; protected: // construction/destruction - nes_waixing_sgz_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 chr_match); + nes_waixing_sgz_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 chr_match); // device-level overrides virtual void device_start() override; @@ -286,7 +286,7 @@ class nes_hengg_shjy3_device : public nes_waixing_sgz_device { public: // construction/destruction - nes_hengg_shjy3_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_hengg_shjy3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/nes/waixing.cpp b/src/devices/bus/nes/waixing.cpp index 1f286c00485..6427b540691 100644 --- a/src/devices/bus/nes/waixing.cpp +++ b/src/devices/bus/nes/waixing.cpp @@ -54,122 +54,122 @@ DEFINE_DEVICE_TYPE(NES_WAIXING_WXZS2, nes_waixing_wxzs2_device, "nes_waixing_wxz DEFINE_DEVICE_TYPE(NES_WAIXING_FS304, nes_waixing_fs304_device, "nes_waixing_fs304", "NES Cart Waixing FS-304 PCB") -nes_waixing_a_device::nes_waixing_a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_a_device::nes_waixing_a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, type, tag, owner, clock) { } -nes_waixing_a_device::nes_waixing_a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_a_device::nes_waixing_a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_a_device(mconfig, NES_WAIXING_A, tag, owner, clock) { } -nes_waixing_a1_device::nes_waixing_a1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_a1_device::nes_waixing_a1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_a_device(mconfig, NES_WAIXING_A1, tag, owner, clock) { } -nes_waixing_b_device::nes_waixing_b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_b_device::nes_waixing_b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_a_device(mconfig, NES_WAIXING_B, tag, owner, clock) { } -nes_waixing_c_device::nes_waixing_c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_c_device::nes_waixing_c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_a_device(mconfig, NES_WAIXING_C, tag, owner, clock) { } -nes_waixing_d_device::nes_waixing_d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_d_device::nes_waixing_d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_a_device(mconfig, NES_WAIXING_D, tag, owner, clock) { } -nes_waixing_e_device::nes_waixing_e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_e_device::nes_waixing_e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_a_device(mconfig, NES_WAIXING_E, tag, owner, clock) { } -nes_waixing_f_device::nes_waixing_f_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_waixing_f_device::nes_waixing_f_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, type, tag, owner, clock) { } -nes_waixing_f_device::nes_waixing_f_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_waixing_f_device::nes_waixing_f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_f_device(mconfig, NES_WAIXING_F, tag, owner, clock) { } -nes_waixing_f1_device::nes_waixing_f1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_waixing_f1_device::nes_waixing_f1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_f_device(mconfig, NES_WAIXING_F1, tag, owner, clock) { } -nes_waixing_g_device::nes_waixing_g_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_g_device::nes_waixing_g_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_a_device(mconfig, NES_WAIXING_G, tag, owner, clock) { } -nes_waixing_h_device::nes_waixing_h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_h_device::nes_waixing_h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, type, tag, owner, clock) { } -nes_waixing_h_device::nes_waixing_h_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_h_device::nes_waixing_h_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_h_device(mconfig, NES_WAIXING_H, tag, owner, clock) { } -nes_waixing_h1_device::nes_waixing_h1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_h1_device::nes_waixing_h1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_h_device(mconfig, NES_WAIXING_H1, tag, owner, clock) { } -nes_waixing_i_device::nes_waixing_i_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_i_device::nes_waixing_i_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_a_device(mconfig, NES_WAIXING_I, tag, owner, clock) { } -nes_waixing_j_device::nes_waixing_j_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_j_device::nes_waixing_j_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_waixing_a_device(mconfig, NES_WAIXING_J, tag, owner, clock) { } -nes_waixing_sh2_device::nes_waixing_sh2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_waixing_sh2_device::nes_waixing_sh2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_WAIXING_SH2, tag, owner, clock) { } -nes_waixing_sec_device::nes_waixing_sec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_sec_device::nes_waixing_sec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_txrom_device(mconfig, NES_WAIXING_SEC, tag, owner, clock), m_reg(0) { } -nes_waixing_sgzlz_device::nes_waixing_sgzlz_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_sgzlz_device::nes_waixing_sgzlz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_WAIXING_SGZLZ, tag, owner, clock), m_reg{ 0, 0, 0, 0 } { } -nes_waixing_ffv_device::nes_waixing_ffv_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_ffv_device::nes_waixing_ffv_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_WAIXING_FFV, tag, owner, clock) { } -nes_waixing_wxzs_device::nes_waixing_wxzs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_wxzs_device::nes_waixing_wxzs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_WAIXING_WXZS, tag, owner, clock) { } -nes_waixing_dq8_device::nes_waixing_dq8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_dq8_device::nes_waixing_dq8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_WAIXING_DQ8, tag, owner, clock) { } -nes_waixing_wxzs2_device::nes_waixing_wxzs2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_wxzs2_device::nes_waixing_wxzs2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_WAIXING_WXZS2, tag, owner, clock) { } -nes_waixing_fs304_device::nes_waixing_fs304_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_waixing_fs304_device::nes_waixing_fs304_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_WAIXING_FS304, tag, owner, clock) { } diff --git a/src/devices/bus/nes/waixing.h b/src/devices/bus/nes/waixing.h index 78a979f4b0b..2f660c8f299 100644 --- a/src/devices/bus/nes/waixing.h +++ b/src/devices/bus/nes/waixing.h @@ -14,7 +14,7 @@ class nes_waixing_a_device : public nes_txrom_device { public: // construction/destruction - nes_waixing_a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_l(offs_t offset) override; virtual void write_l(offs_t offset, uint8_t data) override; @@ -25,7 +25,7 @@ public: virtual void pcb_reset() override; protected: - nes_waixing_a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -42,7 +42,7 @@ class nes_waixing_a1_device : public nes_waixing_a_device { public: // construction/destruction - nes_waixing_a1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_a1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void chr_cb(int start, int bank, int source) override; }; @@ -54,7 +54,7 @@ class nes_waixing_b_device : public nes_waixing_a_device { public: // construction/destruction - nes_waixing_b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void chr_cb(int start, int bank, int source) override; }; @@ -66,7 +66,7 @@ class nes_waixing_c_device : public nes_waixing_a_device { public: // construction/destruction - nes_waixing_c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void chr_cb(int start, int bank, int source) override; }; @@ -78,7 +78,7 @@ class nes_waixing_d_device : public nes_waixing_a_device { public: // construction/destruction - nes_waixing_d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void chr_cb(int start, int bank, int source) override; }; @@ -90,7 +90,7 @@ class nes_waixing_e_device : public nes_waixing_a_device { public: // construction/destruction - nes_waixing_e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void chr_cb(int start, int bank, int source) override; }; @@ -102,14 +102,14 @@ class nes_waixing_f_device : public nes_txrom_device { public: // construction/destruction - nes_waixing_f_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_waixing_f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_l(offs_t offset) override; virtual void write_l(offs_t offset, u8 data) override; protected: // construction/destruction - nes_waixing_f_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_waixing_f_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -119,7 +119,7 @@ class nes_waixing_f1_device : public nes_waixing_f_device { public: // construction/destruction - nes_waixing_f1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_waixing_f1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void set_chr(uint8_t chr, int chr_base, int chr_mask) override; @@ -132,7 +132,7 @@ class nes_waixing_g_device : public nes_waixing_a_device { public: // construction/destruction - nes_waixing_g_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_g_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; virtual void chr_cb(int start, int bank, int source) override; @@ -150,7 +150,7 @@ class nes_waixing_h_device : public nes_txrom_device { public: // construction/destruction - nes_waixing_h_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_h_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; virtual void chr_cb(int start, int bank, int source) override; @@ -158,7 +158,7 @@ public: // This PCB does not have 1K of internal RAM, so it's not derived from nes_waixing_a_device!! protected: - nes_waixing_h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -168,7 +168,7 @@ class nes_waixing_h1_device : public nes_waixing_h_device { public: // construction/destruction - nes_waixing_h1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_h1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -182,7 +182,7 @@ class nes_waixing_i_device : public nes_waixing_a_device { public: // construction/destruction - nes_waixing_i_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_i_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // still to emulate this variant }; @@ -194,7 +194,7 @@ class nes_waixing_j_device : public nes_waixing_a_device { public: // construction/destruction - nes_waixing_j_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_j_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; @@ -215,7 +215,7 @@ class nes_waixing_sh2_device : public nes_txrom_device { public: // construction/destruction - nes_waixing_sh2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_waixing_sh2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 chr_r(offs_t offset) override; @@ -238,7 +238,7 @@ class nes_waixing_sec_device : public nes_txrom_device { public: // construction/destruction - nes_waixing_sec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_sec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; virtual void prg_cb(int start, int bank) override; @@ -260,7 +260,7 @@ class nes_waixing_sgzlz_device : public nes_nrom_device { public: // construction/destruction - nes_waixing_sgzlz_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_sgzlz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; @@ -280,7 +280,7 @@ class nes_waixing_ffv_device : public nes_nrom_device { public: // construction/destruction - nes_waixing_ffv_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_ffv_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; @@ -300,7 +300,7 @@ class nes_waixing_wxzs_device : public nes_nrom_device { public: // construction/destruction - nes_waixing_wxzs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_wxzs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -312,7 +312,7 @@ class nes_waixing_dq8_device : public nes_nrom_device { public: // construction/destruction - nes_waixing_dq8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_dq8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -324,7 +324,7 @@ class nes_waixing_wxzs2_device : public nes_nrom_device { public: // construction/destruction - nes_waixing_wxzs2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_wxzs2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, uint8_t data) override; }; @@ -336,7 +336,7 @@ class nes_waixing_fs304_device : public nes_nrom_device { public: // construction/destruction - nes_waixing_fs304_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_waixing_fs304_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_l(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/nes/zemina.cpp b/src/devices/bus/nes/zemina.cpp index b46da0e7561..7aa684b8cfb 100644 --- a/src/devices/bus/nes/zemina.cpp +++ b/src/devices/bus/nes/zemina.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(NES_ZEMINA, nes_zemina_device, "nes_zemina", "NES Cart Zemina // constructor //------------------------------------------------- -nes_zemina_device::nes_zemina_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_zemina_device::nes_zemina_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_nrom_device(mconfig, NES_ZEMINA, tag, owner, clock) { } diff --git a/src/devices/bus/nes/zemina.h b/src/devices/bus/nes/zemina.h index 992ecdb2c13..6adb9fad091 100644 --- a/src/devices/bus/nes/zemina.h +++ b/src/devices/bus/nes/zemina.h @@ -15,7 +15,7 @@ class nes_zemina_device : public nes_nrom_device { public: // construction/destruction - nes_zemina_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_zemina_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write_h(offs_t offset, u8 data) override; diff --git a/src/devices/bus/nes_ctrl/4score.cpp b/src/devices/bus/nes_ctrl/4score.cpp index d786124d1a5..7d401826098 100644 --- a/src/devices/bus/nes_ctrl/4score.cpp +++ b/src/devices/bus/nes_ctrl/4score.cpp @@ -111,21 +111,21 @@ ioport_constructor nes_4score_p2p4_device::device_input_ports() const // nes_4score_device - constructor //------------------------------------------------- -nes_4score_device::nes_4score_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nes_4score_device::nes_4score_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_latch(0) { } -nes_4score_p1p3_device::nes_4score_p1p3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_4score_p1p3_device::nes_4score_p1p3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_4score_device(mconfig, NES_4SCORE_P1P3, tag, owner, clock) , m_joypad1(*this, "PAD1") , m_joypad3(*this, "PAD3") { } -nes_4score_p2p4_device::nes_4score_p2p4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_4score_p2p4_device::nes_4score_p2p4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_4score_device(mconfig, NES_4SCORE_P2P4, tag, owner, clock) , m_joypad2(*this, "PAD2") , m_joypad4(*this, "PAD4") diff --git a/src/devices/bus/nes_ctrl/4score.h b/src/devices/bus/nes_ctrl/4score.h index 64e5cba8002..81e416b77c9 100644 --- a/src/devices/bus/nes_ctrl/4score.h +++ b/src/devices/bus/nes_ctrl/4score.h @@ -28,7 +28,7 @@ public: protected: // construction/destruction - nes_4score_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nes_4score_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -43,7 +43,7 @@ class nes_4score_p1p3_device : public nes_4score_device { public: // construction/destruction - nes_4score_p1p3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_4score_p1p3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write(uint8_t data) override; @@ -62,7 +62,7 @@ class nes_4score_p2p4_device : public nes_4score_device { public: // construction/destruction - nes_4score_p2p4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_4score_p2p4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void write(uint8_t data) override; diff --git a/src/devices/bus/nes_ctrl/arkpaddle.cpp b/src/devices/bus/nes_ctrl/arkpaddle.cpp index cad203bc45e..80e32c93072 100644 --- a/src/devices/bus/nes_ctrl/arkpaddle.cpp +++ b/src/devices/bus/nes_ctrl/arkpaddle.cpp @@ -84,7 +84,7 @@ void nes_vausfc_device::device_add_mconfig(machine_config &config) // nes_vaus_device - constructor //------------------------------------------------- -nes_vaus_device::nes_vaus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_vaus_device::nes_vaus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_paddle(*this, "PADDLE") @@ -93,12 +93,12 @@ nes_vaus_device::nes_vaus_device(const machine_config &mconfig, device_type type { } -nes_vaus_device::nes_vaus_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_vaus_device::nes_vaus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_vaus_device(mconfig, NES_ARKPADDLE, tag, owner, clock) { } -nes_vausfc_device::nes_vausfc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_vausfc_device::nes_vausfc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_vaus_device(mconfig, NES_ARKPADDLE_FC, tag, owner, clock) , m_daisychain(*this, "subexp") { diff --git a/src/devices/bus/nes_ctrl/arkpaddle.h b/src/devices/bus/nes_ctrl/arkpaddle.h index 7ac48917adb..71ff66668e7 100644 --- a/src/devices/bus/nes_ctrl/arkpaddle.h +++ b/src/devices/bus/nes_ctrl/arkpaddle.h @@ -25,13 +25,13 @@ class nes_vaus_device : public device_t, public device_nes_control_port_interfac { public: // construction/destruction - nes_vaus_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_vaus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_bit34() override; virtual void write(u8 data) override; protected: - nes_vaus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_vaus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -49,7 +49,7 @@ class nes_vausfc_device : public nes_vaus_device { public: // construction/destruction - nes_vausfc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_vausfc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_bit34() override { return 0; } virtual u8 read_exp(offs_t offset) override; diff --git a/src/devices/bus/nes_ctrl/bcbattle.cpp b/src/devices/bus/nes_ctrl/bcbattle.cpp index 26973cfc51c..5e2b846877e 100644 --- a/src/devices/bus/nes_ctrl/bcbattle.cpp +++ b/src/devices/bus/nes_ctrl/bcbattle.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(NES_BARCODE_BATTLER, nes_bcbattle_device, "nes_bcbattle", "Ep void nes_bcbattle_device::device_add_mconfig(machine_config &config) { - BARCODE_READER(config, "battler", 0); + BARCODE_READER(config, "battler"); } @@ -75,7 +75,7 @@ TIMER_CALLBACK_MEMBER(nes_bcbattle_device::scan_tick) // nes_bcbattle_device - constructor //------------------------------------------------- -nes_bcbattle_device::nes_bcbattle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_bcbattle_device::nes_bcbattle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_BARCODE_BATTLER, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_reader(*this, "battler") diff --git a/src/devices/bus/nes_ctrl/bcbattle.h b/src/devices/bus/nes_ctrl/bcbattle.h index c51f2db64ac..f3d79c4063f 100644 --- a/src/devices/bus/nes_ctrl/bcbattle.h +++ b/src/devices/bus/nes_ctrl/bcbattle.h @@ -26,7 +26,7 @@ class nes_bcbattle_device : public device_t, { public: // construction/destruction - nes_bcbattle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_bcbattle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_exp(offs_t offset) override; diff --git a/src/devices/bus/nes_ctrl/ctrl.cpp b/src/devices/bus/nes_ctrl/ctrl.cpp index aaeec552b4e..7aa01cda926 100644 --- a/src/devices/bus/nes_ctrl/ctrl.cpp +++ b/src/devices/bus/nes_ctrl/ctrl.cpp @@ -108,7 +108,7 @@ device_nes_control_port_interface::~device_nes_control_port_interface() // nes_control_port_device - constructor //------------------------------------------------- -nes_control_port_device::nes_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +nes_control_port_device::nes_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_CONTROL_PORT, tag, owner, clock), device_single_card_slot_interface<device_nes_control_port_interface>(mconfig, *this), m_screen(*this, finder_base::DUMMY_TAG), diff --git a/src/devices/bus/nes_ctrl/ctrl.h b/src/devices/bus/nes_ctrl/ctrl.h index 01777358cda..e424913099b 100644 --- a/src/devices/bus/nes_ctrl/ctrl.h +++ b/src/devices/bus/nes_ctrl/ctrl.h @@ -60,14 +60,14 @@ public: // construction/destruction template <typename T> nes_control_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : nes_control_port_device(mconfig, tag, owner, (u32)0) + : nes_control_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - nes_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~nes_control_port_device(); u8 read_bit0(); diff --git a/src/devices/bus/nes_ctrl/dorepiano.cpp b/src/devices/bus/nes_ctrl/dorepiano.cpp index 6fd4179d2f0..71391e98515 100644 --- a/src/devices/bus/nes_ctrl/dorepiano.cpp +++ b/src/devices/bus/nes_ctrl/dorepiano.cpp @@ -93,7 +93,7 @@ ioport_constructor nes_dorepiano_device::device_input_ports() const // nes_dorepiano_device - constructor //------------------------------------------------- -nes_dorepiano_device::nes_dorepiano_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_dorepiano_device::nes_dorepiano_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_DOREPIANO, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_port(*this, "PIANO.%u", 0) diff --git a/src/devices/bus/nes_ctrl/dorepiano.h b/src/devices/bus/nes_ctrl/dorepiano.h index 63f6c1eb7af..2a68ed21422 100644 --- a/src/devices/bus/nes_ctrl/dorepiano.h +++ b/src/devices/bus/nes_ctrl/dorepiano.h @@ -26,7 +26,7 @@ class nes_dorepiano_device : { public: // construction/destruction - nes_dorepiano_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_dorepiano_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/fckeybrd.cpp b/src/devices/bus/nes_ctrl/fckeybrd.cpp index 3fd78131bc7..58f312103cd 100644 --- a/src/devices/bus/nes_ctrl/fckeybrd.cpp +++ b/src/devices/bus/nes_ctrl/fckeybrd.cpp @@ -142,7 +142,7 @@ void nes_fckeybrd_device::device_add_mconfig(machine_config &config) // nes_fckeybrd_device - constructor //------------------------------------------------- -nes_fckeybrd_device::nes_fckeybrd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_fckeybrd_device::nes_fckeybrd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_FCKEYBOARD, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_cassette(*this, "tape") diff --git a/src/devices/bus/nes_ctrl/fckeybrd.h b/src/devices/bus/nes_ctrl/fckeybrd.h index 137ff90fc1f..f6d13cee4d8 100644 --- a/src/devices/bus/nes_ctrl/fckeybrd.h +++ b/src/devices/bus/nes_ctrl/fckeybrd.h @@ -26,7 +26,7 @@ class nes_fckeybrd_device : public device_t, { public: // construction/destruction - nes_fckeybrd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_fckeybrd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/fcmat.cpp b/src/devices/bus/nes_ctrl/fcmat.cpp index f40bb9df48a..35669e37cab 100644 --- a/src/devices/bus/nes_ctrl/fcmat.cpp +++ b/src/devices/bus/nes_ctrl/fcmat.cpp @@ -117,7 +117,7 @@ ioport_constructor nes_taptapmat_device::device_input_ports() const // constructor //------------------------------------------------- -nes_fcmat_device::nes_fcmat_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_fcmat_device::nes_fcmat_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_mat(*this, "MAT_COL.%u", 0) @@ -125,12 +125,12 @@ nes_fcmat_device::nes_fcmat_device(const machine_config &mconfig, device_type ty { } -nes_ftrainer_device::nes_ftrainer_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ftrainer_device::nes_ftrainer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_fcmat_device(mconfig, NES_FTRAINER, tag, owner, clock) { } -nes_taptapmat_device::nes_taptapmat_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_taptapmat_device::nes_taptapmat_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_fcmat_device(mconfig, NES_TAPTAPMAT, tag, owner, clock) { } diff --git a/src/devices/bus/nes_ctrl/fcmat.h b/src/devices/bus/nes_ctrl/fcmat.h index 0ed731c9067..d9406aefc90 100644 --- a/src/devices/bus/nes_ctrl/fcmat.h +++ b/src/devices/bus/nes_ctrl/fcmat.h @@ -31,7 +31,7 @@ public: protected: // construction/destruction - nes_fcmat_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_fcmat_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -48,7 +48,7 @@ class nes_ftrainer_device : public nes_fcmat_device { public: // construction/destruction - nes_ftrainer_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ftrainer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -62,7 +62,7 @@ class nes_taptapmat_device : public nes_fcmat_device { public: // construction/destruction - nes_taptapmat_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_taptapmat_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/nes_ctrl/hori.cpp b/src/devices/bus/nes_ctrl/hori.cpp index 7b1351af3fd..3ac9c815a30 100644 --- a/src/devices/bus/nes_ctrl/hori.cpp +++ b/src/devices/bus/nes_ctrl/hori.cpp @@ -93,14 +93,14 @@ void nes_hori4p_device::device_add_mconfig(machine_config &config) // nes_horitwin_device - constructor //------------------------------------------------- -nes_horitwin_device::nes_horitwin_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_horitwin_device::nes_horitwin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_HORITWIN, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_subexp(*this, "subexp%u", 0) { } -nes_hori4p_device::nes_hori4p_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_hori4p_device::nes_hori4p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_HORI4P, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_subexp(*this, "subexp%u", 0) diff --git a/src/devices/bus/nes_ctrl/hori.h b/src/devices/bus/nes_ctrl/hori.h index 6146aa90d52..3e08d2c3a6b 100644 --- a/src/devices/bus/nes_ctrl/hori.h +++ b/src/devices/bus/nes_ctrl/hori.h @@ -25,7 +25,7 @@ class nes_horitwin_device : public device_t, { public: // construction/destruction - nes_horitwin_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_horitwin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; @@ -47,7 +47,7 @@ class nes_hori4p_device : public device_t, { public: // construction/destruction - nes_hori4p_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_hori4p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/joypad.cpp b/src/devices/bus/nes_ctrl/joypad.cpp index c4972912d78..dcf52df6601 100644 --- a/src/devices/bus/nes_ctrl/joypad.cpp +++ b/src/devices/bus/nes_ctrl/joypad.cpp @@ -203,7 +203,7 @@ void nes_arcstick_device::device_add_mconfig(machine_config &config) // nes_joypad_device - constructor //------------------------------------------------- -nes_joypad_device::nes_joypad_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 latch_fill) +nes_joypad_device::nes_joypad_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 latch_fill) : device_t(mconfig, type, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_joypad(*this, "JOYPAD") @@ -212,45 +212,45 @@ nes_joypad_device::nes_joypad_device(const machine_config &mconfig, device_type { } -nes_joypad_device::nes_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_joypad_device::nes_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_joypad_device(mconfig, NES_JOYPAD, tag, owner, clock) { } -nes_fcpadexp_device::nes_fcpadexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 latch_fill) +nes_fcpadexp_device::nes_fcpadexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 latch_fill) : nes_joypad_device(mconfig, type, tag, owner, clock, latch_fill) { } -nes_fcpadexp_device::nes_fcpadexp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_fcpadexp_device::nes_fcpadexp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_fcpadexp_device(mconfig, NES_FCPAD_EXP, tag, owner, clock) { } -nes_fcpad2_device::nes_fcpad2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_fcpad2_device::nes_fcpad2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_joypad_device(mconfig, NES_FCPAD_P2, tag, owner, clock) , m_mic(*this, "MIC") { } -nes_ccpadl_device::nes_ccpadl_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ccpadl_device::nes_ccpadl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_joypad_device(mconfig, NES_CCPAD_LEFT, tag, owner, clock) { } -nes_ccpadr_device::nes_ccpadr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_ccpadr_device::nes_ccpadr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_joypad_device(mconfig, NES_CCPAD_RIGHT, tag, owner, clock) { } -nes_arcstick_device::nes_arcstick_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_arcstick_device::nes_arcstick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_fcpadexp_device(mconfig, NES_ARCSTICK, tag, owner, clock) , m_daisychain(*this, "subexp") , m_cfg(*this, "CONFIG") { } -nes_vboyctrl_device::nes_vboyctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_vboyctrl_device::nes_vboyctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_joypad_device(mconfig, NES_VBOYCTRL, tag, owner, clock, 0x8000) { } diff --git a/src/devices/bus/nes_ctrl/joypad.h b/src/devices/bus/nes_ctrl/joypad.h index 5e54f26a079..fbead0ff6a6 100644 --- a/src/devices/bus/nes_ctrl/joypad.h +++ b/src/devices/bus/nes_ctrl/joypad.h @@ -26,13 +26,13 @@ class nes_joypad_device : public device_t, { public: // construction/destruction - nes_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_bit0() override; virtual void write(u8 data) override; protected: - nes_joypad_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 latch_fill = 0x80); + nes_joypad_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 latch_fill = 0x80); // device-level overrides virtual void device_start() override; @@ -52,13 +52,13 @@ class nes_fcpadexp_device : public nes_joypad_device { public: // construction/destruction - nes_fcpadexp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_fcpadexp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_bit0() override { return 0; } virtual u8 read_exp(offs_t offset) override; protected: - nes_fcpadexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 latch_fill = 0x80); + nes_fcpadexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 latch_fill = 0x80); }; @@ -68,7 +68,7 @@ class nes_fcpad2_device : public nes_joypad_device { public: // construction/destruction - nes_fcpad2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_fcpad2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_bit2() override; @@ -87,7 +87,7 @@ class nes_ccpadl_device : public nes_joypad_device { public: // construction/destruction - nes_ccpadl_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ccpadl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -101,7 +101,7 @@ class nes_ccpadr_device : public nes_joypad_device { public: // construction/destruction - nes_ccpadr_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_ccpadr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -115,7 +115,7 @@ class nes_arcstick_device : public nes_fcpadexp_device { public: // construction/destruction - nes_arcstick_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_arcstick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; @@ -137,7 +137,7 @@ class nes_vboyctrl_device : public nes_joypad_device { public: // construction/destruction - nes_vboyctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_vboyctrl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/nes_ctrl/konamibag.cpp b/src/devices/bus/nes_ctrl/konamibag.cpp index bef79cfde60..77038bafbfe 100644 --- a/src/devices/bus/nes_ctrl/konamibag.cpp +++ b/src/devices/bus/nes_ctrl/konamibag.cpp @@ -50,7 +50,7 @@ ioport_constructor nes_konamibag_device::device_input_ports() const // nes_konamibag_device - constructor //------------------------------------------------- -nes_konamibag_device::nes_konamibag_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_konamibag_device::nes_konamibag_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_KONAMIBAG, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_sensor(*this, "BAG.%u", 0) diff --git a/src/devices/bus/nes_ctrl/konamibag.h b/src/devices/bus/nes_ctrl/konamibag.h index ff98808c058..c5062493ff2 100644 --- a/src/devices/bus/nes_ctrl/konamibag.h +++ b/src/devices/bus/nes_ctrl/konamibag.h @@ -28,7 +28,7 @@ public: static constexpr feature_type imperfect_features() { return feature::CONTROLS; } // construction/destruction - nes_konamibag_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_konamibag_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/konamihs.cpp b/src/devices/bus/nes_ctrl/konamihs.cpp index d8d95c9bbd6..7113ab9d0ef 100644 --- a/src/devices/bus/nes_ctrl/konamihs.cpp +++ b/src/devices/bus/nes_ctrl/konamihs.cpp @@ -43,7 +43,7 @@ ioport_constructor nes_konamihs_device::device_input_ports() const // nes_konamihs_device - constructor //------------------------------------------------- -nes_konamihs_device::nes_konamihs_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_konamihs_device::nes_konamihs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_KONAMIHS, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_ipt(*this, "P%u", 1) diff --git a/src/devices/bus/nes_ctrl/konamihs.h b/src/devices/bus/nes_ctrl/konamihs.h index 9e8f94b6823..5fe08ce9bec 100644 --- a/src/devices/bus/nes_ctrl/konamihs.h +++ b/src/devices/bus/nes_ctrl/konamihs.h @@ -25,7 +25,7 @@ class nes_konamihs_device : public device_t, { public: // construction/destruction - nes_konamihs_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_konamihs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/miracle.cpp b/src/devices/bus/nes_ctrl/miracle.cpp index 4945358c028..839e9d709c5 100644 --- a/src/devices/bus/nes_ctrl/miracle.cpp +++ b/src/devices/bus/nes_ctrl/miracle.cpp @@ -47,7 +47,7 @@ TIMER_CALLBACK_MEMBER(nes_miracle_device::strobe_tick) // nes_miracle_device - constructor //------------------------------------------------- -nes_miracle_device::nes_miracle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nes_miracle_device::nes_miracle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_MIRACLE, tag, owner, clock), device_serial_interface(mconfig, *this), device_nes_control_port_interface(mconfig, *this), @@ -86,8 +86,8 @@ void nes_miracle_device::device_reset() // set standard MIDI parameters set_data_frame(1, 8, PARITY_NONE, STOP_BITS_1); - set_rcv_rate(31250); - set_tra_rate(31250); + set_rcv_rate(XTAL::u(31250)); + set_tra_rate(XTAL::u(31250)); m_xmit_read = m_xmit_write = 0; m_recv_read = m_recv_write = 0; diff --git a/src/devices/bus/nes_ctrl/miracle.h b/src/devices/bus/nes_ctrl/miracle.h index f06480d9a43..462ef7afc10 100644 --- a/src/devices/bus/nes_ctrl/miracle.h +++ b/src/devices/bus/nes_ctrl/miracle.h @@ -28,7 +28,7 @@ class nes_miracle_device : public device_t, { public: // construction/destruction - nes_miracle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_miracle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_bit0() override; virtual void write(uint8_t data) override; diff --git a/src/devices/bus/nes_ctrl/mjpanel.cpp b/src/devices/bus/nes_ctrl/mjpanel.cpp index 9624ff95226..c08ef5507c4 100644 --- a/src/devices/bus/nes_ctrl/mjpanel.cpp +++ b/src/devices/bus/nes_ctrl/mjpanel.cpp @@ -77,7 +77,7 @@ ioport_constructor nes_mjpanel_device::device_input_ports() const // nes_mjpanel_device - constructor //------------------------------------------------- -nes_mjpanel_device::nes_mjpanel_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_mjpanel_device::nes_mjpanel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_MJPANEL, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_panel(*this, "MJPANEL.%u", 0) diff --git a/src/devices/bus/nes_ctrl/mjpanel.h b/src/devices/bus/nes_ctrl/mjpanel.h index bbe18208426..557368cd313 100644 --- a/src/devices/bus/nes_ctrl/mjpanel.h +++ b/src/devices/bus/nes_ctrl/mjpanel.h @@ -25,7 +25,7 @@ class nes_mjpanel_device : public device_t, { public: // construction/destruction - nes_mjpanel_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_mjpanel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/pachinko.cpp b/src/devices/bus/nes_ctrl/pachinko.cpp index e5b7dd5a6ac..f9462578099 100644 --- a/src/devices/bus/nes_ctrl/pachinko.cpp +++ b/src/devices/bus/nes_ctrl/pachinko.cpp @@ -40,7 +40,7 @@ ioport_constructor nes_pachinko_device::device_input_ports() const // nes_pachinko_device - constructor //------------------------------------------------- -nes_pachinko_device::nes_pachinko_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_pachinko_device::nes_pachinko_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_fcpadexp_device(mconfig, NES_PACHINKO, tag, owner, clock, 0) , m_trigger(*this, "TRIGGER") { diff --git a/src/devices/bus/nes_ctrl/pachinko.h b/src/devices/bus/nes_ctrl/pachinko.h index d70503c6fcf..e546de49228 100644 --- a/src/devices/bus/nes_ctrl/pachinko.h +++ b/src/devices/bus/nes_ctrl/pachinko.h @@ -24,7 +24,7 @@ class nes_pachinko_device : public nes_fcpadexp_device { public: // construction/destruction - nes_pachinko_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_pachinko_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/nes_ctrl/partytap.cpp b/src/devices/bus/nes_ctrl/partytap.cpp index b06be261e49..63de3ae0d0d 100644 --- a/src/devices/bus/nes_ctrl/partytap.cpp +++ b/src/devices/bus/nes_ctrl/partytap.cpp @@ -44,7 +44,7 @@ ioport_constructor nes_partytap_device::device_input_ports() const // nes_partytap_device - constructor //------------------------------------------------- -nes_partytap_device::nes_partytap_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_partytap_device::nes_partytap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_PARTYTAP, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_inputs(*this, "INPUTS") diff --git a/src/devices/bus/nes_ctrl/partytap.h b/src/devices/bus/nes_ctrl/partytap.h index a8531a2b84d..ef03e1feb56 100644 --- a/src/devices/bus/nes_ctrl/partytap.h +++ b/src/devices/bus/nes_ctrl/partytap.h @@ -25,7 +25,7 @@ class nes_partytap_device : public device_t, { public: // construction/destruction - nes_partytap_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_partytap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/powerpad.cpp b/src/devices/bus/nes_ctrl/powerpad.cpp index 688e73e3b12..64da7402259 100644 --- a/src/devices/bus/nes_ctrl/powerpad.cpp +++ b/src/devices/bus/nes_ctrl/powerpad.cpp @@ -78,7 +78,7 @@ ioport_constructor nes_powerpad_device::device_input_ports() const // nes_powerpad_device - constructor //------------------------------------------------- -nes_powerpad_device::nes_powerpad_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_powerpad_device::nes_powerpad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_POWERPAD, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_ipt(*this, "POWERPAD.%u", 0) diff --git a/src/devices/bus/nes_ctrl/powerpad.h b/src/devices/bus/nes_ctrl/powerpad.h index a6d76c81192..75099fc0305 100644 --- a/src/devices/bus/nes_ctrl/powerpad.h +++ b/src/devices/bus/nes_ctrl/powerpad.h @@ -25,7 +25,7 @@ class nes_powerpad_device : public device_t, { public: // construction/destruction - nes_powerpad_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_powerpad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_bit34() override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/rob.cpp b/src/devices/bus/nes_ctrl/rob.cpp index 24747e6a088..11128900a35 100644 --- a/src/devices/bus/nes_ctrl/rob.cpp +++ b/src/devices/bus/nes_ctrl/rob.cpp @@ -51,7 +51,7 @@ ioport_constructor nes_rob_device::device_input_ports() const // constructor //------------------------------------------------- -nes_rob_device::nes_rob_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_rob_device::nes_rob_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_ROB, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -121,7 +121,7 @@ void nes_rob_device::device_add_mconfig(machine_config &config) m_maincpu->write_r<2>().set(FUNC(nes_rob_device::output_w)); m_maincpu->write_r<3>().set(FUNC(nes_rob_device::output_w)); - NES_ZAPPER_SENSOR(config, m_sensor, 0); + NES_ZAPPER_SENSOR(config, m_sensor); if (m_port != nullptr) m_sensor->set_screen_tag(m_port->m_screen); diff --git a/src/devices/bus/nes_ctrl/rob.h b/src/devices/bus/nes_ctrl/rob.h index 05e529f45e2..24cb03939ea 100644 --- a/src/devices/bus/nes_ctrl/rob.h +++ b/src/devices/bus/nes_ctrl/rob.h @@ -27,7 +27,7 @@ class nes_rob_device : public device_t, { public: // construction/destruction - nes_rob_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_rob_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/nes_ctrl/snesadapter.cpp b/src/devices/bus/nes_ctrl/snesadapter.cpp index 8b26824a80d..e7f36497e00 100644 --- a/src/devices/bus/nes_ctrl/snesadapter.cpp +++ b/src/devices/bus/nes_ctrl/snesadapter.cpp @@ -45,7 +45,7 @@ void nes_snesadapter_device::device_add_mconfig(machine_config &config) // nes_snesadapter_device - constructor //------------------------------------------------- -nes_snesadapter_device::nes_snesadapter_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_snesadapter_device::nes_snesadapter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_SNESADAPTER, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_snesctrl(*this, "port") diff --git a/src/devices/bus/nes_ctrl/snesadapter.h b/src/devices/bus/nes_ctrl/snesadapter.h index 903581466c7..cf99a3e4885 100644 --- a/src/devices/bus/nes_ctrl/snesadapter.h +++ b/src/devices/bus/nes_ctrl/snesadapter.h @@ -25,7 +25,7 @@ class nes_snesadapter_device : public device_t, public device_nes_control_port_i { public: // construction/destruction - nes_snesadapter_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_snesadapter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_bit0() override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/suborkey.cpp b/src/devices/bus/nes_ctrl/suborkey.cpp index ce752762913..b335b9376e1 100644 --- a/src/devices/bus/nes_ctrl/suborkey.cpp +++ b/src/devices/bus/nes_ctrl/suborkey.cpp @@ -161,7 +161,7 @@ ioport_constructor nes_suborkey_device::device_input_ports() const // nes_suborkey_device - constructor //------------------------------------------------- -nes_suborkey_device::nes_suborkey_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_suborkey_device::nes_suborkey_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_SUBORKEYBOARD, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_kbd(*this, "SUBOR.%u", 0) diff --git a/src/devices/bus/nes_ctrl/suborkey.h b/src/devices/bus/nes_ctrl/suborkey.h index a72c1dbaca7..20b31023869 100644 --- a/src/devices/bus/nes_ctrl/suborkey.h +++ b/src/devices/bus/nes_ctrl/suborkey.h @@ -25,7 +25,7 @@ class nes_suborkey_device : public device_t, { public: // construction/destruction - nes_suborkey_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_suborkey_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_exp(offs_t offset) override; virtual void write(uint8_t data) override; diff --git a/src/devices/bus/nes_ctrl/turbofile.cpp b/src/devices/bus/nes_ctrl/turbofile.cpp index 5f4db5c1641..1197b38b0dd 100644 --- a/src/devices/bus/nes_ctrl/turbofile.cpp +++ b/src/devices/bus/nes_ctrl/turbofile.cpp @@ -62,7 +62,7 @@ void nes_turbofile_device::device_add_mconfig(machine_config &config) // nes_turbofile_device - constructor //------------------------------------------------- -nes_turbofile_device::nes_turbofile_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_turbofile_device::nes_turbofile_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_TURBOFILE, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_nvram(*this, "nvram") diff --git a/src/devices/bus/nes_ctrl/turbofile.h b/src/devices/bus/nes_ctrl/turbofile.h index ba8545082d4..d9fda2a2154 100644 --- a/src/devices/bus/nes_ctrl/turbofile.h +++ b/src/devices/bus/nes_ctrl/turbofile.h @@ -26,7 +26,7 @@ class nes_turbofile_device : public device_t, { public: // construction/destruction - nes_turbofile_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_turbofile_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/zapper.cpp b/src/devices/bus/nes_ctrl/zapper.cpp index 5d55b1f2d3f..837ecbe4d43 100644 --- a/src/devices/bus/nes_ctrl/zapper.cpp +++ b/src/devices/bus/nes_ctrl/zapper.cpp @@ -63,7 +63,7 @@ ioport_constructor nes_bandaihs_device::device_input_ports() const void nes_zapper_device::device_add_mconfig(machine_config &config) { - NES_ZAPPER_SENSOR(config, m_sensor, 0); + NES_ZAPPER_SENSOR(config, m_sensor); if (m_port != nullptr) m_sensor->set_screen_tag(m_port->m_screen); } @@ -77,7 +77,7 @@ void nes_zapper_device::device_add_mconfig(machine_config &config) // constructor //------------------------------------------------- -nes_zapper_device::nes_zapper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nes_zapper_device::nes_zapper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_nes_control_port_interface(mconfig, *this) , m_sensor(*this, "sensor") @@ -87,12 +87,12 @@ nes_zapper_device::nes_zapper_device(const machine_config &mconfig, device_type { } -nes_zapper_device::nes_zapper_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_zapper_device::nes_zapper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_zapper_device(mconfig, NES_ZAPPER, tag, owner, clock) { } -nes_bandaihs_device::nes_bandaihs_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_bandaihs_device::nes_bandaihs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nes_zapper_device(mconfig, NES_BANDAIHS, tag, owner, clock) , m_joypad(*this, "JOYPAD") , m_latch(0) diff --git a/src/devices/bus/nes_ctrl/zapper.h b/src/devices/bus/nes_ctrl/zapper.h index d3ca9a298bf..8f3ecedfe59 100644 --- a/src/devices/bus/nes_ctrl/zapper.h +++ b/src/devices/bus/nes_ctrl/zapper.h @@ -27,14 +27,14 @@ class nes_zapper_device : public device_t, { public: // construction/destruction - nes_zapper_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_zapper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_bit34() override; virtual u8 read_exp(offs_t offset) override; protected: // construction/destruction - nes_zapper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nes_zapper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -55,7 +55,7 @@ class nes_bandaihs_device : public nes_zapper_device { public: // construction/destruction - nes_bandaihs_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_bandaihs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read_exp(offs_t offset) override; virtual void write(u8 data) override; diff --git a/src/devices/bus/nes_ctrl/zapper_sensor.cpp b/src/devices/bus/nes_ctrl/zapper_sensor.cpp index 6d0bf53fc6d..1e3054a1aa9 100644 --- a/src/devices/bus/nes_ctrl/zapper_sensor.cpp +++ b/src/devices/bus/nes_ctrl/zapper_sensor.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(NES_ZAPPER_SENSOR, nes_zapper_sensor_device, "nes_zapper_sens // constructor //------------------------------------------------- -nes_zapper_sensor_device::nes_zapper_sensor_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nes_zapper_sensor_device::nes_zapper_sensor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NES_ZAPPER_SENSOR, tag, owner, clock) , m_screen(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/bus/nes_ctrl/zapper_sensor.h b/src/devices/bus/nes_ctrl/zapper_sensor.h index f63a38e6b01..5f795d79473 100644 --- a/src/devices/bus/nes_ctrl/zapper_sensor.h +++ b/src/devices/bus/nes_ctrl/zapper_sensor.h @@ -25,7 +25,7 @@ class nes_zapper_sensor_device : public device_t { public: // construction/destruction - nes_zapper_sensor_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nes_zapper_sensor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_screen_tag(T &&tag) { m_screen.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/bus/newbrain/eim.cpp b/src/devices/bus/newbrain/eim.cpp index 7b3685eeea7..823c78998ea 100644 --- a/src/devices/bus/newbrain/eim.cpp +++ b/src/devices/bus/newbrain/eim.cpp @@ -77,7 +77,7 @@ void newbrain_eim_device::device_add_mconfig(machine_config &config) TIMER(config, "z80ctc_c2").configure_periodic(FUNC(newbrain_eim_device::ctc_c2_tick), attotime::from_hz(XTAL(16'000'000)/4/13)); - adc0809_device &adc(ADC0809(config, ADC0809_TAG, 500000)); + adc0809_device &adc(ADC0809(config, ADC0809_TAG, XTAL::u(500000))); adc.eoc_callback().set(FUNC(newbrain_eim_device::adc_eoc_w)); adc.in_callback<0>().set_constant(0); adc.in_callback<1>().set_constant(0); @@ -88,7 +88,7 @@ void newbrain_eim_device::device_add_mconfig(machine_config &config) adc.in_callback<6>().set_constant(0); adc.in_callback<7>().set_constant(0); - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->irq_handler().set(FUNC(newbrain_eim_device::acia_interrupt)); RS232_PORT(config, RS232_TAG, default_rs232_devices, nullptr); @@ -108,7 +108,7 @@ void newbrain_eim_device::device_add_mconfig(machine_config &config) // newbrain_eim_device - constructor //------------------------------------------------- -newbrain_eim_device::newbrain_eim_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +newbrain_eim_device::newbrain_eim_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEWBRAIN_EIM, tag, owner, clock), device_newbrain_expansion_slot_interface(mconfig, *this), m_ctc(*this, Z80CTC_TAG), diff --git a/src/devices/bus/newbrain/eim.h b/src/devices/bus/newbrain/eim.h index 4241fd4b69a..615ab6529bb 100644 --- a/src/devices/bus/newbrain/eim.h +++ b/src/devices/bus/newbrain/eim.h @@ -31,7 +31,7 @@ class newbrain_eim_device : public device_t, public device_newbrain_expansion_s { public: // construction/destruction - newbrain_eim_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + newbrain_eim_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t anout_r(); void anout_w(uint8_t data); diff --git a/src/devices/bus/newbrain/exp.cpp b/src/devices/bus/newbrain/exp.cpp index 66f7d9d302a..bb69373ec94 100644 --- a/src/devices/bus/newbrain/exp.cpp +++ b/src/devices/bus/newbrain/exp.cpp @@ -43,7 +43,7 @@ device_newbrain_expansion_slot_interface::device_newbrain_expansion_slot_interfa // newbrain_expansion_slot_device - constructor //------------------------------------------------- -newbrain_expansion_slot_device::newbrain_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +newbrain_expansion_slot_device::newbrain_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEWBRAIN_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_newbrain_expansion_slot_interface>(mconfig, *this), m_card(nullptr) diff --git a/src/devices/bus/newbrain/exp.h b/src/devices/bus/newbrain/exp.h index 922ef17213a..861109c9b0b 100644 --- a/src/devices/bus/newbrain/exp.h +++ b/src/devices/bus/newbrain/exp.h @@ -56,7 +56,7 @@ class newbrain_expansion_slot_device : public device_t, public: // construction/destruction template <typename T> - newbrain_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) + newbrain_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts, char const *dflt) : newbrain_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -65,7 +65,7 @@ public: set_fixed(false); } - newbrain_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + newbrain_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // computer interface uint8_t mreq_r(offs_t offset, uint8_t data, bool &romov, int &exrm, bool &raminh); diff --git a/src/devices/bus/newbrain/fdc.cpp b/src/devices/bus/newbrain/fdc.cpp index fa046e0d5a9..490c14de6ed 100644 --- a/src/devices/bus/newbrain/fdc.cpp +++ b/src/devices/bus/newbrain/fdc.cpp @@ -110,7 +110,7 @@ void newbrain_fdc_device::device_add_mconfig(machine_config &config) m_maincpu->set_addrmap(AS_PROGRAM, &newbrain_fdc_device::newbrain_fdc_mem); m_maincpu->set_addrmap(AS_IO, &newbrain_fdc_device::newbrain_fdc_io); - UPD765A(config, m_fdc, 8'000'000, false, true); + UPD765A(config, m_fdc, XTAL::u(8'000'000), false, true); m_fdc->intrq_wr_callback().set(FUNC(newbrain_fdc_device::fdc_int_w)); FLOPPY_CONNECTOR(config, UPD765_TAG ":0", newbrain_floppies, "525dd", floppy_image_device::default_mfm_floppy_formats); @@ -130,7 +130,7 @@ void newbrain_fdc_device::device_add_mconfig(machine_config &config) // newbrain_fdc_device - constructor //------------------------------------------------- -newbrain_fdc_device::newbrain_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +newbrain_fdc_device::newbrain_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NEWBRAIN_FDC, tag, owner, clock), device_newbrain_expansion_slot_interface(mconfig, *this), m_maincpu(*this, Z80_TAG), diff --git a/src/devices/bus/newbrain/fdc.h b/src/devices/bus/newbrain/fdc.h index 3ac24faffa6..1a9649efa76 100644 --- a/src/devices/bus/newbrain/fdc.h +++ b/src/devices/bus/newbrain/fdc.h @@ -28,7 +28,7 @@ class newbrain_fdc_device : public device_t, public device_newbrain_expansion_s { public: // construction/destruction - newbrain_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + newbrain_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/nscsi/applecd.cpp b/src/devices/bus/nscsi/applecd.cpp index aec8a154c7a..b75bfe4d329 100644 --- a/src/devices/bus/nscsi/applecd.cpp +++ b/src/devices/bus/nscsi/applecd.cpp @@ -44,7 +44,7 @@ DEFINE_DEVICE_TYPE(APPLECD150, applecd150_device, "aplcd150", "AppleCD 150") -applecd150_device::applecd150_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +applecd150_device::applecd150_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APPLECD150, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, "scsic") { diff --git a/src/devices/bus/nscsi/applecd.h b/src/devices/bus/nscsi/applecd.h index 577dfcf5b01..a2b8b6002d5 100644 --- a/src/devices/bus/nscsi/applecd.h +++ b/src/devices/bus/nscsi/applecd.h @@ -11,7 +11,7 @@ class applecd150_device : public device_t, public nscsi_slot_card_interface { public: - applecd150_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + applecd150_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/nscsi/cd.cpp b/src/devices/bus/nscsi/cd.cpp index db71c61a1e8..b2149bfd885 100644 --- a/src/devices/bus/nscsi/cd.cpp +++ b/src/devices/bus/nscsi/cd.cpp @@ -17,58 +17,58 @@ DEFINE_DEVICE_TYPE(NSCSI_XM5701, nscsi_toshiba_xm5701_device, "nxm5701", "XM-570 DEFINE_DEVICE_TYPE(NSCSI_XM5701SUN, nscsi_toshiba_xm5701_sun_device, "nxm5701sun", "XM-5701B Sun 12x CD-ROM (New)") DEFINE_DEVICE_TYPE(NSCSI_CDROM_APPLE, nscsi_cdrom_apple_device, "scsi_cdrom_apple", "Apple SCSI CD-ROM") -nscsi_cdrom_device::nscsi_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_cdrom_device::nscsi_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_cdrom_device(mconfig, NSCSI_CDROM, tag, owner, "Sony", "CDU-76S", "1.0", 0x00, 0x05) { } -nscsi_cdrom_sgi_device::nscsi_cdrom_sgi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_cdrom_sgi_device::nscsi_cdrom_sgi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_cdrom_device(mconfig, NSCSI_CDROM_SGI, tag, owner, "Sony", "CDU-76S", "1.0", 0x00, 0x05) { } -nscsi_cdrom_news_device::nscsi_cdrom_news_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_cdrom_news_device::nscsi_cdrom_news_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_cdrom_device(mconfig, NSCSI_CDROM_NEWS, tag, owner, "Sony", "CD-ROM CDU-541", "1.0A", 0x00, 0x05) { } -nscsi_dec_rrd45_device::nscsi_dec_rrd45_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_dec_rrd45_device::nscsi_dec_rrd45_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_cdrom_device(mconfig, NSCSI_RRD45, tag, owner, "DEC ", "RRD45 (C) DEC ", "0436", 0x98, 0x02) { } -nscsi_toshiba_xm3301_device::nscsi_toshiba_xm3301_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_toshiba_xm3301_device::nscsi_toshiba_xm3301_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_cdrom_device(mconfig, NSCSI_XM3301, tag, owner, "TOSHIBA ", "CD-ROM XM-3301TA", "0272", 0x88, 0x02) { } -nscsi_toshiba_xm5301_sun_device::nscsi_toshiba_xm5301_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_toshiba_xm5301_sun_device::nscsi_toshiba_xm5301_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_cdrom_device(mconfig, NSCSI_XM5301SUN, tag, owner, "TOSHIBA ", "XM-5301TASUN4XCD", "2915", 0x98, 0x02) { } -nscsi_toshiba_xm5401_sun_device::nscsi_toshiba_xm5401_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_toshiba_xm5401_sun_device::nscsi_toshiba_xm5401_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_cdrom_device(mconfig, NSCSI_XM5401SUN, tag, owner, "TOSHIBA ", "XM-5401TASUN4XCD", "1036", 0x98, 0x02) { } -nscsi_toshiba_xm5701_device::nscsi_toshiba_xm5701_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_toshiba_xm5701_device::nscsi_toshiba_xm5701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_cdrom_device(mconfig, NSCSI_XM5701, tag, owner, "TOSHIBA ", "CD-ROM XM-5701TA", "3136", 0x98, 0x02) { } -nscsi_toshiba_xm5701_sun_device::nscsi_toshiba_xm5701_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_toshiba_xm5701_sun_device::nscsi_toshiba_xm5701_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_cdrom_device(mconfig, NSCSI_XM5701SUN, tag, owner, "TOSHIBA ", "XM5701TASUN12XCD", "0997", 0x98, 0x02) { } // drive identifies as an original Apple CDSC (Sony CDU-8001 with custom firmware) -nscsi_cdrom_apple_device::nscsi_cdrom_apple_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_cdrom_apple_device::nscsi_cdrom_apple_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_cdrom_device(mconfig, NSCSI_CDROM_APPLE, tag, owner, "Sony", "CD-ROM CDU-8001", "1.0", 0x00, 0x05) { } -nscsi_cdrom_device::nscsi_cdrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nscsi_cdrom_device::nscsi_cdrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nscsi_full_device(mconfig, type, tag, owner, clock) , cdrom(nullptr) , bytes_per_block(bytes_per_sector) diff --git a/src/devices/bus/nscsi/cd.h b/src/devices/bus/nscsi/cd.h index c1745615474..b48ec459c5d 100644 --- a/src/devices/bus/nscsi/cd.h +++ b/src/devices/bus/nscsi/cd.h @@ -12,15 +12,15 @@ class nscsi_cdrom_device : public nscsi_full_device { public: - nscsi_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_cdrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_block_size(u32 block_size); protected: - nscsi_cdrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_cdrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); nscsi_cdrom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const char *mfr, const char *product, const char *rev, uint8_t inq_data, uint8_t compliance) - : nscsi_cdrom_device(mconfig, type, tag, owner, 0) + : nscsi_cdrom_device(mconfig, type, tag, owner) { strncpy(manufacturer, mfr, 8); strncpy(this->product, product, 16); @@ -61,7 +61,7 @@ private: class nscsi_cdrom_sgi_device : public nscsi_cdrom_device { public: - nscsi_cdrom_sgi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_cdrom_sgi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void scsi_command() override; @@ -77,43 +77,43 @@ public: class nscsi_dec_rrd45_device : public nscsi_cdrom_device { public: - nscsi_dec_rrd45_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_dec_rrd45_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class nscsi_toshiba_xm3301_device : public nscsi_cdrom_device { public: - nscsi_toshiba_xm3301_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_toshiba_xm3301_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class nscsi_toshiba_xm5301_sun_device : public nscsi_cdrom_device { public: - nscsi_toshiba_xm5301_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_toshiba_xm5301_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class nscsi_toshiba_xm5401_sun_device : public nscsi_cdrom_device { public: - nscsi_toshiba_xm5401_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_toshiba_xm5401_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class nscsi_toshiba_xm5701_device : public nscsi_cdrom_device { public: - nscsi_toshiba_xm5701_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_toshiba_xm5701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class nscsi_toshiba_xm5701_sun_device : public nscsi_cdrom_device { public: - nscsi_toshiba_xm5701_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_toshiba_xm5701_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class nscsi_cdrom_apple_device : public nscsi_cdrom_device { public: - nscsi_cdrom_apple_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_cdrom_apple_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void scsi_command() override; diff --git a/src/devices/bus/nscsi/cdd2000.cpp b/src/devices/bus/nscsi/cdd2000.cpp index 4a2e9c57811..4cb57266e00 100644 --- a/src/devices/bus/nscsi/cdd2000.cpp +++ b/src/devices/bus/nscsi/cdd2000.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(CDD2000, cdd2000_device, "cdd2000", "Philips CDD2000 CD-R") -cdd2000_device::cdd2000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cdd2000_device::cdd2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDD2000, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, "scsic") , m_cdcpu(*this, "cdcpu") @@ -34,11 +34,11 @@ void cdd2000_device::mem_map(address_map &map) void cdd2000_device::device_add_mconfig(machine_config &config) { - mc68hc11f1_device &cdcpu(MC68HC11F1(config, m_cdcpu, 8'000'000)); // type and clock guessed + mc68hc11f1_device &cdcpu(MC68HC11F1(config, m_cdcpu, XTAL::u(8'000'000))); // type and clock guessed cdcpu.set_addrmap(AS_PROGRAM, &cdd2000_device::mem_map); cdcpu.set_default_config(0x0b); - NCR53CF94(config, "scsic", 25'000'000); // type and clock guessed + NCR53CF94(config, "scsic", XTAL::u(25'000'000)); // type and clock guessed } ROM_START(cdd2000) diff --git a/src/devices/bus/nscsi/cdd2000.h b/src/devices/bus/nscsi/cdd2000.h index 8f2b6eb6a20..80139a8e550 100644 --- a/src/devices/bus/nscsi/cdd2000.h +++ b/src/devices/bus/nscsi/cdd2000.h @@ -11,7 +11,7 @@ class cdd2000_device : public device_t, public nscsi_slot_card_interface { public: - cdd2000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cdd2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/nscsi/cdrn820s.cpp b/src/devices/bus/nscsi/cdrn820s.cpp index 9c74b8a31d4..703432a8e10 100644 --- a/src/devices/bus/nscsi/cdrn820s.cpp +++ b/src/devices/bus/nscsi/cdrn820s.cpp @@ -12,14 +12,14 @@ DEFINE_DEVICE_TYPE(CDRN820S, cdrn820s_device, "cdrn820s", "Caravelle CDR-N820s") -cdrn820s_device::cdrn820s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +cdrn820s_device::cdrn820s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, "scsic") , m_h8(*this, "h8") { } -cdrn820s_device::cdrn820s_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cdrn820s_device::cdrn820s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cdrn820s_device(mconfig, CDRN820S, tag, owner, clock) { } @@ -35,11 +35,11 @@ void cdrn820s_device::mem_map(address_map &map) void cdrn820s_device::device_add_mconfig(machine_config &config) { - H83048(config, m_h8, 8'000'000); // type and clock unknown + H83048(config, m_h8, XTAL::u(8'000'000)); // type and clock unknown m_h8->set_addrmap(AS_PROGRAM, &cdrn820s_device::mem_map); m_h8->set_mode_a20(); - WD33C93A(config, "scsic", 10'000'000); // type and clock unknown + WD33C93A(config, "scsic", XTAL::u(10'000'000)); // type and clock unknown } ROM_START(cdrn820s) diff --git a/src/devices/bus/nscsi/cdrn820s.h b/src/devices/bus/nscsi/cdrn820s.h index c76fb007bbd..178db17f212 100644 --- a/src/devices/bus/nscsi/cdrn820s.h +++ b/src/devices/bus/nscsi/cdrn820s.h @@ -12,12 +12,12 @@ class cdrn820s_device : public device_t, public nscsi_slot_card_interface { public: - cdrn820s_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cdrn820s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } protected: - cdrn820s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + cdrn820s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/nscsi/cdu415.cpp b/src/devices/bus/nscsi/cdu415.cpp index a3b733b01d7..65cfb90af4a 100644 --- a/src/devices/bus/nscsi/cdu415.cpp +++ b/src/devices/bus/nscsi/cdu415.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(CDU415, cdu415_device, "cdu415", "Sony CDU415 CD-R") -cdu415_device::cdu415_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cdu415_device::cdu415_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDU415, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, "cxd1804ar") , m_mcu(*this, "mcu") @@ -46,11 +46,11 @@ void cdu415_device::io_map(address_map &map) void cdu415_device::device_add_mconfig(machine_config &config) { - H83032(config, m_mcu, 10000000); + H83032(config, m_mcu, XTAL::u(10000000)); m_mcu->set_addrmap(AS_PROGRAM, &cdu415_device::mem_map); m_mcu->set_addrmap(AS_IO, &cdu415_device::io_map); - NCR53C94(config, m_scsi, 25'000'000); // Temporary placeholder + NCR53C94(config, m_scsi, XTAL::u(25'000'000)); // Temporary placeholder } ROM_START(cdu415) diff --git a/src/devices/bus/nscsi/cdu415.h b/src/devices/bus/nscsi/cdu415.h index 2874c69a8cf..8549ef45577 100644 --- a/src/devices/bus/nscsi/cdu415.h +++ b/src/devices/bus/nscsi/cdu415.h @@ -13,7 +13,7 @@ class cdu415_device : public device_t, public nscsi_slot_card_interface { public: - cdu415_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cdu415_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/nscsi/cdu561.cpp b/src/devices/bus/nscsi/cdu561.cpp index 2382ab23382..f1389cfdda5 100644 --- a/src/devices/bus/nscsi/cdu561.cpp +++ b/src/devices/bus/nscsi/cdu561.cpp @@ -43,7 +43,7 @@ DEFINE_DEVICE_TYPE(CDU561_25, cdu561_25_device, "cdu561_25", "Sony CDU561-25") -cdu561_25_device::cdu561_25_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cdu561_25_device::cdu561_25_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDU561_25, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, "scsic") { diff --git a/src/devices/bus/nscsi/cdu561.h b/src/devices/bus/nscsi/cdu561.h index 1e61ec179c9..bd96d81d7eb 100644 --- a/src/devices/bus/nscsi/cdu561.h +++ b/src/devices/bus/nscsi/cdu561.h @@ -11,7 +11,7 @@ class cdu561_25_device : public device_t, public nscsi_slot_card_interface { public: - cdu561_25_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cdu561_25_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/nscsi/cdu75s.cpp b/src/devices/bus/nscsi/cdu75s.cpp index 40fd92c72fc..05a4015fc12 100644 --- a/src/devices/bus/nscsi/cdu75s.cpp +++ b/src/devices/bus/nscsi/cdu75s.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(CDU75S, cdu75s_device, "cdu75s", "Sony/Apple CDU75S CD-R") -cdu75s_device::cdu75s_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cdu75s_device::cdu75s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDU75S, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, "fas204") , m_mcu(*this, "mcu") @@ -61,7 +61,7 @@ void cdu75s_device::device_add_mconfig(machine_config &config) m_mcu->set_addrmap(AS_PROGRAM, &cdu75s_device::mem_map); m_mcu->set_addrmap(AS_IO, &cdu75s_device::io_map); - NCR53C94(config, m_scsi, 25'000'000); // FAS204, compatible + NCR53C94(config, m_scsi, XTAL::u(25'000'000)); // FAS204, compatible } ROM_START(cdu75s) diff --git a/src/devices/bus/nscsi/cdu75s.h b/src/devices/bus/nscsi/cdu75s.h index b57550f9033..0ab63028f11 100644 --- a/src/devices/bus/nscsi/cdu75s.h +++ b/src/devices/bus/nscsi/cdu75s.h @@ -13,7 +13,7 @@ class cdu75s_device : public device_t, public nscsi_slot_card_interface { public: - cdu75s_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cdu75s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/nscsi/cfp1080s.cpp b/src/devices/bus/nscsi/cfp1080s.cpp index 8425348d78c..949f78b4867 100644 --- a/src/devices/bus/nscsi/cfp1080s.cpp +++ b/src/devices/bus/nscsi/cfp1080s.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(CFP1080S, cfp1080s_device, "cfp1080s", "Conner CFP1080S") -cfp1080s_device::cfp1080s_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cfp1080s_device::cfp1080s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_device(mconfig, CFP1080S, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, DEVICE_SELF) , m_hdcpu(*this, "hdcpu") @@ -80,7 +80,7 @@ void cfp1080s_device::mem_map(address_map &map) void cfp1080s_device::device_add_mconfig(machine_config &config) { - MC68HC16Z1(config, m_hdcpu, 20'000'000); // exact type and clock unknown + MC68HC16Z1(config, m_hdcpu, XTAL::u(20'000'000)); // exact type and clock unknown m_hdcpu->set_addrmap(AS_PROGRAM, &cfp1080s_device::mem_map); } diff --git a/src/devices/bus/nscsi/cfp1080s.h b/src/devices/bus/nscsi/cfp1080s.h index 8b0ea6d568b..8ee9f31f3f0 100644 --- a/src/devices/bus/nscsi/cfp1080s.h +++ b/src/devices/bus/nscsi/cfp1080s.h @@ -11,7 +11,7 @@ class cfp1080s_device : public nscsi_device, public nscsi_slot_card_interface { public: - cfp1080s_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cfp1080s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/nscsi/crd254sh.cpp b/src/devices/bus/nscsi/crd254sh.cpp index 80fc5fae740..c06728c1f67 100644 --- a/src/devices/bus/nscsi/crd254sh.cpp +++ b/src/devices/bus/nscsi/crd254sh.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(CRD254SH, crd254sh_device, "crd254sh", "Sanyo CRD-254SH CD-ROM") -crd254sh_device::crd254sh_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +crd254sh_device::crd254sh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CRD254SH, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, "dummy_scsi") , m_mcu(*this, "mcu") diff --git a/src/devices/bus/nscsi/crd254sh.h b/src/devices/bus/nscsi/crd254sh.h index c1ac2e4123d..1a01595adb8 100644 --- a/src/devices/bus/nscsi/crd254sh.h +++ b/src/devices/bus/nscsi/crd254sh.h @@ -13,7 +13,7 @@ class crd254sh_device : public device_t, public nscsi_slot_card_interface { public: - crd254sh_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + crd254sh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/nscsi/cw7501.cpp b/src/devices/bus/nscsi/cw7501.cpp index c3ff2286f57..5eb085d1658 100644 --- a/src/devices/bus/nscsi/cw7501.cpp +++ b/src/devices/bus/nscsi/cw7501.cpp @@ -13,19 +13,19 @@ DEFINE_DEVICE_TYPE(CW7501, cw7501_device, "cw7501", "Panasonic CW-7501 CD-R") DEFINE_DEVICE_TYPE(CDR4210, cdr4210_device, "cdr4210", "Creative Technology Blaster CD-R 4210") -cw7501_device::cw7501_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +cw7501_device::cw7501_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, "scsic") , m_cdcpu(*this, "cdcpu") { } -cw7501_device::cw7501_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cw7501_device::cw7501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cw7501_device(mconfig, CW7501, tag, owner, clock) { } -cdr4210_device::cdr4210_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cdr4210_device::cdr4210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cw7501_device(mconfig, CDR4210, tag, owner, clock) { } @@ -67,10 +67,10 @@ void cw7501_device::mem_map(address_map &map) void cw7501_device::device_add_mconfig(machine_config &config) { - M37710S4(config, m_cdcpu, 12'500'000); // type and clock are total guesses + M37710S4(config, m_cdcpu, XTAL::u(12'500'000)); // type and clock are total guesses m_cdcpu->set_addrmap(AS_PROGRAM, &cw7501_device::mem_map); - NCR53CF94(config, "scsic", 25'000'000); // type and clock guessed + NCR53CF94(config, "scsic", XTAL::u(25'000'000)); // type and clock guessed } ROM_START(cw7501) diff --git a/src/devices/bus/nscsi/cw7501.h b/src/devices/bus/nscsi/cw7501.h index 0b785c4d3ba..437708f0244 100644 --- a/src/devices/bus/nscsi/cw7501.h +++ b/src/devices/bus/nscsi/cw7501.h @@ -12,12 +12,12 @@ class cw7501_device : public device_t, public nscsi_slot_card_interface { public: - cw7501_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cw7501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } protected: - cw7501_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + cw7501_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_add_mconfig(machine_config &config) override; @@ -38,7 +38,7 @@ private: class cdr4210_device : public cw7501_device { public: - cdr4210_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cdr4210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/nscsi/hd.cpp b/src/devices/bus/nscsi/hd.cpp index 7e0f48730a8..4bcf0864a7e 100644 --- a/src/devices/bus/nscsi/hd.cpp +++ b/src/devices/bus/nscsi/hd.cpp @@ -15,12 +15,12 @@ DEFINE_DEVICE_TYPE(NSCSI_HARDDISK, nscsi_harddisk_device, "scsi_harddisk", "SCSI Hard Disk") -nscsi_harddisk_device::nscsi_harddisk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_harddisk_device::nscsi_harddisk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_harddisk_device(mconfig, NSCSI_HARDDISK, tag, owner, clock) { } -nscsi_harddisk_device::nscsi_harddisk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nscsi_harddisk_device::nscsi_harddisk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nscsi_full_device(mconfig, type, tag, owner, clock), image(*this, "image"), harddisk(nullptr), lba(0), cur_lba(0), blocks(0), bytes_per_sector(0) { } diff --git a/src/devices/bus/nscsi/hd.h b/src/devices/bus/nscsi/hd.h index 7ee1f851d26..ac563c647a0 100644 --- a/src/devices/bus/nscsi/hd.h +++ b/src/devices/bus/nscsi/hd.h @@ -11,10 +11,10 @@ class nscsi_harddisk_device : public nscsi_full_device { public: - nscsi_harddisk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nscsi_harddisk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nscsi_harddisk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nscsi_harddisk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/nscsi/s1410.cpp b/src/devices/bus/nscsi/s1410.cpp index 4667ce04b98..c0812a6db52 100644 --- a/src/devices/bus/nscsi/s1410.cpp +++ b/src/devices/bus/nscsi/s1410.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(NSCSI_S1410, nscsi_s1410_device, "scsi_s1410", "Xebec S1410 5.25 Inch Winchester Disk Controller") -nscsi_s1410_device::nscsi_s1410_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_s1410_device::nscsi_s1410_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_harddisk_device(mconfig, NSCSI_S1410, tag, owner, clock) { } diff --git a/src/devices/bus/nscsi/s1410.h b/src/devices/bus/nscsi/s1410.h index bd44a53c830..d9f0263e07e 100644 --- a/src/devices/bus/nscsi/s1410.h +++ b/src/devices/bus/nscsi/s1410.h @@ -11,7 +11,7 @@ class nscsi_s1410_device : public nscsi_harddisk_device { public: - nscsi_s1410_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nscsi_s1410_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // SCSI status returns diff --git a/src/devices/bus/nscsi/smoc501.cpp b/src/devices/bus/nscsi/smoc501.cpp index 48ede8a888c..c2abb92bbc9 100644 --- a/src/devices/bus/nscsi/smoc501.cpp +++ b/src/devices/bus/nscsi/smoc501.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(SMOC501, smoc501_device, "smoc501", "Sony SMO-C501 MO Disk Controller") -smoc501_device::smoc501_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +smoc501_device::smoc501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMOC501, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, "scsic") { @@ -73,10 +73,10 @@ ioport_constructor smoc501_device::device_input_ports() const void smoc501_device::device_add_mconfig(machine_config &config) { - v40_device &mpu(V40(config, "mpu", 16'000'000)); // clock is guessed + v40_device &mpu(V40(config, "mpu", XTAL::u(16'000'000))); // clock is guessed mpu.set_addrmap(AS_PROGRAM, &smoc501_device::mem_map); - wd33c93_device &scsic(WD33C93(config, "scsic", 10'000'000)); // clock is guessed + wd33c93_device &scsic(WD33C93(config, "scsic", XTAL::u(10'000'000))); // clock is guessed scsic.irq_cb().set_inputline("mpu", INPUT_LINE_IRQ5); } diff --git a/src/devices/bus/nscsi/smoc501.h b/src/devices/bus/nscsi/smoc501.h index a5a30179f82..76950aea0a1 100644 --- a/src/devices/bus/nscsi/smoc501.h +++ b/src/devices/bus/nscsi/smoc501.h @@ -11,7 +11,7 @@ class smoc501_device : public device_t, public nscsi_slot_card_interface { public: - smoc501_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + smoc501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/nubus/bootbug.cpp b/src/devices/bus/nubus/bootbug.cpp index 5c59fff0f3f..d8d28bb14ec 100644 --- a/src/devices/bus/nubus/bootbug.cpp +++ b/src/devices/bus/nubus/bootbug.cpp @@ -78,12 +78,12 @@ const tiny_rom_entry *nubus_bootbug_device::device_rom_region() const // nubus_bootbug_device - constructor //------------------------------------------------- -nubus_bootbug_device::nubus_bootbug_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_bootbug_device::nubus_bootbug_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_bootbug_device(mconfig, NUBUS_BOOTBUG, tag, owner, clock) { } -nubus_bootbug_device::nubus_bootbug_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_bootbug_device::nubus_bootbug_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nubus_card_interface(mconfig, *this), m_uart(*this, "uart_0") diff --git a/src/devices/bus/nubus/bootbug.h b/src/devices/bus/nubus/bootbug.h index 735d343eb6c..598e625f922 100644 --- a/src/devices/bus/nubus/bootbug.h +++ b/src/devices/bus/nubus/bootbug.h @@ -20,10 +20,10 @@ class nubus_bootbug_device : { public: // construction/destruction - nubus_bootbug_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_bootbug_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_bootbug_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_bootbug_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); required_device<ns16450_device> m_uart; diff --git a/src/devices/bus/nubus/laserview.cpp b/src/devices/bus/nubus/laserview.cpp index 9e9d8ef131b..a61976b3208 100644 --- a/src/devices/bus/nubus/laserview.cpp +++ b/src/devices/bus/nubus/laserview.cpp @@ -64,12 +64,12 @@ const tiny_rom_entry *nubus_laserview_device::device_rom_region() const // nubus_laserview_device - constructor //------------------------------------------------- -nubus_laserview_device::nubus_laserview_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_laserview_device::nubus_laserview_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_laserview_device(mconfig, NUBUS_LASERVIEW, tag, owner, clock) { } -nubus_laserview_device::nubus_laserview_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_laserview_device::nubus_laserview_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nubus_card_interface(mconfig, *this), m_vbl_disable(0) diff --git a/src/devices/bus/nubus/laserview.h b/src/devices/bus/nubus/laserview.h index a2d99227566..aeb04a9f01e 100644 --- a/src/devices/bus/nubus/laserview.h +++ b/src/devices/bus/nubus/laserview.h @@ -19,10 +19,10 @@ class nubus_laserview_device : { public: // construction/destruction - nubus_laserview_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_laserview_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_laserview_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_laserview_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/nubus.cpp b/src/devices/bus/nubus/nubus.cpp index 8ac4ea719b9..4fbbc80ada6 100644 --- a/src/devices/bus/nubus/nubus.cpp +++ b/src/devices/bus/nubus/nubus.cpp @@ -27,12 +27,12 @@ DEFINE_DEVICE_TYPE(NUBUS_SLOT, nubus_slot_device, "nubus_slot", "NuBus slot") //------------------------------------------------- // nubus_slot_device - constructor //------------------------------------------------- -nubus_slot_device::nubus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_slot_device::nubus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_slot_device(mconfig, NUBUS_SLOT, tag, owner, clock) { } -nubus_slot_device::nubus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_slot_device::nubus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_single_card_slot_interface(mconfig, *this), m_nubus(*this, finder_base::DUMMY_TAG), @@ -79,12 +79,12 @@ DEFINE_DEVICE_TYPE(NUBUS, nubus_device, "nubus", "NuBus") // nubus_device - constructor //------------------------------------------------- -nubus_device::nubus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_device::nubus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_device(mconfig, NUBUS, tag, owner, clock) { } -nubus_device::nubus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_device::nubus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_space(*this, finder_base::DUMMY_TAG, -1), m_out_irq9_cb(*this), diff --git a/src/devices/bus/nubus/nubus.h b/src/devices/bus/nubus/nubus.h index c99f25b33d6..deb2ccbdeaa 100644 --- a/src/devices/bus/nubus/nubus.h +++ b/src/devices/bus/nubus/nubus.h @@ -70,7 +70,7 @@ public: // construction/destruction template <typename T, typename U> nubus_slot_device(const machine_config &mconfig, T &&tag, device_t *owner, const char *nbtag, U &&opts, const char *dflt) - : nubus_slot_device(mconfig, tag, owner, (uint32_t)0) + : nubus_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -78,7 +78,7 @@ public: set_nubus_slot(std::forward<T>(nbtag), tag); } - nubus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration template <typename T> @@ -89,7 +89,7 @@ public: } protected: - nubus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -110,7 +110,7 @@ class nubus_device : public device_t { public: // construction/destruction - nubus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); ~nubus_device() { m_device_list.detach_all(); } // inline configuration @@ -138,7 +138,7 @@ public: DECLARE_WRITE_LINE_MEMBER( irqe_w ); protected: - nubus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; diff --git a/src/devices/bus/nubus/nubus_48gc.cpp b/src/devices/bus/nubus/nubus_48gc.cpp index 9237b893150..070350fe451 100644 --- a/src/devices/bus/nubus/nubus_48gc.cpp +++ b/src/devices/bus/nubus/nubus_48gc.cpp @@ -323,7 +323,7 @@ uint32_t jmfb_device::palette_entries() const noexcept // jmfb_device - constructor //------------------------------------------------- -jmfb_device::jmfb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +jmfb_device::jmfb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nubus_card_interface(mconfig, *this), device_video_interface(mconfig, *this), @@ -335,12 +335,12 @@ jmfb_device::jmfb_device(const machine_config &mconfig, device_type type, const set_screen(*this, GC48_SCREEN_NAME); } -nubus_48gc_device::nubus_48gc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_48gc_device::nubus_48gc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : jmfb_device(mconfig, NUBUS_MDC48, tag, owner, clock) { } -nubus_824gc_device::nubus_824gc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_824gc_device::nubus_824gc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : jmfb_device(mconfig, NUBUS_MDC824, tag, owner, clock) { } diff --git a/src/devices/bus/nubus/nubus_asntmc3b.cpp b/src/devices/bus/nubus/nubus_asntmc3b.cpp index 2a45e2f2f3f..34630090bde 100644 --- a/src/devices/bus/nubus/nubus_asntmc3b.cpp +++ b/src/devices/bus/nubus/nubus_asntmc3b.cpp @@ -43,7 +43,7 @@ DEFINE_DEVICE_TYPE(NUBUS_APPLEENET, nubus_appleenet_device, "nb_aenet", "Apple N void nubus_mac8390_device::device_add_mconfig(machine_config &config) { - DP8390D(config, m_dp83902, 0); + DP8390D(config, m_dp83902); m_dp83902->irq_callback().set(FUNC(nubus_mac8390_device::dp_irq_w)); m_dp83902->mem_read_callback().set(FUNC(nubus_mac8390_device::dp_mem_read)); m_dp83902->mem_write_callback().set(FUNC(nubus_mac8390_device::dp_mem_write)); @@ -71,19 +71,19 @@ const tiny_rom_entry *nubus_appleenet_device::device_rom_region() const // nubus_mac8390_device - constructor //------------------------------------------------- -nubus_mac8390_device::nubus_mac8390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_mac8390_device::nubus_mac8390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nubus_card_interface(mconfig, *this), m_dp83902(*this, MAC8390_839X) { } -nubus_asntmc3nb_device::nubus_asntmc3nb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_asntmc3nb_device::nubus_asntmc3nb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_mac8390_device(mconfig, NUBUS_ASNTMC3NB, tag, owner, clock) { } -nubus_appleenet_device::nubus_appleenet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_appleenet_device::nubus_appleenet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_mac8390_device(mconfig, NUBUS_APPLEENET, tag, owner, clock) { } diff --git a/src/devices/bus/nubus/nubus_asntmc3b.h b/src/devices/bus/nubus/nubus_asntmc3b.h index 20b3cbe0190..04a685ab93a 100644 --- a/src/devices/bus/nubus/nubus_asntmc3b.h +++ b/src/devices/bus/nubus/nubus_asntmc3b.h @@ -20,7 +20,7 @@ class nubus_mac8390_device : { protected: // construction/destruction - nubus_mac8390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_mac8390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -49,13 +49,13 @@ private: class nubus_asntmc3nb_device : public nubus_mac8390_device { public: - nubus_asntmc3nb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_asntmc3nb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class nubus_appleenet_device : public nubus_mac8390_device { public: - nubus_appleenet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_appleenet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; }; diff --git a/src/devices/bus/nubus/nubus_cb264.cpp b/src/devices/bus/nubus/nubus_cb264.cpp index bc9f436e6bf..139da8cb1fd 100644 --- a/src/devices/bus/nubus/nubus_cb264.cpp +++ b/src/devices/bus/nubus/nubus_cb264.cpp @@ -47,7 +47,7 @@ void nubus_cb264_device::device_add_mconfig(machine_config &config) { screen_device &screen(SCREEN(config, CB264_SCREEN_NAME, SCREEN_TYPE_RASTER)); screen.set_screen_update(FUNC(nubus_cb264_device::screen_update)); - screen.set_raw(25175000, 800, 0, 640, 525, 0, 480); + screen.set_raw(XTAL::u(25175000), 800, 0, 640, 525, 0, 480); screen.set_size(1024, 768); screen.set_visarea(0, 640-1, 0, 480-1); } @@ -69,12 +69,12 @@ const tiny_rom_entry *nubus_cb264_device::device_rom_region() const // nubus_cb264_device - constructor //------------------------------------------------- -nubus_cb264_device::nubus_cb264_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_cb264_device::nubus_cb264_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_cb264_device(mconfig, NUBUS_CB264, tag, owner, clock) { } -nubus_cb264_device::nubus_cb264_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_cb264_device::nubus_cb264_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nubus_card_interface(mconfig, *this), m_cb264_mode(0), m_cb264_vbl_disable(0), m_cb264_toggle(0), m_count(0), m_clutoffs(0) diff --git a/src/devices/bus/nubus/nubus_cb264.h b/src/devices/bus/nubus/nubus_cb264.h index bb7d0e3ac98..fa6781c30ff 100644 --- a/src/devices/bus/nubus/nubus_cb264.h +++ b/src/devices/bus/nubus/nubus_cb264.h @@ -19,10 +19,10 @@ class nubus_cb264_device : { public: // construction/destruction - nubus_cb264_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_cb264_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_cb264_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_cb264_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/nubus_image.cpp b/src/devices/bus/nubus/nubus_image.cpp index 577411e3ff6..1bd830999d1 100644 --- a/src/devices/bus/nubus/nubus_image.cpp +++ b/src/devices/bus/nubus/nubus_image.cpp @@ -38,7 +38,7 @@ class nubus_image_device::messimg_disk_image_device : public device_t, public de { public: // construction/destruction - messimg_disk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + messimg_disk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // image-level overrides virtual bool is_readable() const noexcept override { return true; } @@ -67,7 +67,7 @@ public: // device type definition DEFINE_DEVICE_TYPE(MESSIMG_DISK, nubus_image_device::messimg_disk_image_device, "messimg_disk_image", "Mac image") -nubus_image_device::messimg_disk_image_device::messimg_disk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_image_device::messimg_disk_image_device::messimg_disk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MESSIMG_DISK, tag, owner, clock), device_image_interface(mconfig, *this), m_size(0), m_data(nullptr), m_ejected(false) @@ -142,7 +142,7 @@ DEFINE_DEVICE_TYPE(NUBUS_IMAGE, nubus_image_device, "nb_image", "NuBus Disk Imag void nubus_image_device::device_add_mconfig(machine_config &config) { - MESSIMG_DISK(config, IMAGE_DISK0_TAG, 0); + MESSIMG_DISK(config, IMAGE_DISK0_TAG); } //------------------------------------------------- @@ -162,12 +162,12 @@ const tiny_rom_entry *nubus_image_device::device_rom_region() const // nubus_image_device - constructor //------------------------------------------------- -nubus_image_device::nubus_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_image_device::nubus_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_image_device(mconfig, NUBUS_IMAGE, tag, owner, clock) { } -nubus_image_device::nubus_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_image_device::nubus_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nubus_card_interface(mconfig, *this), m_image(nullptr) diff --git a/src/devices/bus/nubus/nubus_image.h b/src/devices/bus/nubus/nubus_image.h index ae9257ac0c4..0e70cab520d 100644 --- a/src/devices/bus/nubus/nubus_image.h +++ b/src/devices/bus/nubus/nubus_image.h @@ -22,7 +22,7 @@ public: class messimg_disk_image_device; // construction/destruction - nubus_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: enum @@ -46,7 +46,7 @@ protected: uint32_t bytecount; }; - nubus_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/nubus_m2hires.cpp b/src/devices/bus/nubus/nubus_m2hires.cpp index 2e8d5cd0657..69504a6d693 100644 --- a/src/devices/bus/nubus/nubus_m2hires.cpp +++ b/src/devices/bus/nubus/nubus_m2hires.cpp @@ -43,7 +43,7 @@ void nubus_m2hires_device::device_add_mconfig(machine_config &config) { screen_device &screen(SCREEN(config, M2HIRES_SCREEN_NAME, SCREEN_TYPE_RASTER)); screen.set_screen_update(FUNC(nubus_m2hires_device::screen_update)); - screen.set_raw(25175000, 800, 0, 640, 525, 0, 480); + screen.set_raw(XTAL::u(25175000), 800, 0, 640, 525, 0, 480); screen.set_size(1024, 768); screen.set_visarea(0, 640-1, 0, 480-1); } @@ -65,12 +65,12 @@ const tiny_rom_entry *nubus_m2hires_device::device_rom_region() const // nubus_m2hires_device - constructor //------------------------------------------------- -nubus_m2hires_device::nubus_m2hires_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_m2hires_device::nubus_m2hires_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_m2hires_device(mconfig, NUBUS_M2HIRES, tag, owner, clock) { } -nubus_m2hires_device::nubus_m2hires_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_m2hires_device::nubus_m2hires_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), device_nubus_card_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/nubus_m2hires.h b/src/devices/bus/nubus/nubus_m2hires.h index 91af4aedafd..f5836fd14b7 100644 --- a/src/devices/bus/nubus/nubus_m2hires.h +++ b/src/devices/bus/nubus/nubus_m2hires.h @@ -20,10 +20,10 @@ class nubus_m2hires_device : { public: // construction/destruction - nubus_m2hires_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_m2hires_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_m2hires_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_m2hires_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/nubus_m2video.cpp b/src/devices/bus/nubus/nubus_m2video.cpp index 688acf0ec1f..fa48c6966a5 100644 --- a/src/devices/bus/nubus/nubus_m2video.cpp +++ b/src/devices/bus/nubus/nubus_m2video.cpp @@ -44,7 +44,7 @@ void nubus_m2video_device::device_add_mconfig(machine_config &config) { screen_device &screen(SCREEN(config, M2VIDEO_SCREEN_NAME, SCREEN_TYPE_RASTER)); screen.set_screen_update(FUNC(nubus_m2video_device::screen_update)); - screen.set_raw(25175000, 800, 0, 640, 525, 0, 480); + screen.set_raw(XTAL::u(25175000), 800, 0, 640, 525, 0, 480); screen.set_size(1024, 768); screen.set_visarea(0, 640-1, 0, 480-1); } @@ -66,12 +66,12 @@ const tiny_rom_entry *nubus_m2video_device::device_rom_region() const // nubus_m2video_device - constructor //------------------------------------------------- -nubus_m2video_device::nubus_m2video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_m2video_device::nubus_m2video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_m2video_device(mconfig, NUBUS_M2VIDEO, tag, owner, clock) { } -nubus_m2video_device::nubus_m2video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_m2video_device::nubus_m2video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), device_nubus_card_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/nubus_m2video.h b/src/devices/bus/nubus/nubus_m2video.h index 79f0f777eed..e7e6245b90b 100644 --- a/src/devices/bus/nubus/nubus_m2video.h +++ b/src/devices/bus/nubus/nubus_m2video.h @@ -20,10 +20,10 @@ class nubus_m2video_device : { public: // construction/destruction - nubus_m2video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_m2video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_m2video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_m2video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/nubus_radiustpd.cpp b/src/devices/bus/nubus/nubus_radiustpd.cpp index 5bd9cb26475..99c834152d8 100644 --- a/src/devices/bus/nubus/nubus_radiustpd.cpp +++ b/src/devices/bus/nubus/nubus_radiustpd.cpp @@ -63,14 +63,14 @@ const tiny_rom_entry *nubus_radiustpd_device::device_rom_region() const // nubus_radiustpd_device - constructor //------------------------------------------------- -nubus_radiustpd_device::nubus_radiustpd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_radiustpd_device::nubus_radiustpd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_radiustpd_device(mconfig, NUBUS_RADIUSTPD, tag, owner, clock) { (void)m_toggle; (void)&m_colors[0]; } -nubus_radiustpd_device::nubus_radiustpd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_radiustpd_device::nubus_radiustpd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), device_nubus_card_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/nubus_radiustpd.h b/src/devices/bus/nubus/nubus_radiustpd.h index 54fbbaa329e..c3d92be0045 100644 --- a/src/devices/bus/nubus/nubus_radiustpd.h +++ b/src/devices/bus/nubus/nubus_radiustpd.h @@ -20,10 +20,10 @@ class nubus_radiustpd_device : { public: // construction/destruction - nubus_radiustpd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_radiustpd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_radiustpd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_radiustpd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/nubus_spec8.cpp b/src/devices/bus/nubus/nubus_spec8.cpp index e85430b0f17..aa10712ded6 100644 --- a/src/devices/bus/nubus/nubus_spec8.cpp +++ b/src/devices/bus/nubus/nubus_spec8.cpp @@ -198,12 +198,12 @@ uint32_t nubus_spec8s3_device::palette_entries() const noexcept // nubus_spec8s3_device - constructor //------------------------------------------------- -nubus_spec8s3_device::nubus_spec8s3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_spec8s3_device::nubus_spec8s3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_spec8s3_device(mconfig, NUBUS_SPEC8S3, tag, owner, clock) { } -nubus_spec8s3_device::nubus_spec8s3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_spec8s3_device::nubus_spec8s3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nubus_card_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/nubus_specpdq.cpp b/src/devices/bus/nubus/nubus_specpdq.cpp index c496fa77d05..f1b865f30ae 100644 --- a/src/devices/bus/nubus/nubus_specpdq.cpp +++ b/src/devices/bus/nubus/nubus_specpdq.cpp @@ -185,12 +185,12 @@ uint32_t nubus_specpdq_device::palette_entries() const noexcept // nubus_specpdq_device - constructor //------------------------------------------------- -nubus_specpdq_device::nubus_specpdq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_specpdq_device::nubus_specpdq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_specpdq_device(mconfig, NUBUS_SPECPDQ, tag, owner, clock) { } -nubus_specpdq_device::nubus_specpdq_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_specpdq_device::nubus_specpdq_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nubus_card_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/nubus_vikbw.cpp b/src/devices/bus/nubus/nubus_vikbw.cpp index af61f6dc45f..81a1770ed9f 100644 --- a/src/devices/bus/nubus/nubus_vikbw.cpp +++ b/src/devices/bus/nubus/nubus_vikbw.cpp @@ -62,12 +62,12 @@ const tiny_rom_entry *nubus_vikbw_device::device_rom_region() const // nubus_vikbw_device - constructor //------------------------------------------------- -nubus_vikbw_device::nubus_vikbw_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_vikbw_device::nubus_vikbw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_vikbw_device(mconfig, NUBUS_VIKBW, tag, owner, clock) { } -nubus_vikbw_device::nubus_vikbw_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_vikbw_device::nubus_vikbw_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nubus_card_interface(mconfig, *this), m_vbl_disable(0) diff --git a/src/devices/bus/nubus/nubus_vikbw.h b/src/devices/bus/nubus/nubus_vikbw.h index 9cd8a0f295a..a98b31c86bb 100644 --- a/src/devices/bus/nubus/nubus_vikbw.h +++ b/src/devices/bus/nubus/nubus_vikbw.h @@ -19,10 +19,10 @@ class nubus_vikbw_device : { public: // construction/destruction - nubus_vikbw_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_vikbw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_vikbw_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_vikbw_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/nubus_wsportrait.cpp b/src/devices/bus/nubus/nubus_wsportrait.cpp index 41d96442987..bd0eab275bb 100644 --- a/src/devices/bus/nubus/nubus_wsportrait.cpp +++ b/src/devices/bus/nubus/nubus_wsportrait.cpp @@ -68,12 +68,12 @@ const tiny_rom_entry *nubus_wsportrait_device::device_rom_region() const // nubus_wsportrait_device - constructor //------------------------------------------------- -nubus_wsportrait_device::nubus_wsportrait_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_wsportrait_device::nubus_wsportrait_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_wsportrait_device(mconfig, NUBUS_WSPORTRAIT, tag, owner, clock) { } -nubus_wsportrait_device::nubus_wsportrait_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_wsportrait_device::nubus_wsportrait_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), device_nubus_card_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/nubus_wsportrait.h b/src/devices/bus/nubus/nubus_wsportrait.h index e25292c792d..a5338a8c4c7 100644 --- a/src/devices/bus/nubus/nubus_wsportrait.h +++ b/src/devices/bus/nubus/nubus_wsportrait.h @@ -20,10 +20,10 @@ class nubus_wsportrait_device : { public: // construction/destruction - nubus_wsportrait_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_wsportrait_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_wsportrait_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_wsportrait_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/pds30_30hr.cpp b/src/devices/bus/nubus/pds30_30hr.cpp index 064932d8f5c..185012bfb04 100644 --- a/src/devices/bus/nubus/pds30_30hr.cpp +++ b/src/devices/bus/nubus/pds30_30hr.cpp @@ -43,7 +43,7 @@ void nubus_xceed30hr_device::device_add_mconfig(machine_config &config) { screen_device &screen(SCREEN(config, XCEED30HR_SCREEN_NAME, SCREEN_TYPE_RASTER)); screen.set_screen_update(FUNC(nubus_xceed30hr_device::screen_update)); - screen.set_raw(25175000, 800, 0, 640, 525, 0, 480); + screen.set_raw(XTAL::u(25175000), 800, 0, 640, 525, 0, 480); screen.set_size(1024, 768); screen.set_visarea(0, 640-1, 0, 480-1); } @@ -65,12 +65,12 @@ const tiny_rom_entry *nubus_xceed30hr_device::device_rom_region() const // nubus_xceed30hr_device - constructor //------------------------------------------------- -nubus_xceed30hr_device::nubus_xceed30hr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_xceed30hr_device::nubus_xceed30hr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_xceed30hr_device(mconfig, PDS030_XCEED30HR, tag, owner, clock) { } -nubus_xceed30hr_device::nubus_xceed30hr_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_xceed30hr_device::nubus_xceed30hr_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), device_nubus_card_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/pds30_30hr.h b/src/devices/bus/nubus/pds30_30hr.h index 6114a5dcfa8..de041355221 100644 --- a/src/devices/bus/nubus/pds30_30hr.h +++ b/src/devices/bus/nubus/pds30_30hr.h @@ -20,10 +20,10 @@ class nubus_xceed30hr_device : { public: // construction/destruction - nubus_xceed30hr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_xceed30hr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_xceed30hr_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_xceed30hr_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/pds30_cb264.cpp b/src/devices/bus/nubus/pds30_cb264.cpp index c485772c843..b9c47bd16f6 100644 --- a/src/devices/bus/nubus/pds30_cb264.cpp +++ b/src/devices/bus/nubus/pds30_cb264.cpp @@ -39,7 +39,7 @@ void nubus_cb264se30_device::device_add_mconfig(machine_config &config) { screen_device &screen(SCREEN(config, CB264SE30_SCREEN_NAME, SCREEN_TYPE_RASTER)); screen.set_screen_update(FUNC(nubus_cb264se30_device::screen_update)); - screen.set_raw(25175000, 800, 0, 640, 525, 0, 480); + screen.set_raw(XTAL::u(25175000), 800, 0, 640, 525, 0, 480); screen.set_size(1024, 768); screen.set_visarea(0, 640-1, 0, 480-1); } @@ -61,13 +61,13 @@ const tiny_rom_entry *nubus_cb264se30_device::device_rom_region() const // nubus_cb264se30_device - constructor //------------------------------------------------- -nubus_cb264se30_device::nubus_cb264se30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_cb264se30_device::nubus_cb264se30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_cb264se30_device(mconfig, PDS030_CB264SE30, tag, owner, clock) { (void)m_toggle; } -nubus_cb264se30_device::nubus_cb264se30_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_cb264se30_device::nubus_cb264se30_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), device_nubus_card_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/pds30_cb264.h b/src/devices/bus/nubus/pds30_cb264.h index b991dc44d1f..a0ac713121f 100644 --- a/src/devices/bus/nubus/pds30_cb264.h +++ b/src/devices/bus/nubus/pds30_cb264.h @@ -20,10 +20,10 @@ class nubus_cb264se30_device : { public: // construction/destruction - nubus_cb264se30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_cb264se30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_cb264se30_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_cb264se30_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/pds30_mc30.cpp b/src/devices/bus/nubus/pds30_mc30.cpp index 2363f23517d..271694d4c4d 100644 --- a/src/devices/bus/nubus/pds30_mc30.cpp +++ b/src/devices/bus/nubus/pds30_mc30.cpp @@ -42,7 +42,7 @@ void nubus_xceedmc30_device::device_add_mconfig(machine_config &config) { screen_device &screen(SCREEN(config, XCEEDMC30_SCREEN_NAME, SCREEN_TYPE_RASTER)); screen.set_screen_update(FUNC(nubus_xceedmc30_device::screen_update)); - screen.set_raw(25175000, 800, 0, 640, 525, 0, 480); + screen.set_raw(XTAL::u(25175000), 800, 0, 640, 525, 0, 480); screen.set_size(1024, 768); screen.set_visarea(0, 640-1, 0, 480-1); } @@ -64,12 +64,12 @@ const tiny_rom_entry *nubus_xceedmc30_device::device_rom_region() const // nubus_xceedmc30_device - constructor //------------------------------------------------- -nubus_xceedmc30_device::nubus_xceedmc30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_xceedmc30_device::nubus_xceedmc30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_xceedmc30_device(mconfig, PDS030_XCEEDMC30, tag, owner, clock) { } -nubus_xceedmc30_device::nubus_xceedmc30_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_xceedmc30_device::nubus_xceedmc30_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), device_nubus_card_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/pds30_mc30.h b/src/devices/bus/nubus/pds30_mc30.h index 33cdabed6dc..93d72e6e9c1 100644 --- a/src/devices/bus/nubus/pds30_mc30.h +++ b/src/devices/bus/nubus/pds30_mc30.h @@ -20,10 +20,10 @@ class nubus_xceedmc30_device : { public: // construction/destruction - nubus_xceedmc30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_xceedmc30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_xceedmc30_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_xceedmc30_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/pds30_procolor816.cpp b/src/devices/bus/nubus/pds30_procolor816.cpp index e58f55ac07d..5251b83daab 100644 --- a/src/devices/bus/nubus/pds30_procolor816.cpp +++ b/src/devices/bus/nubus/pds30_procolor816.cpp @@ -45,7 +45,7 @@ void nubus_procolor816_device::device_add_mconfig(machine_config &config) { screen_device &screen(SCREEN(config, PROCOLOR816_SCREEN_NAME, SCREEN_TYPE_RASTER)); screen.set_screen_update(FUNC(nubus_procolor816_device::screen_update)); - screen.set_raw(25175000, 800, 0, 640, 525, 0, 480); + screen.set_raw(XTAL::u(25175000), 800, 0, 640, 525, 0, 480); screen.set_size(1024, 768); screen.set_visarea(0, 640-1, 0, 480-1); } @@ -67,12 +67,12 @@ const tiny_rom_entry *nubus_procolor816_device::device_rom_region() const // nubus_procolor816_device - constructor //------------------------------------------------- -nubus_procolor816_device::nubus_procolor816_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_procolor816_device::nubus_procolor816_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_procolor816_device(mconfig, PDS030_PROCOLOR816, tag, owner, clock) { } -nubus_procolor816_device::nubus_procolor816_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_procolor816_device::nubus_procolor816_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), device_nubus_card_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/pds30_procolor816.h b/src/devices/bus/nubus/pds30_procolor816.h index 653186d572b..5caf1a58d7e 100644 --- a/src/devices/bus/nubus/pds30_procolor816.h +++ b/src/devices/bus/nubus/pds30_procolor816.h @@ -20,10 +20,10 @@ class nubus_procolor816_device : { public: // construction/destruction - nubus_procolor816_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_procolor816_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_procolor816_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_procolor816_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/pds30_sigmalview.cpp b/src/devices/bus/nubus/pds30_sigmalview.cpp index 0e82f923cda..f3494fd1f38 100644 --- a/src/devices/bus/nubus/pds30_sigmalview.cpp +++ b/src/devices/bus/nubus/pds30_sigmalview.cpp @@ -61,13 +61,13 @@ const tiny_rom_entry *nubus_lview_device::device_rom_region() const // nubus_lview_device - constructor //------------------------------------------------- -nubus_lview_device::nubus_lview_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_lview_device::nubus_lview_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_lview_device(mconfig, PDS030_LVIEW, tag, owner, clock) { (void)m_toggle; } -nubus_lview_device::nubus_lview_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_lview_device::nubus_lview_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), device_nubus_card_interface(mconfig, *this), diff --git a/src/devices/bus/nubus/pds30_sigmalview.h b/src/devices/bus/nubus/pds30_sigmalview.h index e120b00ab53..4548ce0ad69 100644 --- a/src/devices/bus/nubus/pds30_sigmalview.h +++ b/src/devices/bus/nubus/pds30_sigmalview.h @@ -20,10 +20,10 @@ class nubus_lview_device : { public: // construction/destruction - nubus_lview_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_lview_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_lview_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_lview_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/nubus/quadralink.cpp b/src/devices/bus/nubus/quadralink.cpp index 0e6ecd1a567..35232431ed3 100644 --- a/src/devices/bus/nubus/quadralink.cpp +++ b/src/devices/bus/nubus/quadralink.cpp @@ -85,12 +85,12 @@ const tiny_rom_entry *nubus_quadralink_device::device_rom_region() const // nubus_quadralink_device - constructor //------------------------------------------------- -nubus_quadralink_device::nubus_quadralink_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nubus_quadralink_device::nubus_quadralink_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nubus_quadralink_device(mconfig, NUBUS_QUADRALINK, tag, owner, clock) { } -nubus_quadralink_device::nubus_quadralink_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nubus_quadralink_device::nubus_quadralink_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nubus_card_interface(mconfig, *this), m_scc1(*this, "scc1"), diff --git a/src/devices/bus/nubus/quadralink.h b/src/devices/bus/nubus/quadralink.h index 3960c24d069..6b8ea46e091 100644 --- a/src/devices/bus/nubus/quadralink.h +++ b/src/devices/bus/nubus/quadralink.h @@ -20,10 +20,10 @@ class nubus_quadralink_device : { public: // construction/destruction - nubus_quadralink_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nubus_quadralink_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - nubus_quadralink_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nubus_quadralink_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); required_device<z80scc_device> m_scc1, m_scc2; diff --git a/src/devices/bus/odyssey2/4in1.cpp b/src/devices/bus/odyssey2/4in1.cpp index c0c3788a05e..7c0cda11b63 100644 --- a/src/devices/bus/odyssey2/4in1.cpp +++ b/src/devices/bus/odyssey2/4in1.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(O2_ROM_4IN1, o2_4in1_device, "o2_4in1", "Videopac 40 Cartridg // o2_4in1_device - constructor //------------------------------------------------- -o2_4in1_device::o2_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +o2_4in1_device::o2_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, O2_ROM_4IN1, tag, owner, clock), device_o2_cart_interface(mconfig, *this) { } diff --git a/src/devices/bus/odyssey2/4in1.h b/src/devices/bus/odyssey2/4in1.h index 2840361bfe0..663c5335b63 100644 --- a/src/devices/bus/odyssey2/4in1.h +++ b/src/devices/bus/odyssey2/4in1.h @@ -21,7 +21,7 @@ class o2_4in1_device : public device_t, { public: // construction/destruction - o2_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + o2_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/odyssey2/chess.cpp b/src/devices/bus/odyssey2/chess.cpp index 3bb5fed470c..c26febc2087 100644 --- a/src/devices/bus/odyssey2/chess.cpp +++ b/src/devices/bus/odyssey2/chess.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(O2_ROM_CHESS, o2_chess_device, "o2_chess", "Videopac C7010 Ca // o2_chess_device - constructor //------------------------------------------------- -o2_chess_device::o2_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +o2_chess_device::o2_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, O2_ROM_CHESS, tag, owner, clock), device_o2_cart_interface(mconfig, *this), m_maincpu(*this, "maincpu"), diff --git a/src/devices/bus/odyssey2/chess.h b/src/devices/bus/odyssey2/chess.h index 0b37c50684c..986d16a3090 100644 --- a/src/devices/bus/odyssey2/chess.h +++ b/src/devices/bus/odyssey2/chess.h @@ -24,7 +24,7 @@ class o2_chess_device : public device_t, { public: // construction/destruction - o2_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + o2_chess_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/odyssey2/homecomp.cpp b/src/devices/bus/odyssey2/homecomp.cpp index 2ab6f45b153..91788c9db30 100644 --- a/src/devices/bus/odyssey2/homecomp.cpp +++ b/src/devices/bus/odyssey2/homecomp.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(O2_ROM_HOMECOMP, o2_homecomp_device, "o2_homecomp", "Videopac // o2_homecomp_device - constructor //------------------------------------------------- -o2_homecomp_device::o2_homecomp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +o2_homecomp_device::o2_homecomp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, O2_ROM_HOMECOMP, tag, owner, clock), device_o2_cart_interface(mconfig, *this), m_maincpu(*this, "maincpu"), diff --git a/src/devices/bus/odyssey2/homecomp.h b/src/devices/bus/odyssey2/homecomp.h index 7971afbff02..0fd5ab0fa61 100644 --- a/src/devices/bus/odyssey2/homecomp.h +++ b/src/devices/bus/odyssey2/homecomp.h @@ -25,7 +25,7 @@ class o2_homecomp_device : public device_t, { public: // construction/destruction - o2_homecomp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + o2_homecomp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/odyssey2/ktaa.cpp b/src/devices/bus/odyssey2/ktaa.cpp index b9cf38bbf95..4f885f23bbb 100644 --- a/src/devices/bus/odyssey2/ktaa.cpp +++ b/src/devices/bus/odyssey2/ktaa.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(O2_ROM_KTAA, o2_ktaa_device, "o2_ktaa", "Videopac+ KTAA Cartr // o2_ktaa_device - constructor //------------------------------------------------- -o2_ktaa_device::o2_ktaa_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +o2_ktaa_device::o2_ktaa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, O2_ROM_KTAA, tag, owner, clock), device_o2_cart_interface(mconfig, *this) { } diff --git a/src/devices/bus/odyssey2/ktaa.h b/src/devices/bus/odyssey2/ktaa.h index ebb2da83a0b..53789a817db 100644 --- a/src/devices/bus/odyssey2/ktaa.h +++ b/src/devices/bus/odyssey2/ktaa.h @@ -21,7 +21,7 @@ class o2_ktaa_device : public device_t, { public: // construction/destruction - o2_ktaa_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + o2_ktaa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/odyssey2/rally.cpp b/src/devices/bus/odyssey2/rally.cpp index e2d9adb135d..1245a501052 100644 --- a/src/devices/bus/odyssey2/rally.cpp +++ b/src/devices/bus/odyssey2/rally.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(O2_ROM_RALLY, o2_rally_device, "o2_rally", "Videopac+ 60 Cart // o2_rally_device - constructor //------------------------------------------------- -o2_rally_device::o2_rally_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +o2_rally_device::o2_rally_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, O2_ROM_RALLY, tag, owner, clock), device_o2_cart_interface(mconfig, *this) { } diff --git a/src/devices/bus/odyssey2/rally.h b/src/devices/bus/odyssey2/rally.h index 8d359362dce..63f6e16974f 100644 --- a/src/devices/bus/odyssey2/rally.h +++ b/src/devices/bus/odyssey2/rally.h @@ -21,7 +21,7 @@ class o2_rally_device : public device_t, { public: // construction/destruction - o2_rally_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + o2_rally_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/odyssey2/rom.cpp b/src/devices/bus/odyssey2/rom.cpp index b964d99b584..75664e64168 100644 --- a/src/devices/bus/odyssey2/rom.cpp +++ b/src/devices/bus/odyssey2/rom.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(O2_ROM_STD, o2_rom_device, "o2_rom", "Odyssey 2 Standard Cart // o2_rom_device - constructor //------------------------------------------------- -o2_rom_device::o2_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +o2_rom_device::o2_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, O2_ROM_STD, tag, owner, clock), device_o2_cart_interface(mconfig, *this) { } diff --git a/src/devices/bus/odyssey2/rom.h b/src/devices/bus/odyssey2/rom.h index 204d96030ce..17545c90633 100644 --- a/src/devices/bus/odyssey2/rom.h +++ b/src/devices/bus/odyssey2/rom.h @@ -21,7 +21,7 @@ class o2_rom_device : public device_t, { public: // construction/destruction - o2_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + o2_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/odyssey2/slot.cpp b/src/devices/bus/odyssey2/slot.cpp index 1e85ca3d4fa..8c3762b816a 100644 --- a/src/devices/bus/odyssey2/slot.cpp +++ b/src/devices/bus/odyssey2/slot.cpp @@ -50,7 +50,7 @@ device_o2_cart_interface::~device_o2_cart_interface() // o2_cart_slot_device - constructor //------------------------------------------------- -o2_cart_slot_device::o2_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +o2_cart_slot_device::o2_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, O2_CART_SLOT, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_single_card_slot_interface<device_o2_cart_interface>(mconfig, *this) diff --git a/src/devices/bus/odyssey2/slot.h b/src/devices/bus/odyssey2/slot.h index 09fcd34891e..7031bd5856a 100644 --- a/src/devices/bus/odyssey2/slot.h +++ b/src/devices/bus/odyssey2/slot.h @@ -101,7 +101,7 @@ public: // construction/destruction template <typename T> o2_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : o2_cart_slot_device(mconfig, tag, owner, 0) + : o2_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -109,7 +109,7 @@ public: set_fixed(false); } - o2_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + o2_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~o2_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/odyssey2/test.cpp b/src/devices/bus/odyssey2/test.cpp index 60141698f3c..ccee1c6a0f4 100644 --- a/src/devices/bus/odyssey2/test.cpp +++ b/src/devices/bus/odyssey2/test.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(O2_ROM_TEST, o2_test_device, "o2_test", "Videopac Service Tes // o2_test_device - constructor //------------------------------------------------- -o2_test_device::o2_test_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +o2_test_device::o2_test_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, O2_ROM_TEST, tag, owner, clock), device_o2_cart_interface(mconfig, *this), m_digit_out(*this, "tc_digit") diff --git a/src/devices/bus/odyssey2/test.h b/src/devices/bus/odyssey2/test.h index 9227a9d6ea1..d7a93a71f0c 100644 --- a/src/devices/bus/odyssey2/test.h +++ b/src/devices/bus/odyssey2/test.h @@ -21,7 +21,7 @@ class o2_test_device : public device_t, { public: // construction/destruction - o2_test_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + o2_test_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/odyssey2/voice.cpp b/src/devices/bus/odyssey2/voice.cpp index 831a02bcc1a..3c2b5b0b6e3 100644 --- a/src/devices/bus/odyssey2/voice.cpp +++ b/src/devices/bus/odyssey2/voice.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(O2_ROM_VOICE, o2_voice_device, "o2_voice", "Odyssey 2 The Voi // o2_voice_device - constructor //------------------------------------------------- -o2_voice_device::o2_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +o2_voice_device::o2_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, O2_ROM_VOICE, tag, owner, clock), device_o2_cart_interface(mconfig, *this), m_speech(*this, "speech"), diff --git a/src/devices/bus/odyssey2/voice.h b/src/devices/bus/odyssey2/voice.h index a8e3000032f..32ca5383dab 100644 --- a/src/devices/bus/odyssey2/voice.h +++ b/src/devices/bus/odyssey2/voice.h @@ -22,7 +22,7 @@ class o2_voice_device : public device_t, { public: // construction/destruction - o2_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + o2_voice_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void cart_init() override; diff --git a/src/devices/bus/oricext/jasmin.cpp b/src/devices/bus/oricext/jasmin.cpp index a50ab9d742d..4652f474671 100644 --- a/src/devices/bus/oricext/jasmin.cpp +++ b/src/devices/bus/oricext/jasmin.cpp @@ -37,7 +37,7 @@ void oric_jasmin_device::map(address_map &map) map(0x3f8, 0x3ff).w(m_fdlatch, FUNC(ls259_device::write_d0)); } -oric_jasmin_device::oric_jasmin_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +oric_jasmin_device::oric_jasmin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ORIC_JASMIN, tag, owner, clock), device_oricext_interface(mconfig, *this), m_fdc(*this, "fdc"), diff --git a/src/devices/bus/oricext/jasmin.h b/src/devices/bus/oricext/jasmin.h index 17baba8aaad..d215ef9a334 100644 --- a/src/devices/bus/oricext/jasmin.h +++ b/src/devices/bus/oricext/jasmin.h @@ -15,7 +15,7 @@ DECLARE_DEVICE_TYPE(ORIC_JASMIN, oric_jasmin_device) class oric_jasmin_device : public device_t, public device_oricext_interface { public: - oric_jasmin_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + oric_jasmin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~oric_jasmin_device(); DECLARE_INPUT_CHANGED_MEMBER(boot_pressed); diff --git a/src/devices/bus/oricext/microdisc.cpp b/src/devices/bus/oricext/microdisc.cpp index 31ef1a7941d..a7d539b0bf8 100644 --- a/src/devices/bus/oricext/microdisc.cpp +++ b/src/devices/bus/oricext/microdisc.cpp @@ -29,7 +29,7 @@ void oric_microdisc_device::map(address_map &map) map(0x318, 0x318).r(FUNC(oric_microdisc_device::port_318_r)); } -oric_microdisc_device::oric_microdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +oric_microdisc_device::oric_microdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ORIC_MICRODISC, tag, owner, clock), device_oricext_interface(mconfig, *this), fdc(*this, "fdc"), microdisc_rom(nullptr), diff --git a/src/devices/bus/oricext/microdisc.h b/src/devices/bus/oricext/microdisc.h index 312a9b69954..75a3a7a9228 100644 --- a/src/devices/bus/oricext/microdisc.h +++ b/src/devices/bus/oricext/microdisc.h @@ -12,7 +12,7 @@ DECLARE_DEVICE_TYPE(ORIC_MICRODISC, oric_microdisc_device) class oric_microdisc_device : public device_t, public device_oricext_interface { public: - oric_microdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + oric_microdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~oric_microdisc_device(); protected: diff --git a/src/devices/bus/oricext/oricext.cpp b/src/devices/bus/oricext/oricext.cpp index c678edc0ef6..8511329445b 100644 --- a/src/devices/bus/oricext/oricext.cpp +++ b/src/devices/bus/oricext/oricext.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(ORICEXT_CONNECTOR, oricext_connector, "oricext_connector", "ORIC extension connector") -oricext_connector::oricext_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +oricext_connector::oricext_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ORICEXT_CONNECTOR, tag, owner, clock), device_single_card_slot_interface<device_oricext_interface>(mconfig, *this), irq_handler(*this), diff --git a/src/devices/bus/oricext/oricext.h b/src/devices/bus/oricext/oricext.h index 2d017f1e376..4aaaab64fef 100644 --- a/src/devices/bus/oricext/oricext.h +++ b/src/devices/bus/oricext/oricext.h @@ -22,7 +22,7 @@ class oricext_connector: public device_t, public device_single_card_slot_interfa public: template <typename T, typename U> oricext_connector(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt, U &&cputag) - : oricext_connector(mconfig, tag, owner, (uint32_t)0) + : oricext_connector(mconfig, tag, owner) { option_reset(); opts(*this); @@ -31,7 +31,7 @@ public: set_cputag(std::forward<U>(cputag)); } - oricext_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + oricext_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~oricext_connector(); template <typename T> void set_cputag(T &&tag) { cpu.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/bus/pasopia/pac2.cpp b/src/devices/bus/pasopia/pac2.cpp index 13955bba61f..66022726e44 100644 --- a/src/devices/bus/pasopia/pac2.cpp +++ b/src/devices/bus/pasopia/pac2.cpp @@ -45,7 +45,7 @@ DEFINE_DEVICE_TYPE(PASOPIA_PAC2, pasopia_pac2_slot_device, "pasopia_pac2", "Paso // pasopia_pac2_slot_device - construction //------------------------------------------------- -pasopia_pac2_slot_device::pasopia_pac2_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pasopia_pac2_slot_device::pasopia_pac2_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PASOPIA_PAC2, tag, owner, clock) , device_single_card_slot_interface<pac2_card_interface>(mconfig, *this) , m_card(nullptr) diff --git a/src/devices/bus/pasopia/pac2.h b/src/devices/bus/pasopia/pac2.h index 9bbf30b44ca..8c0dafeec3b 100644 --- a/src/devices/bus/pasopia/pac2.h +++ b/src/devices/bus/pasopia/pac2.h @@ -29,7 +29,7 @@ public: // construction/destruction template <typename T> pasopia_pac2_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : pasopia_pac2_slot_device(mconfig, tag, owner, 0) + : pasopia_pac2_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -37,7 +37,7 @@ public: set_fixed(false); } - pasopia_pac2_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + pasopia_pac2_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // memory accesses u8 read(offs_t offset); diff --git a/src/devices/bus/pasopia/pac2exp.cpp b/src/devices/bus/pasopia/pac2exp.cpp index 2638a7bc645..521dd9344c0 100644 --- a/src/devices/bus/pasopia/pac2exp.cpp +++ b/src/devices/bus/pasopia/pac2exp.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(PASOPIA_PA7234, pasopia_pa7234_device, "pa7234", "PA7234 Paso // pasopia_pa7234_device - construction //------------------------------------------------- -pasopia_pa7234_device::pasopia_pa7234_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pasopia_pa7234_device::pasopia_pa7234_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PASOPIA_PA7234, tag, owner, clock) , pac2_card_interface(mconfig, *this) , m_slot(*this, "slot%u", 1U) diff --git a/src/devices/bus/pasopia/pac2exp.h b/src/devices/bus/pasopia/pac2exp.h index ae874c01490..56ec5b6862e 100644 --- a/src/devices/bus/pasopia/pac2exp.h +++ b/src/devices/bus/pasopia/pac2exp.h @@ -19,7 +19,7 @@ class pasopia_pa7234_device : public device_t, public pac2_card_interface { public: // device type constructor - pasopia_pa7234_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pasopia_pa7234_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pasopia/rampac2.cpp b/src/devices/bus/pasopia/rampac2.cpp index 3c128a10266..f5ca4cd089c 100644 --- a/src/devices/bus/pasopia/rampac2.cpp +++ b/src/devices/bus/pasopia/rampac2.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(PASOPIA_PA7248, pasopia_pa7248_device, "pa7248", "PA7248 Paso // pasopia_rampac2_device - construction //------------------------------------------------- -pasopia_rampac2_device::pasopia_rampac2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 ram_size) +pasopia_rampac2_device::pasopia_rampac2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 ram_size) : device_t(mconfig, type, tag, owner, clock) , pac2_card_interface(mconfig, *this) , device_nvram_interface(mconfig, *this) @@ -43,7 +43,7 @@ pasopia_rampac2_device::pasopia_rampac2_device(const machine_config &mconfig, de // pasopia_pa7243_device - construction //------------------------------------------------- -pasopia_pa7243_device::pasopia_pa7243_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pasopia_pa7243_device::pasopia_pa7243_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pasopia_rampac2_device(mconfig, PASOPIA_PA7243, tag, owner, clock, 0x4000) { } @@ -53,7 +53,7 @@ pasopia_pa7243_device::pasopia_pa7243_device(const machine_config &mconfig, cons // pasopia_pa7245_device - construction //------------------------------------------------- -pasopia_pa7245_device::pasopia_pa7245_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pasopia_pa7245_device::pasopia_pa7245_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pasopia_rampac2_device(mconfig, PASOPIA_PA7245, tag, owner, clock, 0x8000) { } @@ -63,7 +63,7 @@ pasopia_pa7245_device::pasopia_pa7245_device(const machine_config &mconfig, cons // pasopia_pa7248_device - construction //------------------------------------------------- -pasopia_pa7248_device::pasopia_pa7248_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pasopia_pa7248_device::pasopia_pa7248_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pasopia_rampac2_device(mconfig, PASOPIA_PA7248, tag, owner, clock, 0x10000) { } diff --git a/src/devices/bus/pasopia/rampac2.h b/src/devices/bus/pasopia/rampac2.h index 54e8a652049..45858466861 100644 --- a/src/devices/bus/pasopia/rampac2.h +++ b/src/devices/bus/pasopia/rampac2.h @@ -19,7 +19,7 @@ class pasopia_rampac2_device : public device_t, public pac2_card_interface, publ { protected: // construction/destruction - pasopia_rampac2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 ram_size); + pasopia_rampac2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 ram_size); // device-level overrides virtual void device_start() override; @@ -47,7 +47,7 @@ class pasopia_pa7243_device : public pasopia_rampac2_device { public: // device type constructor - pasopia_pa7243_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pasopia_pa7243_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> pasopia_pa7245_device @@ -56,7 +56,7 @@ class pasopia_pa7245_device : public pasopia_rampac2_device { public: // device type constructor - pasopia_pa7245_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pasopia_pa7245_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> pasopia_pa7248_device @@ -65,7 +65,7 @@ class pasopia_pa7248_device : public pasopia_rampac2_device { public: // device type constructor - pasopia_pa7248_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pasopia_pa7248_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type declarations diff --git a/src/devices/bus/pasopia/rompac2.cpp b/src/devices/bus/pasopia/rompac2.cpp index 5ec120ac120..1cb73ad3154 100644 --- a/src/devices/bus/pasopia/rompac2.cpp +++ b/src/devices/bus/pasopia/rompac2.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(PASOPIA_PA7246, pasopia_pa7246_device, "pa7246", "PA7246 Paso // pasopia_pa7246_device - construction //------------------------------------------------- -pasopia_pa7246_device::pasopia_pa7246_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pasopia_pa7246_device::pasopia_pa7246_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PASOPIA_PA7246, tag, owner, clock) , pac2_card_interface(mconfig, *this) , m_kanji_rom(*this, "kanji") diff --git a/src/devices/bus/pasopia/rompac2.h b/src/devices/bus/pasopia/rompac2.h index 1b734e3b29f..9b3dbaf4f37 100644 --- a/src/devices/bus/pasopia/rompac2.h +++ b/src/devices/bus/pasopia/rompac2.h @@ -19,7 +19,7 @@ class pasopia_pa7246_device : public device_t, public pac2_card_interface { public: // device type constructor - pasopia_pa7246_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pasopia_pa7246_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pc1512/mouse.cpp b/src/devices/bus/pc1512/mouse.cpp index f1d92ce4df5..f40e5f8ef7a 100644 --- a/src/devices/bus/pc1512/mouse.cpp +++ b/src/devices/bus/pc1512/mouse.cpp @@ -44,7 +44,7 @@ device_pc1512_mouse_port_interface::device_pc1512_mouse_port_interface(const mac // pc1512_mouse_port_device - constructor //------------------------------------------------- -pc1512_mouse_port_device::pc1512_mouse_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pc1512_mouse_port_device::pc1512_mouse_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC1512_MOUSE_PORT, tag, owner, clock), device_single_card_slot_interface<device_pc1512_mouse_port_interface>(mconfig, *this), m_write_x(*this), @@ -55,7 +55,7 @@ pc1512_mouse_port_device::pc1512_mouse_port_device(const machine_config &mconfig { } -pc1512_mouse_device::pc1512_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pc1512_mouse_device::pc1512_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC1512_MOUSE, tag, owner, clock), device_pc1512_mouse_port_interface(mconfig, *this) { diff --git a/src/devices/bus/pc1512/mouse.h b/src/devices/bus/pc1512/mouse.h index 8b2215fe1c0..a1dc2e054af 100644 --- a/src/devices/bus/pc1512/mouse.h +++ b/src/devices/bus/pc1512/mouse.h @@ -56,7 +56,7 @@ public: // construction/destruction template <typename T> pc1512_mouse_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : pc1512_mouse_port_device(mconfig, tag, owner, 0) + : pc1512_mouse_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -64,7 +64,7 @@ public: set_fixed(false); } - pc1512_mouse_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pc1512_mouse_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // static configuration helpers auto x_wr_callback() { return m_write_x.bind(); } @@ -97,7 +97,7 @@ class pc1512_mouse_device : public device_t, public device_pc1512_mouse_port_int { public: // construction/destruction - pc1512_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc1512_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/pc8801/jmbx1.cpp b/src/devices/bus/pc8801/jmbx1.cpp index 33a48019a20..07ebc63e5c0 100644 --- a/src/devices/bus/pc8801/jmbx1.cpp +++ b/src/devices/bus/pc8801/jmbx1.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(JMBX1, jmbx1_device, "jmbx1", "JMB-X1 \"Sound Board X\"") -jmbx1_device::jmbx1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +jmbx1_device::jmbx1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc8801_exp_device(mconfig, JMBX1, tag, owner, clock) , m_opm1(*this, "opm1") , m_opm2(*this, "opm2") diff --git a/src/devices/bus/pc8801/jmbx1.h b/src/devices/bus/pc8801/jmbx1.h index 27f9050cae5..94e7b779456 100644 --- a/src/devices/bus/pc8801/jmbx1.h +++ b/src/devices/bus/pc8801/jmbx1.h @@ -13,7 +13,7 @@ class jmbx1_device : public pc8801_exp_device { public: - jmbx1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + jmbx1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void io_map(address_map &map) override; diff --git a/src/devices/bus/pc8801/pc8801_23.cpp b/src/devices/bus/pc8801/pc8801_23.cpp index f0b11773d2c..ab6628f6f5f 100644 --- a/src/devices/bus/pc8801/pc8801_23.cpp +++ b/src/devices/bus/pc8801/pc8801_23.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(PC8801_23, pc8801_23_device, "pc8801_23", "NEC PC-8801-23 \"Sound Board II\"") -pc8801_23_device::pc8801_23_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc8801_23_device::pc8801_23_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc8801_exp_device(mconfig, PC8801_23, tag, owner, clock) , m_opna(*this, "opna") { diff --git a/src/devices/bus/pc8801/pc8801_23.h b/src/devices/bus/pc8801/pc8801_23.h index b112274c7d0..c8405bf900a 100644 --- a/src/devices/bus/pc8801/pc8801_23.h +++ b/src/devices/bus/pc8801/pc8801_23.h @@ -12,7 +12,7 @@ class pc8801_23_device : public pc8801_exp_device { public: - pc8801_23_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc8801_23_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::SOUND; } diff --git a/src/devices/bus/pc8801/pc8801_31.cpp b/src/devices/bus/pc8801/pc8801_31.cpp index f979e59162b..1250342bc9a 100644 --- a/src/devices/bus/pc8801/pc8801_31.cpp +++ b/src/devices/bus/pc8801/pc8801_31.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(PC8801_31, pc8801_31_device, "pc8801_31", "NEC PC8801-31 CD-R //------------------------------------------------- -pc8801_31_device::pc8801_31_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc8801_31_device::pc8801_31_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC8801_31, tag, owner, clock) , m_scsibus(*this, "scsi") , m_rom_bank_cb(*this) diff --git a/src/devices/bus/pc8801/pc8801_31.h b/src/devices/bus/pc8801/pc8801_31.h index fd580002610..0a5ac3e9d88 100644 --- a/src/devices/bus/pc8801/pc8801_31.h +++ b/src/devices/bus/pc8801/pc8801_31.h @@ -22,7 +22,7 @@ class pc8801_31_device : public device_t { public: // construction/destruction - pc8801_31_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc8801_31_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/pc8801/pc8801_exp.cpp b/src/devices/bus/pc8801/pc8801_exp.cpp index d99a6d252ff..4bd40698a49 100644 --- a/src/devices/bus/pc8801/pc8801_exp.cpp +++ b/src/devices/bus/pc8801/pc8801_exp.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(PC8801_EXP_SLOT, pc8801_exp_slot_device, "pc8801_exp_slot", "PC-8801 Expansion Slot") -pc8801_exp_slot_device::pc8801_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc8801_exp_slot_device::pc8801_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC8801_EXP_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_pc8801_exp_interface>(mconfig, *this) , m_iospace(*this, finder_base::DUMMY_TAG, -1) @@ -99,7 +99,7 @@ WRITE_LINE_MEMBER( device_pc8801_exp_interface::int3_w ) { m_slot->m_int3_cb(sta WRITE_LINE_MEMBER( device_pc8801_exp_interface::int4_w ) { m_slot->m_int4_cb(state); } WRITE_LINE_MEMBER( device_pc8801_exp_interface::int5_w ) { m_slot->m_int5_cb(state); } -pc8801_exp_device::pc8801_exp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pc8801_exp_device::pc8801_exp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_pc8801_exp_interface(mconfig, *this) { diff --git a/src/devices/bus/pc8801/pc8801_exp.h b/src/devices/bus/pc8801/pc8801_exp.h index f3f540a1c9b..63274aae605 100644 --- a/src/devices/bus/pc8801/pc8801_exp.h +++ b/src/devices/bus/pc8801/pc8801_exp.h @@ -16,14 +16,14 @@ public: // construction/destruction template <typename T> pc8801_exp_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : pc8801_exp_slot_device(mconfig, tag, owner, (uint32_t)0) + : pc8801_exp_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - pc8801_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc8801_exp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~pc8801_exp_slot_device(); template <typename T> void set_iospace(T &&tag, int spacenum) { m_iospace.set_tag(std::forward<T>(tag), spacenum); } @@ -77,7 +77,7 @@ class pc8801_exp_device : public device_t, public device_pc8801_exp_interface { public: // construction/destruction - pc8801_exp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pc8801_exp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); protected: diff --git a/src/devices/bus/pc8801/pcg8100.cpp b/src/devices/bus/pc8801/pcg8100.cpp index c2bf07c7f73..bc565d988fe 100644 --- a/src/devices/bus/pc8801/pcg8100.cpp +++ b/src/devices/bus/pc8801/pcg8100.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(PCG8100, pcg8100_device, "pcg8100", "HAL Laboratory PCG-8100") -pcg8100_device::pcg8100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pcg8100_device::pcg8100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc8801_exp_device(mconfig, PCG8100, tag, owner, clock) , m_pit(*this, "pit") , m_dac1bit(*this, "dac1bit%u", 0L) @@ -35,7 +35,7 @@ void pcg8100_device::device_add_mconfig(machine_config &config) { constexpr XTAL pcg_clock = XTAL(31'948'800) / 8; - PIT8253(config, m_pit, 0); + PIT8253(config, m_pit); m_pit->set_clk<0>(pcg_clock); m_pit->out_handler<0>().set(m_dac1bit[0], FUNC(speaker_sound_device::level_w)); m_pit->set_clk<1>(pcg_clock); diff --git a/src/devices/bus/pc8801/pcg8100.h b/src/devices/bus/pc8801/pcg8100.h index 4d71f8509d1..eaac2ef5de3 100644 --- a/src/devices/bus/pc8801/pcg8100.h +++ b/src/devices/bus/pc8801/pcg8100.h @@ -13,7 +13,7 @@ class pcg8100_device : public pc8801_exp_device { public: - pcg8100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pcg8100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void io_map(address_map &map) override; diff --git a/src/devices/bus/pc_joy/pc_joy.cpp b/src/devices/bus/pc_joy/pc_joy.cpp index 2171a9ddbf7..44278790488 100644 --- a/src/devices/bus/pc_joy/pc_joy.cpp +++ b/src/devices/bus/pc_joy/pc_joy.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(PC_JOY, pc_joy_device, "pc_joy", "PC joystick port") -pc_joy_device::pc_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pc_joy_device::pc_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC_JOY, tag, owner, clock), device_single_card_slot_interface<device_pc_joy_interface>(mconfig, *this), m_dev(nullptr) @@ -84,7 +84,7 @@ ioport_constructor pc_basic_joy_device::device_input_ports() const DEFINE_DEVICE_TYPE(PC_BASIC_JOY, pc_basic_joy_device, "pc_basic_joy", "PC basic joystick") -pc_basic_joy_device::pc_basic_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pc_basic_joy_device::pc_basic_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC_BASIC_JOY, tag, owner, clock), device_pc_joy_interface(mconfig, *this), m_btn(*this, "btn"), diff --git a/src/devices/bus/pc_joy/pc_joy.h b/src/devices/bus/pc_joy/pc_joy.h index e09520f6436..416938427ce 100644 --- a/src/devices/bus/pc_joy/pc_joy.h +++ b/src/devices/bus/pc_joy/pc_joy.h @@ -35,7 +35,7 @@ protected: class pc_joy_device : public device_t, public device_single_card_slot_interface<device_pc_joy_interface> { public: - pc_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pc_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint8_t joy_port_r(); void joy_port_w(uint8_t data); @@ -55,7 +55,7 @@ class pc_basic_joy_device : public device_t, public device_pc_joy_interface { public: - pc_basic_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pc_basic_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ioport_constructor device_input_ports() const override; virtual uint8_t x1(int delta) override { return (m_x1->read() > delta); } diff --git a/src/devices/bus/pc_joy/pc_joy_sw.cpp b/src/devices/bus/pc_joy/pc_joy_sw.cpp index 8c9b2c75d4b..7e20651c3ad 100644 --- a/src/devices/bus/pc_joy/pc_joy_sw.cpp +++ b/src/devices/bus/pc_joy/pc_joy_sw.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(PC_MSSW_PAD, pc_mssw_pad_device, "mssw_pad", "Microsoft Sidewinder Pad") -pc_mssw_pad_device::pc_mssw_pad_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +pc_mssw_pad_device::pc_mssw_pad_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, PC_MSSW_PAD, tag, owner, clock), device_pc_joy_interface(mconfig, *this), m_btn1(*this, "btn1"), diff --git a/src/devices/bus/pc_joy/pc_joy_sw.h b/src/devices/bus/pc_joy/pc_joy_sw.h index 5d83a10d0c1..b27a143af70 100644 --- a/src/devices/bus/pc_joy/pc_joy_sw.h +++ b/src/devices/bus/pc_joy/pc_joy_sw.h @@ -9,7 +9,7 @@ class pc_mssw_pad_device : public device_t, public device_pc_joy_interface { public: - pc_mssw_pad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc_mssw_pad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; virtual uint8_t btn() override { return m_state; } diff --git a/src/devices/bus/pc_kbd/ec1841.cpp b/src/devices/bus/pc_kbd/ec1841.cpp index c9f5aa57f98..4f1e1600415 100644 --- a/src/devices/bus/pc_kbd/ec1841.cpp +++ b/src/devices/bus/pc_kbd/ec1841.cpp @@ -284,7 +284,7 @@ ioport_constructor ec_1841_keyboard_device::device_input_ports() const // ec_1841_keyboard_device - constructor //------------------------------------------------- -ec_1841_keyboard_device::ec_1841_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ec_1841_keyboard_device::ec_1841_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC_KBD_EC_1841, tag, owner, clock), device_pc_kbd_interface(mconfig, *this), m_maincpu(*this, I8048_TAG), diff --git a/src/devices/bus/pc_kbd/ec1841.h b/src/devices/bus/pc_kbd/ec1841.h index 08309b35d9e..00a94c31bdf 100644 --- a/src/devices/bus/pc_kbd/ec1841.h +++ b/src/devices/bus/pc_kbd/ec1841.h @@ -26,7 +26,7 @@ class ec_1841_keyboard_device : public device_t, public device_pc_kbd_interface { public: // construction/destruction - ec_1841_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ec_1841_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pc_kbd/hle_mouse.cpp b/src/devices/bus/pc_kbd/hle_mouse.cpp index 15ac7854d09..dc59b332543 100644 --- a/src/devices/bus/pc_kbd/hle_mouse.cpp +++ b/src/devices/bus/pc_kbd/hle_mouse.cpp @@ -67,7 +67,7 @@ INPUT_PORTS_END static constexpr attotime serial_cycle = attotime::from_usec(25); -hle_ps2_mouse_device::hle_ps2_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hle_ps2_mouse_device::hle_ps2_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HLE_PS2_MOUSE, tag, owner, clock) , device_pc_kbd_interface(mconfig, *this) , m_port_x_axis(*this, "mouse_x_axis") diff --git a/src/devices/bus/pc_kbd/hle_mouse.h b/src/devices/bus/pc_kbd/hle_mouse.h index d4222a35fd2..53b567adaaa 100644 --- a/src/devices/bus/pc_kbd/hle_mouse.h +++ b/src/devices/bus/pc_kbd/hle_mouse.h @@ -13,7 +13,7 @@ class hle_ps2_mouse_device , public device_pc_kbd_interface { public: - hle_ps2_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hle_ps2_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/pc_kbd/iskr1030.cpp b/src/devices/bus/pc_kbd/iskr1030.cpp index 5a39c103b50..c0b83d0f8cb 100644 --- a/src/devices/bus/pc_kbd/iskr1030.cpp +++ b/src/devices/bus/pc_kbd/iskr1030.cpp @@ -251,7 +251,7 @@ ioport_constructor iskr_1030_keyboard_device::device_input_ports() const // iskr_1030_keyboard_device - constructor //------------------------------------------------- -iskr_1030_keyboard_device::iskr_1030_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iskr_1030_keyboard_device::iskr_1030_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC_KBD_ISKR_1030, tag, owner, clock), device_pc_kbd_interface(mconfig, *this), m_maincpu(*this, I8048_TAG), diff --git a/src/devices/bus/pc_kbd/iskr1030.h b/src/devices/bus/pc_kbd/iskr1030.h index 5c849a2b6b0..32562c62935 100644 --- a/src/devices/bus/pc_kbd/iskr1030.h +++ b/src/devices/bus/pc_kbd/iskr1030.h @@ -27,7 +27,7 @@ class iskr_1030_keyboard_device : public device_t, public device_pc_kbd_interfac { public: // construction/destruction - iskr_1030_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iskr_1030_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pc_kbd/keytro.cpp b/src/devices/bus/pc_kbd/keytro.cpp index d178bfceb6f..16c9207d6c9 100644 --- a/src/devices/bus/pc_kbd/keytro.cpp +++ b/src/devices/bus/pc_kbd/keytro.cpp @@ -364,7 +364,7 @@ ROM_START( keytronic_pc3270 ) ROM_END -pc_kbd_keytronic_pc3270_device::pc_kbd_keytronic_pc3270_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pc_kbd_keytronic_pc3270_device::pc_kbd_keytronic_pc3270_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc_kbd_keytronic_pc3270_device(mconfig, PC_KBD_KEYTRONIC_PC3270, tag, owner, clock) { } @@ -383,7 +383,7 @@ pc_kbd_keytronic_pc3270_device::pc_kbd_keytronic_pc3270_device( } -pc_kbd_keytronic_pc3270_at_device::pc_kbd_keytronic_pc3270_at_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pc_kbd_keytronic_pc3270_at_device::pc_kbd_keytronic_pc3270_at_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc_kbd_keytronic_pc3270_device(mconfig, PC_KBD_KEYTRONIC_PC3270_AT, tag, owner, clock) { } @@ -422,7 +422,7 @@ void pc_kbd_keytronic_pc3270_device::device_reset() void pc_kbd_keytronic_pc3270_device::device_add_mconfig(machine_config &config) { - I8051(config, m_cpu, 11060250); + I8051(config, m_cpu, XTAL::u(11060250)); m_cpu->set_addrmap(AS_PROGRAM, &pc_kbd_keytronic_pc3270_device::keytronic_pc3270_program); m_cpu->set_addrmap(AS_IO, &pc_kbd_keytronic_pc3270_device::keytronic_pc3270_io); m_cpu->port_in_cb<1>().set(FUNC(pc_kbd_keytronic_pc3270_device::p1_read)); diff --git a/src/devices/bus/pc_kbd/keytro.h b/src/devices/bus/pc_kbd/keytro.h index 8fb6f021967..7ec801205cf 100644 --- a/src/devices/bus/pc_kbd/keytro.h +++ b/src/devices/bus/pc_kbd/keytro.h @@ -25,7 +25,7 @@ class pc_kbd_keytronic_pc3270_device : public device_t, { public: // construction/destruction - pc_kbd_keytronic_pc3270_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc_kbd_keytronic_pc3270_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: pc_kbd_keytronic_pc3270_device( @@ -73,7 +73,7 @@ class pc_kbd_keytronic_pc3270_at_device : public pc_kbd_keytronic_pc3270_device { public: // construction/destruction - pc_kbd_keytronic_pc3270_at_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc_kbd_keytronic_pc3270_at_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; }; diff --git a/src/devices/bus/pc_kbd/msnat.cpp b/src/devices/bus/pc_kbd/msnat.cpp index 058a1ef39ff..9a406e29315 100644 --- a/src/devices/bus/pc_kbd/msnat.cpp +++ b/src/devices/bus/pc_kbd/msnat.cpp @@ -205,7 +205,7 @@ ROM_START( microsoft_natural ) ROM_END -pc_kbd_microsoft_natural_device::pc_kbd_microsoft_natural_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc_kbd_microsoft_natural_device::pc_kbd_microsoft_natural_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC_KBD_MICROSOFT_NATURAL, tag, owner, clock) , device_pc_kbd_interface(mconfig, *this) , m_cpu(*this, "ms_natrl_cpu") diff --git a/src/devices/bus/pc_kbd/msnat.h b/src/devices/bus/pc_kbd/msnat.h index 6ec5327675e..9ec831cd1e0 100644 --- a/src/devices/bus/pc_kbd/msnat.h +++ b/src/devices/bus/pc_kbd/msnat.h @@ -23,7 +23,7 @@ class pc_kbd_microsoft_natural_device : public device_t, { public: // construction/destruction - pc_kbd_microsoft_natural_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc_kbd_microsoft_natural_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pc_kbd/pc83.cpp b/src/devices/bus/pc_kbd/pc83.cpp index 5e214660257..4c7c1fd23db 100644 --- a/src/devices/bus/pc_kbd/pc83.cpp +++ b/src/devices/bus/pc_kbd/pc83.cpp @@ -230,7 +230,7 @@ ioport_constructor ibm_pc_83_keyboard_device::device_input_ports() const // ibm_pc_83_keyboard_device - constructor //------------------------------------------------- -ibm_pc_83_keyboard_device::ibm_pc_83_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ibm_pc_83_keyboard_device::ibm_pc_83_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC_KBD_IBM_PC_83, tag, owner, clock), device_pc_kbd_interface(mconfig, *this), m_maincpu(*this, I8048_TAG), diff --git a/src/devices/bus/pc_kbd/pc83.h b/src/devices/bus/pc_kbd/pc83.h index 44b58dfbc7f..a25a61fbddf 100644 --- a/src/devices/bus/pc_kbd/pc83.h +++ b/src/devices/bus/pc_kbd/pc83.h @@ -28,7 +28,7 @@ class ibm_pc_83_keyboard_device : public device_t, { public: // construction/destruction - ibm_pc_83_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ibm_pc_83_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pc_kbd/pc_kbdc.cpp b/src/devices/bus/pc_kbd/pc_kbdc.cpp index 4461648de7f..a7b9cb99e6f 100644 --- a/src/devices/bus/pc_kbd/pc_kbdc.cpp +++ b/src/devices/bus/pc_kbd/pc_kbdc.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(PC_KBDC, pc_kbdc_device, "pc_kbdc", "PC keyboard connector") //------------------------------------------------- // pc_kbdc_device - constructor //------------------------------------------------- -pc_kbdc_device::pc_kbdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pc_kbdc_device::pc_kbdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC_KBDC, tag, owner, clock), device_single_card_slot_interface<device_pc_kbd_interface>(mconfig, *this), m_out_clock_cb(*this), diff --git a/src/devices/bus/pc_kbd/pc_kbdc.h b/src/devices/bus/pc_kbd/pc_kbdc.h index 4cbff6fc890..a962630953e 100644 --- a/src/devices/bus/pc_kbd/pc_kbdc.h +++ b/src/devices/bus/pc_kbd/pc_kbdc.h @@ -29,14 +29,14 @@ public: // construction/destruction template <typename T> pc_kbdc_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : pc_kbdc_device(mconfig, tag, owner, (uint32_t)0) + : pc_kbdc_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - pc_kbdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc_kbdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto out_clock_cb() { return m_out_clock_cb.bind(); } auto out_data_cb() { return m_out_data_cb.bind(); } diff --git a/src/devices/bus/pc_kbd/pcat101.cpp b/src/devices/bus/pc_kbd/pcat101.cpp index 955e9d17f48..706bc20a2e1 100644 --- a/src/devices/bus/pc_kbd/pcat101.cpp +++ b/src/devices/bus/pc_kbd/pcat101.cpp @@ -233,7 +233,7 @@ ioport_constructor ibm_pc_at_101_keyboard_device::device_input_ports() const return INPUT_PORTS_NAME(ibm_pc_at_101_keyboard); } -ibm_pc_at_101_keyboard_device::ibm_pc_at_101_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ibm_pc_at_101_keyboard_device::ibm_pc_at_101_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC_KBD_IBM_PC_AT_101, tag, owner, clock) , device_pc_kbd_interface(mconfig, *this) , m_mcu(*this, "mcu") diff --git a/src/devices/bus/pc_kbd/pcat101.h b/src/devices/bus/pc_kbd/pcat101.h index 449947eccad..8a3f2d4f35e 100644 --- a/src/devices/bus/pc_kbd/pcat101.h +++ b/src/devices/bus/pc_kbd/pcat101.h @@ -15,7 +15,7 @@ class ibm_pc_at_101_keyboard_device { public: // construction/destruction - ibm_pc_at_101_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ibm_pc_at_101_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pc_kbd/pcat84.cpp b/src/devices/bus/pc_kbd/pcat84.cpp index d45588eea34..2643dcafd78 100644 --- a/src/devices/bus/pc_kbd/pcat84.cpp +++ b/src/devices/bus/pc_kbd/pcat84.cpp @@ -107,7 +107,7 @@ const tiny_rom_entry *ibm_3270pc_122_keyboard_device::device_rom_region() const void ibm_pc_at_84_keyboard_device::device_add_mconfig(machine_config &config) { - I8048(config, m_maincpu, 5364000); + I8048(config, m_maincpu, XTAL::u(5364000)); m_maincpu->bus_out_cb().set(FUNC(ibm_pc_at_84_keyboard_device::bus_w)); m_maincpu->p1_in_cb().set(FUNC(ibm_pc_at_84_keyboard_device::p1_r)); m_maincpu->p1_out_cb().set(FUNC(ibm_pc_at_84_keyboard_device::p1_w)); @@ -339,7 +339,7 @@ ioport_constructor ibm_3270pc_122_keyboard_device::device_input_ports() const // ibm_pc_at_84_keyboard_device - constructor //------------------------------------------------- -ibm_pc_at_84_keyboard_device::ibm_pc_at_84_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +ibm_pc_at_84_keyboard_device::ibm_pc_at_84_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_pc_kbd_interface(mconfig, *this), m_maincpu(*this, I8048_TAG), @@ -354,12 +354,12 @@ ibm_pc_at_84_keyboard_device::ibm_pc_at_84_keyboard_device(const machine_config { } -ibm_pc_at_84_keyboard_device::ibm_pc_at_84_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ibm_pc_at_84_keyboard_device::ibm_pc_at_84_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ibm_pc_at_84_keyboard_device(mconfig, PC_KBD_IBM_PC_AT_84, tag, owner, clock) { } -ibm_3270pc_122_keyboard_device::ibm_3270pc_122_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ibm_3270pc_122_keyboard_device::ibm_3270pc_122_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ibm_pc_at_84_keyboard_device(mconfig, PC_KBD_IBM_3270PC_122, tag, owner, clock) { } diff --git a/src/devices/bus/pc_kbd/pcat84.h b/src/devices/bus/pc_kbd/pcat84.h index 3953786f900..24067260936 100644 --- a/src/devices/bus/pc_kbd/pcat84.h +++ b/src/devices/bus/pc_kbd/pcat84.h @@ -28,10 +28,10 @@ class ibm_pc_at_84_keyboard_device : public device_t, { public: // construction/destruction - ibm_pc_at_84_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ibm_pc_at_84_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - ibm_pc_at_84_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ibm_pc_at_84_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -83,7 +83,7 @@ class ibm_3270pc_122_keyboard_device : public ibm_pc_at_84_keyboard_device { public: // construction/destruction - ibm_3270pc_122_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ibm_3270pc_122_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/pc_kbd/pcxt83.cpp b/src/devices/bus/pc_kbd/pcxt83.cpp index f155e9c853c..e22ddb9063b 100644 --- a/src/devices/bus/pc_kbd/pcxt83.cpp +++ b/src/devices/bus/pc_kbd/pcxt83.cpp @@ -232,7 +232,7 @@ ioport_constructor ibm_pc_xt_83_keyboard_device::device_input_ports() const // ibm_pc_xt_83_keyboard_device - constructor //------------------------------------------------- -ibm_pc_xt_83_keyboard_device::ibm_pc_xt_83_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ibm_pc_xt_83_keyboard_device::ibm_pc_xt_83_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC_KBD_IBM_PC_XT_83, tag, owner, clock), device_pc_kbd_interface(mconfig, *this), m_maincpu(*this, I8048_TAG), diff --git a/src/devices/bus/pc_kbd/pcxt83.h b/src/devices/bus/pc_kbd/pcxt83.h index 6044141610e..0a690652344 100644 --- a/src/devices/bus/pc_kbd/pcxt83.h +++ b/src/devices/bus/pc_kbd/pcxt83.h @@ -27,7 +27,7 @@ class ibm_pc_xt_83_keyboard_device : public device_t, public device_pc_kbd_inter { public: // construction/destruction - ibm_pc_xt_83_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ibm_pc_xt_83_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pce/pce_rom.cpp b/src/devices/bus/pce/pce_rom.cpp index fea0d9f7dcc..c4e71571bf7 100644 --- a/src/devices/bus/pce/pce_rom.cpp +++ b/src/devices/bus/pce/pce_rom.cpp @@ -25,33 +25,33 @@ DEFINE_DEVICE_TYPE(PCE_ROM_SF2, pce_sf2_device, "pce_sf2", "PCE S DEFINE_DEVICE_TYPE(PCE_ROM_TENNOKOE, pce_tennokoe_device, "pce_tennokoe", "PCE Tennokoe Bank Cart") -pce_rom_device::pce_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pce_rom_device::pce_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_pce_cart_interface( mconfig, *this ) { } -pce_rom_device::pce_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pce_rom_device::pce_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pce_rom_device(mconfig, PCE_ROM_STD, tag, owner, clock) { } -pce_cdsys3_device::pce_cdsys3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pce_cdsys3_device::pce_cdsys3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pce_rom_device(mconfig, PCE_ROM_CDSYS3, tag, owner, clock) { } -pce_populous_device::pce_populous_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pce_populous_device::pce_populous_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pce_rom_device(mconfig, PCE_ROM_POPULOUS, tag, owner, clock) { } -pce_sf2_device::pce_sf2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pce_sf2_device::pce_sf2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pce_rom_device(mconfig, PCE_ROM_SF2, tag, owner, clock), m_bank_base(0) { } -pce_tennokoe_device::pce_tennokoe_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pce_tennokoe_device::pce_tennokoe_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pce_rom_device(mconfig, PCE_ROM_TENNOKOE, tag, owner, clock), device_nvram_interface(mconfig, *this) { diff --git a/src/devices/bus/pce/pce_rom.h b/src/devices/bus/pce/pce_rom.h index 43499851eb7..fb79b81fc6a 100644 --- a/src/devices/bus/pce/pce_rom.h +++ b/src/devices/bus/pce/pce_rom.h @@ -16,13 +16,13 @@ class pce_rom_device : public device_t, { public: // construction/destruction - pce_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pce_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; protected: - pce_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pce_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -35,7 +35,7 @@ class pce_cdsys3_device : public pce_rom_device { public: // construction/destruction - pce_cdsys3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pce_cdsys3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -49,7 +49,7 @@ class pce_populous_device : public pce_rom_device { public: // construction/destruction - pce_populous_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pce_populous_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -63,7 +63,7 @@ class pce_sf2_device : public pce_rom_device { public: // construction/destruction - pce_sf2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pce_sf2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -85,7 +85,7 @@ class pce_tennokoe_device : public pce_rom_device, { public: // construction/destruction - pce_tennokoe_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pce_tennokoe_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; diff --git a/src/devices/bus/pce/pce_slot.cpp b/src/devices/bus/pce/pce_slot.cpp index e49642447de..356bfe0c546 100644 --- a/src/devices/bus/pce/pce_slot.cpp +++ b/src/devices/bus/pce/pce_slot.cpp @@ -134,7 +134,7 @@ void device_pce_cart_interface::rom_map_setup(uint32_t size) //------------------------------------------------- // pce_cart_slot_device - constructor //------------------------------------------------- -pce_cart_slot_device::pce_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pce_cart_slot_device::pce_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCE_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_pce_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/pce/pce_slot.h b/src/devices/bus/pce/pce_slot.h index 3770002ca5c..b8499dee0c0 100644 --- a/src/devices/bus/pce/pce_slot.h +++ b/src/devices/bus/pce/pce_slot.h @@ -68,7 +68,7 @@ public: // construction/destruction template <typename T> pce_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt, const char *interface) - : pce_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : pce_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -77,7 +77,7 @@ public: set_intf(interface); } - pce_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pce_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~pce_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/pce_ctrl/joypad2.cpp b/src/devices/bus/pce_ctrl/joypad2.cpp index 2da64ed49ce..192fa78142f 100644 --- a/src/devices/bus/pce_ctrl/joypad2.cpp +++ b/src/devices/bus/pce_ctrl/joypad2.cpp @@ -99,14 +99,14 @@ ioport_constructor pce_joypad2_turbo_device::device_input_ports() const // pce_joypad2_device - constructor //------------------------------------------------- -pce_joypad2_device::pce_joypad2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +pce_joypad2_device::pce_joypad2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_pce_control_port_interface(mconfig, *this), m_muxer(*this, "mux") { } -pce_joypad2_device::pce_joypad2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pce_joypad2_device::pce_joypad2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pce_joypad2_device(mconfig, PCE_JOYPAD2, tag, owner, clock) { } @@ -116,7 +116,7 @@ pce_joypad2_device::pce_joypad2_device(const machine_config &mconfig, const char // pce_joypad2_turbo_device - constructor //------------------------------------------------- -pce_joypad2_turbo_device::pce_joypad2_turbo_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pce_joypad2_turbo_device::pce_joypad2_turbo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pce_joypad2_device(mconfig, PCE_JOYPAD2_TURBO, tag, owner, clock), m_buttons_io(*this, "BUTTONS"), m_turbo_io(*this, "TURBO"), diff --git a/src/devices/bus/pce_ctrl/joypad2.h b/src/devices/bus/pce_ctrl/joypad2.h index 13fc0cbe7de..b156bcd96b4 100644 --- a/src/devices/bus/pce_ctrl/joypad2.h +++ b/src/devices/bus/pce_ctrl/joypad2.h @@ -28,11 +28,11 @@ class pce_joypad2_device : public device_t, { public: // construction/destruction - pce_joypad2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pce_joypad2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // construction/destruction - pce_joypad2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + pce_joypad2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; @@ -56,7 +56,7 @@ class pce_joypad2_turbo_device : public pce_joypad2_device { public: // construction/destruction - pce_joypad2_turbo_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pce_joypad2_turbo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/pce_ctrl/joypad6.cpp b/src/devices/bus/pce_ctrl/joypad6.cpp index b11d400d5d1..101ab068cb5 100644 --- a/src/devices/bus/pce_ctrl/joypad6.cpp +++ b/src/devices/bus/pce_ctrl/joypad6.cpp @@ -131,7 +131,7 @@ ioport_constructor pce_arcade_pad_6_device::device_input_ports() const // pce_joypad6_base_device - constructor //------------------------------------------------- -pce_joypad6_base_device::pce_joypad6_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +pce_joypad6_base_device::pce_joypad6_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_pce_control_port_interface(mconfig, *this), m_muxer(*this, "mux_%u", 0U), @@ -146,7 +146,7 @@ pce_joypad6_base_device::pce_joypad6_base_device(const machine_config &mconfig, // pce_avenue_pad_6_device - constructor //------------------------------------------------- -pce_avenue_pad_6_device::pce_avenue_pad_6_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +pce_avenue_pad_6_device::pce_avenue_pad_6_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : pce_joypad6_base_device(mconfig, type, tag, owner, clock), m_buttons_io(*this, "BUTTONS_%u", 0U), m_turbo_io(*this, "TURBO") @@ -154,7 +154,7 @@ pce_avenue_pad_6_device::pce_avenue_pad_6_device(const machine_config &mconfig, } -pce_avenue_pad_6_device::pce_avenue_pad_6_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pce_avenue_pad_6_device::pce_avenue_pad_6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pce_avenue_pad_6_device(mconfig, PCE_AVENUE_PAD_6, tag, owner, clock) { } @@ -164,7 +164,7 @@ pce_avenue_pad_6_device::pce_avenue_pad_6_device(const machine_config &mconfig, // pce_arcade_pad_6_device - constructor //------------------------------------------------- -pce_arcade_pad_6_device::pce_arcade_pad_6_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pce_arcade_pad_6_device::pce_arcade_pad_6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pce_avenue_pad_6_device(mconfig, PCE_ARCADE_PAD_6, tag, owner, clock) { } diff --git a/src/devices/bus/pce_ctrl/joypad6.h b/src/devices/bus/pce_ctrl/joypad6.h index fedac375a22..66b579309b6 100644 --- a/src/devices/bus/pce_ctrl/joypad6.h +++ b/src/devices/bus/pce_ctrl/joypad6.h @@ -31,7 +31,7 @@ public: protected: // construction/destruction - pce_joypad6_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + pce_joypad6_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_add_mconfig(machine_config &config) override; @@ -64,11 +64,11 @@ class pce_avenue_pad_6_device : public pce_joypad6_base_device { public: // construction/destruction - pce_avenue_pad_6_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pce_avenue_pad_6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // construction/destruction - pce_avenue_pad_6_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + pce_avenue_pad_6_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; @@ -90,7 +90,7 @@ class pce_arcade_pad_6_device : public pce_avenue_pad_6_device { public: // construction/destruction - pce_arcade_pad_6_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pce_arcade_pad_6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/pce_ctrl/multitap.cpp b/src/devices/bus/pce_ctrl/multitap.cpp index 22d08658b77..f71961d73d7 100644 --- a/src/devices/bus/pce_ctrl/multitap.cpp +++ b/src/devices/bus/pce_ctrl/multitap.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(PCE_MULTITAP, pce_multitap_device, "pce_multitap", "NEC PC En // pce_multitap_device - constructor //------------------------------------------------- -pce_multitap_device::pce_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pce_multitap_device::pce_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCE_MULTITAP, tag, owner, clock), device_pce_control_port_interface(mconfig, *this), m_subctrl_port(*this, "ctrl%u", 1U), diff --git a/src/devices/bus/pce_ctrl/multitap.h b/src/devices/bus/pce_ctrl/multitap.h index 5dd3234114b..214053fff3c 100644 --- a/src/devices/bus/pce_ctrl/multitap.h +++ b/src/devices/bus/pce_ctrl/multitap.h @@ -27,7 +27,7 @@ class pce_multitap_device : public device_t, { public: // construction/destruction - pce_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pce_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pce_ctrl/pcectrl.cpp b/src/devices/bus/pce_ctrl/pcectrl.cpp index 71e2d9db525..a474b69e493 100644 --- a/src/devices/bus/pce_ctrl/pcectrl.cpp +++ b/src/devices/bus/pce_ctrl/pcectrl.cpp @@ -103,7 +103,7 @@ device_pce_control_port_interface::~device_pce_control_port_interface() // pce_control_port_device - constructor //------------------------------------------------- -pce_control_port_device::pce_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pce_control_port_device::pce_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCE_CONTROL_PORT, tag, owner, clock), device_slot_interface(mconfig, *this), m_device(nullptr) diff --git a/src/devices/bus/pce_ctrl/pcectrl.h b/src/devices/bus/pce_ctrl/pcectrl.h index 3d190f5e1f3..ff5a180810d 100644 --- a/src/devices/bus/pce_ctrl/pcectrl.h +++ b/src/devices/bus/pce_ctrl/pcectrl.h @@ -27,7 +27,7 @@ public: // construction/destruction template <typename T> pce_control_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : pce_control_port_device(mconfig, tag, owner, 0) + : pce_control_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -35,7 +35,7 @@ public: set_fixed(false); } - pce_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pce_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~pce_control_port_device(); u8 port_r(); diff --git a/src/devices/bus/pet/2joysnd.cpp b/src/devices/bus/pet/2joysnd.cpp index 6d65b70542a..0e20f4a7e5c 100644 --- a/src/devices/bus/pet/2joysnd.cpp +++ b/src/devices/bus/pet/2joysnd.cpp @@ -95,7 +95,7 @@ ioport_constructor pet_userport_joystick_and_sound_device::device_input_ports() void pet_userport_joystick_and_sound_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "speaker").front_center(); - DAC_1BIT(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.99); + DAC_1BIT(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.99); } //************************************************************************** @@ -106,7 +106,7 @@ void pet_userport_joystick_and_sound_device::device_add_mconfig(machine_config & // pet_user_port_dual_joystick_and_sound_device - constructor //------------------------------------------------- -pet_userport_joystick_and_sound_device::pet_userport_joystick_and_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pet_userport_joystick_and_sound_device::pet_userport_joystick_and_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PET_USERPORT_JOYSTICK_AND_SOUND_DEVICE, tag, owner, clock), device_pet_user_port_interface(mconfig, *this), m_dac(*this, "dac"), diff --git a/src/devices/bus/pet/2joysnd.h b/src/devices/bus/pet/2joysnd.h index 644d64fc564..6822c3a4bef 100644 --- a/src/devices/bus/pet/2joysnd.h +++ b/src/devices/bus/pet/2joysnd.h @@ -26,7 +26,7 @@ class pet_userport_joystick_and_sound_device : public device_t, public device_pe { public: // construction/destruction - pet_userport_joystick_and_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pet_userport_joystick_and_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER( input_m ) override; diff --git a/src/devices/bus/pet/64k.cpp b/src/devices/bus/pet/64k.cpp index 7e335ba97ff..b03a0802217 100644 --- a/src/devices/bus/pet/64k.cpp +++ b/src/devices/bus/pet/64k.cpp @@ -76,7 +76,7 @@ inline void pet_64k_expansion_device::write_ram(offs_t offset, uint8_t data) // pet_64k_expansion_device - constructor //------------------------------------------------- -pet_64k_expansion_device::pet_64k_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pet_64k_expansion_device::pet_64k_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PET_64K, tag, owner, clock), device_pet_expansion_card_interface(mconfig, *this), m_ram(*this, "ram", 0x10000, ENDIANNESS_LITTLE), diff --git a/src/devices/bus/pet/64k.h b/src/devices/bus/pet/64k.h index 6b55cc3098e..02e30d1ab2c 100644 --- a/src/devices/bus/pet/64k.h +++ b/src/devices/bus/pet/64k.h @@ -25,7 +25,7 @@ class pet_64k_expansion_device : public device_t, public device_pet_expansion_ca { public: // construction/destruction - pet_64k_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pet_64k_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pet/c2n.cpp b/src/devices/bus/pet/c2n.cpp index 94f0dc4dca3..665102fedbc 100644 --- a/src/devices/bus/pet/c2n.cpp +++ b/src/devices/bus/pet/c2n.cpp @@ -42,7 +42,7 @@ void c2n_device::device_add_mconfig(machine_config &config) // c2n_device - constructor //------------------------------------------------- -c2n_device::c2n_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +c2n_device::c2n_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_pet_datassette_port_interface(mconfig, *this) , m_cassette(*this, "cassette") @@ -51,7 +51,7 @@ c2n_device::c2n_device(const machine_config &mconfig, device_type type, const ch { } -c2n_device::c2n_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c2n_device::c2n_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c2n_device(mconfig, C2N, tag, owner, clock) { } @@ -61,7 +61,7 @@ c2n_device::c2n_device(const machine_config &mconfig, const char *tag, device_t // c1530_device - constructor //------------------------------------------------- -c1530_device::c1530_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c1530_device::c1530_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c2n_device(mconfig, C1530, tag, owner, clock) { } @@ -71,7 +71,7 @@ c1530_device::c1530_device(const machine_config &mconfig, const char *tag, devic // c1531_device - constructor //------------------------------------------------- -c1531_device::c1531_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c1531_device::c1531_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c2n_device(mconfig, C1531, tag, owner, clock) { } diff --git a/src/devices/bus/pet/c2n.h b/src/devices/bus/pet/c2n.h index 86d8e5df288..67824fc2977 100644 --- a/src/devices/bus/pet/c2n.h +++ b/src/devices/bus/pet/c2n.h @@ -28,10 +28,10 @@ class c2n_device : public device_t, { public: // construction/destruction - c2n_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c2n_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - c2n_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + c2n_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -63,7 +63,7 @@ class c1530_device : public c2n_device { public: // construction/destruction - c1530_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c1530_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -73,7 +73,7 @@ class c1531_device : public c2n_device { public: // construction/destruction - c1531_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c1531_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/pet/cass.cpp b/src/devices/bus/pet/cass.cpp index 301633e6d73..bea32856dfe 100644 --- a/src/devices/bus/pet/cass.cpp +++ b/src/devices/bus/pet/cass.cpp @@ -52,7 +52,7 @@ device_pet_datassette_port_interface::~device_pet_datassette_port_interface() // pet_datassette_port_device - constructor //------------------------------------------------- -pet_datassette_port_device::pet_datassette_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pet_datassette_port_device::pet_datassette_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PET_DATASSETTE_PORT, tag, owner, clock), device_single_card_slot_interface<device_pet_datassette_port_interface>(mconfig, *this), m_read_handler(*this), m_cart(nullptr) diff --git a/src/devices/bus/pet/cass.h b/src/devices/bus/pet/cass.h index a6a6eac11f9..2c6f484822d 100644 --- a/src/devices/bus/pet/cass.h +++ b/src/devices/bus/pet/cass.h @@ -44,7 +44,7 @@ class pet_datassette_port_device : public device_t, public device_single_card_sl public: template <typename T> pet_datassette_port_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : pet_datassette_port_device(mconfig, tag, owner, 0) + : pet_datassette_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -52,7 +52,7 @@ public: set_fixed(false); } - pet_datassette_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pet_datassette_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~pet_datassette_port_device(); // static configuration helpers diff --git a/src/devices/bus/pet/cb2snd.cpp b/src/devices/bus/pet/cb2snd.cpp index b80d2efcce8..70e30bb10eb 100644 --- a/src/devices/bus/pet/cb2snd.cpp +++ b/src/devices/bus/pet/cb2snd.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(PET_USERPORT_CB2_SOUND_DEVICE, pet_userport_cb2_sound_device, void pet_userport_cb2_sound_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "speaker").front_center(); - DAC_1BIT(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.99); + DAC_1BIT(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.99); } //************************************************************************** @@ -39,7 +39,7 @@ void pet_userport_cb2_sound_device::device_add_mconfig(machine_config &config) // pet_userport_cb2_sound_device - constructor //------------------------------------------------- -pet_userport_cb2_sound_device::pet_userport_cb2_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pet_userport_cb2_sound_device::pet_userport_cb2_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PET_USERPORT_CB2_SOUND_DEVICE, tag, owner, clock), device_pet_user_port_interface(mconfig, *this), m_dac(*this, "dac") diff --git a/src/devices/bus/pet/cb2snd.h b/src/devices/bus/pet/cb2snd.h index cd39cc5bbb8..c5b08100514 100644 --- a/src/devices/bus/pet/cb2snd.h +++ b/src/devices/bus/pet/cb2snd.h @@ -23,7 +23,7 @@ class pet_userport_cb2_sound_device : public device_t, { public: // construction/destruction - pet_userport_cb2_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pet_userport_cb2_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER( input_m ) override; diff --git a/src/devices/bus/pet/diag.cpp b/src/devices/bus/pet/diag.cpp index 42e915e6d19..db40d342b5d 100644 --- a/src/devices/bus/pet/diag.cpp +++ b/src/devices/bus/pet/diag.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(PET_USERPORT_DIAGNOSTIC_CONNECTOR, pet_userport_diagnostic_co // pet_userport_diagnostic_connector_t - constructor //------------------------------------------------- -pet_userport_diagnostic_connector_device::pet_userport_diagnostic_connector_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pet_userport_diagnostic_connector_device::pet_userport_diagnostic_connector_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PET_USERPORT_DIAGNOSTIC_CONNECTOR, tag, owner, clock), device_pet_user_port_interface(mconfig, *this) { diff --git a/src/devices/bus/pet/diag.h b/src/devices/bus/pet/diag.h index 8bcf1bfd415..98fcf2721b1 100644 --- a/src/devices/bus/pet/diag.h +++ b/src/devices/bus/pet/diag.h @@ -25,7 +25,7 @@ class pet_userport_diagnostic_connector_device : public device_t, public device_ { public: // construction/destruction - pet_userport_diagnostic_connector_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pet_userport_diagnostic_connector_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_pet_user_port_interface overrides virtual DECLARE_WRITE_LINE_MEMBER( input_2 ) override { output_b(state); } diff --git a/src/devices/bus/pet/diag264_lb_tape.cpp b/src/devices/bus/pet/diag264_lb_tape.cpp index afe5efab4dd..38345feb7f2 100644 --- a/src/devices/bus/pet/diag264_lb_tape.cpp +++ b/src/devices/bus/pet/diag264_lb_tape.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(DIAG264_CASSETTE_LOOPBACK, diag264_cassette_loopback_device, // diag264_cassette_loopback_device - constructor //------------------------------------------------- -diag264_cassette_loopback_device::diag264_cassette_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +diag264_cassette_loopback_device::diag264_cassette_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DIAG264_CASSETTE_LOOPBACK, tag, owner, clock) , device_pet_datassette_port_interface(mconfig, *this) , m_read(1) diff --git a/src/devices/bus/pet/diag264_lb_tape.h b/src/devices/bus/pet/diag264_lb_tape.h index 6eb11fd395d..4ac7756986b 100644 --- a/src/devices/bus/pet/diag264_lb_tape.h +++ b/src/devices/bus/pet/diag264_lb_tape.h @@ -26,7 +26,7 @@ class diag264_cassette_loopback_device : public device_t, { public: // construction/destruction - diag264_cassette_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + diag264_cassette_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pet/exp.cpp b/src/devices/bus/pet/exp.cpp index aef8c5dfbf4..cc2409b9860 100644 --- a/src/devices/bus/pet/exp.cpp +++ b/src/devices/bus/pet/exp.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(PET_EXPANSION_SLOT, pet_expansion_slot_device, "pet_expansion // pet_expansion_slot_device - constructor //------------------------------------------------- -pet_expansion_slot_device::pet_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pet_expansion_slot_device::pet_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PET_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_pet_expansion_card_interface>(mconfig, *this), m_card(nullptr), diff --git a/src/devices/bus/pet/exp.h b/src/devices/bus/pet/exp.h index e8018bdd732..b2a3b6f5669 100644 --- a/src/devices/bus/pet/exp.h +++ b/src/devices/bus/pet/exp.h @@ -29,7 +29,7 @@ class pet_expansion_slot_device : public device_t, { public: template <typename T> - pet_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + pet_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : pet_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -38,7 +38,7 @@ public: set_fixed(false); } - pet_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pet_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~pet_expansion_slot_device(); auto dma_read_callback() { return m_read_dma.bind(); } diff --git a/src/devices/bus/pet/hsg.cpp b/src/devices/bus/pet/hsg.cpp index 7c6e7c657d6..894f4e46b3b 100644 --- a/src/devices/bus/pet/hsg.cpp +++ b/src/devices/bus/pet/hsg.cpp @@ -100,7 +100,7 @@ void cbm8000_hsg_a_device::device_add_mconfig(machine_config &config) screen.set_refresh_hz(25); PALETTE(config, "palette", palette_device::MONOCHROME); - EF9365(config, m_gdc, 1750000); + EF9365(config, m_gdc, XTAL::u(1750000)); m_gdc->set_screen(SCREEN_TAG); m_gdc->set_addrmap(0, &cbm8000_hsg_a_device::hsg_a_map); m_gdc->set_palette_tag("palette"); @@ -117,7 +117,7 @@ void cbm8000_hsg_b_device::device_add_mconfig(machine_config &config) screen.set_refresh_hz(50); PALETTE(config, "palette", palette_device::MONOCHROME); - EF9365(config, m_gdc, 1750000); //EF9366 + EF9365(config, m_gdc, XTAL::u(1750000)); //EF9366 m_gdc->set_screen(SCREEN_TAG); m_gdc->set_addrmap(0, &cbm8000_hsg_b_device::hsg_b_map); m_gdc->set_palette_tag("palette"); @@ -135,7 +135,7 @@ void cbm8000_hsg_b_device::device_add_mconfig(machine_config &config) // cbm8000_hsg_device - constructor //------------------------------------------------- -cbm8000_hsg_device::cbm8000_hsg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +cbm8000_hsg_device::cbm8000_hsg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_pet_expansion_card_interface(mconfig, *this), m_gdc(*this, EF9365_TAG), @@ -144,12 +144,12 @@ cbm8000_hsg_device::cbm8000_hsg_device(const machine_config &mconfig, device_typ { } -cbm8000_hsg_a_device::cbm8000_hsg_a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm8000_hsg_a_device::cbm8000_hsg_a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cbm8000_hsg_device(mconfig, CBM8000_HSG_A, tag, owner, clock) { } -cbm8000_hsg_b_device::cbm8000_hsg_b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cbm8000_hsg_b_device::cbm8000_hsg_b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cbm8000_hsg_device(mconfig, CBM8000_HSG_B, tag, owner, clock) { } diff --git a/src/devices/bus/pet/hsg.h b/src/devices/bus/pet/hsg.h index e86cb101ac3..62696045338 100644 --- a/src/devices/bus/pet/hsg.h +++ b/src/devices/bus/pet/hsg.h @@ -26,7 +26,7 @@ class cbm8000_hsg_device : public device_t, public device_pet_expansion_card_int { protected: // construction/destruction - cbm8000_hsg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cbm8000_hsg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -54,7 +54,7 @@ class cbm8000_hsg_a_device : public cbm8000_hsg_device { public: // construction/destruction - cbm8000_hsg_a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm8000_hsg_a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -71,7 +71,7 @@ class cbm8000_hsg_b_device : public cbm8000_hsg_device { public: // construction/destruction - cbm8000_hsg_b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cbm8000_hsg_b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/pet/petuja.cpp b/src/devices/bus/pet/petuja.cpp index aee8c2a1f0f..63eeed343c0 100644 --- a/src/devices/bus/pet/petuja.cpp +++ b/src/devices/bus/pet/petuja.cpp @@ -60,7 +60,7 @@ ioport_constructor pet_userport_joystick_adapter_device::device_input_ports() co // pet_userport_joystick_adapter_device - constructor //------------------------------------------------- -pet_userport_joystick_adapter_device::pet_userport_joystick_adapter_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pet_userport_joystick_adapter_device::pet_userport_joystick_adapter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PET_USERPORT_JOYSTICK_ADAPTER, tag, owner, clock), device_pet_user_port_interface(mconfig, *this), m_up1(1), diff --git a/src/devices/bus/pet/petuja.h b/src/devices/bus/pet/petuja.h index b268c0d1519..a4a9c0e54c5 100644 --- a/src/devices/bus/pet/petuja.h +++ b/src/devices/bus/pet/petuja.h @@ -27,7 +27,7 @@ class pet_userport_joystick_adapter_device : public device_t, { public: // construction/destruction - pet_userport_joystick_adapter_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pet_userport_joystick_adapter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/pet/superpet.cpp b/src/devices/bus/pet/superpet.cpp index df5c0071600..c6e3a626693 100644 --- a/src/devices/bus/pet/superpet.cpp +++ b/src/devices/bus/pet/superpet.cpp @@ -77,7 +77,7 @@ void superpet_device::device_add_mconfig(machine_config &config) MOS6702(config, m_dongle, 16_MHz_XTAL / 16); - MOS6551(config, m_acia, 0); + MOS6551(config, m_acia); m_acia->set_xtal(1.8432_MHz_XTAL); m_acia->irq_handler().set(FUNC(superpet_device::acia_irq_w)); m_acia->txd_handler().set(RS232_TAG, FUNC(rs232_port_device::write_txd)); @@ -166,7 +166,7 @@ inline bool superpet_device::is_ram_writable() // superpet_device - constructor //------------------------------------------------- -superpet_device::superpet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +superpet_device::superpet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SUPERPET, tag, owner, clock), device_pet_expansion_card_interface(mconfig, *this), m_maincpu(*this, M6809_TAG), diff --git a/src/devices/bus/pet/superpet.h b/src/devices/bus/pet/superpet.h index 56c07df525f..9077ada1f88 100644 --- a/src/devices/bus/pet/superpet.h +++ b/src/devices/bus/pet/superpet.h @@ -28,7 +28,7 @@ class superpet_device : public device_t, { public: // construction/destruction - superpet_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + superpet_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pet/user.cpp b/src/devices/bus/pet/user.cpp index 574c6c9afe9..03ec82d699e 100644 --- a/src/devices/bus/pet/user.cpp +++ b/src/devices/bus/pet/user.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(PET_USER_PORT, pet_user_port_device, "pet_user_port", "PET user port") -pet_user_port_device::pet_user_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pet_user_port_device::pet_user_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PET_USER_PORT, tag, owner, clock), device_slot_interface(mconfig, *this), m_2_handler(*this), diff --git a/src/devices/bus/pet/user.h b/src/devices/bus/pet/user.h index 4a6a64c3081..e907a2022ba 100644 --- a/src/devices/bus/pet/user.h +++ b/src/devices/bus/pet/user.h @@ -38,14 +38,14 @@ class pet_user_port_device : public device_t, public device_slot_interface public: template <typename T> pet_user_port_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : pet_user_port_device(mconfig, tag, owner, 0) + : pet_user_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - pet_user_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pet_user_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto p2_handler() { return m_2_handler.bind(); } auto p3_handler() { return m_3_handler.bind(); } diff --git a/src/devices/bus/plus4/c1551.cpp b/src/devices/bus/plus4/c1551.cpp index 42bca7daa57..16592c2a53f 100644 --- a/src/devices/bus/plus4/c1551.cpp +++ b/src/devices/bus/plus4/c1551.cpp @@ -344,7 +344,7 @@ void c1551_device::device_add_mconfig(machine_config &config) PLS100(config, m_pla); - TPI6525(config, m_tpi0, 0); + TPI6525(config, m_tpi0); m_tpi0->in_pa_cb().set(FUNC(c1551_device::tcbm_data_r)); m_tpi0->out_pa_cb().set(FUNC(c1551_device::tcbm_data_w)); m_tpi0->in_pb_cb().set(m_ga, FUNC(c64h156_device::yb_r)); @@ -352,7 +352,7 @@ void c1551_device::device_add_mconfig(machine_config &config) m_tpi0->in_pc_cb().set(FUNC(c1551_device::tpi0_pc_r)); m_tpi0->out_pc_cb().set(FUNC(c1551_device::tpi0_pc_w)); - TPI6525(config, m_tpi1, 0); + TPI6525(config, m_tpi1); m_tpi1->in_pa_cb().set(FUNC(c1551_device::tcbm_data_r)); m_tpi1->out_pa_cb().set(FUNC(c1551_device::tcbm_data_w)); m_tpi1->in_pb_cb().set(FUNC(c1551_device::tpi1_pb_r)); @@ -362,7 +362,7 @@ void c1551_device::device_add_mconfig(machine_config &config) C64H156(config, m_ga, XTAL(16'000'000)); m_ga->byte_callback().set(m_ga, FUNC(c64h156_device::atni_w)); - floppy_connector &connector(FLOPPY_CONNECTOR(config, C64H156_TAG":0", 0)); + floppy_connector &connector(FLOPPY_CONNECTOR(config, C64H156_TAG":0")); connector.option_add("525ssqd", FLOPPY_525_SSQD); connector.set_default_option("525ssqd"); connector.set_fixed(true); @@ -408,7 +408,7 @@ ioport_constructor c1551_device::device_input_ports() const // c1551_device - constructor //------------------------------------------------- -c1551_device::c1551_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c1551_device::c1551_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C1551, tag, owner, clock) , device_plus4_expansion_card_interface(mconfig, *this) , m_maincpu(*this, M6510T_TAG) diff --git a/src/devices/bus/plus4/c1551.h b/src/devices/bus/plus4/c1551.h index eddad2c8046..b44f4275bd3 100644 --- a/src/devices/bus/plus4/c1551.h +++ b/src/devices/bus/plus4/c1551.h @@ -30,7 +30,7 @@ class c1551_device : public device_t, public device_plus4_expansion_card_interfa { public: // construction/destruction - c1551_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c1551_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/plus4/diag264_lb_user.cpp b/src/devices/bus/plus4/diag264_lb_user.cpp index a8e4dc32b8c..82113623c3d 100644 --- a/src/devices/bus/plus4/diag264_lb_user.cpp +++ b/src/devices/bus/plus4/diag264_lb_user.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(DIAG264_USER_PORT_LOOPBACK, diag264_user_port_loopback_device // diag264_user_port_loopback_device - constructor //------------------------------------------------- -diag264_user_port_loopback_device::diag264_user_port_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +diag264_user_port_loopback_device::diag264_user_port_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DIAG264_USER_PORT_LOOPBACK, tag, owner, clock) , device_pet_user_port_interface(mconfig, *this) { diff --git a/src/devices/bus/plus4/diag264_lb_user.h b/src/devices/bus/plus4/diag264_lb_user.h index dd45e469106..611d0c95f7c 100644 --- a/src/devices/bus/plus4/diag264_lb_user.h +++ b/src/devices/bus/plus4/diag264_lb_user.h @@ -25,7 +25,7 @@ class diag264_user_port_loopback_device : public device_t, public device_pet_use { public: // construction/destruction - diag264_user_port_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + diag264_user_port_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/plus4/exp.cpp b/src/devices/bus/plus4/exp.cpp index 1086683c02a..ab260c33548 100644 --- a/src/devices/bus/plus4/exp.cpp +++ b/src/devices/bus/plus4/exp.cpp @@ -64,7 +64,7 @@ device_plus4_expansion_card_interface::~device_plus4_expansion_card_interface() // plus4_expansion_slot_device - constructor //------------------------------------------------- -plus4_expansion_slot_device::plus4_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +plus4_expansion_slot_device::plus4_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PLUS4_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_plus4_expansion_card_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/plus4/exp.h b/src/devices/bus/plus4/exp.h index bac19750c2d..2744e46dae8 100644 --- a/src/devices/bus/plus4/exp.h +++ b/src/devices/bus/plus4/exp.h @@ -57,7 +57,7 @@ class plus4_expansion_slot_device : public device_t, public: // construction/destruction template <typename T> - plus4_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) + plus4_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts, char const *dflt) : plus4_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -65,7 +65,7 @@ public: set_default_option(dflt); set_fixed(false); } - plus4_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + plus4_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_wr_callback() { return m_write_irq.bind(); } auto cd_rd_callback() { return m_read_dma_cd.bind(); } @@ -81,7 +81,7 @@ public: void dma_cd_w(offs_t offset, uint8_t data) { m_write_dma_cd(offset, data); } DECLARE_WRITE_LINE_MEMBER( irq_w ) { m_write_irq(state); } DECLARE_WRITE_LINE_MEMBER( aec_w ) { m_write_aec(state); } - int phi2() { return clock(); } + XTAL phi2() { return clock(); } protected: // device-level overrides diff --git a/src/devices/bus/plus4/sid.cpp b/src/devices/bus/plus4/sid.cpp index b5c6e9d897f..5c0b9dcfbb6 100644 --- a/src/devices/bus/plus4/sid.cpp +++ b/src/devices/bus/plus4/sid.cpp @@ -82,7 +82,7 @@ void plus4_sid_cartridge_device::device_add_mconfig(machine_config &config) // plus4_sid_cartridge_device - constructor //------------------------------------------------- -plus4_sid_cartridge_device::plus4_sid_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +plus4_sid_cartridge_device::plus4_sid_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PLUS4_SID, tag, owner, clock), device_plus4_expansion_card_interface(mconfig, *this), m_sid(*this, MOS8580_TAG), diff --git a/src/devices/bus/plus4/sid.h b/src/devices/bus/plus4/sid.h index 1566381e6d2..73045f5a4e7 100644 --- a/src/devices/bus/plus4/sid.h +++ b/src/devices/bus/plus4/sid.h @@ -28,7 +28,7 @@ class plus4_sid_cartridge_device : public device_t, { public: // construction/destruction - plus4_sid_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + plus4_sid_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/plus4/std.cpp b/src/devices/bus/plus4/std.cpp index ed9e9ff83a5..73157b36292 100644 --- a/src/devices/bus/plus4/std.cpp +++ b/src/devices/bus/plus4/std.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(PLUS4_STD, plus4_standard_cartridge_device, "plus4_standard", // plus4_standard_cartridge_device - constructor //------------------------------------------------- -plus4_standard_cartridge_device::plus4_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +plus4_standard_cartridge_device::plus4_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PLUS4_STD, tag, owner, clock), device_plus4_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/plus4/std.h b/src/devices/bus/plus4/std.h index f1f3ae75328..6a3de9f252b 100644 --- a/src/devices/bus/plus4/std.h +++ b/src/devices/bus/plus4/std.h @@ -26,7 +26,7 @@ class plus4_standard_cartridge_device : public device_t, { public: // construction/destruction - plus4_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + plus4_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pofo/ccm.cpp b/src/devices/bus/pofo/ccm.cpp index d491af7266f..aa9ff2767f4 100644 --- a/src/devices/bus/pofo/ccm.cpp +++ b/src/devices/bus/pofo/ccm.cpp @@ -45,7 +45,7 @@ device_portfolio_memory_card_slot_interface::device_portfolio_memory_card_slot_i // portfolio_memory_card_slot_device - constructor //------------------------------------------------- -portfolio_memory_card_slot_device::portfolio_memory_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +portfolio_memory_card_slot_device::portfolio_memory_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PORTFOLIO_MEMORY_CARD_SLOT, tag, owner, clock), device_single_card_slot_interface<device_portfolio_memory_card_slot_interface>(mconfig, *this), device_memcard_image_interface(mconfig, *this), diff --git a/src/devices/bus/pofo/ccm.h b/src/devices/bus/pofo/ccm.h index 53e3c7a65ea..0605dc919d8 100644 --- a/src/devices/bus/pofo/ccm.h +++ b/src/devices/bus/pofo/ccm.h @@ -98,7 +98,7 @@ public: // construction/destruction template <typename T> portfolio_memory_card_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : portfolio_memory_card_slot_device(mconfig, tag, owner, 0) + : portfolio_memory_card_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -106,7 +106,7 @@ public: set_fixed(false); } - portfolio_memory_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + portfolio_memory_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // computer interface bool cdet_r() { return (m_card != nullptr) ? m_card->cdet() : 1; } diff --git a/src/devices/bus/pofo/exp.cpp b/src/devices/bus/pofo/exp.cpp index 8dc14ecfd03..cba649e965a 100644 --- a/src/devices/bus/pofo/exp.cpp +++ b/src/devices/bus/pofo/exp.cpp @@ -47,7 +47,7 @@ WRITE_LINE_MEMBER( device_portfolio_expansion_slot_interface::wake_w ) { m_slot- // portfolio_expansion_slot_device - constructor //------------------------------------------------- -portfolio_expansion_slot_device::portfolio_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +portfolio_expansion_slot_device::portfolio_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PORTFOLIO_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_portfolio_expansion_slot_interface>(mconfig, *this), m_write_eint(*this), diff --git a/src/devices/bus/pofo/exp.h b/src/devices/bus/pofo/exp.h index 0790aa04123..30e63837c07 100644 --- a/src/devices/bus/pofo/exp.h +++ b/src/devices/bus/pofo/exp.h @@ -89,7 +89,7 @@ class portfolio_expansion_slot_device : public device_t, public device_single_ca public: // construction/destruction template <typename T> - portfolio_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) + portfolio_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts, char const *dflt) : portfolio_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -98,7 +98,7 @@ public: set_fixed(false); } - portfolio_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + portfolio_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto eint_wr_callback() { return m_write_eint.bind(); } auto nmio_wr_callback() { return m_write_nmio.bind(); } diff --git a/src/devices/bus/pofo/hpc101.cpp b/src/devices/bus/pofo/hpc101.cpp index 692c42ae7fc..210ae88004e 100644 --- a/src/devices/bus/pofo/hpc101.cpp +++ b/src/devices/bus/pofo/hpc101.cpp @@ -68,7 +68,7 @@ void pofo_hpc101_device::device_add_mconfig(machine_config &config) // pofo_hpc101_device - constructor //------------------------------------------------- -pofo_hpc101_device::pofo_hpc101_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pofo_hpc101_device::pofo_hpc101_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, POFO_HPC101, tag, owner, clock), device_portfolio_expansion_slot_interface(mconfig, *this), m_ppi(*this, M82C55A_TAG) diff --git a/src/devices/bus/pofo/hpc101.h b/src/devices/bus/pofo/hpc101.h index fa18b5d6d4d..152440ba049 100644 --- a/src/devices/bus/pofo/hpc101.h +++ b/src/devices/bus/pofo/hpc101.h @@ -27,7 +27,7 @@ class pofo_hpc101_device : public device_t, public device_portfolio_expansion_sl { public: // construction/destruction - pofo_hpc101_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pofo_hpc101_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pofo/hpc102.cpp b/src/devices/bus/pofo/hpc102.cpp index 00838036bf0..01c740e6219 100644 --- a/src/devices/bus/pofo/hpc102.cpp +++ b/src/devices/bus/pofo/hpc102.cpp @@ -58,7 +58,7 @@ void pofo_hpc102_device::device_add_mconfig(machine_config &config) // pofo_hpc102_device - constructor //------------------------------------------------- -pofo_hpc102_device::pofo_hpc102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pofo_hpc102_device::pofo_hpc102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, POFO_HPC102, tag, owner, clock), device_portfolio_expansion_slot_interface(mconfig, *this), m_uart(*this, M82C50A_TAG) diff --git a/src/devices/bus/pofo/hpc102.h b/src/devices/bus/pofo/hpc102.h index c7168b12787..d1d7f1bc82a 100644 --- a/src/devices/bus/pofo/hpc102.h +++ b/src/devices/bus/pofo/hpc102.h @@ -27,7 +27,7 @@ class pofo_hpc102_device : public device_t, public device_portfolio_expansion_sl { public: // construction/destruction - pofo_hpc102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pofo_hpc102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pofo/hpc104.cpp b/src/devices/bus/pofo/hpc104.cpp index 0d8953b20c6..c492e656029 100644 --- a/src/devices/bus/pofo/hpc104.cpp +++ b/src/devices/bus/pofo/hpc104.cpp @@ -95,7 +95,7 @@ ioport_constructor pofo_hpc104_2_device::device_input_ports() const // pofo_hpc104_device - constructor //------------------------------------------------- -pofo_hpc104_device::pofo_hpc104_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +pofo_hpc104_device::pofo_hpc104_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_portfolio_expansion_slot_interface(mconfig, *this), device_nvram_interface(mconfig, *this), @@ -106,7 +106,7 @@ pofo_hpc104_device::pofo_hpc104_device(const machine_config &mconfig, device_typ { } -pofo_hpc104_device::pofo_hpc104_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pofo_hpc104_device::pofo_hpc104_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pofo_hpc104_device(mconfig, POFO_HPC104, tag, owner, clock) { } @@ -116,7 +116,7 @@ pofo_hpc104_device::pofo_hpc104_device(const machine_config &mconfig, const char // pofo_hpc104_2_device - constructor //------------------------------------------------- -pofo_hpc104_2_device::pofo_hpc104_2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pofo_hpc104_2_device::pofo_hpc104_2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pofo_hpc104_device(mconfig, POFO_HPC104_2, tag, owner, clock) { } diff --git a/src/devices/bus/pofo/hpc104.h b/src/devices/bus/pofo/hpc104.h index d5d1c36c3d3..45a78faec87 100644 --- a/src/devices/bus/pofo/hpc104.h +++ b/src/devices/bus/pofo/hpc104.h @@ -28,10 +28,10 @@ class pofo_hpc104_device : public device_t, { public: // construction/destruction - pofo_hpc104_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pofo_hpc104_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - pofo_hpc104_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pofo_hpc104_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -71,7 +71,7 @@ class pofo_hpc104_2_device : public pofo_hpc104_device { public: // construction/destruction - pofo_hpc104_2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pofo_hpc104_2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/pofo/ram.cpp b/src/devices/bus/pofo/ram.cpp index 7f1298b8b95..027cdd394fe 100644 --- a/src/devices/bus/pofo/ram.cpp +++ b/src/devices/bus/pofo/ram.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(PORTFOLIO_RAM_CARD, portfolio_ram_card_device, "portfolio_ram // portfolio_ram_card_device - constructor //------------------------------------------------- -portfolio_ram_card_device::portfolio_ram_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +portfolio_ram_card_device::portfolio_ram_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PORTFOLIO_RAM_CARD, tag, owner, clock), device_portfolio_memory_card_slot_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/bus/pofo/ram.h b/src/devices/bus/pofo/ram.h index 7217299a989..47fa1fbcb74 100644 --- a/src/devices/bus/pofo/ram.h +++ b/src/devices/bus/pofo/ram.h @@ -27,7 +27,7 @@ class portfolio_ram_card_device : public device_t, { public: // construction/destruction - portfolio_ram_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + portfolio_ram_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/pofo/rom.cpp b/src/devices/bus/pofo/rom.cpp index 2e49c3df8dd..05aa1fee9b0 100644 --- a/src/devices/bus/pofo/rom.cpp +++ b/src/devices/bus/pofo/rom.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(PORTFOLIO_ROM_CARD, portfolio_rom_card_device, "portfolio_rom // portfolio_rom_card_device - constructor //------------------------------------------------- -portfolio_rom_card_device::portfolio_rom_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +portfolio_rom_card_device::portfolio_rom_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PORTFOLIO_ROM_CARD, tag, owner, clock), device_portfolio_memory_card_slot_interface(mconfig, *this) { diff --git a/src/devices/bus/pofo/rom.h b/src/devices/bus/pofo/rom.h index 6df19402a36..bbad55d288e 100644 --- a/src/devices/bus/pofo/rom.h +++ b/src/devices/bus/pofo/rom.h @@ -26,7 +26,7 @@ class portfolio_rom_card_device : public device_t, { public: // construction/destruction - portfolio_rom_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + portfolio_rom_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/psi_kbd/ergoline.cpp b/src/devices/bus/psi_kbd/ergoline.cpp index 7b892cf861b..e519e99fc1c 100644 --- a/src/devices/bus/psi_kbd/ergoline.cpp +++ b/src/devices/bus/psi_kbd/ergoline.cpp @@ -74,7 +74,7 @@ void ergoline_keyboard_device::device_add_mconfig(machine_config &config) // ergoline_keyboard_device - constructor //------------------------------------------------- -ergoline_keyboard_device::ergoline_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ergoline_keyboard_device::ergoline_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ERGOLINE_KEYBOARD, tag, owner, clock), device_psi_keyboard_interface(mconfig, *this) { diff --git a/src/devices/bus/psi_kbd/ergoline.h b/src/devices/bus/psi_kbd/ergoline.h index 3b3329d45cb..8655671cc14 100644 --- a/src/devices/bus/psi_kbd/ergoline.h +++ b/src/devices/bus/psi_kbd/ergoline.h @@ -26,7 +26,7 @@ class ergoline_keyboard_device : public device_t, public device_psi_keyboard_int { public: // construction/destruction - ergoline_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ergoline_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::KEYBOARD; } diff --git a/src/devices/bus/psi_kbd/hle.cpp b/src/devices/bus/psi_kbd/hle.cpp index 7fd1b02677f..03988bc7092 100644 --- a/src/devices/bus/psi_kbd/hle.cpp +++ b/src/devices/bus/psi_kbd/hle.cpp @@ -217,7 +217,7 @@ ioport_constructor psi_hle_keyboard_device::device_input_ports() const // psi_hle_keyboard_device - constructor //------------------------------------------------- -psi_hle_keyboard_device::psi_hle_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psi_hle_keyboard_device::psi_hle_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSI_HLE_KEYBOARD, tag, owner, clock), device_psi_keyboard_interface(mconfig, *this), device_matrix_keyboard_interface(mconfig, *this, "row_0", "row_1", "row_2", "row_3", "row_4", "row_5", "row_6"), diff --git a/src/devices/bus/psi_kbd/hle.h b/src/devices/bus/psi_kbd/hle.h index b563489ef22..1266e280679 100644 --- a/src/devices/bus/psi_kbd/hle.h +++ b/src/devices/bus/psi_kbd/hle.h @@ -27,7 +27,7 @@ class psi_hle_keyboard_device : public device_t, { public: // construction/destruction - psi_hle_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psi_hle_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/psi_kbd/psi_kbd.cpp b/src/devices/bus/psi_kbd/psi_kbd.cpp index 1ba3a0e2620..e59165a7ae1 100644 --- a/src/devices/bus/psi_kbd/psi_kbd.cpp +++ b/src/devices/bus/psi_kbd/psi_kbd.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(PSI_KEYBOARD_INTERFACE, psi_keyboard_bus_device, "psi_kbd", " // psi_keyboard_bus_device - constructor //------------------------------------------------- -psi_keyboard_bus_device::psi_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psi_keyboard_bus_device::psi_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSI_KEYBOARD_INTERFACE, tag, owner, clock), device_single_card_slot_interface<device_psi_keyboard_interface>(mconfig, *this), m_kbd(nullptr), diff --git a/src/devices/bus/psi_kbd/psi_kbd.h b/src/devices/bus/psi_kbd/psi_kbd.h index 364ef98586a..a4a70a39142 100644 --- a/src/devices/bus/psi_kbd/psi_kbd.h +++ b/src/devices/bus/psi_kbd/psi_kbd.h @@ -46,14 +46,14 @@ class psi_keyboard_bus_device : public device_t, public device_single_card_slot_ public: // construction/destruction psi_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *dflt) - : psi_keyboard_bus_device(mconfig, tag, owner, (uint32_t)0) + : psi_keyboard_bus_device(mconfig, tag, owner) { option_reset(); psi_keyboard_devices(*this); set_default_option(dflt); set_fixed(false); } - psi_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psi_keyboard_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~psi_keyboard_bus_device(); // callbacks diff --git a/src/devices/bus/psx/analogue.cpp b/src/devices/bus/psx/analogue.cpp index 61feefeb311..805c75f41b7 100644 --- a/src/devices/bus/psx/analogue.cpp +++ b/src/devices/bus/psx/analogue.cpp @@ -6,7 +6,7 @@ DEFINE_DEVICE_TYPE(PSX_DUALSHOCK, psx_dualshock_device, "psx_dualshock_pad", "Playstation Dualshock Pad") DEFINE_DEVICE_TYPE(PSX_ANALOG_JOYSTICK, psx_analog_joystick_device, "psx_analog_joystick", "Playstation Analog Joystick") -psx_analog_controller_device::psx_analog_controller_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, model mod) : +psx_analog_controller_device::psx_analog_controller_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, model mod) : device_t(mconfig, type, tag, owner, clock), device_psx_controller_interface(mconfig, *this), m_model(mod), @@ -24,12 +24,12 @@ psx_analog_controller_device::psx_analog_controller_device(const machine_config { } -psx_dualshock_device::psx_dualshock_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psx_dualshock_device::psx_dualshock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : psx_analog_controller_device(mconfig, PSX_DUALSHOCK, tag, owner, clock, model::DUALSHOCK) { } -psx_analog_joystick_device::psx_analog_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psx_analog_joystick_device::psx_analog_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : psx_analog_controller_device(mconfig, PSX_ANALOG_JOYSTICK, tag, owner, clock, model::JOYSTICK) { } diff --git a/src/devices/bus/psx/analogue.h b/src/devices/bus/psx/analogue.h index 09eaf9baa65..f4e1abd72f5 100644 --- a/src/devices/bus/psx/analogue.h +++ b/src/devices/bus/psx/analogue.h @@ -19,7 +19,7 @@ public: protected: enum class model { JOYSTICK, DUALSHOCK }; - psx_analog_controller_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, model mod); + psx_analog_controller_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, model mod); virtual void device_start() override { } virtual void device_reset() override; @@ -48,13 +48,13 @@ private: class psx_dualshock_device : public psx_analog_controller_device { public: - psx_dualshock_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psx_dualshock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class psx_analog_joystick_device : public psx_analog_controller_device { public: - psx_analog_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psx_analog_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; #endif // MAME_BUS_PSX_ANALOGUE_H diff --git a/src/devices/bus/psx/ctlrport.cpp b/src/devices/bus/psx/ctlrport.cpp index 1e6158ff614..908b6ce91f4 100644 --- a/src/devices/bus/psx/ctlrport.cpp +++ b/src/devices/bus/psx/ctlrport.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(PSX_CONTROLLER_PORT, psx_controller_port_device, "psx DEFINE_DEVICE_TYPE(PSXCONTROLLERPORTS, psxcontrollerports_device, "psxcontrollerports", "Playstation Controller Bus") DEFINE_DEVICE_TYPE(PSX_STANDARD_CONTROLLER, psx_standard_controller_device, "psx_standard_controller", "Playstation Standard Controller") -psx_controller_port_device::psx_controller_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psx_controller_port_device::psx_controller_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSX_CONTROLLER_PORT, tag, owner, clock), device_single_card_slot_interface<device_psx_controller_interface>(mconfig, *this), m_tx(false), @@ -27,7 +27,7 @@ void psx_controller_port_device::device_config_complete() void psx_controller_port_device::device_add_mconfig(machine_config &config) { - PSXCARD(config, m_card, 0); + PSXCARD(config, m_card); } void psx_controller_port_device::disable_card(bool state) @@ -38,7 +38,7 @@ void psx_controller_port_device::disable_card(bool state) m_card->disable(state); } -psxcontrollerports_device::psxcontrollerports_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psxcontrollerports_device::psxcontrollerports_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSXCONTROLLERPORTS, tag, owner, clock), m_port0(*this, "^port1"), m_port1(*this, "^port2"), @@ -177,7 +177,7 @@ void device_psx_controller_interface::sel_w(bool state) { m_sel = state; } -psx_standard_controller_device::psx_standard_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psx_standard_controller_device::psx_standard_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSX_STANDARD_CONTROLLER, tag, owner, clock), device_psx_controller_interface(mconfig, *this), m_pad0(*this, "PSXPAD0"), diff --git a/src/devices/bus/psx/ctlrport.h b/src/devices/bus/psx/ctlrport.h index 5c8fc82dd22..baf48895c4b 100644 --- a/src/devices/bus/psx/ctlrport.h +++ b/src/devices/bus/psx/ctlrport.h @@ -65,7 +65,7 @@ class psx_standard_controller_device : public device_t, public device_psx_controller_interface { public: - psx_standard_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psx_standard_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; @@ -82,7 +82,7 @@ private: class psxcontrollerports_device : public device_t { public: - psxcontrollerports_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psxcontrollerports_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void ack(); @@ -110,14 +110,14 @@ class psx_controller_port_device : public device_t, public: template <typename T> psx_controller_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : psx_controller_port_device(mconfig, tag, owner, (uint32_t)0) + : psx_controller_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - psx_controller_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psx_controller_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); typedef delegate<void ()> void_cb; void ack() { if(!ack_cb.isnull()) ack_cb(); } diff --git a/src/devices/bus/psx/gamebooster.cpp b/src/devices/bus/psx/gamebooster.cpp index 1c414ca41a2..96416856073 100644 --- a/src/devices/bus/psx/gamebooster.cpp +++ b/src/devices/bus/psx/gamebooster.cpp @@ -46,7 +46,7 @@ ROM_END // psx_gamebooster_device - constructor //------------------------------------------------- -psx_gamebooster_device::psx_gamebooster_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +psx_gamebooster_device::psx_gamebooster_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSX_GAMEBOOSTER, tag, owner, clock) , psx_parallel_interface(mconfig, *this) , device_memory_interface(mconfig, *this) diff --git a/src/devices/bus/psx/gamebooster.h b/src/devices/bus/psx/gamebooster.h index 9e990f726d5..caa6b08a0db 100644 --- a/src/devices/bus/psx/gamebooster.h +++ b/src/devices/bus/psx/gamebooster.h @@ -22,7 +22,7 @@ class psx_gamebooster_device : { public: // construction/destruction - psx_gamebooster_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psx_gamebooster_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // psx_parallel_interface implementation virtual uint16_t exp_r(offs_t offset, uint16_t mem_mask = ~0) override; diff --git a/src/devices/bus/psx/memcard.cpp b/src/devices/bus/psx/memcard.cpp index 682439ff76e..451115ed9ff 100644 --- a/src/devices/bus/psx/memcard.cpp +++ b/src/devices/bus/psx/memcard.cpp @@ -41,7 +41,7 @@ enum transfer_states state_end }; -psxcard_device::psxcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +psxcard_device::psxcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSXCARD, tag, owner, clock), device_memcard_image_interface(mconfig, *this), pkt_ptr(0), diff --git a/src/devices/bus/psx/memcard.h b/src/devices/bus/psx/memcard.h index a558f07164c..21705316c87 100644 --- a/src/devices/bus/psx/memcard.h +++ b/src/devices/bus/psx/memcard.h @@ -15,7 +15,7 @@ class psxcard_device : public device_t, public device_memcard_image_interface { public: - psxcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psxcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual bool is_reset_on_load() const noexcept override { return false; } virtual const char *file_extensions() const noexcept override { return "mc"; } diff --git a/src/devices/bus/psx/multitap.cpp b/src/devices/bus/psx/multitap.cpp index 5de09102287..447d9f56abc 100644 --- a/src/devices/bus/psx/multitap.cpp +++ b/src/devices/bus/psx/multitap.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(PSX_MULTITAP, psx_multitap_device, "psx_multitap", "Playstation Multitap") -psx_multitap_device::psx_multitap_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +psx_multitap_device::psx_multitap_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, PSX_MULTITAP, tag, owner, clock), device_psx_controller_interface(mconfig, *this), m_activeport(0), diff --git a/src/devices/bus/psx/multitap.h b/src/devices/bus/psx/multitap.h index 0ac7e6626f7..446eeedb8da 100644 --- a/src/devices/bus/psx/multitap.h +++ b/src/devices/bus/psx/multitap.h @@ -11,7 +11,7 @@ class psx_multitap_device : public device_t, public device_psx_controller_interface { public: - psx_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psx_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/psx/parallel.cpp b/src/devices/bus/psx/parallel.cpp index 8faf038cfec..01112b1cd79 100644 --- a/src/devices/bus/psx/parallel.cpp +++ b/src/devices/bus/psx/parallel.cpp @@ -46,7 +46,7 @@ psx_parallel_interface::~psx_parallel_interface() // psx_parallel_slot_device - constructor //------------------------------------------------- -psx_parallel_slot_device::psx_parallel_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psx_parallel_slot_device::psx_parallel_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSX_PARALLEL_SLOT, tag, owner, clock), device_single_card_slot_interface<psx_parallel_interface>(mconfig, *this), m_card(nullptr) diff --git a/src/devices/bus/psx/parallel.h b/src/devices/bus/psx/parallel.h index 313a2ecc951..52fe3a43233 100644 --- a/src/devices/bus/psx/parallel.h +++ b/src/devices/bus/psx/parallel.h @@ -20,14 +20,14 @@ public: // construction/destruction template <typename T> psx_parallel_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : psx_parallel_slot_device(mconfig, tag, owner, (uint32_t)0) + : psx_parallel_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - psx_parallel_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psx_parallel_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~psx_parallel_slot_device(); uint16_t exp_r(offs_t offset); diff --git a/src/devices/bus/qbus/dsd4432.cpp b/src/devices/bus/qbus/dsd4432.cpp index eebb97f05fc..7ff765f5e65 100644 --- a/src/devices/bus/qbus/dsd4432.cpp +++ b/src/devices/bus/qbus/dsd4432.cpp @@ -24,7 +24,7 @@ // device type definition DEFINE_DEVICE_TYPE(DSD4432, dsd4432_device, "dsd4432", "DSD A4432 Floppy Disk Interface") -dsd4432_device::dsd4432_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dsd4432_device::dsd4432_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DSD4432, tag, owner, clock) , device_qbus_card_interface(mconfig, *this) , m_bootstrap(*this, "bootstrap") diff --git a/src/devices/bus/qbus/dsd4432.h b/src/devices/bus/qbus/dsd4432.h index 6f59404077c..55f95036e6d 100644 --- a/src/devices/bus/qbus/dsd4432.h +++ b/src/devices/bus/qbus/dsd4432.h @@ -23,7 +23,7 @@ class dsd4432_device : public device_t, public device_qbus_card_interface { public: // device type constructor - dsd4432_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dsd4432_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/qbus/dvk_kgd.cpp b/src/devices/bus/qbus/dvk_kgd.cpp index 1c7f28c5fc8..92548fda2d7 100644 --- a/src/devices/bus/qbus/dvk_kgd.cpp +++ b/src/devices/bus/qbus/dvk_kgd.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(DVK_KGD, dvk_kgd_device, "kgd", "DVK KGD framebuffer") // dvk_kgd_device - constructor //------------------------------------------------- -dvk_kgd_device::dvk_kgd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dvk_kgd_device::dvk_kgd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DVK_KGD, tag, owner, clock) , device_qbus_card_interface(mconfig, *this) , m_screen(*this, "screen") diff --git a/src/devices/bus/qbus/dvk_kgd.h b/src/devices/bus/qbus/dvk_kgd.h index 8ecd4ef23e2..aa1cb031ae0 100644 --- a/src/devices/bus/qbus/dvk_kgd.h +++ b/src/devices/bus/qbus/dvk_kgd.h @@ -33,7 +33,7 @@ class dvk_kgd_device : public device_t, { public: // construction/destruction - dvk_kgd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dvk_kgd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); diff --git a/src/devices/bus/qbus/pc11.cpp b/src/devices/bus/qbus/pc11.cpp index 2fc73ada4df..014bb336658 100644 --- a/src/devices/bus/qbus/pc11.cpp +++ b/src/devices/bus/qbus/pc11.cpp @@ -54,7 +54,7 @@ const char* pc11_regnames[] = { // pc11_device - constructor //------------------------------------------------- -pc11_device::pc11_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc11_device::pc11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : paper_tape_reader_device(mconfig, DEC_PC11, tag, owner, clock) , device_qbus_card_interface(mconfig, *this) , m_rxvec(070) diff --git a/src/devices/bus/qbus/pc11.h b/src/devices/bus/qbus/pc11.h index cbc0d134f47..9a938a57fa6 100644 --- a/src/devices/bus/qbus/pc11.h +++ b/src/devices/bus/qbus/pc11.h @@ -34,7 +34,7 @@ class pc11_device : public paper_tape_reader_device, { public: // construction/destruction - pc11_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // image-level overrides virtual const char *image_interface() const noexcept override { return "pdp11_ptap"; } diff --git a/src/devices/bus/qbus/qbus.cpp b/src/devices/bus/qbus/qbus.cpp index c159bb976ff..b6866f12165 100644 --- a/src/devices/bus/qbus/qbus.cpp +++ b/src/devices/bus/qbus/qbus.cpp @@ -53,7 +53,7 @@ device_qbus_card_interface::device_qbus_card_interface(const machine_config &mco //------------------------------------------------- // qbus_slot_device - constructor //------------------------------------------------- -qbus_slot_device::qbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +qbus_slot_device::qbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, QBUS_SLOT, tag, owner, clock), device_slot_interface(mconfig, *this), m_write_birq4(*this), @@ -88,7 +88,7 @@ void qbus_slot_device::device_start() // qbus_device - constructor //------------------------------------------------- -qbus_device::qbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +qbus_device::qbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, QBUS, tag, owner, clock), device_memory_interface(mconfig, *this), device_z80daisy_interface(mconfig, *this), diff --git a/src/devices/bus/qbus/qbus.h b/src/devices/bus/qbus/qbus.h index 3b5ca881292..6b091185a61 100644 --- a/src/devices/bus/qbus/qbus.h +++ b/src/devices/bus/qbus/qbus.h @@ -60,12 +60,12 @@ public: // construction/destruction template <typename T> qbus_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cputag, int spacenum) - : qbus_device(mconfig, tag, owner, (uint32_t)0) + : qbus_device(mconfig, tag, owner) { set_cputag(std::forward<T>(cputag), spacenum); } - qbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + qbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); ~qbus_device() { m_device_list.detach_all(); } @@ -135,7 +135,7 @@ public: set_default_option(dflt); set_fixed(false); } - qbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + qbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // computer interface DECLARE_WRITE_LINE_MEMBER( biaki_w ) { if (m_card) m_card->biaki_w(state); } diff --git a/src/devices/bus/qbus/qtx.cpp b/src/devices/bus/qbus/qtx.cpp index b4e684577d1..08140fa27ee 100644 --- a/src/devices/bus/qbus/qtx.cpp +++ b/src/devices/bus/qbus/qtx.cpp @@ -29,7 +29,7 @@ Other: LED, 20MHz crystal. Next to the MC68901P is another chip just as large (4 DEFINE_DEVICE_TYPE(TTI_QTS1, qts1_device, "qts1", "TTI QTS-1 SCSI Host Adapter") -qts1_device::qts1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +qts1_device::qts1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTI_QTS1, tag, owner, clock) , device_qbus_card_interface(mconfig, *this) , m_localcpu(*this, "localcpu") diff --git a/src/devices/bus/qbus/qtx.h b/src/devices/bus/qbus/qtx.h index 99c38f9f3ec..f5a817e42e5 100644 --- a/src/devices/bus/qbus/qtx.h +++ b/src/devices/bus/qbus/qtx.h @@ -21,7 +21,7 @@ class qts1_device : public device_t, public device_qbus_card_interface { public: // device type constructor - qts1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + qts1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/ql/cst_q_plus4.cpp b/src/devices/bus/ql/cst_q_plus4.cpp index 96269dc6ef5..13cabc98e59 100644 --- a/src/devices/bus/ql/cst_q_plus4.cpp +++ b/src/devices/bus/ql/cst_q_plus4.cpp @@ -52,7 +52,7 @@ const tiny_rom_entry *cst_q_plus4_device::device_rom_region() const void cst_q_plus4_device::device_add_mconfig(machine_config &config) { - PIA6821(config, MC6821_TAG, 0); + PIA6821(config, MC6821_TAG); QL_EXPANSION_SLOT(config, m_exp1, DERIVED_CLOCK(1, 1), ql_expansion_cards, nullptr); m_exp1->extintl_wr_callback().set(FUNC(cst_q_plus4_device::exp1_extintl_w)); @@ -77,7 +77,7 @@ void cst_q_plus4_device::device_add_mconfig(machine_config &config) // cst_q_plus4_device - constructor //------------------------------------------------- -cst_q_plus4_device::cst_q_plus4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cst_q_plus4_device::cst_q_plus4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CST_Q_PLUS4, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this), m_exp1(*this, "exp1"), diff --git a/src/devices/bus/ql/cst_q_plus4.h b/src/devices/bus/ql/cst_q_plus4.h index 4c8ea616f51..5e5a16f8c04 100644 --- a/src/devices/bus/ql/cst_q_plus4.h +++ b/src/devices/bus/ql/cst_q_plus4.h @@ -26,7 +26,7 @@ class cst_q_plus4_device : public device_t, public device_ql_expansion_card_inte { public: // construction/destruction - cst_q_plus4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cst_q_plus4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/ql/cst_qdisc.cpp b/src/devices/bus/ql/cst_qdisc.cpp index 2fe46dc4f5e..e3e4112b3d3 100644 --- a/src/devices/bus/ql/cst_qdisc.cpp +++ b/src/devices/bus/ql/cst_qdisc.cpp @@ -51,7 +51,7 @@ const tiny_rom_entry *cst_ql_disc_interface_device::device_rom_region() const // cst_ql_disc_interface_device - constructor //------------------------------------------------- -cst_ql_disc_interface_device::cst_ql_disc_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cst_ql_disc_interface_device::cst_ql_disc_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CST_QL_DISC_INTERFACE, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/ql/cst_qdisc.h b/src/devices/bus/ql/cst_qdisc.h index fdd492f1230..87206ae8a2d 100644 --- a/src/devices/bus/ql/cst_qdisc.h +++ b/src/devices/bus/ql/cst_qdisc.h @@ -26,7 +26,7 @@ class cst_ql_disc_interface_device : public device_t, { public: // construction/destruction - cst_ql_disc_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cst_ql_disc_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/ql/cumana_fdi.cpp b/src/devices/bus/ql/cumana_fdi.cpp index 204dea12608..e73a21a103d 100644 --- a/src/devices/bus/ql/cumana_fdi.cpp +++ b/src/devices/bus/ql/cumana_fdi.cpp @@ -51,7 +51,7 @@ const tiny_rom_entry *cumana_floppy_disk_interface_device::device_rom_region() c // cumana_floppy_disk_interface_device - constructor //------------------------------------------------- -cumana_floppy_disk_interface_device::cumana_floppy_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cumana_floppy_disk_interface_device::cumana_floppy_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CUMANA_FLOPPY_DISK_INTERFACE, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/ql/cumana_fdi.h b/src/devices/bus/ql/cumana_fdi.h index 2080251fcf3..4a7957892fd 100644 --- a/src/devices/bus/ql/cumana_fdi.h +++ b/src/devices/bus/ql/cumana_fdi.h @@ -25,7 +25,7 @@ class cumana_floppy_disk_interface_device : public device_t, public device_ql_ex { public: // construction/destruction - cumana_floppy_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cumana_floppy_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/ql/exp.cpp b/src/devices/bus/ql/exp.cpp index aadb3905b86..cce48b3e552 100644 --- a/src/devices/bus/ql/exp.cpp +++ b/src/devices/bus/ql/exp.cpp @@ -50,7 +50,7 @@ void device_ql_expansion_card_interface::interface_post_start() // ql_expansion_slot_device - constructor //------------------------------------------------- -ql_expansion_slot_device::ql_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ql_expansion_slot_device::ql_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, QL_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_ql_expansion_card_interface>(mconfig, *this), m_write_ipl0l(*this), diff --git a/src/devices/bus/ql/exp.h b/src/devices/bus/ql/exp.h index 31948566bfd..1c9cbb580f1 100644 --- a/src/devices/bus/ql/exp.h +++ b/src/devices/bus/ql/exp.h @@ -84,7 +84,7 @@ class ql_expansion_slot_device : public device_t, public device_single_card_slot public: // construction/destruction template <typename T> - ql_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + ql_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : ql_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -92,7 +92,7 @@ public: set_default_option(dflt); set_fixed(false); } - ql_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ql_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto ipl0l_wr_callback() { return m_write_ipl0l.bind(); } auto ipl1l_wr_callback() { return m_write_ipl1l.bind(); } diff --git a/src/devices/bus/ql/kempston_di.cpp b/src/devices/bus/ql/kempston_di.cpp index 1535f171ff6..adc1778caa5 100644 --- a/src/devices/bus/ql/kempston_di.cpp +++ b/src/devices/bus/ql/kempston_di.cpp @@ -49,7 +49,7 @@ const tiny_rom_entry *kempston_disk_interface_device::device_rom_region() const // kempston_disk_interface_device - constructor //------------------------------------------------- -kempston_disk_interface_device::kempston_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +kempston_disk_interface_device::kempston_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, KEMPSTON_DISK_INTERFACE, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/ql/kempston_di.h b/src/devices/bus/ql/kempston_di.h index cc75a5fe0fc..7172ba35cda 100644 --- a/src/devices/bus/ql/kempston_di.h +++ b/src/devices/bus/ql/kempston_di.h @@ -25,7 +25,7 @@ class kempston_disk_interface_device : public device_t, public device_ql_expansi { public: // construction/destruction - kempston_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kempston_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/ql/miracle_gold_card.cpp b/src/devices/bus/ql/miracle_gold_card.cpp index bf6be7fe136..871058db347 100644 --- a/src/devices/bus/ql/miracle_gold_card.cpp +++ b/src/devices/bus/ql/miracle_gold_card.cpp @@ -51,7 +51,7 @@ const tiny_rom_entry *miracle_gold_card_device::device_rom_region() const // miracle_gold_card_device - constructor //------------------------------------------------- -miracle_gold_card_device::miracle_gold_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +miracle_gold_card_device::miracle_gold_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MIRACLE_GOLD_CARD, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/ql/miracle_gold_card.h b/src/devices/bus/ql/miracle_gold_card.h index 7ed9d0e2eb8..c5931bcf77f 100644 --- a/src/devices/bus/ql/miracle_gold_card.h +++ b/src/devices/bus/ql/miracle_gold_card.h @@ -25,7 +25,7 @@ class miracle_gold_card_device : public device_t, public device_ql_expansion_car { public: // construction/destruction - miracle_gold_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + miracle_gold_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/ql/miracle_hd.cpp b/src/devices/bus/ql/miracle_hd.cpp index f2f16715c72..b8464b64be9 100644 --- a/src/devices/bus/ql/miracle_hd.cpp +++ b/src/devices/bus/ql/miracle_hd.cpp @@ -49,7 +49,7 @@ const tiny_rom_entry *miracle_hard_disk_device::device_rom_region() const // miracle_hard_disk_device - constructor //------------------------------------------------- -miracle_hard_disk_device::miracle_hard_disk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +miracle_hard_disk_device::miracle_hard_disk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MIRACLE_HARD_DISK, tag, owner, clock), device_ql_rom_cartridge_card_interface(mconfig, *this) { diff --git a/src/devices/bus/ql/miracle_hd.h b/src/devices/bus/ql/miracle_hd.h index 983dce66f8b..37210b346c8 100644 --- a/src/devices/bus/ql/miracle_hd.h +++ b/src/devices/bus/ql/miracle_hd.h @@ -26,7 +26,7 @@ class miracle_hard_disk_device : public device_t, { public: // construction/destruction - miracle_hard_disk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + miracle_hard_disk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/ql/mp_fdi.cpp b/src/devices/bus/ql/mp_fdi.cpp index 4e2a90ce52d..76c14e4cb46 100644 --- a/src/devices/bus/ql/mp_fdi.cpp +++ b/src/devices/bus/ql/mp_fdi.cpp @@ -49,7 +49,7 @@ const tiny_rom_entry *micro_peripherals_floppy_disk_interface_device::device_rom // micro_peripherals_floppy_disk_interface_device - constructor //------------------------------------------------- -micro_peripherals_floppy_disk_interface_device::micro_peripherals_floppy_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +micro_peripherals_floppy_disk_interface_device::micro_peripherals_floppy_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MICRO_PERIPHERALS_FLOPPY_DISK_INTERFACE, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/ql/mp_fdi.h b/src/devices/bus/ql/mp_fdi.h index 3fc9d9d8c83..fc1fbdcddf2 100644 --- a/src/devices/bus/ql/mp_fdi.h +++ b/src/devices/bus/ql/mp_fdi.h @@ -24,7 +24,7 @@ class micro_peripherals_floppy_disk_interface_device : public device_t, public d { public: // construction/destruction - micro_peripherals_floppy_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + micro_peripherals_floppy_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/ql/opd_basic_master.cpp b/src/devices/bus/ql/opd_basic_master.cpp index b3b6f18dc19..3081ea7ffc7 100644 --- a/src/devices/bus/ql/opd_basic_master.cpp +++ b/src/devices/bus/ql/opd_basic_master.cpp @@ -47,7 +47,7 @@ const tiny_rom_entry *opd_basic_master_device::device_rom_region() const // opd_basic_master_device - constructor //------------------------------------------------- -opd_basic_master_device::opd_basic_master_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +opd_basic_master_device::opd_basic_master_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, OPD_BASIC_MASTER, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/ql/opd_basic_master.h b/src/devices/bus/ql/opd_basic_master.h index 3592823dd2b..976f97bc135 100644 --- a/src/devices/bus/ql/opd_basic_master.h +++ b/src/devices/bus/ql/opd_basic_master.h @@ -25,7 +25,7 @@ class opd_basic_master_device : public device_t, public device_ql_expansion_card { public: // construction/destruction - opd_basic_master_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + opd_basic_master_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/ql/pcml_qdisk.cpp b/src/devices/bus/ql/pcml_qdisk.cpp index ed92c569509..87c279f7dac 100644 --- a/src/devices/bus/ql/pcml_qdisk.cpp +++ b/src/devices/bus/ql/pcml_qdisk.cpp @@ -49,7 +49,7 @@ const tiny_rom_entry *pcml_q_disk_interface_device::device_rom_region() const // pcml_q_disk_interface_device - constructor //------------------------------------------------- -pcml_q_disk_interface_device::pcml_q_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pcml_q_disk_interface_device::pcml_q_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCML_Q_DISK_INTERFACE, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/ql/pcml_qdisk.h b/src/devices/bus/ql/pcml_qdisk.h index cedd3f953f7..74480c9c0de 100644 --- a/src/devices/bus/ql/pcml_qdisk.h +++ b/src/devices/bus/ql/pcml_qdisk.h @@ -25,7 +25,7 @@ class pcml_q_disk_interface_device : public device_t, public device_ql_expansion { public: // construction/destruction - pcml_q_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pcml_q_disk_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/ql/qubide.cpp b/src/devices/bus/ql/qubide.cpp index 7ed66ef8886..0abe98a57d3 100644 --- a/src/devices/bus/ql/qubide.cpp +++ b/src/devices/bus/ql/qubide.cpp @@ -160,7 +160,7 @@ ioport_constructor qubide_device::device_input_ports() const // qubide_device - constructor //------------------------------------------------- -qubide_device::qubide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +qubide_device::qubide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, QUBIDE, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this), m_ata(*this, "ata"), diff --git a/src/devices/bus/ql/qubide.h b/src/devices/bus/ql/qubide.h index 8f4d88d37ee..13c40449397 100644 --- a/src/devices/bus/ql/qubide.h +++ b/src/devices/bus/ql/qubide.h @@ -26,7 +26,7 @@ class qubide_device : public device_t, public device_ql_expansion_card_interface { public: // construction/destruction - qubide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + qubide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/ql/rom.cpp b/src/devices/bus/ql/rom.cpp index a3186b9a5b8..14523499980 100644 --- a/src/devices/bus/ql/rom.cpp +++ b/src/devices/bus/ql/rom.cpp @@ -59,7 +59,7 @@ void device_ql_rom_cartridge_card_interface::interface_post_start() // ql_rom_cartridge_slot_device - constructor //------------------------------------------------- -ql_rom_cartridge_slot_device::ql_rom_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ql_rom_cartridge_slot_device::ql_rom_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, QL_ROM_CARTRIDGE_SLOT, tag, owner, clock), device_single_card_slot_interface<device_ql_rom_cartridge_card_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/ql/rom.h b/src/devices/bus/ql/rom.h index 690b3c231bc..88b3364e47b 100644 --- a/src/devices/bus/ql/rom.h +++ b/src/devices/bus/ql/rom.h @@ -76,14 +76,14 @@ public: // construction/destruction template <typename T> ql_rom_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : ql_rom_cartridge_slot_device(mconfig, tag, owner, 0) + : ql_rom_cartridge_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - ql_rom_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ql_rom_cartridge_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // computer interface uint8_t read(offs_t offset, uint8_t data) { if (m_card) data = m_card->read(offset, data); return data; } diff --git a/src/devices/bus/ql/sandy_superdisk.cpp b/src/devices/bus/ql/sandy_superdisk.cpp index 45b0f3035a4..a458a996c6a 100644 --- a/src/devices/bus/ql/sandy_superdisk.cpp +++ b/src/devices/bus/ql/sandy_superdisk.cpp @@ -86,7 +86,7 @@ WRITE_LINE_MEMBER( sandy_super_disk_device::busy_w ) void sandy_super_disk_device::device_add_mconfig(machine_config &config) { - WD1772(config, m_fdc, 8000000); + WD1772(config, m_fdc, XTAL::u(8000000)); FLOPPY_CONNECTOR(config, m_floppy0, sandy_super_disk_floppies, "35dd", sandy_super_disk_device::floppy_formats); FLOPPY_CONNECTOR(config, m_floppy1, sandy_super_disk_floppies, nullptr, sandy_super_disk_device::floppy_formats); @@ -106,7 +106,7 @@ void sandy_super_disk_device::device_add_mconfig(machine_config &config) // sandy_super_disk_device - constructor //------------------------------------------------- -sandy_super_disk_device::sandy_super_disk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sandy_super_disk_device::sandy_super_disk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SANDY_SUPER_DISK, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this), m_fdc(*this, WD1772_TAG), diff --git a/src/devices/bus/ql/sandy_superdisk.h b/src/devices/bus/ql/sandy_superdisk.h index 8f821e953ad..80d85193148 100644 --- a/src/devices/bus/ql/sandy_superdisk.h +++ b/src/devices/bus/ql/sandy_superdisk.h @@ -29,7 +29,7 @@ class sandy_super_disk_device : public device_t, public device_ql_expansion_card { public: // construction/destruction - sandy_super_disk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sandy_super_disk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/ql/sandy_superqboard.cpp b/src/devices/bus/ql/sandy_superqboard.cpp index ad1ce340524..05bdec1f658 100644 --- a/src/devices/bus/ql/sandy_superqboard.cpp +++ b/src/devices/bus/ql/sandy_superqboard.cpp @@ -207,12 +207,12 @@ ioport_constructor sandy_superqmouse_512k_device::device_input_ports() const // sandy_superqboard_device - constructor //------------------------------------------------- -sandy_superqboard_device::sandy_superqboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sandy_superqboard_device::sandy_superqboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sandy_superqboard_device(mconfig, SANDY_SUPERQBOARD, tag, owner, clock, 256*1024) { } -sandy_superqboard_device::sandy_superqboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int ram_size) : +sandy_superqboard_device::sandy_superqboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int ram_size) : device_t(mconfig, type, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this), m_fdc(*this, WD1772_TAG), @@ -230,17 +230,17 @@ sandy_superqboard_device::sandy_superqboard_device(const machine_config &mconfig { } -sandy_superqboard_512k_device::sandy_superqboard_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sandy_superqboard_512k_device::sandy_superqboard_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sandy_superqboard_device(mconfig, SANDY_SUPERQBOARD_512K, tag, owner, clock, 512*1024) { } -sandy_superqmouse_device::sandy_superqmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sandy_superqmouse_device::sandy_superqmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sandy_superqboard_device(mconfig, SANDY_SUPERQMOUSE, tag, owner, clock, 256*1024) { } -sandy_superqmouse_512k_device::sandy_superqmouse_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sandy_superqmouse_512k_device::sandy_superqmouse_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sandy_superqboard_device(mconfig, SANDY_SUPERQMOUSE_512K, tag, owner, clock, 512*1024) { } diff --git a/src/devices/bus/ql/sandy_superqboard.h b/src/devices/bus/ql/sandy_superqboard.h index 244d0e8a54f..287a9deebdc 100644 --- a/src/devices/bus/ql/sandy_superqboard.h +++ b/src/devices/bus/ql/sandy_superqboard.h @@ -29,13 +29,13 @@ class sandy_superqboard_device : public device_t, public device_ql_expansion_car { public: // construction/destruction - sandy_superqboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sandy_superqboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER( mouse_x_changed ); DECLARE_INPUT_CHANGED_MEMBER( mouse_y_changed ); protected: - sandy_superqboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int ram_size); + sandy_superqboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int ram_size); // device-level overrides virtual void device_start() override; @@ -91,7 +91,7 @@ class sandy_superqboard_512k_device : public sandy_superqboard_device { public: // construction/destruction - sandy_superqboard_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sandy_superqboard_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -101,7 +101,7 @@ class sandy_superqmouse_device : public sandy_superqboard_device { public: // construction/destruction - sandy_superqmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sandy_superqmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; @@ -114,7 +114,7 @@ class sandy_superqmouse_512k_device : public sandy_superqboard_device { public: // construction/destruction - sandy_superqmouse_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sandy_superqmouse_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/ql/std.cpp b/src/devices/bus/ql/std.cpp index 7524cc1693d..305f4f1a569 100644 --- a/src/devices/bus/ql/std.cpp +++ b/src/devices/bus/ql/std.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(QL_STANDARD_ROM_CARTRIDGE, ql_standard_rom_cartridge_device, // ql_standard_rom_cartridge_device - constructor //------------------------------------------------- -ql_standard_rom_cartridge_device::ql_standard_rom_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ql_standard_rom_cartridge_device::ql_standard_rom_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, QL_STANDARD_ROM_CARTRIDGE, tag, owner, clock), device_ql_rom_cartridge_card_interface(mconfig, *this) { diff --git a/src/devices/bus/ql/std.h b/src/devices/bus/ql/std.h index 823c3a70008..f369a5f5771 100644 --- a/src/devices/bus/ql/std.h +++ b/src/devices/bus/ql/std.h @@ -25,7 +25,7 @@ class ql_standard_rom_cartridge_device : public device_t, public device_ql_rom_c { public: // construction/destruction - ql_standard_rom_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ql_standard_rom_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/ql/trumpcard.cpp b/src/devices/bus/ql/trumpcard.cpp index 7c51ad3c220..c33b4bc35fb 100644 --- a/src/devices/bus/ql/trumpcard.cpp +++ b/src/devices/bus/ql/trumpcard.cpp @@ -90,7 +90,7 @@ void ql_trump_card_device::floppy_formats(format_registration &fr) void ql_trump_card_device::device_add_mconfig(machine_config &config) { - WD1772(config, m_fdc, 8000000); + WD1772(config, m_fdc, XTAL::u(8000000)); FLOPPY_CONNECTOR(config, m_floppy0, ql_trump_card_floppies, "35dd", ql_trump_card_device::floppy_formats); FLOPPY_CONNECTOR(config, m_floppy1, ql_trump_card_floppies, nullptr, ql_trump_card_device::floppy_formats); } @@ -104,12 +104,12 @@ void ql_trump_card_device::device_add_mconfig(machine_config &config) // ql_trump_card_device - constructor //------------------------------------------------- -ql_trump_card_device::ql_trump_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ql_trump_card_device::ql_trump_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ql_trump_card_device(mconfig, QL_TRUMP_CARD, tag, owner, clock, 0) { } -ql_trump_card_device::ql_trump_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int ram_size) : +ql_trump_card_device::ql_trump_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int ram_size) : device_t(mconfig, type, tag, owner, clock), device_ql_expansion_card_interface(mconfig, *this), m_fdc(*this, WD1772_TAG), @@ -122,17 +122,17 @@ ql_trump_card_device::ql_trump_card_device(const machine_config &mconfig, device { } -ql_trump_card_256k_device::ql_trump_card_256k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ql_trump_card_256k_device::ql_trump_card_256k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ql_trump_card_device(mconfig, QL_TRUMP_CARD_256K, tag, owner, clock, 256*1024) { } -ql_trump_card_512k_device::ql_trump_card_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ql_trump_card_512k_device::ql_trump_card_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ql_trump_card_device(mconfig, QL_TRUMP_CARD_512K, tag, owner, clock, 512*1024) { } -ql_trump_card_768k_device::ql_trump_card_768k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ql_trump_card_768k_device::ql_trump_card_768k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ql_trump_card_device(mconfig, QL_TRUMP_CARD_768K, tag, owner, clock, 768*1024) { } diff --git a/src/devices/bus/ql/trumpcard.h b/src/devices/bus/ql/trumpcard.h index 42fad0633e1..8bc6ee48524 100644 --- a/src/devices/bus/ql/trumpcard.h +++ b/src/devices/bus/ql/trumpcard.h @@ -28,10 +28,10 @@ class ql_trump_card_device : public device_t, public device_ql_expansion_card_in { public: // construction/destruction - ql_trump_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ql_trump_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - ql_trump_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int ram_size); + ql_trump_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int ram_size); // device-level overrides virtual void device_start() override; @@ -66,7 +66,7 @@ class ql_trump_card_256k_device : public ql_trump_card_device { public: // construction/destruction - ql_trump_card_256k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ql_trump_card_256k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -76,7 +76,7 @@ class ql_trump_card_512k_device : public ql_trump_card_device { public: // construction/destruction - ql_trump_card_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ql_trump_card_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -86,7 +86,7 @@ class ql_trump_card_768k_device : public ql_trump_card_device { public: // construction/destruction - ql_trump_card_768k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ql_trump_card_768k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/rc2014/cf.cpp b/src/devices/bus/rc2014/cf.cpp index 9640853da86..a40380f45f0 100644 --- a/src/devices/bus/rc2014/cf.cpp +++ b/src/devices/bus/rc2014/cf.cpp @@ -21,7 +21,7 @@ class compact_flash_device : public device_t, public device_rc2014_card_interfac { public: // construction/destruction - compact_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + compact_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -37,7 +37,7 @@ private: required_device<ata_interface_device> m_ata; }; -compact_flash_device::compact_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +compact_flash_device::compact_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_COMPACT_FLASH, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_ata(*this, "ata") diff --git a/src/devices/bus/rc2014/clock.cpp b/src/devices/bus/rc2014/clock.cpp index bb73143edc2..dbbb097d7c6 100644 --- a/src/devices/bus/rc2014/clock.cpp +++ b/src/devices/bus/rc2014/clock.cpp @@ -21,7 +21,7 @@ class single_clock_device : public device_t, public device_rc2014_card_interface { public: // construction/destruction - single_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + single_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -31,7 +31,7 @@ protected: DECLARE_WRITE_LINE_MEMBER( clk_w ) { m_bus->clk_w(state); } }; -single_clock_device::single_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +single_clock_device::single_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_SINGLE_CLOCK, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) { @@ -61,7 +61,7 @@ class dual_clock_base : public device_t { protected: // construction/destruction - dual_clock_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + dual_clock_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -79,7 +79,7 @@ protected: required_ioport m_clk_sel_2; }; -dual_clock_base::dual_clock_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +dual_clock_base::dual_clock_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_clock_1(*this, "clock1") , m_clock_2(*this, "clock2") @@ -151,10 +151,10 @@ ioport_constructor dual_clock_base::device_input_ports() const void dual_clock_base::device_add_mconfig(machine_config &config) { - CLOCK(config, m_clock_1, 0); + CLOCK(config, m_clock_1); m_clock_1->signal_handler().set(FUNC(dual_clock_base::clk_w)); - CLOCK(config, m_clock_2, 0); + CLOCK(config, m_clock_2); m_clock_2->signal_handler().set(FUNC(dual_clock_base::clk2_w)); } @@ -166,7 +166,7 @@ class dual_clock_device : public dual_clock_base, public device_rc2014_ext_card_ { public: // construction/destruction - dual_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dual_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -177,7 +177,7 @@ protected: DECLARE_WRITE_LINE_MEMBER( clk2_w ) override { m_bus->clk2_w(state); } }; -dual_clock_device::dual_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dual_clock_device::dual_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dual_clock_base(mconfig, RC2014_DUAL_CLOCK, tag, owner, clock) , device_rc2014_ext_card_interface(mconfig, *this) { @@ -197,7 +197,7 @@ class dual_clock_device_40pin : public dual_clock_base, public device_rc2014_car { public: // construction/destruction - dual_clock_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dual_clock_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -208,7 +208,7 @@ protected: DECLARE_WRITE_LINE_MEMBER( clk2_w ) override { } }; -dual_clock_device_40pin::dual_clock_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dual_clock_device_40pin::dual_clock_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dual_clock_base(mconfig, RC2014_DUAL_CLOCK_40P, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) { diff --git a/src/devices/bus/rc2014/edge.cpp b/src/devices/bus/rc2014/edge.cpp index 5585c790d17..94a5bbc7802 100644 --- a/src/devices/bus/rc2014/edge.cpp +++ b/src/devices/bus/rc2014/edge.cpp @@ -21,10 +21,10 @@ class sc106_device : public device_t, public device_rc2014_rc80_card_interface { public: // construction/destruction - sc106_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sc106_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - sc106_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + sc106_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -34,14 +34,14 @@ private: required_device<rc2014_rc80_bus_device> m_rc80_bus; }; -sc106_device::sc106_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +sc106_device::sc106_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_rc2014_rc80_card_interface(mconfig, *this) , m_rc80_bus(*this, ":bus") { } -sc106_device::sc106_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sc106_device::sc106_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sc106_device(mconfig, RC2014_SC106, tag, owner, clock) { } @@ -73,10 +73,10 @@ class sc107_device : public sc106_device { public: // construction/destruction - sc107_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sc107_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; -sc107_device::sc107_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sc107_device::sc107_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sc106_device(mconfig, RC2014_SC107, tag, owner, clock) { } @@ -92,10 +92,10 @@ class sc113_device : public sc106_device { public: // construction/destruction - sc113_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sc113_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; -sc113_device::sc113_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sc113_device::sc113_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sc106_device(mconfig, RC2014_SC113, tag, owner, clock) { } @@ -109,7 +109,7 @@ class sc141_device : public device_t, public device_rc2014_card_interface { public: // construction/destruction - sc141_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sc141_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -120,7 +120,7 @@ private: required_device<rc2014_bus_device> m_rc40_bus; }; -sc141_device::sc141_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sc141_device::sc141_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_SC141, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_rc40_bus(*this, ":bus") @@ -157,7 +157,7 @@ class sc147_device : public device_t, public device_rc2014_card_interface { public: // construction/destruction - sc147_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sc147_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -168,7 +168,7 @@ private: required_device<rc2014_bus_device> m_rc40_bus; }; -sc147_device::sc147_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sc147_device::sc147_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_SC147, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_rc40_bus(*this, ":bus") diff --git a/src/devices/bus/rc2014/fdc.cpp b/src/devices/bus/rc2014/fdc.cpp index ba8ce96d7ab..41cd7846744 100644 --- a/src/devices/bus/rc2014/fdc.cpp +++ b/src/devices/bus/rc2014/fdc.cpp @@ -25,7 +25,7 @@ class rc2014_fdc9266_device : public device_t, public device_rc2014_card_interfa { public: // construction/destruction - rc2014_fdc9266_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rc2014_fdc9266_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -42,7 +42,7 @@ private: required_device_array<floppy_connector, 2> m_floppy; }; -rc2014_fdc9266_device::rc2014_fdc9266_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rc2014_fdc9266_device::rc2014_fdc9266_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_FDC9266, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_addr(*this, "SV1") @@ -151,7 +151,7 @@ class rc2014_wd37c65_device : public device_t, public device_rc2014_card_interfa { public: // construction/destruction - rc2014_wd37c65_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rc2014_wd37c65_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -169,7 +169,7 @@ private: required_device_array<floppy_connector, 2> m_floppy; }; -rc2014_wd37c65_device::rc2014_wd37c65_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rc2014_wd37c65_device::rc2014_wd37c65_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_WD37C65, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_addr(*this, "SV1") diff --git a/src/devices/bus/rc2014/ide.cpp b/src/devices/bus/rc2014/ide.cpp index e81a168cba6..9a4b580af5b 100644 --- a/src/devices/bus/rc2014/ide.cpp +++ b/src/devices/bus/rc2014/ide.cpp @@ -21,7 +21,7 @@ class rc2014_ide_base : public device_t, public device_rc2014_card_interface { protected: // construction/destruction - rc2014_ide_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + rc2014_ide_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -41,7 +41,7 @@ protected: uint8_t m_prev; }; -rc2014_ide_base::rc2014_ide_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +rc2014_ide_base::rc2014_ide_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_ata(*this, "ata") @@ -56,7 +56,7 @@ void rc2014_ide_base::device_start() void rc2014_ide_base::device_add_mconfig(machine_config &config) { - I8255(config, m_ppi, 0); + I8255(config, m_ppi); m_ppi->in_pa_callback().set(FUNC(rc2014_ide_base::ppi_pa_r)); m_ppi->in_pb_callback().set(FUNC(rc2014_ide_base::ppi_pb_r)); m_ppi->out_pa_callback().set(FUNC(rc2014_ide_base::ppi_pa_w)); @@ -75,7 +75,7 @@ class rc2014_82c55_ide_device : public rc2014_ide_base { public: // construction/destruction - rc2014_82c55_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rc2014_82c55_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -93,7 +93,7 @@ private: uint8_t m_dior; }; -rc2014_82c55_ide_device::rc2014_82c55_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rc2014_82c55_ide_device::rc2014_82c55_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rc2014_ide_base(mconfig, RC2014_82C55_IDE, tag, owner, clock) , m_sw(*this, "SW1") , m_jp(*this, "JP%u", 1U) @@ -206,7 +206,7 @@ class rc2014_ide_hdd_device : public rc2014_ide_base { public: // construction/destruction - rc2014_ide_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rc2014_ide_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -218,7 +218,7 @@ private: required_ioport m_jp; }; -rc2014_ide_hdd_device::rc2014_ide_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rc2014_ide_hdd_device::rc2014_ide_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rc2014_ide_base(mconfig, RC2014_IDE_HDD, tag, owner, clock) , m_jp(*this, "J1") { diff --git a/src/devices/bus/rc2014/micro.cpp b/src/devices/bus/rc2014/micro.cpp index f818dcd8c7f..be085f2dbe1 100644 --- a/src/devices/bus/rc2014/micro.cpp +++ b/src/devices/bus/rc2014/micro.cpp @@ -27,7 +27,7 @@ class rc2014_micro : public device_t, public device_rc2014_card_interface { public: // construction/destruction - rc2014_micro(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rc2014_micro(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: // device-level overrides @@ -55,7 +55,7 @@ private: static constexpr XTAL MAIN_CLOCK = XTAL(7'372'800); }; -rc2014_micro::rc2014_micro(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rc2014_micro::rc2014_micro(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_MICRO, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -121,7 +121,7 @@ void rc2014_micro::device_add_mconfig(machine_config &config) clock.signal_handler().append(m_acia, FUNC(acia6850_device::write_txc)); clock.signal_handler().append(m_acia, FUNC(acia6850_device::write_rxc)); - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("rs232", FUNC(rs232_port_device::write_txd)); m_acia->txd_handler().append(FUNC(rc2014_micro::tx_w)); m_acia->rts_handler().set("rs232", FUNC(rs232_port_device::write_rts)); @@ -175,7 +175,7 @@ class rc2014_mini_cpm : public device_t, public device_rc2014_card_interface { public: // construction/destruction - rc2014_mini_cpm(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rc2014_mini_cpm(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -209,7 +209,7 @@ private: memory_bank_creator m_rambank; }; -rc2014_mini_cpm::rc2014_mini_cpm(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rc2014_mini_cpm::rc2014_mini_cpm(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_MINI_CPM, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_ata(*this, "ata") diff --git a/src/devices/bus/rc2014/ram.cpp b/src/devices/bus/rc2014/ram.cpp index dc7c89ae170..46ea505b9bb 100644 --- a/src/devices/bus/rc2014/ram.cpp +++ b/src/devices/bus/rc2014/ram.cpp @@ -20,7 +20,7 @@ class ram_32k_device : public device_t, public device_rc2014_card_interface { public: // construction/destruction - ram_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ram_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -30,7 +30,7 @@ private: std::unique_ptr<u8[]> m_ram; }; -ram_32k_device::ram_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ram_32k_device::ram_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_RAM_32K, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_ram(nullptr) @@ -59,7 +59,7 @@ class ram_64k_base : public device_t { protected: // construction/destruction - ram_64k_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + ram_64k_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -79,7 +79,7 @@ protected: required_ioport m_paged; }; -ram_64k_base::ram_64k_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +ram_64k_base::ram_64k_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_bank(0) , m_ram(nullptr) @@ -128,7 +128,7 @@ class ram_64k_device : public ram_64k_base, public device_rc2014_ext_card_interf { public: // construction/destruction - ram_64k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ram_64k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -139,7 +139,7 @@ protected: void update_banks() override; }; -ram_64k_device::ram_64k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ram_64k_device::ram_64k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ram_64k_base(mconfig, RC2014_RAM_64K, tag, owner, clock) , device_rc2014_ext_card_interface(mconfig, *this) { @@ -177,7 +177,7 @@ class ram_64k_device_40pin : public ram_64k_base, public device_rc2014_card_inte { public: // construction/destruction - ram_64k_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ram_64k_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -187,7 +187,7 @@ protected: void update_banks() override {}; }; -ram_64k_device_40pin::ram_64k_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ram_64k_device_40pin::ram_64k_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ram_64k_base(mconfig, RC2014_RAM_64K_40P, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) { diff --git a/src/devices/bus/rc2014/rc2014.cpp b/src/devices/bus/rc2014/rc2014.cpp index afe6ba6172a..589db6ebe63 100644 --- a/src/devices/bus/rc2014/rc2014.cpp +++ b/src/devices/bus/rc2014/rc2014.cpp @@ -17,7 +17,7 @@ // rc2014_bus_device //------------------------------------------------- -rc2014_bus_device::rc2014_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +rc2014_bus_device::rc2014_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_installer{} , m_clk(*this) @@ -32,7 +32,7 @@ rc2014_bus_device::rc2014_bus_device(const machine_config &mconfig, device_type { } -rc2014_bus_device::rc2014_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rc2014_bus_device::rc2014_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rc2014_bus_device(mconfig, RC2014_BUS, tag, owner, clock) { } @@ -115,14 +115,14 @@ void device_rc2014_card_interface::set_bus_device(rc2014_bus_device *bus_device) // rc2014_slot_device //------------------------------------------------- -rc2014_slot_device::rc2014_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +rc2014_slot_device::rc2014_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_slot_interface(mconfig, *this) , m_bus(*this, finder_base::DUMMY_TAG) { } -rc2014_slot_device::rc2014_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rc2014_slot_device::rc2014_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rc2014_slot_device(mconfig, RC2014_SLOT, tag, owner, clock) { } @@ -147,12 +147,12 @@ void rc2014_slot_device::device_resolve_objects() // rc2014_ext_bus_device //------------------------------------------------- -rc2014_ext_bus_device::rc2014_ext_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rc2014_ext_bus_device::rc2014_ext_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rc2014_ext_bus_device(mconfig, RC2014_EXT_BUS, tag, owner, clock) { } -rc2014_ext_bus_device::rc2014_ext_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +rc2014_ext_bus_device::rc2014_ext_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : rc2014_bus_device(mconfig, type, tag, owner, clock) , m_clk2(*this) , m_page(*this) @@ -199,12 +199,12 @@ void device_rc2014_ext_card_interface::set_bus_device(rc2014_ext_bus_device *bus // rc2014_ext_slot_device //------------------------------------------------- -rc2014_ext_slot_device::rc2014_ext_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rc2014_ext_slot_device::rc2014_ext_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rc2014_ext_slot_device(mconfig, RC2014_EXT_SLOT, tag, owner, clock) { } -rc2014_ext_slot_device::rc2014_ext_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +rc2014_ext_slot_device::rc2014_ext_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : rc2014_slot_device(mconfig, type, tag, owner, clock) { } @@ -230,12 +230,12 @@ void rc2014_ext_slot_device::device_resolve_objects() // rc2014_rc80_bus_device //------------------------------------------------- -rc2014_rc80_bus_device::rc2014_rc80_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rc2014_rc80_bus_device::rc2014_rc80_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rc2014_rc80_bus_device(mconfig, RC2014_RC80_BUS, tag, owner, clock) { } -rc2014_rc80_bus_device::rc2014_rc80_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +rc2014_rc80_bus_device::rc2014_rc80_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : rc2014_ext_bus_device(mconfig, type, tag, owner, clock) { @@ -265,7 +265,7 @@ void device_rc2014_rc80_card_interface::set_bus_device(rc2014_rc80_bus_device *b // rc2014_rc80_slot_device //------------------------------------------------- -rc2014_rc80_slot_device::rc2014_rc80_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rc2014_rc80_slot_device::rc2014_rc80_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rc2014_ext_slot_device(mconfig, RC2014_RC80_SLOT, tag, owner, clock) { } diff --git a/src/devices/bus/rc2014/rc2014.h b/src/devices/bus/rc2014/rc2014.h index a40355af389..5dc190b805a 100644 --- a/src/devices/bus/rc2014/rc2014.h +++ b/src/devices/bus/rc2014/rc2014.h @@ -74,7 +74,7 @@ class rc2014_bus_device : public device_t { public: // construction/destruction - rc2014_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rc2014_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~rc2014_bus_device(); auto clk_callback() { return m_clk.bind(); } @@ -103,7 +103,7 @@ public: const z80_daisy_config* get_daisy_chain(); protected: - rc2014_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + rc2014_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; virtual void device_reset() override; @@ -144,7 +144,7 @@ protected: class rc2014_slot_device : public device_t, public device_slot_interface { public: - rc2014_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + rc2014_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); template <typename T, typename U> rc2014_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bus_tag, U &&slot_options, char const *default_option, bool fixed = false) @@ -158,7 +158,7 @@ public: } protected: - rc2014_slot_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + rc2014_slot_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; virtual void device_resolve_objects() override; @@ -176,7 +176,7 @@ class rc2014_ext_bus_device : public rc2014_bus_device { public: // construction/destruction - rc2014_ext_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rc2014_ext_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto clk2_callback() { return m_clk2.bind(); } auto page_callback() { return m_page.bind(); } @@ -199,7 +199,7 @@ public: DECLARE_WRITE_LINE_MEMBER( user8_w ) { m_user8(state); } protected: - rc2014_ext_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + rc2014_ext_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -237,7 +237,7 @@ protected: class rc2014_ext_slot_device : public rc2014_slot_device { public: - rc2014_ext_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + rc2014_ext_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); template <typename T, typename U> rc2014_ext_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bus_tag, U &&slot_options, char const *default_option, bool fixed = false) @@ -251,7 +251,7 @@ public: } protected: - rc2014_ext_slot_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + rc2014_ext_slot_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; virtual void device_resolve_objects() override; @@ -267,10 +267,10 @@ class rc2014_rc80_bus_device : public rc2014_ext_bus_device { public: // construction/destruction - rc2014_rc80_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rc2014_rc80_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - rc2014_rc80_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + rc2014_rc80_bus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; }; @@ -297,7 +297,7 @@ protected: class rc2014_rc80_slot_device : public rc2014_ext_slot_device { public: - rc2014_rc80_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + rc2014_rc80_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); template <typename T, typename U> rc2014_rc80_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bus_tag, U &&slot_options, char const *default_option, bool fixed = false) diff --git a/src/devices/bus/rc2014/rom.cpp b/src/devices/bus/rc2014/rom.cpp index 61d0d8bb191..48a15c2b6e4 100644 --- a/src/devices/bus/rc2014/rom.cpp +++ b/src/devices/bus/rc2014/rom.cpp @@ -20,7 +20,7 @@ class switchable_rom_device : public device_t, public device_rc2014_card_interfa { public: // construction/destruction - switchable_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + switchable_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -33,7 +33,7 @@ private: required_ioport m_rom_selector; }; -switchable_rom_device::switchable_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +switchable_rom_device::switchable_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_SWITCHABLE_ROM, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_rom(*this, "rom") @@ -112,7 +112,7 @@ class pagable_rom_device : public device_t, public device_rc2014_ext_card_interf { public: // construction/destruction - pagable_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pagable_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -135,7 +135,7 @@ private: required_ioport_array<6> m_page_addr_conf; }; -pagable_rom_device::pagable_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pagable_rom_device::pagable_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_PAGABLE_ROM, tag, owner, clock) , device_rc2014_ext_card_interface(mconfig, *this) , m_bank(0) diff --git a/src/devices/bus/rc2014/romram.cpp b/src/devices/bus/rc2014/romram.cpp index e0fcc03fa39..5840bc950eb 100644 --- a/src/devices/bus/rc2014/romram.cpp +++ b/src/devices/bus/rc2014/romram.cpp @@ -21,7 +21,7 @@ class rom_ram_512k_device : public device_t, public device_rc2014_card_interface { public: // construction/destruction - rom_ram_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rom_ram_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -43,7 +43,7 @@ private: required_device<sst_39sf040_device> m_flash; }; -rom_ram_512k_device::rom_ram_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rom_ram_512k_device::rom_ram_512k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_ROM_RAM_512, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_page_reg{0,0,0,0} @@ -163,7 +163,7 @@ class sc119_device : public device_t, public device_rc2014_rc80_card_interface { public: // construction/destruction - sc119_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sc119_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -176,7 +176,7 @@ private: required_device<sst_39sf040_device> m_flash; }; -sc119_device::sc119_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sc119_device::sc119_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_SC119, tag, owner, clock) , device_rc2014_rc80_card_interface(mconfig, *this) , m_ram(nullptr) diff --git a/src/devices/bus/rc2014/rtc.cpp b/src/devices/bus/rc2014/rtc.cpp index 4e8659c2771..20dfc29f271 100644 --- a/src/devices/bus/rc2014/rtc.cpp +++ b/src/devices/bus/rc2014/rtc.cpp @@ -21,7 +21,7 @@ class rc2014_ds1302_device : public device_t, public device_rc2014_card_interfac { public: // construction/destruction - rc2014_ds1302_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rc2014_ds1302_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -37,7 +37,7 @@ private: required_ioport m_addr; }; -rc2014_ds1302_device::rc2014_ds1302_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rc2014_ds1302_device::rc2014_ds1302_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_DS1302_RTC, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_rtc(*this, "rtc") diff --git a/src/devices/bus/rc2014/serial.cpp b/src/devices/bus/rc2014/serial.cpp index 9453055f2ce..5cea66b6ee6 100644 --- a/src/devices/bus/rc2014/serial.cpp +++ b/src/devices/bus/rc2014/serial.cpp @@ -23,7 +23,7 @@ class serial_io_device : public device_t, public device_rc2014_card_interface { public: // construction/destruction - serial_io_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + serial_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -38,7 +38,7 @@ private: required_device<acia6850_device> m_acia; }; -serial_io_device::serial_io_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +serial_io_device::serial_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RC2014_SERIAL_IO, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_acia(*this, "acia") @@ -75,7 +75,7 @@ DEVICE_INPUT_DEFAULTS_END void serial_io_device::device_add_mconfig(machine_config &config) { - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("rs232", FUNC(rs232_port_device::write_txd)); m_acia->txd_handler().append(FUNC(serial_io_device::tx_w)); m_acia->rts_handler().set("rs232", FUNC(rs232_port_device::write_rts)); @@ -100,7 +100,7 @@ class dual_serial_base : public device_t { protected: // construction/destruction - dual_serial_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + dual_serial_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -120,7 +120,7 @@ protected: required_device<z80sio_device> m_sio; }; -dual_serial_base::dual_serial_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +dual_serial_base::dual_serial_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_clk_portb(0) , m_portb(*this, "JP1") @@ -139,7 +139,7 @@ void dual_serial_base::device_reset() void dual_serial_base::device_add_mconfig(machine_config &config) { - Z80SIO(config, m_sio, 0); + Z80SIO(config, m_sio); m_sio->out_txda_callback().set("rs232a", FUNC(rs232_port_device::write_txd)); m_sio->out_txda_callback().append(FUNC(dual_serial_base::tx_w)); m_sio->out_rtsa_callback().set("rs232a", FUNC(rs232_port_device::write_rts)); @@ -180,7 +180,7 @@ class dual_serial_device : public dual_serial_base, public device_rc2014_ext_car { public: // construction/destruction - dual_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dual_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -193,7 +193,7 @@ protected: DECLARE_WRITE_LINE_MEMBER( tx2_w ) override { m_bus->tx2_w(state); } }; -dual_serial_device::dual_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dual_serial_device::dual_serial_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dual_serial_base(mconfig, RC2014_DUAL_SERIAL, tag, owner, clock) , device_rc2014_ext_card_interface(mconfig, *this) { @@ -230,7 +230,7 @@ class dual_serial_device_40pin : public dual_serial_base, public device_rc2014_c { public: // construction/destruction - dual_serial_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dual_serial_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -243,7 +243,7 @@ protected: DECLARE_WRITE_LINE_MEMBER( tx2_w ) override { } }; -dual_serial_device_40pin::dual_serial_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dual_serial_device_40pin::dual_serial_device_40pin(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dual_serial_base(mconfig, RC2014_DUAL_SERIAL_40P, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) { diff --git a/src/devices/bus/rc2014/sound.cpp b/src/devices/bus/rc2014/sound.cpp index 204d52f9f6c..d0d27df54bf 100644 --- a/src/devices/bus/rc2014/sound.cpp +++ b/src/devices/bus/rc2014/sound.cpp @@ -22,7 +22,7 @@ class rc2014_ym_ay_device : public device_t, public device_rc2014_card_interface { protected: // construction/destruction - rc2014_ym_ay_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + rc2014_ym_ay_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -34,7 +34,7 @@ protected: required_ioport_array<6> m_jp; }; -rc2014_ym_ay_device::rc2014_ym_ay_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +rc2014_ym_ay_device::rc2014_ym_ay_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) , m_psg(*this, "psg") @@ -133,7 +133,7 @@ class rc2014_ym2149_device : public rc2014_ym_ay_device { public: // construction/destruction - rc2014_ym2149_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rc2014_ym2149_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -141,7 +141,7 @@ protected: virtual void device_add_mconfig(machine_config &config) override; }; -rc2014_ym2149_device::rc2014_ym2149_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rc2014_ym2149_device::rc2014_ym2149_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rc2014_ym_ay_device(mconfig, RC2014_YM2149_SOUND, tag, owner, clock) { } @@ -161,7 +161,7 @@ void rc2014_ym2149_device::device_add_mconfig(machine_config &config) SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - YM2149(config, m_psg, 0); + YM2149(config, m_psg); m_psg->add_route(0, "rspeaker", 0.25); m_psg->add_route(2, "rspeaker", 0.25); m_psg->add_route(1, "lspeaker", 0.25); @@ -176,14 +176,14 @@ class rc2014_ay8190_device : public rc2014_ym_ay_device { public: // construction/destruction - rc2014_ay8190_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rc2014_ay8190_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides virtual void device_add_mconfig(machine_config &config) override; }; -rc2014_ay8190_device::rc2014_ay8190_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rc2014_ay8190_device::rc2014_ay8190_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rc2014_ym_ay_device(mconfig, RC2014_AY8190_SOUND, tag, owner, clock) { } @@ -193,7 +193,7 @@ void rc2014_ay8190_device::device_add_mconfig(machine_config &config) SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - AY8910(config, m_psg, 0); + AY8910(config, m_psg); m_psg->add_route(0, "rspeaker", 0.25); m_psg->add_route(2, "rspeaker", 0.25); m_psg->add_route(1, "lspeaker", 0.25); diff --git a/src/devices/bus/rc2014/z180cpu.cpp b/src/devices/bus/rc2014/z180cpu.cpp index c715970b299..0d7dd2f5a32 100644 --- a/src/devices/bus/rc2014/z180cpu.cpp +++ b/src/devices/bus/rc2014/z180cpu.cpp @@ -23,7 +23,7 @@ class z180cpu_base : public device_t, public device_rc2014_rc80_card_interface { protected: // construction/destruction - z180cpu_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + z180cpu_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -43,7 +43,7 @@ protected: static constexpr XTAL MAIN_CLOCK = XTAL(18'432'000); }; -z180cpu_base::z180cpu_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +z180cpu_base::z180cpu_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_rc2014_rc80_card_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -109,14 +109,14 @@ class sc111_device : public z180cpu_base { public: // construction/destruction - sc111_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sc111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides virtual void device_start() override; }; -sc111_device::sc111_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sc111_device::sc111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z180cpu_base(mconfig, RC2014_SC111, tag, owner, clock) { } diff --git a/src/devices/bus/rc2014/z80cpu.cpp b/src/devices/bus/rc2014/z80cpu.cpp index 9723c947e2e..d7cd0d200af 100644 --- a/src/devices/bus/rc2014/z80cpu.cpp +++ b/src/devices/bus/rc2014/z80cpu.cpp @@ -21,7 +21,7 @@ class z80cpu_base : public device_t { protected: // construction/destruction - z80cpu_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + z80cpu_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -34,7 +34,7 @@ protected: required_device<z80_device> m_maincpu; }; -z80cpu_base::z80cpu_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +z80cpu_base::z80cpu_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_maincpu(*this, "maincpu") { @@ -60,7 +60,7 @@ class z80cpu_device : public z80cpu_base, public device_rc2014_card_interface { public: // construction/destruction - z80cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + z80cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -68,7 +68,7 @@ protected: virtual void device_resolve_objects() override; }; -z80cpu_device::z80cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +z80cpu_device::z80cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80cpu_base(mconfig, RC2014_Z80CPU, tag, owner, clock) , device_rc2014_card_interface(mconfig, *this) { @@ -96,14 +96,14 @@ class z80cpu21_device : public z80cpu_base, public device_rc2014_ext_card_interf { public: // construction/destruction - z80cpu21_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + z80cpu21_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides virtual void device_start() override; virtual void device_resolve_objects() override; }; -z80cpu21_device::z80cpu21_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +z80cpu21_device::z80cpu21_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80cpu_base(mconfig, RC2014_Z80CPU_21, tag, owner, clock) , device_rc2014_ext_card_interface(mconfig, *this) { diff --git a/src/devices/bus/rs232/exorterm.cpp b/src/devices/bus/rs232/exorterm.cpp index a4980d53538..58957a878e3 100644 --- a/src/devices/bus/rs232/exorterm.cpp +++ b/src/devices/bus/rs232/exorterm.cpp @@ -4,7 +4,7 @@ #include "emu.h" #include "exorterm.h" -exorterm155_terminal_device::exorterm155_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +exorterm155_terminal_device::exorterm155_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SERIAL_TERMINAL_EXORTERM155, tag, owner, clock) , device_rs232_port_interface(mconfig, *this) , m_exorterm155(*this, "exorterm155") @@ -14,7 +14,7 @@ exorterm155_terminal_device::exorterm155_terminal_device(const machine_config &m void exorterm155_terminal_device::device_add_mconfig(machine_config &config) { - EXORTERM155(config, m_exorterm155, 0); + EXORTERM155(config, m_exorterm155); m_exorterm155->rs232_conn_txd_handler().set(FUNC(exorterm155_terminal_device::output_rxd)); m_exorterm155->rs232_conn_rts_handler().set(FUNC(exorterm155_terminal_device::route_term_rts)); m_exorterm155->rs232_conn_dtr_handler().set(FUNC(exorterm155_terminal_device::route_term_dtr)); diff --git a/src/devices/bus/rs232/exorterm.h b/src/devices/bus/rs232/exorterm.h index c8ae8298b13..76f1abc6563 100644 --- a/src/devices/bus/rs232/exorterm.h +++ b/src/devices/bus/rs232/exorterm.h @@ -13,7 +13,7 @@ class exorterm155_terminal_device : public device_t, public device_rs232_port_interface { public: - exorterm155_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + exorterm155_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER(input_txd) override; diff --git a/src/devices/bus/rs232/hlemouse.cpp b/src/devices/bus/rs232/hlemouse.cpp index 7b25b1e327b..4f04b4c6042 100644 --- a/src/devices/bus/rs232/hlemouse.cpp +++ b/src/devices/bus/rs232/hlemouse.cpp @@ -343,7 +343,7 @@ void hle_msft_mouse_device::transmit_extensions(uint8_t btn_val, uint8_t btn_sen // Logitech 3-button mouse //************************************************** -hle_logitech_mouse_device::hle_logitech_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +hle_logitech_mouse_device::hle_logitech_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : hle_msmouse_device_base(mconfig, LOGITECH_HLE_SERIAL_MOUSE, tag, owner, clock) { } diff --git a/src/devices/bus/rs232/hlemouse.h b/src/devices/bus/rs232/hlemouse.h index d2fae5bd4d1..93deff4d8a5 100644 --- a/src/devices/bus/rs232/hlemouse.h +++ b/src/devices/bus/rs232/hlemouse.h @@ -28,7 +28,7 @@ public: DECLARE_INPUT_CHANGED_MEMBER(input_changed); protected: - hle_msmouse_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock); + hle_msmouse_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); virtual void device_resolve_objects() override; virtual void device_start() override; @@ -65,7 +65,7 @@ private: class hle_msft_mouse_device : public hle_msmouse_device_base { public: - hle_msft_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + hle_msft_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override; @@ -83,7 +83,7 @@ private: class hle_logitech_mouse_device : public hle_msmouse_device_base { public: - hle_logitech_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + hle_logitech_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override; @@ -101,7 +101,7 @@ private: class hle_wheel_mouse_device : public hle_msmouse_device_base { public: - hle_wheel_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + hle_wheel_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override; @@ -129,7 +129,7 @@ public: DECLARE_INPUT_CHANGED_MEMBER(input_changed); protected: - hle_msystems_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock); + hle_msystems_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -157,10 +157,10 @@ private: class hle_msystems_mouse_device : public hle_msystems_device_base { public: - hle_msystems_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + hle_msystems_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: - hle_msystems_mouse_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock); + hle_msystems_mouse_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; virtual void device_start() override; @@ -187,7 +187,7 @@ private: class hle_rotatable_mouse_device : public hle_msystems_device_base { public: - hle_rotatable_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + hle_rotatable_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual ioport_constructor device_input_ports() const override; @@ -214,7 +214,7 @@ private: class hle_sgi_mouse_device : public hle_msystems_mouse_device { public: - hle_sgi_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + hle_sgi_mouse_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/rs232/ie15.cpp b/src/devices/bus/rs232/ie15.cpp index 904d65f246c..f729f7857c2 100644 --- a/src/devices/bus/rs232/ie15.cpp +++ b/src/devices/bus/rs232/ie15.cpp @@ -11,7 +11,7 @@ namespace { class ie15_terminal_device : public device_t, public device_rs232_port_interface { public: - ie15_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + ie15_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SERIAL_TERMINAL_IE15, tag, owner, clock) , device_rs232_port_interface(mconfig, *this) , m_ie15(*this, "ie15") @@ -33,7 +33,7 @@ private: void ie15_terminal_device::device_add_mconfig(machine_config &config) { - IE15(config, m_ie15, 0); + IE15(config, m_ie15); m_ie15->rs232_conn_txd_handler().set(FUNC(ie15_terminal_device::output_rxd)); //m_ie15->rs232_conn_rts_handler().set(FUNC(ie15_terminal_device::route_term_rts)); diff --git a/src/devices/bus/rs232/keyboard.cpp b/src/devices/bus/rs232/keyboard.cpp index 64beb75d6f2..76422a71baa 100644 --- a/src/devices/bus/rs232/keyboard.cpp +++ b/src/devices/bus/rs232/keyboard.cpp @@ -14,12 +14,12 @@ INPUT_PORTS_START(serial_keyboard) INPUT_PORTS_END } // anonymous namespace -serial_keyboard_device::serial_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +serial_keyboard_device::serial_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : serial_keyboard_device(mconfig, SERIAL_KEYBOARD, tag, owner, clock) { } -serial_keyboard_device::serial_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +serial_keyboard_device::serial_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : generic_keyboard_device(mconfig, type, tag, owner, clock) , device_buffered_serial_interface(mconfig, *this) , device_rs232_port_interface(mconfig, *this) diff --git a/src/devices/bus/rs232/keyboard.h b/src/devices/bus/rs232/keyboard.h index 190a33a49e4..0db97ff59af 100644 --- a/src/devices/bus/rs232/keyboard.h +++ b/src/devices/bus/rs232/keyboard.h @@ -14,7 +14,7 @@ class serial_keyboard_device , public device_rs232_port_interface { public: - serial_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + serial_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; @@ -23,7 +23,7 @@ public: DECLARE_WRITE_LINE_MEMBER(update_serial); protected: - serial_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + serial_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_reset() override; virtual void tra_callback() override; diff --git a/src/devices/bus/rs232/loopback.cpp b/src/devices/bus/rs232/loopback.cpp index de1f07f3cd7..6552bda2fda 100644 --- a/src/devices/bus/rs232/loopback.cpp +++ b/src/devices/bus/rs232/loopback.cpp @@ -6,7 +6,7 @@ DEFINE_DEVICE_TYPE(RS232_LOOPBACK, rs232_loopback_device, "rs232_loopback", "RS232 Loopback") -rs232_loopback_device::rs232_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rs232_loopback_device::rs232_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RS232_LOOPBACK, tag, owner, clock) , device_rs232_port_interface(mconfig, *this) { @@ -45,7 +45,7 @@ WRITE_LINE_MEMBER( rs232_loopback_device::input_dtr ) DEFINE_DEVICE_TYPE(DEC_RS232_LOOPBACK, dec_rs232_loopback_device, "dec_rs232_loopback", "RS232 Loopback (DEC 12-15336-00)") -dec_rs232_loopback_device::dec_rs232_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dec_rs232_loopback_device::dec_rs232_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DEC_RS232_LOOPBACK, tag, owner, clock) , device_rs232_port_interface(mconfig, *this) { diff --git a/src/devices/bus/rs232/loopback.h b/src/devices/bus/rs232/loopback.h index b7f499d08d0..52022afef7f 100644 --- a/src/devices/bus/rs232/loopback.h +++ b/src/devices/bus/rs232/loopback.h @@ -11,7 +11,7 @@ class rs232_loopback_device : public device_t, public device_rs232_port_interface { public: - rs232_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rs232_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual WRITE_LINE_MEMBER( input_txd ) override; virtual WRITE_LINE_MEMBER( input_rts ) override; @@ -24,7 +24,7 @@ protected: class dec_rs232_loopback_device : public device_t, public device_rs232_port_interface { public: - dec_rs232_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dec_rs232_loopback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual WRITE_LINE_MEMBER( input_txd ) override; virtual WRITE_LINE_MEMBER( input_rts ) override; diff --git a/src/devices/bus/rs232/mboardd.cpp b/src/devices/bus/rs232/mboardd.cpp index b2b44a6db70..104584c9dd9 100644 --- a/src/devices/bus/rs232/mboardd.cpp +++ b/src/devices/bus/rs232/mboardd.cpp @@ -34,7 +34,7 @@ ROM_END class mockingboard_d_device : public device_t, public device_rs232_port_interface { public: - mockingboard_d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mockingboard_d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER( input_txd ) override; @@ -61,7 +61,7 @@ private: u8 m_c000_latch; }; -mockingboard_d_device::mockingboard_d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mockingboard_d_device::mockingboard_d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SERIAL_MOCKINGBOARD_D, tag, owner, clock) , device_rs232_port_interface(mconfig, *this) , m_cpu(*this, "mbdcpu") @@ -80,9 +80,9 @@ void mockingboard_d_device::device_add_mconfig(machine_config &config) SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - AY8913(config, m_ay1, 1022727); + AY8913(config, m_ay1, XTAL::u(1022727)); m_ay1->add_route(ALL_OUTPUTS, "lspeaker", 0.5); - AY8913(config, m_ay2, 1022727); + AY8913(config, m_ay2, XTAL::u(1022727)); m_ay2->add_route(ALL_OUTPUTS, "lspeaker", 0.5); } diff --git a/src/devices/bus/rs232/null_modem.cpp b/src/devices/bus/rs232/null_modem.cpp index 5b19f1d8e29..af693a9860d 100644 --- a/src/devices/bus/rs232/null_modem.cpp +++ b/src/devices/bus/rs232/null_modem.cpp @@ -3,7 +3,7 @@ #include "emu.h" #include "null_modem.h" -null_modem_device::null_modem_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +null_modem_device::null_modem_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NULL_MODEM, tag, owner, clock), device_serial_interface(mconfig, *this), device_rs232_port_interface(mconfig, *this), @@ -25,7 +25,7 @@ null_modem_device::null_modem_device(const machine_config &mconfig, const char * void null_modem_device::device_add_mconfig(machine_config &config) { - BITBANGER(config, m_stream, 0); + BITBANGER(config, m_stream); } static INPUT_PORTS_START(null_modem) diff --git a/src/devices/bus/rs232/null_modem.h b/src/devices/bus/rs232/null_modem.h index bd9b2520fc4..235d073f982 100644 --- a/src/devices/bus/rs232/null_modem.h +++ b/src/devices/bus/rs232/null_modem.h @@ -14,7 +14,7 @@ class null_modem_device : public device_t, public device_rs232_port_interface { public: - null_modem_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + null_modem_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual WRITE_LINE_MEMBER( input_txd ) override { device_serial_interface::rx_w(state); } virtual WRITE_LINE_MEMBER( input_rts ) override { m_rts = state; } diff --git a/src/devices/bus/rs232/printer.cpp b/src/devices/bus/rs232/printer.cpp index 19347b84002..4078e7cb3da 100644 --- a/src/devices/bus/rs232/printer.cpp +++ b/src/devices/bus/rs232/printer.cpp @@ -15,12 +15,12 @@ #include "emu.h" #include "printer.h" -serial_printer_device::serial_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +serial_printer_device::serial_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : serial_printer_device(mconfig, SERIAL_PRINTER, tag, owner, clock) { } -serial_printer_device::serial_printer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +serial_printer_device::serial_printer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_serial_interface(mconfig, *this), device_rs232_port_interface(mconfig, *this), @@ -35,7 +35,7 @@ serial_printer_device::serial_printer_device(const machine_config &mconfig, devi void serial_printer_device::device_add_mconfig(machine_config &config) { - PRINTER(config, m_printer, 0); + PRINTER(config, m_printer); m_printer->online_callback().set(FUNC(serial_printer_device::printer_online)); } @@ -90,7 +90,7 @@ void serial_printer_device::rcv_complete() m_printer->output(get_received_char()); } -radio_shack_serial_printer_device::radio_shack_serial_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +radio_shack_serial_printer_device::radio_shack_serial_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : serial_printer_device(mconfig, RADIO_SHACK_SERIAL_PRINTER, tag, owner, clock) { m_initial_rx_state = 0; diff --git a/src/devices/bus/rs232/printer.h b/src/devices/bus/rs232/printer.h index cdc0fbbbbf7..9e2722ba7cf 100644 --- a/src/devices/bus/rs232/printer.h +++ b/src/devices/bus/rs232/printer.h @@ -14,14 +14,14 @@ class serial_printer_device : public device_t, public device_rs232_port_interface { public: - serial_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + serial_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER( input_txd ) override { device_serial_interface::rx_w(state); } DECLARE_WRITE_LINE_MEMBER(update_serial); protected: - serial_printer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + serial_printer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; virtual ioport_constructor device_input_ports() const override; virtual void device_start() override; @@ -44,7 +44,7 @@ private: class radio_shack_serial_printer_device : public serial_printer_device { public: - radio_shack_serial_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + radio_shack_serial_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(SERIAL_PRINTER, serial_printer_device) diff --git a/src/devices/bus/rs232/pty.cpp b/src/devices/bus/rs232/pty.cpp index 3cef298dc6c..11f0bd17d10 100644 --- a/src/devices/bus/rs232/pty.cpp +++ b/src/devices/bus/rs232/pty.cpp @@ -9,7 +9,7 @@ static constexpr int TIMER_POLL = 1; -pseudo_terminal_device::pseudo_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pseudo_terminal_device::pseudo_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSEUDO_TERMINAL, tag, owner, clock), device_serial_interface(mconfig, *this), device_rs232_port_interface(mconfig, *this), diff --git a/src/devices/bus/rs232/pty.h b/src/devices/bus/rs232/pty.h index f9fefec5e72..aecc336a61c 100644 --- a/src/devices/bus/rs232/pty.h +++ b/src/devices/bus/rs232/pty.h @@ -15,7 +15,7 @@ class pseudo_terminal_device : public device_t, public device_pty_interface { public: - pseudo_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pseudo_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER( input_txd ) override { device_serial_interface::rx_w(state); } diff --git a/src/devices/bus/rs232/rs232.cpp b/src/devices/bus/rs232/rs232.cpp index 805d295c4de..7a396b2471e 100644 --- a/src/devices/bus/rs232/rs232.cpp +++ b/src/devices/bus/rs232/rs232.cpp @@ -44,12 +44,12 @@ DEFINE_DEVICE_TYPE(RS232_PORT, rs232_port_device, "rs232", "RS-232 Port") -rs232_port_device::rs232_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +rs232_port_device::rs232_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rs232_port_device(mconfig, RS232_PORT, tag, owner, clock) { } -rs232_port_device::rs232_port_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +rs232_port_device::rs232_port_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_single_card_slot_interface<device_rs232_port_interface>(mconfig, *this), m_rxd(0), diff --git a/src/devices/bus/rs232/rs232.h b/src/devices/bus/rs232/rs232.h index 576b0797dc4..ecfc05e1013 100644 --- a/src/devices/bus/rs232/rs232.h +++ b/src/devices/bus/rs232/rs232.h @@ -108,14 +108,14 @@ class rs232_port_device : public device_t, public device_single_card_slot_interf public: template <typename T> rs232_port_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : rs232_port_device(mconfig, tag, owner, 0) + : rs232_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - rs232_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rs232_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~rs232_port_device(); // static configuration helpers @@ -144,7 +144,7 @@ public: DECLARE_READ_LINE_MEMBER( txc_r ) { return m_dce_txc; } // DB25 pin 15 V.24 circuit 114 Transmitter signal element timing (DCE) protected: - rs232_port_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + rs232_port_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_resolve_objects() override; virtual void device_reset() override; @@ -283,7 +283,7 @@ public: } protected: - buffered_rs232_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + buffered_rs232_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : device_t(mconfig, type, tag, owner, clock) , device_buffered_serial_interface<FIFO_LENGTH>(mconfig, *this) , device_rs232_port_interface(mconfig, *this) diff --git a/src/devices/bus/rs232/rs232_sync_io.cpp b/src/devices/bus/rs232/rs232_sync_io.cpp index 8403c41e2cf..cc8a1c9c2ef 100644 --- a/src/devices/bus/rs232/rs232_sync_io.cpp +++ b/src/devices/bus/rs232/rs232_sync_io.cpp @@ -55,7 +55,7 @@ namespace { } } -rs232_sync_io_device::rs232_sync_io_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rs232_sync_io_device::rs232_sync_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , RS232_SYNC_IO , tag , owner , clock) , device_rs232_port_interface(mconfig , *this) , m_stream(*this , "stream") diff --git a/src/devices/bus/rs232/rs232_sync_io.h b/src/devices/bus/rs232/rs232_sync_io.h index a5b6818de48..e140114c243 100644 --- a/src/devices/bus/rs232/rs232_sync_io.h +++ b/src/devices/bus/rs232/rs232_sync_io.h @@ -20,7 +20,7 @@ class rs232_sync_io_device : public device_t, public device_rs232_port_interface { public: // construction/destruction - rs232_sync_io_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rs232_sync_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~rs232_sync_io_device(); virtual DECLARE_WRITE_LINE_MEMBER(input_txd) override; diff --git a/src/devices/bus/rs232/swtpc8212.cpp b/src/devices/bus/rs232/swtpc8212.cpp index b7265aea5d5..efa48cf2680 100644 --- a/src/devices/bus/rs232/swtpc8212.cpp +++ b/src/devices/bus/rs232/swtpc8212.cpp @@ -4,7 +4,7 @@ #include "emu.h" #include "swtpc8212.h" -swtpc8212_terminal_device::swtpc8212_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +swtpc8212_terminal_device::swtpc8212_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SERIAL_TERMINAL_SWTPC8212, tag, owner, clock) , device_rs232_port_interface(mconfig, *this) , m_swtpc8212(*this, "swtpc8212") @@ -14,7 +14,7 @@ swtpc8212_terminal_device::swtpc8212_terminal_device(const machine_config &mconf void swtpc8212_terminal_device::device_add_mconfig(machine_config &config) { - SWTPC8212(config, m_swtpc8212, 0); + SWTPC8212(config, m_swtpc8212); m_swtpc8212->rs232_conn_txd_handler().set(FUNC(swtpc8212_terminal_device::output_rxd)); m_swtpc8212->rs232_conn_rts_handler().set(FUNC(swtpc8212_terminal_device::route_term_rts)); m_swtpc8212->rs232_conn_dtr_handler().set(FUNC(swtpc8212_terminal_device::route_term_dtr)); diff --git a/src/devices/bus/rs232/swtpc8212.h b/src/devices/bus/rs232/swtpc8212.h index 2af82fa3215..4797da5a7df 100644 --- a/src/devices/bus/rs232/swtpc8212.h +++ b/src/devices/bus/rs232/swtpc8212.h @@ -13,7 +13,7 @@ class swtpc8212_terminal_device : public device_t, public device_rs232_port_interface { public: - swtpc8212_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + swtpc8212_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER(input_txd) override; diff --git a/src/devices/bus/rs232/terminal.cpp b/src/devices/bus/rs232/terminal.cpp index 24c37f5a0e2..5db97affccb 100644 --- a/src/devices/bus/rs232/terminal.cpp +++ b/src/devices/bus/rs232/terminal.cpp @@ -13,7 +13,7 @@ class serial_terminal_device : public generic_terminal_device, public device_rs232_port_interface { public: - serial_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + serial_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_WRITE_LINE_MEMBER( input_txd ) override { device_buffered_serial_interface::rx_w(state); } @@ -36,7 +36,7 @@ private: required_ioport m_rs232_stopbits; }; -serial_terminal_device::serial_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +serial_terminal_device::serial_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_terminal_device(mconfig, SERIAL_TERMINAL, tag, owner, clock, TERMINAL_WIDTH, TERMINAL_HEIGHT) , device_buffered_serial_interface(mconfig, *this) , device_rs232_port_interface(mconfig, *this) diff --git a/src/devices/bus/rs232/xvd701.cpp b/src/devices/bus/rs232/xvd701.cpp index a04365f2239..0411eea7a9e 100644 --- a/src/devices/bus/rs232/xvd701.cpp +++ b/src/devices/bus/rs232/xvd701.cpp @@ -13,7 +13,7 @@ #define LOGCMD(...) LOGMASKED(LOG_COMMAND, __VA_ARGS__) -jvc_xvd701_device::jvc_xvd701_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +jvc_xvd701_device::jvc_xvd701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, JVC_XVD701, tag, owner, clock), device_serial_interface(mconfig, *this), device_rs232_port_interface(mconfig, *this), diff --git a/src/devices/bus/rs232/xvd701.h b/src/devices/bus/rs232/xvd701.h index 8e85e377f76..93a907c9a16 100644 --- a/src/devices/bus/rs232/xvd701.h +++ b/src/devices/bus/rs232/xvd701.h @@ -11,7 +11,7 @@ class jvc_xvd701_device : public device_t, public device_rs232_port_interface { public: - jvc_xvd701_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + jvc_xvd701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual WRITE_LINE_MEMBER( input_txd ) override { device_serial_interface::rx_w(state); } protected: diff --git a/src/devices/bus/rtpc/kbd.cpp b/src/devices/bus/rtpc/kbd.cpp index 13cc1759a2d..33234f03694 100644 --- a/src/devices/bus/rtpc/kbd.cpp +++ b/src/devices/bus/rtpc/kbd.cpp @@ -57,7 +57,7 @@ DEFINE_DEVICE_TYPE(RTPC_KBD, rtpc_kbd_device, "rtpc_kbd", "IBM PC RT Keyboard") -rtpc_kbd_device::rtpc_kbd_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +rtpc_kbd_device::rtpc_kbd_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RTPC_KBD, tag, owner, clock) , device_rtpc_kbd_interface(mconfig, *this) , m_mcu(*this, "mcu") diff --git a/src/devices/bus/rtpc/kbd.h b/src/devices/bus/rtpc/kbd.h index 860cb5c2218..b9962577122 100644 --- a/src/devices/bus/rtpc/kbd.h +++ b/src/devices/bus/rtpc/kbd.h @@ -14,7 +14,7 @@ class rtpc_kbd_device , public device_rtpc_kbd_interface { public: - rtpc_kbd_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + rtpc_kbd_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/rtpc/kbd_con.cpp b/src/devices/bus/rtpc/kbd_con.cpp index f8617fe3ef5..6b4c552b462 100644 --- a/src/devices/bus/rtpc/kbd_con.cpp +++ b/src/devices/bus/rtpc/kbd_con.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(RTPC_KBD_CON, rtpc_kbd_con_device, "rtpc_kbd_con", "RT PC keyboard connector") -rtpc_kbd_con_device::rtpc_kbd_con_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +rtpc_kbd_con_device::rtpc_kbd_con_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RTPC_KBD_CON, tag, owner, clock) , device_single_card_slot_interface<device_rtpc_kbd_interface>(mconfig, *this) , m_out_clock_cb(*this) diff --git a/src/devices/bus/rtpc/kbd_con.h b/src/devices/bus/rtpc/kbd_con.h index b066fc56137..18e7e13ecb3 100644 --- a/src/devices/bus/rtpc/kbd_con.h +++ b/src/devices/bus/rtpc/kbd_con.h @@ -15,14 +15,14 @@ class rtpc_kbd_con_device public: template <typename T> rtpc_kbd_con_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : rtpc_kbd_con_device(mconfig, tag, owner, 0U) + : rtpc_kbd_con_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - rtpc_kbd_con_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0U); + rtpc_kbd_con_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); auto out_clock_cb() { return m_out_clock_cb.bind(); } auto out_data_cb() { return m_out_data_cb.bind(); } diff --git a/src/devices/bus/s100/am310.cpp b/src/devices/bus/s100/am310.cpp index 5eee55b1a2e..857a9031f6d 100644 --- a/src/devices/bus/s100/am310.cpp +++ b/src/devices/bus/s100/am310.cpp @@ -29,7 +29,7 @@ class s100_am310_device : public device_t, public device_s100_card_interface { public: // construction/destruction - s100_am310_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + s100_am310_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -69,7 +69,7 @@ private: DEFINE_DEVICE_TYPE_PRIVATE(S100_AM310, device_s100_card_interface, s100_am310_device, "s100_am310", "Alpha Micro AM-310 Communications Controller") -s100_am310_device::s100_am310_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +s100_am310_device::s100_am310_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_AM310, tag, owner, clock) , device_s100_card_interface(mconfig, *this) , m_z80(*this, "z80") diff --git a/src/devices/bus/s100/ascsasi.cpp b/src/devices/bus/s100/ascsasi.cpp index 73cacf9680a..0606b07e401 100644 --- a/src/devices/bus/s100/ascsasi.cpp +++ b/src/devices/bus/s100/ascsasi.cpp @@ -30,7 +30,7 @@ class asc_sasi_device : public device_t, public device_s100_card_interface public: // construction/destruction - asc_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + asc_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -72,7 +72,7 @@ constexpr attotime asc_sasi_device::s_pulse_width; // stupid non-inline semantic DEFINE_DEVICE_TYPE_PRIVATE(S100_ASC_SASI, device_s100_card_interface, asc_sasi_device, "ascsasi", "ASC Associates SASI Host Computer Adapter") -asc_sasi_device::asc_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +asc_sasi_device::asc_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_ASC_SASI, tag, owner, clock) , device_s100_card_interface(mconfig, *this) , m_sasi(*this, "sasi") diff --git a/src/devices/bus/s100/dg640.cpp b/src/devices/bus/s100/dg640.cpp index f6adb27cfa8..cab365d23ee 100644 --- a/src/devices/bus/s100/dg640.cpp +++ b/src/devices/bus/s100/dg640.cpp @@ -21,7 +21,7 @@ in the April 1978 issue of Electronics Today International (Australia). DEFINE_DEVICE_TYPE(S100_DG640, dg640_device, "dg640", "DG640 VDU") -dg640_device::dg640_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dg640_device::dg640_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_DG640, tag, owner, clock) , device_s100_card_interface(mconfig, *this) , m_p_chargen(*this, "chargen") diff --git a/src/devices/bus/s100/dg640.h b/src/devices/bus/s100/dg640.h index 97d1a3ecbc3..b835dc55673 100644 --- a/src/devices/bus/s100/dg640.h +++ b/src/devices/bus/s100/dg640.h @@ -17,7 +17,7 @@ class dg640_device : public device_t, public device_s100_card_interface { public: // construction/destruction - dg640_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dg640_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/s100/dj2db.cpp b/src/devices/bus/s100/dj2db.cpp index 6ee50a89840..c55c957d832 100644 --- a/src/devices/bus/s100/dj2db.cpp +++ b/src/devices/bus/s100/dj2db.cpp @@ -242,7 +242,7 @@ ioport_constructor s100_dj2db_device::device_input_ports() const // s100_dj2db_device - constructor //------------------------------------------------- -s100_dj2db_device::s100_dj2db_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +s100_dj2db_device::s100_dj2db_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_DJ2DB, tag, owner, clock), device_s100_card_interface(mconfig, *this), m_fdc(*this, MB8866_TAG), diff --git a/src/devices/bus/s100/dj2db.h b/src/devices/bus/s100/dj2db.h index e285ab43f42..49eb999c4d7 100644 --- a/src/devices/bus/s100/dj2db.h +++ b/src/devices/bus/s100/dj2db.h @@ -30,7 +30,7 @@ class s100_dj2db_device : public device_t, { public: // construction/destruction - s100_dj2db_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s100_dj2db_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/s100/djdma.cpp b/src/devices/bus/s100/djdma.cpp index 0ee7dab0a0c..a6bf49d36aa 100644 --- a/src/devices/bus/s100/djdma.cpp +++ b/src/devices/bus/s100/djdma.cpp @@ -109,7 +109,7 @@ void s100_djdma_device::device_add_mconfig(machine_config &config) // s100_djdma_device - constructor //------------------------------------------------- -s100_djdma_device::s100_djdma_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +s100_djdma_device::s100_djdma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_DJDMA, tag, owner, clock) , device_s100_card_interface(mconfig, *this) , m_diskcpu(*this, Z80_TAG) diff --git a/src/devices/bus/s100/djdma.h b/src/devices/bus/s100/djdma.h index d9453aef25c..428d6a25aa6 100644 --- a/src/devices/bus/s100/djdma.h +++ b/src/devices/bus/s100/djdma.h @@ -26,7 +26,7 @@ class s100_djdma_device : public device_t, public device_s100_card_interface { public: // construction/destruction - s100_djdma_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + s100_djdma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/s100/mm65k16s.cpp b/src/devices/bus/s100/mm65k16s.cpp index 5f64ce67aa4..49f6f5f1c64 100644 --- a/src/devices/bus/s100/mm65k16s.cpp +++ b/src/devices/bus/s100/mm65k16s.cpp @@ -202,7 +202,7 @@ ioport_constructor s100_mm65k16s_device::device_input_ports() const // s100_mm65k16s_device - constructor //------------------------------------------------- -s100_mm65k16s_device::s100_mm65k16s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +s100_mm65k16s_device::s100_mm65k16s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_MM65K16S, tag, owner, clock), device_s100_card_interface(mconfig, *this), m_ram(*this, "ram", 0x10000, ENDIANNESS_LITTLE) diff --git a/src/devices/bus/s100/mm65k16s.h b/src/devices/bus/s100/mm65k16s.h index 706d7e697b6..0eaa8ad07ef 100644 --- a/src/devices/bus/s100/mm65k16s.h +++ b/src/devices/bus/s100/mm65k16s.h @@ -26,7 +26,7 @@ class s100_mm65k16s_device : public device_t, { public: // construction/destruction - s100_mm65k16s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s100_mm65k16s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/s100/nsmdsa.cpp b/src/devices/bus/s100/nsmdsa.cpp index 53441107c7d..dda0971e2fe 100644 --- a/src/devices/bus/s100/nsmdsa.cpp +++ b/src/devices/bus/s100/nsmdsa.cpp @@ -73,7 +73,7 @@ void s100_mds_a_device::device_add_mconfig(machine_config &config) // s100_mds_a_device - constructor //------------------------------------------------- -s100_mds_a_device::s100_mds_a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +s100_mds_a_device::s100_mds_a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_MDS_A, tag, owner, clock), device_s100_card_interface(mconfig, *this), m_floppy(*this, "floppy%u", 0U), diff --git a/src/devices/bus/s100/nsmdsa.h b/src/devices/bus/s100/nsmdsa.h index a36f39127ec..e8e3a59647b 100644 --- a/src/devices/bus/s100/nsmdsa.h +++ b/src/devices/bus/s100/nsmdsa.h @@ -27,7 +27,7 @@ class s100_mds_a_device : public device_t, { public: // construction/destruction - s100_mds_a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s100_mds_a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/s100/nsmdsad.cpp b/src/devices/bus/s100/nsmdsad.cpp index 00343623711..c365e0abe57 100644 --- a/src/devices/bus/s100/nsmdsad.cpp +++ b/src/devices/bus/s100/nsmdsad.cpp @@ -74,7 +74,7 @@ void s100_mds_ad_device::device_add_mconfig(machine_config &config) // s100_mds_ad_device - constructor //------------------------------------------------- -s100_mds_ad_device::s100_mds_ad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +s100_mds_ad_device::s100_mds_ad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_MDS_AD, tag, owner, clock), device_s100_card_interface(mconfig, *this), m_floppy(*this, "floppy%u", 0U), diff --git a/src/devices/bus/s100/nsmdsad.h b/src/devices/bus/s100/nsmdsad.h index ce5a248d553..16d5faeda6f 100644 --- a/src/devices/bus/s100/nsmdsad.h +++ b/src/devices/bus/s100/nsmdsad.h @@ -27,7 +27,7 @@ class s100_mds_ad_device : public device_t, { public: // construction/destruction - s100_mds_ad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s100_mds_ad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/s100/poly16k.cpp b/src/devices/bus/s100/poly16k.cpp index 98861545d39..0e8f0f7f485 100644 --- a/src/devices/bus/s100/poly16k.cpp +++ b/src/devices/bus/s100/poly16k.cpp @@ -26,7 +26,7 @@ class poly_16k_ram_device : public device_t, public device_s100_card_interface { public: // construction/destruction - poly_16k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + poly_16k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-specific overrides @@ -82,7 +82,7 @@ INPUT_PORTS_END // poly_16k_ram_device - constructor //------------------------------------------------- -poly_16k_ram_device::poly_16k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +poly_16k_ram_device::poly_16k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_POLY_16K, tag, owner, clock) , device_s100_card_interface(mconfig, *this) , m_dsw(*this, "DSW") diff --git a/src/devices/bus/s100/polyfdc.cpp b/src/devices/bus/s100/polyfdc.cpp index 962424324e0..fed3a81d6ea 100644 --- a/src/devices/bus/s100/polyfdc.cpp +++ b/src/devices/bus/s100/polyfdc.cpp @@ -20,7 +20,7 @@ class poly_fdc_device : public device_t, public device_s100_card_interface { public: // construction/destruction - poly_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + poly_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } @@ -45,7 +45,7 @@ private: DEFINE_DEVICE_TYPE_PRIVATE(S100_POLY_FDC, device_s100_card_interface, poly_fdc_device, "polyfdc", "PolyMorphic Systems Disk Controller") -poly_fdc_device::poly_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +poly_fdc_device::poly_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_POLY_FDC, tag, owner, clock) , device_s100_card_interface(mconfig, *this) , m_usrt(*this, "usrt") @@ -115,7 +115,7 @@ void poly_fdc_device::pc_w(u8 data) void poly_fdc_device::device_add_mconfig(machine_config &config) { - MC6852(config, m_usrt, 0); // E generated from PDBIN+ and PWR- + MC6852(config, m_usrt); // E generated from PDBIN+ and PWR- I8255(config, m_pio); m_pio->out_pa_callback().set(FUNC(poly_fdc_device::pa_w)); diff --git a/src/devices/bus/s100/polyvti.cpp b/src/devices/bus/s100/polyvti.cpp index 242d13a8fe2..a07bbacd513 100644 --- a/src/devices/bus/s100/polyvti.cpp +++ b/src/devices/bus/s100/polyvti.cpp @@ -36,7 +36,7 @@ class poly_vti_device : public device_t, public device_s100_card_interface public: // construction/destruction - poly_vti_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + poly_vti_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -69,7 +69,7 @@ private: DEFINE_DEVICE_TYPE_PRIVATE(S100_POLY_VTI, device_s100_card_interface, poly_vti_device, "polyvti", "PolyMorphic Systems Video Terminal Interface") -poly_vti_device::poly_vti_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +poly_vti_device::poly_vti_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_POLY_VTI, tag, owner, clock) , device_s100_card_interface(mconfig, *this) , m_kbdlatch(*this, "kbdlatch") @@ -324,7 +324,7 @@ void poly_vti_device::device_add_mconfig(machine_config &config) GFXDECODE(config, "gfxdecode", "palette", gfx_vti); PALETTE(config, "palette", palette_device::MONOCHROME); - generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, "keyboard", 0)); + generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, "keyboard")); keyboard.set_keyboard_callback(FUNC(poly_vti_device::kbd_put)); I8212(config, m_kbdlatch); diff --git a/src/devices/bus/s100/s100.cpp b/src/devices/bus/s100/s100.cpp index 67a5df55124..60ad6e85665 100644 --- a/src/devices/bus/s100/s100.cpp +++ b/src/devices/bus/s100/s100.cpp @@ -44,7 +44,7 @@ void device_s100_card_interface::interface_pre_start() //------------------------------------------------- // s100_slot_device - constructor //------------------------------------------------- -s100_slot_device::s100_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +s100_slot_device::s100_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_SLOT, tag, owner, clock), device_single_card_slot_interface<device_s100_card_interface>(mconfig, *this), m_bus(*this, DEVICE_SELF_OWNER) @@ -68,7 +68,7 @@ void s100_slot_device::device_start() // s100_bus_device - constructor //------------------------------------------------- -s100_bus_device::s100_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +s100_bus_device::s100_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_BUS, tag, owner, clock), m_write_irq(*this), m_write_nmi(*this), diff --git a/src/devices/bus/s100/s100.h b/src/devices/bus/s100/s100.h index ae10f4e70bc..97efdba57b2 100644 --- a/src/devices/bus/s100/s100.h +++ b/src/devices/bus/s100/s100.h @@ -138,7 +138,7 @@ class s100_bus_device : public device_t { public: // construction/destruction - s100_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s100_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~s100_bus_device() { m_device_list.detach_all(); } auto irq() { return m_write_irq.bind(); } @@ -228,7 +228,7 @@ public: set_default_option(dflt); set_fixed(false); } - s100_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s100_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_bus(T &&tag) { m_bus.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/bus/s100/seals8k.cpp b/src/devices/bus/s100/seals8k.cpp index 58a040efad4..25383ef342a 100644 --- a/src/devices/bus/s100/seals8k.cpp +++ b/src/devices/bus/s100/seals8k.cpp @@ -40,11 +40,11 @@ class s100_8k_sc_device : public device_t, public device_s100_card_interface { public: // construction/destruction - s100_8k_sc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + s100_8k_sc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // delegated construction - s100_8k_sc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + s100_8k_sc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-specific overrides virtual ioport_constructor device_input_ports() const override; @@ -71,7 +71,7 @@ class s100_8k_sc_bb_device : public s100_8k_sc_device, public device_nvram_inter { public: // construction/destruction - s100_8k_sc_bb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + s100_8k_sc_bb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_nvram_interface overrides @@ -112,7 +112,7 @@ INPUT_PORTS_END // s100_8k_sc_device - constructor //------------------------------------------------- -s100_8k_sc_device::s100_8k_sc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +s100_8k_sc_device::s100_8k_sc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_s100_card_interface(mconfig, *this), m_dsw(*this, "DSW") @@ -120,7 +120,7 @@ s100_8k_sc_device::s100_8k_sc_device(const machine_config &mconfig, device_type } -s100_8k_sc_device::s100_8k_sc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +s100_8k_sc_device::s100_8k_sc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : s100_8k_sc_device(mconfig, S100_8K_SC, tag, owner, clock) { } @@ -130,7 +130,7 @@ s100_8k_sc_device::s100_8k_sc_device(const machine_config &mconfig, const char * // s100_8k_sc_bb_device - constructor //------------------------------------------------- -s100_8k_sc_bb_device::s100_8k_sc_bb_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +s100_8k_sc_bb_device::s100_8k_sc_bb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : s100_8k_sc_device(mconfig, S100_8K_SC_BB, tag, owner, clock), device_nvram_interface(mconfig, *this) { diff --git a/src/devices/bus/s100/wunderbus.cpp b/src/devices/bus/s100/wunderbus.cpp index 29efc80b185..9faf42fa31d 100644 --- a/src/devices/bus/s100/wunderbus.cpp +++ b/src/devices/bus/s100/wunderbus.cpp @@ -88,7 +88,7 @@ WRITE_LINE_MEMBER( s100_wunderbus_device::rtc_tp_w ) void s100_wunderbus_device::device_add_mconfig(machine_config &config) { - PIC8259(config, m_pic, 0); + PIC8259(config, m_pic); m_pic->out_int_callback().set(FUNC(s100_wunderbus_device::pic_int_w)); m_pic->in_sp_callback().set_constant(1); @@ -233,7 +233,7 @@ ioport_constructor s100_wunderbus_device::device_input_ports() const // s100_wunderbus_device - constructor //------------------------------------------------- -s100_wunderbus_device::s100_wunderbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +s100_wunderbus_device::s100_wunderbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S100_WUNDERBUS, tag, owner, clock), device_s100_card_interface(mconfig, *this), m_pic(*this, I8259A_TAG), diff --git a/src/devices/bus/s100/wunderbus.h b/src/devices/bus/s100/wunderbus.h index ca9a6d0e641..7d5ae782215 100644 --- a/src/devices/bus/s100/wunderbus.h +++ b/src/devices/bus/s100/wunderbus.h @@ -29,7 +29,7 @@ class s100_wunderbus_device : public device_t, { public: // construction/destruction - s100_wunderbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s100_wunderbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/saitek_osa/expansion.cpp b/src/devices/bus/saitek_osa/expansion.cpp index 76a4ac6b6cd..41e3270857b 100644 --- a/src/devices/bus/saitek_osa/expansion.cpp +++ b/src/devices/bus/saitek_osa/expansion.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(SAITEKOSA_EXPANSION, saitekosa_expansion_device, "saitekosa_e // saitekosa_expansion_device - constructor //------------------------------------------------- -saitekosa_expansion_device::saitekosa_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +saitekosa_expansion_device::saitekosa_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAITEKOSA_EXPANSION, tag, owner, clock), device_single_card_slot_interface<device_saitekosa_expansion_interface>(mconfig, *this), m_stb_handler(*this), diff --git a/src/devices/bus/saitek_osa/expansion.h b/src/devices/bus/saitek_osa/expansion.h index 47364d492ec..b85450c417d 100644 --- a/src/devices/bus/saitek_osa/expansion.h +++ b/src/devices/bus/saitek_osa/expansion.h @@ -48,7 +48,7 @@ public: // construction/destruction template <typename T> saitekosa_expansion_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts) : - saitekosa_expansion_device(mconfig, tag, owner, u32(0)) + saitekosa_expansion_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -56,7 +56,7 @@ public: set_fixed(false); } - saitekosa_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + saitekosa_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~saitekosa_expansion_device(); // callbacks diff --git a/src/devices/bus/saitek_osa/maestro.cpp b/src/devices/bus/saitek_osa/maestro.cpp index 7237eb78d22..8f8cb930e2f 100644 --- a/src/devices/bus/saitek_osa/maestro.cpp +++ b/src/devices/bus/saitek_osa/maestro.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(OSA_ANALYST, saitekosa_analyst_device, "osa_analyst", "Analys // initialization //------------------------------------------------- -saitekosa_maestro_device::saitekosa_maestro_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +saitekosa_maestro_device::saitekosa_maestro_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_saitekosa_expansion_interface(mconfig, *this), m_maincpu(*this, "maincpu"), @@ -57,11 +57,11 @@ saitekosa_maestro_device::saitekosa_maestro_device(const machine_config &mconfig m_extrom(*this, "extrom") { } -saitekosa_maestro_device::saitekosa_maestro_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +saitekosa_maestro_device::saitekosa_maestro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saitekosa_maestro_device(mconfig, OSA_MAESTRO, tag, owner, clock) { } -saitekosa_analyst_device::saitekosa_analyst_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +saitekosa_analyst_device::saitekosa_analyst_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saitekosa_maestro_device(mconfig, OSA_ANALYST, tag, owner, clock), m_lcd(*this, "lcd") { } @@ -237,7 +237,7 @@ void saitekosa_analyst_device::device_add_mconfig(machine_config &config) saitekosa_maestro_device::device_add_mconfig(config); // video hardware - HD44780(config, m_lcd, 0); + HD44780(config, m_lcd); } diff --git a/src/devices/bus/saitek_osa/maestro.h b/src/devices/bus/saitek_osa/maestro.h index 1b79423e424..38cb3b72e58 100644 --- a/src/devices/bus/saitek_osa/maestro.h +++ b/src/devices/bus/saitek_osa/maestro.h @@ -24,7 +24,7 @@ class saitekosa_maestro_device : public device_t, public device_saitekosa_expans { public: // construction/destruction - saitekosa_maestro_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + saitekosa_maestro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(switch_cpu_freq) { set_cpu_freq(); } @@ -34,7 +34,7 @@ public: virtual void ack_w(int state) override; protected: - saitekosa_maestro_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + saitekosa_maestro_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual const tiny_rom_entry *device_rom_region() const override; virtual ioport_constructor device_input_ports() const override; @@ -68,7 +68,7 @@ protected: class saitekosa_analyst_device : public saitekosa_maestro_device { public: - saitekosa_analyst_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + saitekosa_analyst_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) override; diff --git a/src/devices/bus/saitek_osa/maestroa.cpp b/src/devices/bus/saitek_osa/maestroa.cpp index c7b82583f5b..9526994ec10 100644 --- a/src/devices/bus/saitek_osa/maestroa.cpp +++ b/src/devices/bus/saitek_osa/maestroa.cpp @@ -36,7 +36,7 @@ DEFINE_DEVICE_TYPE(OSA_MAESTROA, saitekosa_maestroa_device, "osa_maestroa", "Mae // initialization //------------------------------------------------- -saitekosa_maestroa_device::saitekosa_maestroa_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +saitekosa_maestroa_device::saitekosa_maestroa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, OSA_MAESTROA, tag, owner, clock), device_saitekosa_expansion_interface(mconfig, *this), m_maincpu(*this, "maincpu") diff --git a/src/devices/bus/saitek_osa/maestroa.h b/src/devices/bus/saitek_osa/maestroa.h index 35b5744f07d..d9765b066a9 100644 --- a/src/devices/bus/saitek_osa/maestroa.h +++ b/src/devices/bus/saitek_osa/maestroa.h @@ -20,7 +20,7 @@ class saitekosa_maestroa_device : public device_t, public device_saitekosa_expan { public: // construction/destruction - saitekosa_maestroa_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + saitekosa_maestroa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(switch_cpu_freq) { set_cpu_freq(); } diff --git a/src/devices/bus/saitek_osa/sparc.cpp b/src/devices/bus/saitek_osa/sparc.cpp index 61a215b68cf..be950c9a361 100644 --- a/src/devices/bus/saitek_osa/sparc.cpp +++ b/src/devices/bus/saitek_osa/sparc.cpp @@ -43,7 +43,7 @@ DEFINE_DEVICE_TYPE(OSA_SPARC, saitekosa_sparc_device, "osa_sparc", "Sparc") // initialization //------------------------------------------------- -saitekosa_sparc_device::saitekosa_sparc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +saitekosa_sparc_device::saitekosa_sparc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, OSA_SPARC, tag, owner, clock), device_saitekosa_expansion_interface(mconfig, *this), m_maincpu(*this, "maincpu"), diff --git a/src/devices/bus/saitek_osa/sparc.h b/src/devices/bus/saitek_osa/sparc.h index ffdda735502..6436a8dcaa1 100644 --- a/src/devices/bus/saitek_osa/sparc.h +++ b/src/devices/bus/saitek_osa/sparc.h @@ -22,7 +22,7 @@ class saitekosa_sparc_device : public device_t, public device_saitekosa_expansio { public: // construction/destruction - saitekosa_sparc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + saitekosa_sparc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual u8 data_r() override; diff --git a/src/devices/bus/samcoupe/drive/atom.cpp b/src/devices/bus/samcoupe/drive/atom.cpp index 5ca86f5d327..7d4fc2731b8 100644 --- a/src/devices/bus/samcoupe/drive/atom.cpp +++ b/src/devices/bus/samcoupe/drive/atom.cpp @@ -34,7 +34,7 @@ void sam_atom_hdd_device::device_add_mconfig(machine_config &config) // sam_atom_hdd_device - constructor //------------------------------------------------- -sam_atom_hdd_device::sam_atom_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_atom_hdd_device::sam_atom_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAM_ATOM_HDD, tag, owner, clock), device_samcoupe_drive_interface(mconfig, *this), m_ata(*this, "ata"), diff --git a/src/devices/bus/samcoupe/drive/atom.h b/src/devices/bus/samcoupe/drive/atom.h index 0abfee86749..1ad0bc7b4bc 100644 --- a/src/devices/bus/samcoupe/drive/atom.h +++ b/src/devices/bus/samcoupe/drive/atom.h @@ -25,7 +25,7 @@ class sam_atom_hdd_device : public device_t, public device_samcoupe_drive_interf { public: // construction/destruction - sam_atom_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_atom_hdd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual uint8_t read(offs_t offset) override; diff --git a/src/devices/bus/samcoupe/drive/drive.cpp b/src/devices/bus/samcoupe/drive/drive.cpp index 564b2299fc2..6cc796e033a 100644 --- a/src/devices/bus/samcoupe/drive/drive.cpp +++ b/src/devices/bus/samcoupe/drive/drive.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(SAMCOUPE_DRIVE_PORT, samcoupe_drive_port_device, "samcoupe_dr // samcoupe_drive_port_device - constructor //------------------------------------------------- -samcoupe_drive_port_device::samcoupe_drive_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +samcoupe_drive_port_device::samcoupe_drive_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAMCOUPE_DRIVE_PORT, tag, owner, clock), device_single_card_slot_interface<device_samcoupe_drive_interface>(mconfig, *this), m_module(nullptr) diff --git a/src/devices/bus/samcoupe/drive/drive.h b/src/devices/bus/samcoupe/drive/drive.h index 83f7ce0f069..66f968f81b1 100644 --- a/src/devices/bus/samcoupe/drive/drive.h +++ b/src/devices/bus/samcoupe/drive/drive.h @@ -45,7 +45,7 @@ public: // construction/destruction template <typename T> samcoupe_drive_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, const char *dflt) - : samcoupe_drive_port_device(mconfig, tag, owner, uint32_t(0)) + : samcoupe_drive_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -53,7 +53,7 @@ public: set_fixed(false); } - samcoupe_drive_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + samcoupe_drive_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~samcoupe_drive_port_device(); // called from host diff --git a/src/devices/bus/samcoupe/drive/floppy.cpp b/src/devices/bus/samcoupe/drive/floppy.cpp index 3940e9f5ddb..c78e5bbb1b6 100644 --- a/src/devices/bus/samcoupe/drive/floppy.cpp +++ b/src/devices/bus/samcoupe/drive/floppy.cpp @@ -47,7 +47,7 @@ void sam_floppy_device::device_add_mconfig(machine_config &config) // sam_floppy_device - constructor //------------------------------------------------- -sam_floppy_device::sam_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_floppy_device::sam_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAM_FLOPPY, tag, owner, clock), device_samcoupe_drive_interface(mconfig, *this), m_fdc(*this, "fdc"), diff --git a/src/devices/bus/samcoupe/drive/floppy.h b/src/devices/bus/samcoupe/drive/floppy.h index 8f227009cbb..58109ed8b2a 100644 --- a/src/devices/bus/samcoupe/drive/floppy.h +++ b/src/devices/bus/samcoupe/drive/floppy.h @@ -26,7 +26,7 @@ class sam_floppy_device : public device_t, public device_samcoupe_drive_interfac { public: // construction/destruction - sam_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_floppy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual uint8_t read(offs_t offset) override; diff --git a/src/devices/bus/samcoupe/expansion/blue_sampler.cpp b/src/devices/bus/samcoupe/expansion/blue_sampler.cpp index 9a70d3cac3d..c31e1274c29 100644 --- a/src/devices/bus/samcoupe/expansion/blue_sampler.cpp +++ b/src/devices/bus/samcoupe/expansion/blue_sampler.cpp @@ -31,7 +31,7 @@ void sam_blue_sound_sampler_device::device_add_mconfig(machine_config &config) m_ppi->out_pb_callback().set(FUNC(sam_blue_sound_sampler_device::ppi_portb_w)); m_ppi->in_pc_callback().set(FUNC(sam_blue_sound_sampler_device::ppi_portc_r)); - ZN426E(config, m_dac, 0).add_route(ALL_OUTPUTS, "mono", 0.5); + ZN426E(config, m_dac).add_route(ALL_OUTPUTS, "mono", 0.5); // TODO: ZN449E ADC @@ -48,7 +48,7 @@ void sam_blue_sound_sampler_device::device_add_mconfig(machine_config &config) // sam_blue_sound_sampler_device - constructor //------------------------------------------------- -sam_blue_sound_sampler_device::sam_blue_sound_sampler_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_blue_sound_sampler_device::sam_blue_sound_sampler_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAM_BLUE_SOUND_SAMPLER, tag, owner, clock), device_samcoupe_expansion_interface(mconfig, *this), m_ppi(*this, "ppi"), diff --git a/src/devices/bus/samcoupe/expansion/blue_sampler.h b/src/devices/bus/samcoupe/expansion/blue_sampler.h index 56c1298345c..41caa6d78f9 100644 --- a/src/devices/bus/samcoupe/expansion/blue_sampler.h +++ b/src/devices/bus/samcoupe/expansion/blue_sampler.h @@ -27,7 +27,7 @@ class sam_blue_sound_sampler_device : public device_t, public device_samcoupe_ex { public: // construction/destruction - sam_blue_sound_sampler_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_blue_sound_sampler_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual uint8_t iorq_r(offs_t offset) override; diff --git a/src/devices/bus/samcoupe/expansion/dallas.cpp b/src/devices/bus/samcoupe/expansion/dallas.cpp index 30e7a1d0005..1d35d82add5 100644 --- a/src/devices/bus/samcoupe/expansion/dallas.cpp +++ b/src/devices/bus/samcoupe/expansion/dallas.cpp @@ -35,7 +35,7 @@ void sam_dallas_clock_device::device_add_mconfig(machine_config &config) // sam_dallas_clock_device - constructor //------------------------------------------------- -sam_dallas_clock_device::sam_dallas_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_dallas_clock_device::sam_dallas_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAM_DALLAS_CLOCK, tag, owner, clock), device_samcoupe_expansion_interface(mconfig, *this), m_rtc(*this, "rtc"), diff --git a/src/devices/bus/samcoupe/expansion/dallas.h b/src/devices/bus/samcoupe/expansion/dallas.h index 4b011e5db34..d08e62813d3 100644 --- a/src/devices/bus/samcoupe/expansion/dallas.h +++ b/src/devices/bus/samcoupe/expansion/dallas.h @@ -25,7 +25,7 @@ class sam_dallas_clock_device : public device_t, public device_samcoupe_expansio { public: // construction/destruction - sam_dallas_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_dallas_clock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual void print_w(int state) override; diff --git a/src/devices/bus/samcoupe/expansion/expansion.cpp b/src/devices/bus/samcoupe/expansion/expansion.cpp index b52792eb43d..1463bea6376 100644 --- a/src/devices/bus/samcoupe/expansion/expansion.cpp +++ b/src/devices/bus/samcoupe/expansion/expansion.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(SAMCOUPE_EXPANSION, samcoupe_expansion_device, "samcoupe_expa // samcoupe_expansion_device - constructor //------------------------------------------------- -samcoupe_expansion_device::samcoupe_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +samcoupe_expansion_device::samcoupe_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAMCOUPE_EXPANSION, tag, owner, clock), device_single_card_slot_interface<device_samcoupe_expansion_interface>(mconfig, *this), m_int_handler(*this), diff --git a/src/devices/bus/samcoupe/expansion/expansion.h b/src/devices/bus/samcoupe/expansion/expansion.h index 90390286ac2..a78400f7d20 100644 --- a/src/devices/bus/samcoupe/expansion/expansion.h +++ b/src/devices/bus/samcoupe/expansion/expansion.h @@ -61,7 +61,7 @@ public: // construction/destruction template <typename T> samcoupe_expansion_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts) - : samcoupe_expansion_device(mconfig, tag, owner, uint32_t(0)) + : samcoupe_expansion_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -69,7 +69,7 @@ public: set_fixed(false); } - samcoupe_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + samcoupe_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~samcoupe_expansion_device(); // callbacks diff --git a/src/devices/bus/samcoupe/expansion/onemeg.cpp b/src/devices/bus/samcoupe/expansion/onemeg.cpp index 05c7c01860d..39326df125c 100644 --- a/src/devices/bus/samcoupe/expansion/onemeg.cpp +++ b/src/devices/bus/samcoupe/expansion/onemeg.cpp @@ -43,7 +43,7 @@ ioport_constructor sam_onemeg_device::device_input_ports() const // sam_onemeg_device - constructor //------------------------------------------------- -sam_onemeg_device::sam_onemeg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_onemeg_device::sam_onemeg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAM_ONEMEG, tag, owner, clock), device_samcoupe_expansion_interface(mconfig, *this), m_dip(*this, "dip"), diff --git a/src/devices/bus/samcoupe/expansion/onemeg.h b/src/devices/bus/samcoupe/expansion/onemeg.h index 40b60accf82..73f3de3e448 100644 --- a/src/devices/bus/samcoupe/expansion/onemeg.h +++ b/src/devices/bus/samcoupe/expansion/onemeg.h @@ -24,7 +24,7 @@ class sam_onemeg_device : public device_t, public device_samcoupe_expansion_inte { public: // construction/destruction - sam_onemeg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_onemeg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual void xmem_w(int state) override; diff --git a/src/devices/bus/samcoupe/expansion/sambus.cpp b/src/devices/bus/samcoupe/expansion/sambus.cpp index 5b68ff49f88..817354e9478 100644 --- a/src/devices/bus/samcoupe/expansion/sambus.cpp +++ b/src/devices/bus/samcoupe/expansion/sambus.cpp @@ -39,7 +39,7 @@ void sam_sambus_device::device_add_mconfig(machine_config &config) // sam_sambus_device - constructor //------------------------------------------------- -sam_sambus_device::sam_sambus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_sambus_device::sam_sambus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAM_SAMBUS, tag, owner, clock), device_samcoupe_expansion_interface(mconfig, *this), m_rtc(*this, "rtc"), diff --git a/src/devices/bus/samcoupe/expansion/sambus.h b/src/devices/bus/samcoupe/expansion/sambus.h index 4d17ed4ae74..ecfc53b495f 100644 --- a/src/devices/bus/samcoupe/expansion/sambus.h +++ b/src/devices/bus/samcoupe/expansion/sambus.h @@ -25,7 +25,7 @@ class sam_sambus_device : public device_t, public device_samcoupe_expansion_inte { public: // construction/destruction - sam_sambus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_sambus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual void xmem_w(int state) override; diff --git a/src/devices/bus/samcoupe/expansion/sdide.cpp b/src/devices/bus/samcoupe/expansion/sdide.cpp index 4c442b816c6..c676acc90ae 100644 --- a/src/devices/bus/samcoupe/expansion/sdide.cpp +++ b/src/devices/bus/samcoupe/expansion/sdide.cpp @@ -34,7 +34,7 @@ void sam_sdide_device::device_add_mconfig(machine_config &config) // sam_sdide_device - constructor //------------------------------------------------- -sam_sdide_device::sam_sdide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_sdide_device::sam_sdide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAM_SDIDE, tag, owner, clock), device_samcoupe_expansion_interface(mconfig, *this), m_ata(*this, "ata"), diff --git a/src/devices/bus/samcoupe/expansion/sdide.h b/src/devices/bus/samcoupe/expansion/sdide.h index 75974d885f8..09db6d50752 100644 --- a/src/devices/bus/samcoupe/expansion/sdide.h +++ b/src/devices/bus/samcoupe/expansion/sdide.h @@ -25,7 +25,7 @@ class sam_sdide_device : public device_t, public device_samcoupe_expansion_inter { public: // construction/destruction - sam_sdide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_sdide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual uint8_t iorq_r(offs_t offset) override; diff --git a/src/devices/bus/samcoupe/expansion/sid.cpp b/src/devices/bus/samcoupe/expansion/sid.cpp index 45c3c0c7f83..29ef3458fe2 100644 --- a/src/devices/bus/samcoupe/expansion/sid.cpp +++ b/src/devices/bus/samcoupe/expansion/sid.cpp @@ -45,7 +45,7 @@ void sam_sid8580_device::device_add_mconfig(machine_config &config) // sam_sid_device - constructor //------------------------------------------------- -sam_sid_device::sam_sid_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +sam_sid_device::sam_sid_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_samcoupe_expansion_interface(mconfig, *this), m_sid(*this, "sid") @@ -56,7 +56,7 @@ sam_sid_device::sam_sid_device(const machine_config &mconfig, device_type type, // sam_sid6581_device - constructor //------------------------------------------------- -sam_sid6581_device::sam_sid6581_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_sid6581_device::sam_sid6581_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sam_sid_device(mconfig, SAM_SID6581, tag, owner, clock) { } @@ -65,7 +65,7 @@ sam_sid6581_device::sam_sid6581_device(const machine_config &mconfig, const char // sam_sid8580_device - constructor //------------------------------------------------- -sam_sid8580_device::sam_sid8580_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_sid8580_device::sam_sid8580_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sam_sid_device(mconfig, SAM_SID8580, tag, owner, clock) { } diff --git a/src/devices/bus/samcoupe/expansion/sid.h b/src/devices/bus/samcoupe/expansion/sid.h index 9580f00af65..0189ff1387c 100644 --- a/src/devices/bus/samcoupe/expansion/sid.h +++ b/src/devices/bus/samcoupe/expansion/sid.h @@ -25,7 +25,7 @@ class sam_sid_device : public device_t, public device_samcoupe_expansion_interfa { public: // construction/destruction - sam_sid_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sam_sid_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // from host virtual void iorq_w(offs_t offset, uint8_t data) override; @@ -42,7 +42,7 @@ class sam_sid6581_device : public sam_sid_device { public: // construction/destruction - sam_sid6581_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_sid6581_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -54,7 +54,7 @@ class sam_sid8580_device : public sam_sid_device { public: // construction/destruction - sam_sid8580_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_sid8580_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/samcoupe/expansion/spi.cpp b/src/devices/bus/samcoupe/expansion/spi.cpp index 47343f32dc1..39cf4cd4c4e 100644 --- a/src/devices/bus/samcoupe/expansion/spi.cpp +++ b/src/devices/bus/samcoupe/expansion/spi.cpp @@ -38,7 +38,7 @@ void sam_spi_device::device_add_mconfig(machine_config &config) // sambus_device - constructor //------------------------------------------------- -sam_spi_device::sam_spi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_spi_device::sam_spi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAM_SPI, tag, owner, clock), device_samcoupe_expansion_interface(mconfig, *this), m_data_out(*this, "data_out"), diff --git a/src/devices/bus/samcoupe/expansion/spi.h b/src/devices/bus/samcoupe/expansion/spi.h index 38e813bd6ee..4968d7901ef 100644 --- a/src/devices/bus/samcoupe/expansion/spi.h +++ b/src/devices/bus/samcoupe/expansion/spi.h @@ -25,7 +25,7 @@ class sam_spi_device : public device_t, public device_samcoupe_expansion_interfa { public: // construction/destruction - sam_spi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_spi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual void print_w(int state) override; diff --git a/src/devices/bus/samcoupe/expansion/voicebox.cpp b/src/devices/bus/samcoupe/expansion/voicebox.cpp index d52fc3275a7..9bd6ebd84bd 100644 --- a/src/devices/bus/samcoupe/expansion/voicebox.cpp +++ b/src/devices/bus/samcoupe/expansion/voicebox.cpp @@ -38,7 +38,7 @@ const tiny_rom_entry *sam_voicebox_device::device_rom_region() const void sam_voicebox_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "mono").front_center(); - SP0256(config, m_sp0256, 3000000); // ??? + SP0256(config, m_sp0256, XTAL::u(3000000)); // ??? m_sp0256->add_route(ALL_OUTPUTS, "mono", 1.00); } @@ -51,7 +51,7 @@ void sam_voicebox_device::device_add_mconfig(machine_config &config) // sam_voicebox_device - constructor //------------------------------------------------- -sam_voicebox_device::sam_voicebox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_voicebox_device::sam_voicebox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAM_VOICEBOX, tag, owner, clock), device_samcoupe_expansion_interface(mconfig, *this), m_sp0256(*this, "sp0256") diff --git a/src/devices/bus/samcoupe/expansion/voicebox.h b/src/devices/bus/samcoupe/expansion/voicebox.h index 775bc544a49..9dcbe660d43 100644 --- a/src/devices/bus/samcoupe/expansion/voicebox.h +++ b/src/devices/bus/samcoupe/expansion/voicebox.h @@ -25,7 +25,7 @@ class sam_voicebox_device : public device_t, public device_samcoupe_expansion_in { public: // construction/destruction - sam_voicebox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_voicebox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual uint8_t iorq_r(offs_t offset) override; diff --git a/src/devices/bus/samcoupe/mouse/mouse.cpp b/src/devices/bus/samcoupe/mouse/mouse.cpp index fbacfa67c7a..f29b870cb1f 100644 --- a/src/devices/bus/samcoupe/mouse/mouse.cpp +++ b/src/devices/bus/samcoupe/mouse/mouse.cpp @@ -48,7 +48,7 @@ ioport_constructor sam_mouse_device::device_input_ports() const // sam_mouse_device - constructor //------------------------------------------------- -sam_mouse_device::sam_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sam_mouse_device::sam_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAM_MOUSE, tag, owner, clock), device_samcoupe_mouse_interface(mconfig, *this), m_io_buttons(*this, "buttons"), diff --git a/src/devices/bus/samcoupe/mouse/mouse.h b/src/devices/bus/samcoupe/mouse/mouse.h index 076f3035b6d..4c4f136aa54 100644 --- a/src/devices/bus/samcoupe/mouse/mouse.h +++ b/src/devices/bus/samcoupe/mouse/mouse.h @@ -24,7 +24,7 @@ class sam_mouse_device : public device_t, public device_samcoupe_mouse_interface { public: // construction/destruction - sam_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sam_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual uint8_t read() override; diff --git a/src/devices/bus/samcoupe/mouse/mouseport.cpp b/src/devices/bus/samcoupe/mouse/mouseport.cpp index 3bfc609c093..7875214a3dc 100644 --- a/src/devices/bus/samcoupe/mouse/mouseport.cpp +++ b/src/devices/bus/samcoupe/mouse/mouseport.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(SAMCOUPE_MOUSE_PORT, samcoupe_mouse_port_device, "samcoupe_mo // samcoupe_mouse_port_device - constructor //------------------------------------------------- -samcoupe_mouse_port_device::samcoupe_mouse_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +samcoupe_mouse_port_device::samcoupe_mouse_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAMCOUPE_MOUSE_PORT, tag, owner, clock), device_single_card_slot_interface<device_samcoupe_mouse_interface>(mconfig, *this), m_mseint_handler(*this), diff --git a/src/devices/bus/samcoupe/mouse/mouseport.h b/src/devices/bus/samcoupe/mouse/mouseport.h index 92943f39a7c..6e73bb9b6c1 100644 --- a/src/devices/bus/samcoupe/mouse/mouseport.h +++ b/src/devices/bus/samcoupe/mouse/mouseport.h @@ -37,7 +37,7 @@ public: // construction/destruction template <typename T> samcoupe_mouse_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts) - : samcoupe_mouse_port_device(mconfig, tag, owner, uint32_t(0)) + : samcoupe_mouse_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -45,7 +45,7 @@ public: set_fixed(false); } - samcoupe_mouse_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + samcoupe_mouse_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~samcoupe_mouse_port_device(); // callbacks diff --git a/src/devices/bus/sat_ctrl/analog.cpp b/src/devices/bus/sat_ctrl/analog.cpp index 6e513b18d47..794348ade35 100644 --- a/src/devices/bus/sat_ctrl/analog.cpp +++ b/src/devices/bus/sat_ctrl/analog.cpp @@ -63,7 +63,7 @@ ioport_constructor saturn_analog_device::device_input_ports() const // saturn_analog_device - constructor //------------------------------------------------- -saturn_analog_device::saturn_analog_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saturn_analog_device::saturn_analog_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_ANALOG, tag, owner, clock), device_saturn_control_port_interface(mconfig, *this), m_joy(*this, "JOY"), diff --git a/src/devices/bus/sat_ctrl/analog.h b/src/devices/bus/sat_ctrl/analog.h index d86313e59a1..b6cddd3b4d5 100644 --- a/src/devices/bus/sat_ctrl/analog.h +++ b/src/devices/bus/sat_ctrl/analog.h @@ -25,7 +25,7 @@ class saturn_analog_device : public device_t, { public: // construction/destruction - saturn_analog_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_analog_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sat_ctrl/ctrl.cpp b/src/devices/bus/sat_ctrl/ctrl.cpp index aeff9244cc8..8b3dc45a800 100644 --- a/src/devices/bus/sat_ctrl/ctrl.cpp +++ b/src/devices/bus/sat_ctrl/ctrl.cpp @@ -60,7 +60,7 @@ device_saturn_control_port_interface::~device_saturn_control_port_interface() // saturn_control_port_device - constructor //------------------------------------------------- -saturn_control_port_device::saturn_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saturn_control_port_device::saturn_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_CONTROL_PORT, tag, owner, clock), device_single_card_slot_interface<device_saturn_control_port_interface>(mconfig, *this), m_device(nullptr) diff --git a/src/devices/bus/sat_ctrl/ctrl.h b/src/devices/bus/sat_ctrl/ctrl.h index d17bed9b067..88a5a9fe9c0 100644 --- a/src/devices/bus/sat_ctrl/ctrl.h +++ b/src/devices/bus/sat_ctrl/ctrl.h @@ -46,7 +46,7 @@ public: // construction/destruction template <typename T> saturn_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, char const* dflt) - : saturn_control_port_device(mconfig, tag, owner, (uint32_t)0) + : saturn_control_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -54,7 +54,7 @@ public: set_fixed(false); } - saturn_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + saturn_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~saturn_control_port_device(); uint16_t read_direct(); diff --git a/src/devices/bus/sat_ctrl/joy.cpp b/src/devices/bus/sat_ctrl/joy.cpp index f44b0f6b4ee..b98b6e7e53d 100644 --- a/src/devices/bus/sat_ctrl/joy.cpp +++ b/src/devices/bus/sat_ctrl/joy.cpp @@ -54,7 +54,7 @@ ioport_constructor saturn_joy_device::device_input_ports() const // saturn_joy_device - constructor //------------------------------------------------- -saturn_joy_device::saturn_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saturn_joy_device::saturn_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_JOY, tag, owner, clock), device_saturn_control_port_interface(mconfig, *this), m_joy(*this, "JOY") diff --git a/src/devices/bus/sat_ctrl/joy.h b/src/devices/bus/sat_ctrl/joy.h index b4e124fc034..9f4775f9ce6 100644 --- a/src/devices/bus/sat_ctrl/joy.h +++ b/src/devices/bus/sat_ctrl/joy.h @@ -25,7 +25,7 @@ class saturn_joy_device : public device_t, { public: // construction/destruction - saturn_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_joy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sat_ctrl/joy_md.cpp b/src/devices/bus/sat_ctrl/joy_md.cpp index 987dffcf528..9db15d42fb9 100644 --- a/src/devices/bus/sat_ctrl/joy_md.cpp +++ b/src/devices/bus/sat_ctrl/joy_md.cpp @@ -70,7 +70,7 @@ ioport_constructor saturn_joymd6b_device::device_input_ports() const // constructors //------------------------------------------------- -saturn_joymd3b_device::saturn_joymd3b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saturn_joymd3b_device::saturn_joymd3b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_JOYMD3B, tag, owner, clock), device_saturn_control_port_interface(mconfig, *this), m_joy(*this, "JOY") @@ -79,7 +79,7 @@ saturn_joymd3b_device::saturn_joymd3b_device(const machine_config &mconfig, cons } -saturn_joymd6b_device::saturn_joymd6b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saturn_joymd6b_device::saturn_joymd6b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_JOYMD6B, tag, owner, clock), device_saturn_control_port_interface(mconfig, *this), m_joy(*this, "JOY") diff --git a/src/devices/bus/sat_ctrl/joy_md.h b/src/devices/bus/sat_ctrl/joy_md.h index 845c6bce9da..9ccf2905f10 100644 --- a/src/devices/bus/sat_ctrl/joy_md.h +++ b/src/devices/bus/sat_ctrl/joy_md.h @@ -25,7 +25,7 @@ class saturn_joymd3b_device : public device_t, { public: // construction/destruction - saturn_joymd3b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_joymd3b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; @@ -52,7 +52,7 @@ class saturn_joymd6b_device : public device_t, { public: // construction/destruction - saturn_joymd6b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_joymd6b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sat_ctrl/keybd.cpp b/src/devices/bus/sat_ctrl/keybd.cpp index 3ab0d8dc4ab..8fa1486a4e3 100644 --- a/src/devices/bus/sat_ctrl/keybd.cpp +++ b/src/devices/bus/sat_ctrl/keybd.cpp @@ -206,7 +206,7 @@ ioport_constructor saturn_keybd_device::device_input_ports() const // saturn_keybd_device - constructor //------------------------------------------------- -saturn_keybd_device::saturn_keybd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saturn_keybd_device::saturn_keybd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_KEYBD, tag, owner, clock), device_saturn_control_port_interface(mconfig, *this), m_key(*this, "KEY.%u", 0), diff --git a/src/devices/bus/sat_ctrl/keybd.h b/src/devices/bus/sat_ctrl/keybd.h index dafb932974c..1011763826d 100644 --- a/src/devices/bus/sat_ctrl/keybd.h +++ b/src/devices/bus/sat_ctrl/keybd.h @@ -25,7 +25,7 @@ class saturn_keybd_device : public device_t, { public: // construction/destruction - saturn_keybd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_keybd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sat_ctrl/mouse.cpp b/src/devices/bus/sat_ctrl/mouse.cpp index acef9feb8fd..12607c84758 100644 --- a/src/devices/bus/sat_ctrl/mouse.cpp +++ b/src/devices/bus/sat_ctrl/mouse.cpp @@ -51,7 +51,7 @@ ioport_constructor saturn_mouse_device::device_input_ports() const // saturn_mouse_device - constructor //------------------------------------------------- -saturn_mouse_device::saturn_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saturn_mouse_device::saturn_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_MOUSE, tag, owner, clock), device_saturn_control_port_interface(mconfig, *this), m_pointx(*this, "MOUSE_X"), diff --git a/src/devices/bus/sat_ctrl/mouse.h b/src/devices/bus/sat_ctrl/mouse.h index 2b896ca6b49..28b80e494eb 100644 --- a/src/devices/bus/sat_ctrl/mouse.h +++ b/src/devices/bus/sat_ctrl/mouse.h @@ -25,7 +25,7 @@ class saturn_mouse_device : public device_t, { public: // construction/destruction - saturn_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sat_ctrl/multitap.cpp b/src/devices/bus/sat_ctrl/multitap.cpp index 71eacdf0053..04a5075982d 100644 --- a/src/devices/bus/sat_ctrl/multitap.cpp +++ b/src/devices/bus/sat_ctrl/multitap.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(SATURN_MULTITAP, saturn_multitap_device, "saturn_multitap", " // LIVE DEVICE //************************************************************************** -saturn_multitap_device::saturn_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saturn_multitap_device::saturn_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_MULTITAP, tag, owner, clock) , device_saturn_control_port_interface(mconfig, *this) , m_subctrl_port(*this, "ctrl%u", 1U) diff --git a/src/devices/bus/sat_ctrl/multitap.h b/src/devices/bus/sat_ctrl/multitap.h index 5aa98dacf3b..62091210e10 100644 --- a/src/devices/bus/sat_ctrl/multitap.h +++ b/src/devices/bus/sat_ctrl/multitap.h @@ -23,7 +23,7 @@ class saturn_multitap_device : public device_t, public device_saturn_control_por { public: // construction/destruction - saturn_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/sat_ctrl/pointer.cpp b/src/devices/bus/sat_ctrl/pointer.cpp index 10eceae1a2d..79900245e2f 100644 --- a/src/devices/bus/sat_ctrl/pointer.cpp +++ b/src/devices/bus/sat_ctrl/pointer.cpp @@ -51,7 +51,7 @@ ioport_constructor saturn_track_device::device_input_ports() const // saturn_track_device - constructor //------------------------------------------------- -saturn_track_device::saturn_track_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saturn_track_device::saturn_track_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_TRACK, tag, owner, clock), device_saturn_control_port_interface(mconfig, *this), m_pointx(*this, "POINT_X"), diff --git a/src/devices/bus/sat_ctrl/pointer.h b/src/devices/bus/sat_ctrl/pointer.h index 869455706ef..0bfdcdf5581 100644 --- a/src/devices/bus/sat_ctrl/pointer.h +++ b/src/devices/bus/sat_ctrl/pointer.h @@ -25,7 +25,7 @@ class saturn_track_device : public device_t, { public: // construction/destruction - saturn_track_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_track_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sat_ctrl/racing.cpp b/src/devices/bus/sat_ctrl/racing.cpp index 91444de2b6a..c7ea15801ce 100644 --- a/src/devices/bus/sat_ctrl/racing.cpp +++ b/src/devices/bus/sat_ctrl/racing.cpp @@ -57,7 +57,7 @@ ioport_constructor saturn_wheel_device::device_input_ports() const // saturn_wheel_device - constructor //------------------------------------------------- -saturn_wheel_device::saturn_wheel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saturn_wheel_device::saturn_wheel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_WHEEL, tag, owner, clock), device_saturn_control_port_interface(mconfig, *this), m_joy(*this, "JOY"), diff --git a/src/devices/bus/sat_ctrl/racing.h b/src/devices/bus/sat_ctrl/racing.h index 9f426c9ef51..de09eda8c7d 100644 --- a/src/devices/bus/sat_ctrl/racing.h +++ b/src/devices/bus/sat_ctrl/racing.h @@ -25,7 +25,7 @@ class saturn_wheel_device : public device_t, { public: // construction/destruction - saturn_wheel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_wheel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sat_ctrl/segatap.cpp b/src/devices/bus/sat_ctrl/segatap.cpp index baaa52071ed..8591daa4491 100644 --- a/src/devices/bus/sat_ctrl/segatap.cpp +++ b/src/devices/bus/sat_ctrl/segatap.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(SATURN_SEGATAP, saturn_segatap_device, "saturn_segatap", "sat // LIVE DEVICE //************************************************************************** -saturn_segatap_device::saturn_segatap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saturn_segatap_device::saturn_segatap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_SEGATAP, tag, owner, clock) , device_saturn_control_port_interface(mconfig, *this) , m_subctrl_port(*this, "ctrl%u", 1U) diff --git a/src/devices/bus/sat_ctrl/segatap.h b/src/devices/bus/sat_ctrl/segatap.h index 799d4d8356a..d0b0d166c94 100644 --- a/src/devices/bus/sat_ctrl/segatap.h +++ b/src/devices/bus/sat_ctrl/segatap.h @@ -24,7 +24,7 @@ class saturn_segatap_device : public device_t, public device_saturn_control_port { public: // construction/destruction - saturn_segatap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_segatap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/saturn/bram.cpp b/src/devices/bus/saturn/bram.cpp index 604948343ed..d6854366eb1 100644 --- a/src/devices/bus/saturn/bram.cpp +++ b/src/devices/bus/saturn/bram.cpp @@ -21,29 +21,29 @@ DEFINE_DEVICE_TYPE(SATURN_BRAM_16MB, saturn_bram16mb_device, "sat_bram_16mb", "S DEFINE_DEVICE_TYPE(SATURN_BRAM_32MB, saturn_bram32mb_device, "sat_bram_32mb", "Saturn Battery RAM 32Mbit Cart") -saturn_bram_device::saturn_bram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int cart_type) +saturn_bram_device::saturn_bram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cart_type) : device_t(mconfig, type, tag, owner, clock) , device_sat_cart_interface(mconfig, *this, cart_type) , device_nvram_interface(mconfig, *this) { } -saturn_bram4mb_device::saturn_bram4mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saturn_bram4mb_device::saturn_bram4mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saturn_bram_device(mconfig, SATURN_BRAM_4MB, tag, owner, clock, 0x21) { } -saturn_bram8mb_device::saturn_bram8mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saturn_bram8mb_device::saturn_bram8mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saturn_bram_device(mconfig, SATURN_BRAM_8MB, tag, owner, clock, 0x22) { } -saturn_bram16mb_device::saturn_bram16mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saturn_bram16mb_device::saturn_bram16mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saturn_bram_device(mconfig, SATURN_BRAM_16MB, tag, owner, clock, 0x23) { } -saturn_bram32mb_device::saturn_bram32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saturn_bram32mb_device::saturn_bram32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saturn_bram_device(mconfig, SATURN_BRAM_32MB, tag, owner, clock, 0x24) { } diff --git a/src/devices/bus/saturn/bram.h b/src/devices/bus/saturn/bram.h index 97e419b19fd..873f0c75711 100644 --- a/src/devices/bus/saturn/bram.h +++ b/src/devices/bus/saturn/bram.h @@ -19,7 +19,7 @@ public: protected: // construction/destruction - saturn_bram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int cart_type); + saturn_bram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cart_type); // device-level overrides virtual void device_start() override; @@ -35,28 +35,28 @@ class saturn_bram4mb_device : public saturn_bram_device { public: // construction/destruction - saturn_bram4mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_bram4mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class saturn_bram8mb_device : public saturn_bram_device { public: // construction/destruction - saturn_bram8mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_bram8mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class saturn_bram16mb_device : public saturn_bram_device { public: // construction/destruction - saturn_bram16mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_bram16mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class saturn_bram32mb_device : public saturn_bram_device { public: // construction/destruction - saturn_bram32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_bram32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/saturn/dram.cpp b/src/devices/bus/saturn/dram.cpp index c0380752aea..0cb154ee7f5 100644 --- a/src/devices/bus/saturn/dram.cpp +++ b/src/devices/bus/saturn/dram.cpp @@ -19,18 +19,18 @@ DEFINE_DEVICE_TYPE(SATURN_DRAM_8MB, saturn_dram8mb_device, "sat_dram_8mb", "S DEFINE_DEVICE_TYPE(SATURN_DRAM_32MB, saturn_dram32mb_device, "sat_dram_32mb", "Saturn Data RAM 32Mbit Cart") -saturn_dram_device::saturn_dram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int cart_type) +saturn_dram_device::saturn_dram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cart_type) : device_t(mconfig, type, tag, owner, clock) , device_sat_cart_interface(mconfig, *this, cart_type) { } -saturn_dram8mb_device::saturn_dram8mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saturn_dram8mb_device::saturn_dram8mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saturn_dram_device(mconfig, SATURN_DRAM_8MB, tag, owner, clock, 0x5a) { } -saturn_dram32mb_device::saturn_dram32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saturn_dram32mb_device::saturn_dram32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saturn_dram_device(mconfig, SATURN_DRAM_32MB, tag, owner, clock, 0x5c) { } diff --git a/src/devices/bus/saturn/dram.h b/src/devices/bus/saturn/dram.h index 847c90a9955..8cebdf86f88 100644 --- a/src/devices/bus/saturn/dram.h +++ b/src/devices/bus/saturn/dram.h @@ -20,7 +20,7 @@ public: protected: // construction/destruction - saturn_dram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int cart_type); + saturn_dram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cart_type); // device-level overrides virtual void device_start() override; @@ -31,14 +31,14 @@ class saturn_dram8mb_device : public saturn_dram_device { public: // construction/destruction - saturn_dram8mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_dram8mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class saturn_dram32mb_device : public saturn_dram_device { public: // construction/destruction - saturn_dram32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_dram32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/saturn/rom.cpp b/src/devices/bus/saturn/rom.cpp index 5853a7b4bdb..38a437214a3 100644 --- a/src/devices/bus/saturn/rom.cpp +++ b/src/devices/bus/saturn/rom.cpp @@ -18,13 +18,13 @@ DEFINE_DEVICE_TYPE(SATURN_ROM, saturn_rom_device, "sat_rom", "Saturn ROM Carts") -saturn_rom_device::saturn_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int cart_type) +saturn_rom_device::saturn_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cart_type) : device_t(mconfig, type, tag, owner, clock) , device_sat_cart_interface(mconfig, *this, cart_type) { } -saturn_rom_device::saturn_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saturn_rom_device::saturn_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saturn_rom_device(mconfig, SATURN_ROM, tag, owner, clock, 0xff) // actually not clear if ROM carts have a type ID like DRAM/BRAM carts { } diff --git a/src/devices/bus/saturn/rom.h b/src/devices/bus/saturn/rom.h index 0706a74a420..ee77b98bb29 100644 --- a/src/devices/bus/saturn/rom.h +++ b/src/devices/bus/saturn/rom.h @@ -12,13 +12,13 @@ class saturn_rom_device : public device_t, public device_sat_cart_interface { public: // construction/destruction - saturn_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint32_t read_rom(offs_t offset) override; protected: - saturn_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int cart_type); + saturn_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cart_type); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/saturn/sat_slot.cpp b/src/devices/bus/saturn/sat_slot.cpp index 975a67403f0..cd8dc9c0026 100644 --- a/src/devices/bus/saturn/sat_slot.cpp +++ b/src/devices/bus/saturn/sat_slot.cpp @@ -102,7 +102,7 @@ void device_sat_cart_interface::dram1_alloc(uint32_t size) //------------------------------------------------- // sat_cart_slot_device - constructor //------------------------------------------------- -sat_cart_slot_device::sat_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sat_cart_slot_device::sat_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SATURN_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_sat_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/saturn/sat_slot.h b/src/devices/bus/saturn/sat_slot.h index 0a501866374..57a3dd33ae3 100644 --- a/src/devices/bus/saturn/sat_slot.h +++ b/src/devices/bus/saturn/sat_slot.h @@ -69,14 +69,14 @@ public: // construction/destruction template <typename T> sat_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : sat_cart_slot_device(mconfig, tag, owner, 0) + : sat_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sat_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sat_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~sat_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/sbus/artecon.cpp b/src/devices/bus/sbus/artecon.cpp index 0117ec12cd9..6f24ad471e5 100644 --- a/src/devices/bus/sbus/artecon.cpp +++ b/src/devices/bus/sbus/artecon.cpp @@ -39,7 +39,7 @@ void sbus_artecon_device::device_add_mconfig(machine_config &config) } -sbus_artecon_device::sbus_artecon_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sbus_artecon_device::sbus_artecon_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SBUS_SB300P, tag, owner, clock) , device_sbus_card_interface(mconfig, *this) , m_rom(*this, "prom") diff --git a/src/devices/bus/sbus/artecon.h b/src/devices/bus/sbus/artecon.h index 9b0d9a4cbbb..cb4c39b2b44 100644 --- a/src/devices/bus/sbus/artecon.h +++ b/src/devices/bus/sbus/artecon.h @@ -18,7 +18,7 @@ class sbus_artecon_device : public device_t, public device_sbus_card_interface { public: // construction/destruction - sbus_artecon_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sbus_artecon_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/sbus/bwtwo.cpp b/src/devices/bus/sbus/bwtwo.cpp index c034d43e05f..422d55e307f 100644 --- a/src/devices/bus/sbus/bwtwo.cpp +++ b/src/devices/bus/sbus/bwtwo.cpp @@ -46,7 +46,7 @@ void sbus_bwtwo_device::device_add_mconfig(machine_config &config) } -sbus_bwtwo_device::sbus_bwtwo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sbus_bwtwo_device::sbus_bwtwo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SBUS_BWTWO, tag, owner, clock) , device_sbus_card_interface(mconfig, *this) , m_rom(*this, "prom") diff --git a/src/devices/bus/sbus/bwtwo.h b/src/devices/bus/sbus/bwtwo.h index d307f16f977..3296f2ca9b8 100644 --- a/src/devices/bus/sbus/bwtwo.h +++ b/src/devices/bus/sbus/bwtwo.h @@ -18,7 +18,7 @@ class sbus_bwtwo_device : public device_t, public device_sbus_card_interface { public: // construction/destruction - sbus_bwtwo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sbus_bwtwo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/sbus/cgsix.cpp b/src/devices/bus/sbus/cgsix.cpp index 4ae3301c285..319778513d4 100644 --- a/src/devices/bus/sbus/cgsix.cpp +++ b/src/devices/bus/sbus/cgsix.cpp @@ -28,7 +28,7 @@ void sbus_cgsix_device::base_map(address_map &map) map(0x00700000, 0x00700fff).rw(FUNC(sbus_cgsix_device::fbc_r), FUNC(sbus_cgsix_device::fbc_w)); } -sbus_cgsix_device::sbus_cgsix_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sbus_cgsix_device::sbus_cgsix_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sbus_card_interface(mconfig, *this) , m_rom(*this, "prom") @@ -1322,10 +1322,10 @@ void sbus_turbogx_device::device_add_mconfig(machine_config &config) m_screen->set_raw(105.561_MHz_XTAL, 1472, 0, 1152, 943, 0, 900); m_screen->screen_vblank().set(FUNC(sbus_turbogx_device::vblank_w)); - BT458(config, m_ramdac, 0); + BT458(config, m_ramdac); } -sbus_turbogx_device::sbus_turbogx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sbus_turbogx_device::sbus_turbogx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sbus_cgsix_device(mconfig, SBUS_TURBOGX, tag, owner, clock, 0x100000) { } @@ -1364,10 +1364,10 @@ void sbus_turbogxp_device::device_add_mconfig(machine_config &config) m_screen->set_refresh_hz(72); m_screen->screen_vblank().set(FUNC(sbus_turbogxp_device::vblank_w)); - BT467(config, m_ramdac, 0); + BT467(config, m_ramdac); } -sbus_turbogxp_device::sbus_turbogxp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sbus_turbogxp_device::sbus_turbogxp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sbus_cgsix_device(mconfig, SBUS_TURBOGXP, tag, owner, clock, 0x400000) { } diff --git a/src/devices/bus/sbus/cgsix.h b/src/devices/bus/sbus/cgsix.h index b6f3fe7520d..096add5dae6 100644 --- a/src/devices/bus/sbus/cgsix.h +++ b/src/devices/bus/sbus/cgsix.h @@ -22,13 +22,13 @@ public: protected: // construction/destruction - sbus_cgsix_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const uint32_t vram_size) + sbus_cgsix_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const uint32_t vram_size) : sbus_cgsix_device(mconfig, type, tag, owner, clock) { set_vram_size(vram_size); } - sbus_cgsix_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sbus_cgsix_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // configuration void set_vram_size(uint32_t vram_size) { m_vram_size = vram_size; } @@ -520,7 +520,7 @@ protected: class sbus_turbogx_device : public sbus_cgsix_device { public: - sbus_turbogx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sbus_turbogx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides @@ -536,7 +536,7 @@ protected: class sbus_turbogxp_device : public sbus_cgsix_device { public: - sbus_turbogxp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sbus_turbogxp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/sbus/cgthree.cpp b/src/devices/bus/sbus/cgthree.cpp index 2ca7e930c04..ebd57c13c2a 100644 --- a/src/devices/bus/sbus/cgthree.cpp +++ b/src/devices/bus/sbus/cgthree.cpp @@ -38,10 +38,10 @@ void sbus_cgthree_device::device_add_mconfig(machine_config &config) m_screen->set_screen_update(FUNC(sbus_cgthree_device::screen_update)); m_screen->set_raw(92.9405_MHz_XTAL, 1504, 0, 1152, 937, 0, 900); - BT458(config, m_ramdac, 0); + BT458(config, m_ramdac); } -sbus_cgthree_device::sbus_cgthree_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sbus_cgthree_device::sbus_cgthree_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SBUS_CGTHREE, tag, owner, clock) , device_sbus_card_interface(mconfig, *this) , m_rom(*this, "prom") diff --git a/src/devices/bus/sbus/cgthree.h b/src/devices/bus/sbus/cgthree.h index d95a104aef5..741051f66b9 100644 --- a/src/devices/bus/sbus/cgthree.h +++ b/src/devices/bus/sbus/cgthree.h @@ -20,7 +20,7 @@ public: static constexpr feature_type imperfect_features() { return feature::GRAPHICS; } // construction/destruction - sbus_cgthree_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sbus_cgthree_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/sbus/hme.cpp b/src/devices/bus/sbus/hme.cpp index b11354f8e1e..a37de672eef 100644 --- a/src/devices/bus/sbus/hme.cpp +++ b/src/devices/bus/sbus/hme.cpp @@ -38,7 +38,7 @@ void sbus_hme_device::device_add_mconfig(machine_config &config) } -sbus_hme_device::sbus_hme_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sbus_hme_device::sbus_hme_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SBUS_HME, tag, owner, clock) , device_sbus_card_interface(mconfig, *this) , m_rom(*this, "prom") diff --git a/src/devices/bus/sbus/hme.h b/src/devices/bus/sbus/hme.h index fde0571c755..b996272a259 100644 --- a/src/devices/bus/sbus/hme.h +++ b/src/devices/bus/sbus/hme.h @@ -18,7 +18,7 @@ class sbus_hme_device : public device_t, public device_sbus_card_interface { public: // construction/destruction - sbus_hme_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sbus_hme_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/sbus/sbus.cpp b/src/devices/bus/sbus/sbus.cpp index 6640509d3ec..aa4766cab39 100644 --- a/src/devices/bus/sbus/sbus.cpp +++ b/src/devices/bus/sbus/sbus.cpp @@ -35,12 +35,12 @@ void sbus_cards(device_slot_interface &device) DEFINE_DEVICE_TYPE(SBUS_SLOT, sbus_slot_device, "sbus_slot", "Sun SBus Slot") -sbus_slot_device::sbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sbus_slot_device::sbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sbus_slot_device(mconfig, SBUS_SLOT, tag, owner, clock) { } -sbus_slot_device::sbus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sbus_slot_device::sbus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_single_card_slot_interface<device_sbus_card_interface>(mconfig, *this) , m_sbus(*this, finder_base::DUMMY_TAG) @@ -75,12 +75,12 @@ device_memory_interface::space_config_vector sbus_device::memory_space_config() }; } -sbus_device::sbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sbus_device::sbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sbus_device(mconfig, SBUS, tag, owner, clock) { } -sbus_device::sbus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sbus_device::sbus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_space_config("sbus", ENDIANNESS_BIG, 32, 32, 0, address_map_constructor()) diff --git a/src/devices/bus/sbus/sbus.h b/src/devices/bus/sbus/sbus.h index 2c66318c8aa..df8674d4a7f 100644 --- a/src/devices/bus/sbus/sbus.h +++ b/src/devices/bus/sbus/sbus.h @@ -23,7 +23,7 @@ class sbus_slot_device : public device_t, public device_single_card_slot_interfa public: // construction/destruction template <typename T, typename U> - sbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&sbus_tag, int slot, U &&opts, const char *dflt, bool fixed = false) + sbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&sbus_tag, int slot, U &&opts, const char *dflt, bool fixed = false) : sbus_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -33,10 +33,10 @@ public: m_sbus.set_tag(std::forward<T>(sbus_tag)); m_slot = slot; } - sbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - sbus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sbus_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_validity_check(validity_checker &valid) const override; @@ -58,14 +58,14 @@ class sbus_device : public device_t, public: // construction/destruction template <typename T, typename U> - sbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, U &&space_tag, int space_num) + sbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, U &&space_tag, int space_num) : sbus_device(mconfig, tag, owner, clock) { set_cpu(std::forward<T>(cpu_tag)); set_type1space(std::forward<U>(space_tag), space_num); } - sbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration template <typename T> void set_cpu(T &&tag) { m_maincpu.set_tag(std::forward<T>(tag)); } @@ -91,7 +91,7 @@ public: void write(offs_t offset, uint32_t data, uint32_t mem_mask = ~0); protected: - sbus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sbus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; diff --git a/src/devices/bus/sbus/sunpc.cpp b/src/devices/bus/sbus/sunpc.cpp index bfb88b4726f..7968e6d405d 100644 --- a/src/devices/bus/sbus/sunpc.cpp +++ b/src/devices/bus/sbus/sunpc.cpp @@ -38,7 +38,7 @@ void sbus_sunpc_device::device_add_mconfig(machine_config &config) } -sbus_sunpc_device::sbus_sunpc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sbus_sunpc_device::sbus_sunpc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SBUS_SUNPC, tag, owner, clock) , device_sbus_card_interface(mconfig, *this) , m_rom(*this, "prom") diff --git a/src/devices/bus/sbus/sunpc.h b/src/devices/bus/sbus/sunpc.h index 951b0c6f7d6..6c41d38b70b 100644 --- a/src/devices/bus/sbus/sunpc.h +++ b/src/devices/bus/sbus/sunpc.h @@ -18,7 +18,7 @@ class sbus_sunpc_device : public device_t, public device_sbus_card_interface { public: // construction/destruction - sbus_sunpc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sbus_sunpc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/scsi/acb4070.cpp b/src/devices/bus/scsi/acb4070.cpp index 0b9e67b438f..3c4886d2da3 100644 --- a/src/devices/bus/scsi/acb4070.cpp +++ b/src/devices/bus/scsi/acb4070.cpp @@ -11,7 +11,7 @@ // device type definition DEFINE_DEVICE_TYPE(ACB4070, acb4070_device, "acb4070", "ACB4070") -acb4070_device::acb4070_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acb4070_device::acb4070_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsihd_device(mconfig, ACB4070, tag, owner, clock) { } diff --git a/src/devices/bus/scsi/acb4070.h b/src/devices/bus/scsi/acb4070.h index 848798152a5..d0fd4f4fa8f 100644 --- a/src/devices/bus/scsi/acb4070.h +++ b/src/devices/bus/scsi/acb4070.h @@ -11,7 +11,7 @@ class acb4070_device : public scsihd_device { public: // construction/destruction - acb4070_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acb4070_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void ExecCommand() override; virtual void WriteData( uint8_t *data, int dataLength ) override; diff --git a/src/devices/bus/scsi/cdu76s.cpp b/src/devices/bus/scsi/cdu76s.cpp index 01860e7f31c..e4e581efe5e 100644 --- a/src/devices/bus/scsi/cdu76s.cpp +++ b/src/devices/bus/scsi/cdu76s.cpp @@ -42,7 +42,7 @@ void sony_cdu76s_device::ReadData( uint8_t *data, int dataLength ) // device type definition DEFINE_DEVICE_TYPE(CDU76S, sony_cdu76s_device, "cdu76s", "Sony CDU-76S") -sony_cdu76s_device::sony_cdu76s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sony_cdu76s_device::sony_cdu76s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsicd_device(mconfig, CDU76S, tag, owner, clock) { } diff --git a/src/devices/bus/scsi/cdu76s.h b/src/devices/bus/scsi/cdu76s.h index 7eb6f7487ea..6d0ab4ef5cc 100644 --- a/src/devices/bus/scsi/cdu76s.h +++ b/src/devices/bus/scsi/cdu76s.h @@ -19,7 +19,7 @@ class sony_cdu76s_device : public scsicd_device { public: - sony_cdu76s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sony_cdu76s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void ExecCommand() override; virtual void ReadData( uint8_t *data, int dataLength ) override; diff --git a/src/devices/bus/scsi/d9060hd.cpp b/src/devices/bus/scsi/d9060hd.cpp index 1d7ee7e503d..4b41a8f2c14 100644 --- a/src/devices/bus/scsi/d9060hd.cpp +++ b/src/devices/bus/scsi/d9060hd.cpp @@ -11,7 +11,7 @@ // device type definition DEFINE_DEVICE_TYPE(D9060HD, d9060hd_device, "d9060hd", "D9060HD") -d9060hd_device::d9060hd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +d9060hd_device::d9060hd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsihd_device(mconfig, D9060HD, tag, owner, clock) { } diff --git a/src/devices/bus/scsi/d9060hd.h b/src/devices/bus/scsi/d9060hd.h index 3e7140e74cd..3bf3091fceb 100644 --- a/src/devices/bus/scsi/d9060hd.h +++ b/src/devices/bus/scsi/d9060hd.h @@ -11,7 +11,7 @@ class d9060hd_device : public scsihd_device { public: // construction/destruction - d9060hd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + d9060hd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void ExecCommand() override; }; diff --git a/src/devices/bus/scsi/omti5100.cpp b/src/devices/bus/scsi/omti5100.cpp index a76893fd12c..df75fa490bc 100644 --- a/src/devices/bus/scsi/omti5100.cpp +++ b/src/devices/bus/scsi/omti5100.cpp @@ -24,7 +24,7 @@ const tiny_rom_entry *omti5100_device::device_rom_region() const } #endif -omti5100_device::omti5100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +omti5100_device::omti5100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsihd_device(mconfig, OMTI5100, tag, owner, clock) , m_image0(*this, "image0") , m_image1(*this, "image1") diff --git a/src/devices/bus/scsi/omti5100.h b/src/devices/bus/scsi/omti5100.h index 4b1e1dda59a..fcccc2bc9a7 100644 --- a/src/devices/bus/scsi/omti5100.h +++ b/src/devices/bus/scsi/omti5100.h @@ -10,7 +10,7 @@ class omti5100_device : public scsihd_device { public: - omti5100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + omti5100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void ExecCommand() override; virtual void ReadData( uint8_t *data, int dataLength ) override; diff --git a/src/devices/bus/scsi/pc9801_sasi.cpp b/src/devices/bus/scsi/pc9801_sasi.cpp index b7c93f98094..03a51c8b199 100644 --- a/src/devices/bus/scsi/pc9801_sasi.cpp +++ b/src/devices/bus/scsi/pc9801_sasi.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(PC9801_SASI, pc9801_sasi_device, "pc9801_sasi", "PC9801 SASI Controller") -pc9801_sasi_device::pc9801_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc9801_sasi_device::pc9801_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsihd_device(mconfig, PC9801_SASI, tag, owner, clock) { } diff --git a/src/devices/bus/scsi/pc9801_sasi.h b/src/devices/bus/scsi/pc9801_sasi.h index 773de463c61..34b7c2d1b07 100644 --- a/src/devices/bus/scsi/pc9801_sasi.h +++ b/src/devices/bus/scsi/pc9801_sasi.h @@ -9,7 +9,7 @@ class pc9801_sasi_device : public scsihd_device { public: // construction/destruction - pc9801_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc9801_sasi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void ExecCommand() override; }; diff --git a/src/devices/bus/scsi/s1410.cpp b/src/devices/bus/scsi/s1410.cpp index 0aec38db1b2..eddb80fe4bc 100644 --- a/src/devices/bus/scsi/s1410.cpp +++ b/src/devices/bus/scsi/s1410.cpp @@ -186,7 +186,7 @@ void s1410_device::device_add_mconfig(machine_config &config) // s1410_device - constructor //------------------------------------------------- -s1410_device::s1410_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s1410_device::s1410_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsihd_device(mconfig, S1410, tag, owner, clock) { } diff --git a/src/devices/bus/scsi/s1410.h b/src/devices/bus/scsi/s1410.h index 03ec288b76a..27de1531d64 100644 --- a/src/devices/bus/scsi/s1410.h +++ b/src/devices/bus/scsi/s1410.h @@ -17,7 +17,7 @@ class s1410_device : public scsihd_device { public: // construction/destruction - s1410_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s1410_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/scsi/sa1403d.cpp b/src/devices/bus/scsi/sa1403d.cpp index 5ab22288835..029f0298905 100644 --- a/src/devices/bus/scsi/sa1403d.cpp +++ b/src/devices/bus/scsi/sa1403d.cpp @@ -113,7 +113,7 @@ ioport_constructor sa1403d_device::device_input_ports() const // sa1403d_device - constructor //------------------------------------------------- -sa1403d_device::sa1403d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sa1403d_device::sa1403d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsihd_device(mconfig, SA1403D, tag, owner, clock) { } diff --git a/src/devices/bus/scsi/sa1403d.h b/src/devices/bus/scsi/sa1403d.h index f4b229d6514..b7ba6c0c409 100644 --- a/src/devices/bus/scsi/sa1403d.h +++ b/src/devices/bus/scsi/sa1403d.h @@ -18,7 +18,7 @@ class sa1403d_device : public scsihd_device { public: // construction/destruction - sa1403d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sa1403d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void ExecCommand() override; virtual void WriteData( uint8_t *data, int dataLength ) override; diff --git a/src/devices/bus/scsi/scsi.cpp b/src/devices/bus/scsi/scsi.cpp index a4477483766..3646fd36c32 100644 --- a/src/devices/bus/scsi/scsi.cpp +++ b/src/devices/bus/scsi/scsi.cpp @@ -4,7 +4,7 @@ #include "emu.h" #include "scsi.h" -scsi_port_device::scsi_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +scsi_port_device::scsi_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SCSI_PORT, tag, owner, clock), m_bsy_handler(*this), m_sel_handler(*this), @@ -671,7 +671,7 @@ void scsi_port_device::set_output_latch(output_latch_device &latch) DEFINE_DEVICE_TYPE(SCSI_PORT, scsi_port_device, "scsi", "SCSI Port") -scsi_port_slot_device::scsi_port_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +scsi_port_slot_device::scsi_port_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SCSI_PORT_SLOT, tag, owner, clock), device_single_card_slot_interface<scsi_port_interface>(mconfig, *this), m_dev(nullptr), diff --git a/src/devices/bus/scsi/scsi.h b/src/devices/bus/scsi/scsi.h index 07e64d5f102..01f72064c0d 100644 --- a/src/devices/bus/scsi/scsi.h +++ b/src/devices/bus/scsi/scsi.h @@ -27,7 +27,7 @@ class scsi_port_device : public device_t public: // construction/destruction - scsi_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + scsi_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto bsy_handler() { return m_bsy_handler.bind(); } auto sel_handler() { return m_sel_handler.bind(); } @@ -174,7 +174,7 @@ class scsi_port_slot_device : public device_t, public device_single_card_slot_in friend class scsi_port_interface; public: - scsi_port_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + scsi_port_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); scsi_port_interface *dev() { return m_dev; } scsi_port_device *port() { return m_port; } diff --git a/src/devices/bus/scsi/scsicd.cpp b/src/devices/bus/scsi/scsicd.cpp index 0f577ea44d3..4bad210f21f 100644 --- a/src/devices/bus/scsi/scsicd.cpp +++ b/src/devices/bus/scsi/scsicd.cpp @@ -12,12 +12,12 @@ // device type definition DEFINE_DEVICE_TYPE(SCSICD, scsicd_device, "scsicd", "SCSI CD") -scsicd_device::scsicd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +scsicd_device::scsicd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsicd_device(mconfig, SCSICD, tag, owner, clock) { } -scsicd_device::scsicd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +scsicd_device::scsicd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : scsihle_device(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/bus/scsi/scsicd.h b/src/devices/bus/scsi/scsicd.h index 9d88f6bd1a8..97fc4a1cf83 100644 --- a/src/devices/bus/scsi/scsicd.h +++ b/src/devices/bus/scsi/scsicd.h @@ -16,10 +16,10 @@ class scsicd_device : public scsihle_device, public t10mmc { public: // construction/destruction - scsicd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scsicd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - scsicd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + scsicd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/scsi/scsicd512.cpp b/src/devices/bus/scsi/scsicd512.cpp index 5395d9ff5b4..9b521dc62b5 100644 --- a/src/devices/bus/scsi/scsicd512.cpp +++ b/src/devices/bus/scsi/scsicd512.cpp @@ -66,37 +66,37 @@ void scsicd512_device::ReadData(uint8_t *data, int dataLength) } } -scsicd512_device::scsicd512_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +scsicd512_device::scsicd512_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : scsicd_device(mconfig, type, tag, owner, clock) { } -dec_rrd45_device::dec_rrd45_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dec_rrd45_device::dec_rrd45_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsicd512_device(mconfig, RRD45, tag, owner, "DEC ", "RRD45 (C) DEC ", "0436", 0x98) { } -toshiba_xm3301_device::toshiba_xm3301_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +toshiba_xm3301_device::toshiba_xm3301_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsicd512_device(mconfig, XM3301, tag, owner, "TOSHIBA ", "CD-ROM XM-3301TA", "0272", 0x88) { } -toshiba_xm5301_sun_device::toshiba_xm5301_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +toshiba_xm5301_sun_device::toshiba_xm5301_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsicd512_device(mconfig, XM5301SUN, tag, owner, "TOSHIBA ", "XM-5301TASUN4XCD", "2915", 0x98) { } -toshiba_xm5401_sun_device::toshiba_xm5401_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +toshiba_xm5401_sun_device::toshiba_xm5401_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsicd512_device(mconfig, XM5401SUN, tag, owner, "TOSHIBA ", "XM-5401TASUN4XCD", "1036", 0x98) { } -toshiba_xm5701_device::toshiba_xm5701_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +toshiba_xm5701_device::toshiba_xm5701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsicd512_device(mconfig, XM5701, tag, owner, "TOSHIBA ", "CD-ROM XM-5701TA", "3136", 0x98) { } -toshiba_xm5701_sun_device::toshiba_xm5701_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +toshiba_xm5701_sun_device::toshiba_xm5701_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsicd512_device(mconfig, XM5701SUN, tag, owner, "TOSHIBA ", "XM5701TASUN12XCD", "0997", 0x98) { } diff --git a/src/devices/bus/scsi/scsicd512.h b/src/devices/bus/scsi/scsicd512.h index 0345a74ca9a..ea0ec296a0f 100644 --- a/src/devices/bus/scsi/scsicd512.h +++ b/src/devices/bus/scsi/scsicd512.h @@ -20,11 +20,11 @@ public: virtual void ReadData(uint8_t *data, int dataLength) override; protected: - scsicd512_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock = 0); + scsicd512_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); scsicd512_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const char *mfr, const char *product, const char *rev, uint8_t data) - : scsicd512_device(mconfig, type, tag, owner, 0) + : scsicd512_device(mconfig, type, tag, owner) { strncpy(m_manufacturer, mfr, 8); strncpy(m_product, product, 16); @@ -43,37 +43,37 @@ protected: class dec_rrd45_device : public scsicd512_device { public: - dec_rrd45_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + dec_rrd45_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class toshiba_xm3301_device : public scsicd512_device { public: - toshiba_xm3301_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + toshiba_xm3301_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class toshiba_xm5301_sun_device : public scsicd512_device { public: - toshiba_xm5301_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + toshiba_xm5301_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class toshiba_xm5401_sun_device : public scsicd512_device { public: - toshiba_xm5401_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + toshiba_xm5401_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class toshiba_xm5701_device : public scsicd512_device { public: - toshiba_xm5701_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + toshiba_xm5701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class toshiba_xm5701_sun_device : public scsicd512_device { public: - toshiba_xm5701_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + toshiba_xm5701_sun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(RRD45, dec_rrd45_device) diff --git a/src/devices/bus/scsi/scsihd.cpp b/src/devices/bus/scsi/scsihd.cpp index 4fb01e02130..806e9f8fa5e 100644 --- a/src/devices/bus/scsi/scsihd.cpp +++ b/src/devices/bus/scsi/scsihd.cpp @@ -12,12 +12,12 @@ // device type definition DEFINE_DEVICE_TYPE(SCSIHD, scsihd_device, "scsihd", "SCSI HD") -scsihd_device::scsihd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scsihd_device::scsihd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scsihd_device(mconfig, SCSIHD, tag, owner, clock) { } -scsihd_device::scsihd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +scsihd_device::scsihd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : scsihle_device(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/bus/scsi/scsihd.h b/src/devices/bus/scsi/scsihd.h index 3cc50af8ec2..69673f68b2b 100644 --- a/src/devices/bus/scsi/scsihd.h +++ b/src/devices/bus/scsi/scsihd.h @@ -18,10 +18,10 @@ class scsihd_device : public scsihle_device, public t10sbc { public: // construction/destruction - scsihd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scsihd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - scsihd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + scsihd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/scsi/scsihle.cpp b/src/devices/bus/scsi/scsihle.cpp index 09a0fa84eca..3d5a35b68ae 100644 --- a/src/devices/bus/scsi/scsihle.cpp +++ b/src/devices/bus/scsi/scsihle.cpp @@ -11,7 +11,7 @@ Base class for HLE'd SCSI devices. #include "emu.h" #include "scsihle.h" -scsihle_device::scsihle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +scsihle_device::scsihle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), scsi_port_interface(mconfig, *this), m_scsi_id(*this, "SCSI_ID"), diff --git a/src/devices/bus/scsi/scsihle.h b/src/devices/bus/scsi/scsihle.h index ea6f577a592..edf5a6d4e46 100644 --- a/src/devices/bus/scsi/scsihle.h +++ b/src/devices/bus/scsi/scsihle.h @@ -37,7 +37,7 @@ public: protected: // construction/destruction - scsihle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + scsihle_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/scv/rom.cpp b/src/devices/bus/scv/rom.cpp index 8be6a020752..e5c802b6e0e 100644 --- a/src/devices/bus/scv/rom.cpp +++ b/src/devices/bus/scv/rom.cpp @@ -26,42 +26,42 @@ DEFINE_DEVICE_TYPE(SCV_ROM128K, scv_rom128_device, "scv_rom128", DEFINE_DEVICE_TYPE(SCV_ROM128K_RAM4K, scv_rom128ram4_device, "scv_rom128_ram4", "SCV 128K + RAM 4K Carts") -scv_rom8_device::scv_rom8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +scv_rom8_device::scv_rom8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_scv_cart_interface(mconfig, *this) { } -scv_rom8_device::scv_rom8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scv_rom8_device::scv_rom8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scv_rom8_device(mconfig, SCV_ROM8K, tag, owner, clock) { } -scv_rom16_device::scv_rom16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scv_rom16_device::scv_rom16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scv_rom8_device(mconfig, SCV_ROM16K, tag, owner, clock) { } -scv_rom32_device::scv_rom32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scv_rom32_device::scv_rom32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scv_rom8_device(mconfig, SCV_ROM32K, tag, owner, clock) { } -scv_rom32ram8_device::scv_rom32ram8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scv_rom32ram8_device::scv_rom32ram8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scv_rom8_device(mconfig, SCV_ROM32K_RAM8K, tag, owner, clock), m_ram_enabled(0) { } -scv_rom64_device::scv_rom64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scv_rom64_device::scv_rom64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scv_rom8_device(mconfig, SCV_ROM64K, tag, owner, clock), m_bank_base(0) { } -scv_rom128_device::scv_rom128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scv_rom128_device::scv_rom128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scv_rom8_device(mconfig, SCV_ROM128K, tag, owner, clock), m_bank_base(0) { } -scv_rom128ram4_device::scv_rom128ram4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scv_rom128ram4_device::scv_rom128ram4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scv_rom8_device(mconfig, SCV_ROM128K_RAM4K, tag, owner, clock), m_bank_base(0), m_ram_enabled(0) { } diff --git a/src/devices/bus/scv/rom.h b/src/devices/bus/scv/rom.h index 74fa0591179..c1cd3de8abd 100644 --- a/src/devices/bus/scv/rom.h +++ b/src/devices/bus/scv/rom.h @@ -15,13 +15,13 @@ class scv_rom8_device : public device_t, { public: // construction/destruction - scv_rom8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scv_rom8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; protected: - scv_rom8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + scv_rom8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -34,7 +34,7 @@ class scv_rom16_device : public scv_rom8_device { public: // construction/destruction - scv_rom16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scv_rom16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -47,7 +47,7 @@ class scv_rom32_device : public scv_rom8_device { public: // construction/destruction - scv_rom32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scv_rom32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -60,7 +60,7 @@ class scv_rom32ram8_device : public scv_rom8_device { public: // construction/destruction - scv_rom32ram8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scv_rom32ram8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -83,7 +83,7 @@ class scv_rom64_device : public scv_rom8_device { public: // construction/destruction - scv_rom64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scv_rom64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -104,7 +104,7 @@ class scv_rom128_device : public scv_rom8_device { public: // construction/destruction - scv_rom128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scv_rom128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -126,7 +126,7 @@ class scv_rom128ram4_device : public scv_rom8_device { public: // construction/destruction - scv_rom128ram4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scv_rom128ram4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; diff --git a/src/devices/bus/scv/slot.cpp b/src/devices/bus/scv/slot.cpp index b3ca1e08873..6339c144a16 100644 --- a/src/devices/bus/scv/slot.cpp +++ b/src/devices/bus/scv/slot.cpp @@ -71,7 +71,7 @@ void device_scv_cart_interface::ram_alloc(uint32_t size) //------------------------------------------------- // scv_cart_slot_device - constructor //------------------------------------------------- -scv_cart_slot_device::scv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +scv_cart_slot_device::scv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SCV_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_scv_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/scv/slot.h b/src/devices/bus/scv/slot.h index 24ce208ab3d..7f302bc8b01 100644 --- a/src/devices/bus/scv/slot.h +++ b/src/devices/bus/scv/slot.h @@ -68,7 +68,7 @@ public: // construction/destruction template <typename T> scv_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : scv_cart_slot_device(mconfig, tag, owner, 0) + : scv_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -76,7 +76,7 @@ public: set_fixed(false); } - scv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + scv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~scv_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/sdk85/i8755.cpp b/src/devices/bus/sdk85/i8755.cpp index 8c1d7a79fbf..7f3382195be 100644 --- a/src/devices/bus/sdk85/i8755.cpp +++ b/src/devices/bus/sdk85/i8755.cpp @@ -7,7 +7,7 @@ // device type definition DEFINE_DEVICE_TYPE(SDK85_I8755, sdk85exp_i8755_device, "sdk85exp_i8755", "SDK-85 PROM I/O Expansion (Intel 8755)") -sdk85exp_i8755_device::sdk85exp_i8755_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sdk85exp_i8755_device::sdk85exp_i8755_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SDK85_I8755, tag, owner, clock) , device_sdk85_romexp_card_interface(mconfig, *this) , m_i8755(*this, "i8755") diff --git a/src/devices/bus/sdk85/i8755.h b/src/devices/bus/sdk85/i8755.h index 2960be386e7..ec040f7fbf8 100644 --- a/src/devices/bus/sdk85/i8755.h +++ b/src/devices/bus/sdk85/i8755.h @@ -15,7 +15,7 @@ class sdk85exp_i8755_device : public device_t, public device_sdk85_romexp_card_i { public: // construction/destruction - sdk85exp_i8755_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sdk85exp_i8755_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/sdk85/memexp.cpp b/src/devices/bus/sdk85/memexp.cpp index a5a752c4339..827454d4956 100644 --- a/src/devices/bus/sdk85/memexp.cpp +++ b/src/devices/bus/sdk85/memexp.cpp @@ -14,7 +14,7 @@ // device type definition DEFINE_DEVICE_TYPE(SDK85_ROMEXP, sdk85_romexp_device, "sdk85_romexp", "SDK-85 expansion ROM socket") -sdk85_romexp_device::sdk85_romexp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sdk85_romexp_device::sdk85_romexp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SDK85_ROMEXP, tag, owner, clock) , device_rom_image_interface(mconfig, *this) , device_single_card_slot_interface<device_sdk85_romexp_card_interface>(mconfig, *this) diff --git a/src/devices/bus/sdk85/memexp.h b/src/devices/bus/sdk85/memexp.h index fbd005c48c2..d93763caa72 100644 --- a/src/devices/bus/sdk85/memexp.h +++ b/src/devices/bus/sdk85/memexp.h @@ -33,9 +33,9 @@ class sdk85_romexp_device : public device_t, { public: // construction/destruction - sdk85_romexp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sdk85_romexp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> - sdk85_romexp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&opts, const char *dflt) + sdk85_romexp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : sdk85_romexp_device(mconfig, tag, owner, clock) { option_reset(); diff --git a/src/devices/bus/sega8/ccatch.cpp b/src/devices/bus/sega8/ccatch.cpp index baf7fc52151..2c52d99b108 100644 --- a/src/devices/bus/sega8/ccatch.cpp +++ b/src/devices/bus/sega8/ccatch.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(SEGA8_ROM_CARDCATCH, sega8_cardcatch_device, "sega8_ccatch", -sega8_cardcatch_device::sega8_cardcatch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_cardcatch_device::sega8_cardcatch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_CARDCATCH, tag, owner, clock), m_card(*this, "cardslot") { } diff --git a/src/devices/bus/sega8/ccatch.h b/src/devices/bus/sega8/ccatch.h index ab00942904f..141d86fa3ed 100644 --- a/src/devices/bus/sega8/ccatch.h +++ b/src/devices/bus/sega8/ccatch.h @@ -14,7 +14,7 @@ class sega8_cardcatch_device : public sega8_rom_device { public: // construction/destruction - sega8_cardcatch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_cardcatch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; diff --git a/src/devices/bus/sega8/mgear.cpp b/src/devices/bus/sega8/mgear.cpp index 1c128c830ec..7969d275959 100644 --- a/src/devices/bus/sega8/mgear.cpp +++ b/src/devices/bus/sega8/mgear.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(SEGA8_ROM_MGEAR, sega8_mgear_device, "sega8_mgear", "Master Gear Converter") -sega8_mgear_device::sega8_mgear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_mgear_device::sega8_mgear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_MGEAR, tag, owner, clock), m_subslot(*this, "subslot") { } diff --git a/src/devices/bus/sega8/mgear.h b/src/devices/bus/sega8/mgear.h index 3e8e5f64fc9..85a51f8fa72 100644 --- a/src/devices/bus/sega8/mgear.h +++ b/src/devices/bus/sega8/mgear.h @@ -15,7 +15,7 @@ class sega8_mgear_device : public sega8_rom_device { public: // construction/destruction - sega8_mgear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_mgear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override { return m_subslot->read_cart(offset); } diff --git a/src/devices/bus/sega8/rom.cpp b/src/devices/bus/sega8/rom.cpp index 6d7abd8338c..e26de175ed7 100644 --- a/src/devices/bus/sega8/rom.cpp +++ b/src/devices/bus/sega8/rom.cpp @@ -50,7 +50,7 @@ DEFINE_DEVICE_TYPE(SEGA8_ROM_MULTICART, sega8_multicart_device, "sega8_mul DEFINE_DEVICE_TYPE(SEGA8_ROM_MEGACART, sega8_megacart_device, "sega8_megacart", "SC-3000 Megacart Cart") -sega8_rom_device::sega8_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sega8_rom_device::sega8_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sega8_cart_interface(mconfig, *this) , m_ram_base(0) @@ -58,7 +58,7 @@ sega8_rom_device::sega8_rom_device(const machine_config &mconfig, device_type ty { } -sega8_rom_device::sega8_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_rom_device::sega8_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_STD, tag, owner, clock) { } @@ -66,31 +66,31 @@ sega8_rom_device::sega8_rom_device(const machine_config &mconfig, const char *ta -sega8_othello_device::sega8_othello_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_othello_device::sega8_othello_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_OTHELLO, tag, owner, clock) { } -sega8_castle_device::sega8_castle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_castle_device::sega8_castle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_CASTLE, tag, owner, clock) { } -sega8_basic_l3_device::sega8_basic_l3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_basic_l3_device::sega8_basic_l3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_BASIC_L3, tag, owner, clock) { } -sega8_music_editor_device::sega8_music_editor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_music_editor_device::sega8_music_editor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_MUSIC_EDITOR, tag, owner, clock) { } -sega8_terebi_device::sega8_terebi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_terebi_device::sega8_terebi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_TEREBI, tag, owner, clock) , m_tvdraw_x(*this, "TVDRAW_X") , m_tvdraw_y(*this, "TVDRAW_Y") @@ -100,13 +100,13 @@ sega8_terebi_device::sega8_terebi_device(const machine_config &mconfig, const ch } -sega8_dahjee_typea_device::sega8_dahjee_typea_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_dahjee_typea_device::sega8_dahjee_typea_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_DAHJEE_TYPEA, tag, owner, clock) { } -sega8_dahjee_typeb_device::sega8_dahjee_typeb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_dahjee_typeb_device::sega8_dahjee_typeb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_DAHJEE_TYPEB, tag, owner, clock) { } @@ -114,7 +114,7 @@ sega8_dahjee_typeb_device::sega8_dahjee_typeb_device(const machine_config &mconf -sega8_eeprom_device::sega8_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_eeprom_device::sega8_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SEGA8_ROM_EEPROM, tag, owner, clock) , device_sega8_cart_interface(mconfig, *this) , m_eeprom(*this, "eeprom") @@ -124,7 +124,7 @@ sega8_eeprom_device::sega8_eeprom_device(const machine_config &mconfig, const ch } -sega8_codemasters_device::sega8_codemasters_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_codemasters_device::sega8_codemasters_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SEGA8_ROM_CODEMASTERS, tag, owner, clock) , device_sega8_cart_interface(mconfig, *this) , m_ram_base(0) @@ -133,13 +133,13 @@ sega8_codemasters_device::sega8_codemasters_device(const machine_config &mconfig } -sega8_4pak_device::sega8_4pak_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_4pak_device::sega8_4pak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_4PAK, tag, owner, clock) { } -sega8_zemina_device::sega8_zemina_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sega8_zemina_device::sega8_zemina_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sega8_cart_interface(mconfig, *this) , m_ram_base(0) @@ -147,64 +147,64 @@ sega8_zemina_device::sega8_zemina_device(const machine_config &mconfig, device_t { } -sega8_zemina_device::sega8_zemina_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_zemina_device::sega8_zemina_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_zemina_device(mconfig, SEGA8_ROM_ZEMINA, tag, owner, clock) { } -sega8_nemesis_device::sega8_nemesis_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_nemesis_device::sega8_nemesis_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_zemina_device(mconfig, SEGA8_ROM_NEMESIS, tag, owner, clock) { } -sega8_janggun_device::sega8_janggun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_janggun_device::sega8_janggun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SEGA8_ROM_JANGGUN, tag, owner, clock) , device_sega8_cart_interface(mconfig, *this) { } -sega8_hicom_device::sega8_hicom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_hicom_device::sega8_hicom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_HICOM, tag, owner, clock) , m_rom_bank_base(0) { } -sega8_korean_device::sega8_korean_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_korean_device::sega8_korean_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_KOREAN, tag, owner, clock) { } -sega8_korean_188_device::sega8_korean_188_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sega8_korean_188_device::sega8_korean_188_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_KOREAN_188, tag, owner, clock) , m_rom_bank_base(0) { } -sega8_korean_nb_device::sega8_korean_nb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_korean_nb_device::sega8_korean_nb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_KOREAN_NB, tag, owner, clock) { } -sega8_seojin_device::sega8_seojin_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_seojin_device::sega8_seojin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_SEOJIN, tag, owner, clock) { } -sega8_multicart_device::sega8_multicart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_multicart_device::sega8_multicart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_MULTICART, tag, owner, clock) { } -sega8_megacart_device::sega8_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_megacart_device::sega8_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_MEGACART, tag, owner, clock) { } @@ -1208,7 +1208,7 @@ into the X-Terminator to search for cheat codes. -------------------------------------------------*/ -sega8_x_terminator_device::sega8_x_terminator_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_x_terminator_device::sega8_x_terminator_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_rom_device(mconfig, SEGA8_ROM_X_TERMINATOR, tag, owner, clock) , m_subslot(*this, "subslot") , m_switch(*this, "SWITCH") diff --git a/src/devices/bus/sega8/rom.h b/src/devices/bus/sega8/rom.h index ec4928fba22..01a8a5f555c 100644 --- a/src/devices/bus/sega8/rom.h +++ b/src/devices/bus/sega8/rom.h @@ -15,7 +15,7 @@ class sega8_rom_device : public device_t, { public: // construction/destruction - sega8_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void late_bank_setup() override; @@ -25,7 +25,7 @@ public: virtual void write_mapper(offs_t offset, uint8_t data) override; protected: - sega8_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sega8_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -45,7 +45,7 @@ class sega8_othello_device : public sega8_rom_device { public: // construction/destruction - sega8_othello_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_othello_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -60,7 +60,7 @@ class sega8_castle_device : public sega8_rom_device { public: // construction/destruction - sega8_castle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_castle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -75,7 +75,7 @@ class sega8_basic_l3_device : public sega8_rom_device { public: // construction/destruction - sega8_basic_l3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_basic_l3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -94,7 +94,7 @@ class sega8_music_editor_device : public sega8_rom_device { public: // construction/destruction - sega8_music_editor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_music_editor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -113,7 +113,7 @@ class sega8_terebi_device : public sega8_rom_device { public: // construction/destruction - sega8_terebi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_terebi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; @@ -141,7 +141,7 @@ class sega8_dahjee_typea_device : public sega8_rom_device { public: // construction/destruction - sega8_dahjee_typea_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_dahjee_typea_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -160,7 +160,7 @@ class sega8_dahjee_typeb_device : public sega8_rom_device { public: // construction/destruction - sega8_dahjee_typeb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_dahjee_typeb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -182,7 +182,7 @@ class sega8_eeprom_device : public device_t, { public: // construction/destruction - sega8_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void late_bank_setup() override; @@ -213,7 +213,7 @@ class sega8_codemasters_device : public device_t, { public: // construction/destruction - sega8_codemasters_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_codemasters_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void late_bank_setup() override; @@ -239,7 +239,7 @@ class sega8_4pak_device : public sega8_rom_device { public: // construction/destruction - sega8_4pak_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_4pak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -262,7 +262,7 @@ class sega8_zemina_device : public device_t, { public: // construction/destruction - sega8_zemina_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_zemina_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void late_bank_setup() override; @@ -272,7 +272,7 @@ public: // no mapper write for this! protected: - sega8_zemina_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sega8_zemina_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -290,7 +290,7 @@ class sega8_nemesis_device : public sega8_zemina_device { public: // construction/destruction - sega8_nemesis_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_nemesis_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void late_bank_setup() override; }; @@ -303,7 +303,7 @@ class sega8_janggun_device : public device_t, { public: // construction/destruction - sega8_janggun_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_janggun_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void late_bank_setup() override; @@ -326,7 +326,7 @@ class sega8_hicom_device : public sega8_rom_device { public: // construction/destruction - sega8_hicom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_hicom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void late_bank_setup() override; @@ -349,7 +349,7 @@ class sega8_korean_device : public sega8_rom_device { public: // construction/destruction - sega8_korean_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_korean_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void late_bank_setup() override; @@ -365,7 +365,7 @@ class sega8_korean_188_device : public sega8_rom_device { public: // construction/destruction - sega8_korean_188_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sega8_korean_188_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual u8 read_cart(offs_t offset) override; @@ -387,7 +387,7 @@ class sega8_korean_nb_device : public sega8_rom_device { public: // construction/destruction - sega8_korean_nb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_korean_nb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual void write_mapper(offs_t offset, uint8_t data) override {} @@ -400,7 +400,7 @@ class sega8_seojin_device : public sega8_rom_device { public: // construction/destruction - sega8_seojin_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_seojin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -425,7 +425,7 @@ class sega8_multicart_device : public sega8_rom_device { public: // construction/destruction - sega8_multicart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_multicart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -452,7 +452,7 @@ class sega8_megacart_device : public sega8_rom_device { public: // construction/destruction - sega8_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_cart(offs_t offset) override; @@ -475,7 +475,7 @@ private: class sega8_x_terminator_device : public sega8_rom_device { public: - sega8_x_terminator_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_x_terminator_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sega8/sega8_slot.cpp b/src/devices/bus/sega8/sega8_slot.cpp index f2ac85c896e..6fcfe03c547 100644 --- a/src/devices/bus/sega8/sega8_slot.cpp +++ b/src/devices/bus/sega8/sega8_slot.cpp @@ -116,7 +116,7 @@ void device_sega8_cart_interface::ram_alloc(uint32_t size) // sega8_cart_slot_device - constructor //------------------------------------------------- -sega8_cart_slot_device::sega8_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool is_card) +sega8_cart_slot_device::sega8_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_card) : device_t(mconfig, type, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_single_card_slot_interface<device_sega8_cart_interface>(mconfig, *this) @@ -126,59 +126,59 @@ sega8_cart_slot_device::sega8_cart_slot_device(const machine_config &mconfig, de { } -sega8_cart_slot_device::sega8_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_cart_slot_device::sega8_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_cart_slot_device(mconfig, SEGA8_CART_SLOT, tag, owner, clock, false) { } -sega8_card_slot_device::sega8_card_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sega8_card_slot_device::sega8_card_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sega8_cart_slot_device(mconfig, type, tag, owner, clock, true) { } -sega8_card_slot_device::sega8_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega8_card_slot_device::sega8_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_card_slot_device(mconfig, SEGA8_CARD_SLOT, tag, owner, clock) { } -sg1000_cart_slot_device::sg1000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sg1000_cart_slot_device::sg1000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_cart_slot_device(mconfig, SG1000_CART_SLOT, tag, owner, clock) { } -omv_cart_slot_device::omv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +omv_cart_slot_device::omv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_cart_slot_device(mconfig, OMV_CART_SLOT, tag, owner, clock) { } -sc3000_cart_slot_device::sc3000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sc3000_cart_slot_device::sc3000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_cart_slot_device(mconfig, SC3000_CART_SLOT, tag, owner, clock) { } -sg1000mk3_cart_slot_device::sg1000mk3_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sg1000mk3_cart_slot_device::sg1000mk3_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_cart_slot_device(mconfig, SG1000MK3_CART_SLOT, tag, owner, clock) { } -sms_cart_slot_device::sms_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sms_cart_slot_device::sms_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_cart_slot_device(mconfig, SMS_CART_SLOT, tag, owner, clock) { } -gamegear_cart_slot_device::gamegear_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gamegear_cart_slot_device::gamegear_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_cart_slot_device(mconfig, GAMEGEAR_CART_SLOT, tag, owner, clock) { } -sms_card_slot_device::sms_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sms_card_slot_device::sms_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_card_slot_device(mconfig, SMS_CARD_SLOT, tag, owner, clock) { } -sg1000_card_slot_device::sg1000_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sg1000_card_slot_device::sg1000_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega8_card_slot_device(mconfig, SG1000_CARD_SLOT, tag, owner, clock) { } diff --git a/src/devices/bus/sega8/sega8_slot.h b/src/devices/bus/sega8/sega8_slot.h index 01f34842343..ad553ae4b9b 100644 --- a/src/devices/bus/sega8/sega8_slot.h +++ b/src/devices/bus/sega8/sega8_slot.h @@ -113,7 +113,7 @@ class sega8_cart_slot_device : public device_t, { public: // construction/destruction - sega8_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~sega8_cart_slot_device(); // image-level overrides @@ -150,7 +150,7 @@ public: int get_sms_mode() { return m_cart->get_sms_mode(); } protected: - sega8_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool is_card = false); + sega8_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_card = false); // device-level overrides virtual void device_start() override; @@ -166,14 +166,14 @@ class sega8_card_slot_device : public sega8_cart_slot_device { public: // construction/destruction - sega8_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega8_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_type_name() const noexcept override { return "card"; } virtual const char *image_brief_type_name() const noexcept override { return "card"; } protected: // construction/destruction - sega8_card_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sega8_card_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> sg1000_cart_slot_device @@ -184,14 +184,14 @@ public: // construction/destruction template <typename T> sg1000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : sg1000_cart_slot_device(mconfig, tag, owner, u32(0)) + : sg1000_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sg1000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sg1000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "sg1000_cart"; } virtual const char *file_extensions() const noexcept override { return "bin,sg"; } }; @@ -204,14 +204,14 @@ public: // construction/destruction template <typename T> omv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : omv_cart_slot_device(mconfig, tag, owner, u32(0)) + : omv_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - omv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + omv_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "sg1000_cart"; } virtual const char *file_extensions() const noexcept override { return "bin,sg"; } }; @@ -224,14 +224,14 @@ public: // construction/destruction template <typename T> sc3000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : sc3000_cart_slot_device(mconfig, tag, owner, u32(0)) + : sc3000_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sc3000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sc3000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "sg1000_cart"; } virtual const char *file_extensions() const noexcept override { return "bin,sg,sc"; } }; @@ -244,14 +244,14 @@ public: // construction/destruction template <typename T> sg1000mk3_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : sg1000mk3_cart_slot_device(mconfig, tag, owner, u32(0)) + : sg1000mk3_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sg1000mk3_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sg1000mk3_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "sms_cart,sg1000_cart"; } virtual const char *file_extensions() const noexcept override { return "bin,sms,sg"; } }; @@ -264,14 +264,14 @@ public: // construction/destruction template <typename T> sms_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : sms_cart_slot_device(mconfig, tag, owner, u32(0)) + : sms_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sms_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "sms_cart"; } virtual const char *file_extensions() const noexcept override { return "bin,sms"; } }; @@ -284,14 +284,14 @@ public: // construction/destruction template <typename T> gamegear_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : gamegear_cart_slot_device(mconfig, tag, owner, u32(0)) + : gamegear_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - gamegear_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gamegear_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "gamegear_cart"; } virtual const char *file_extensions() const noexcept override { return "bin,gg"; } }; @@ -305,14 +305,14 @@ public: // construction/destruction template <typename T> sms_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : sms_card_slot_device(mconfig, tag, owner, u32(0)) + : sms_card_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sms_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "sms_card"; } virtual const char *file_extensions() const noexcept override { return "bin"; } }; @@ -325,14 +325,14 @@ public: // construction/destruction template <typename T> sg1000_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : sg1000_card_slot_device(mconfig, tag, owner, u32(0)) + : sg1000_card_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sg1000_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sg1000_card_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "sg1000_cart"; } virtual const char *file_extensions() const noexcept override { return "bin,sg"; } }; diff --git a/src/devices/bus/sg1000_exp/fm_unit.cpp b/src/devices/bus/sg1000_exp/fm_unit.cpp index 339b41254b2..c39799a3cc7 100644 --- a/src/devices/bus/sg1000_exp/fm_unit.cpp +++ b/src/devices/bus/sg1000_exp/fm_unit.cpp @@ -67,7 +67,7 @@ void sega_fm_unit_device::device_add_mconfig(machine_config &config) // sega_fm_unit_device - constructor //------------------------------------------------- -sega_fm_unit_device::sega_fm_unit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_fm_unit_device::sega_fm_unit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SEGA_FM_UNIT, tag, owner, clock), device_sg1000_expansion_slot_interface(mconfig, *this), m_ym(*this, "ym2413"), diff --git a/src/devices/bus/sg1000_exp/fm_unit.h b/src/devices/bus/sg1000_exp/fm_unit.h index d1c80e0b178..ffe6d6230c8 100644 --- a/src/devices/bus/sg1000_exp/fm_unit.h +++ b/src/devices/bus/sg1000_exp/fm_unit.h @@ -29,7 +29,7 @@ class sega_fm_unit_device : public device_t, { public: // construction/destruction - sega_fm_unit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega_fm_unit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/sg1000_exp/kblink.cpp b/src/devices/bus/sg1000_exp/kblink.cpp index 8d98e006f94..c32604cfaa9 100644 --- a/src/devices/bus/sg1000_exp/kblink.cpp +++ b/src/devices/bus/sg1000_exp/kblink.cpp @@ -56,7 +56,7 @@ DEFINE_DEVICE_TYPE(SK1100_LINK_CABLE, sk1100_link_cable_device, "sk1100_link_cab // sk1100_link_cable_device - constructor //------------------------------------------------- -sk1100_link_cable_device::sk1100_link_cable_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sk1100_link_cable_device::sk1100_link_cable_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SK1100_LINK_CABLE, tag, owner, clock), device_sk1100_printer_port_interface(mconfig, *this), m_stream(*this, "stream"), @@ -113,7 +113,7 @@ void sk1100_link_cable_device::device_reset() void sk1100_link_cable_device::device_add_mconfig(machine_config &config) { - BITBANGER(config, m_stream, 0); + BITBANGER(config, m_stream); } TIMER_CALLBACK_MEMBER(sk1100_link_cable_device::update_queue) diff --git a/src/devices/bus/sg1000_exp/kblink.h b/src/devices/bus/sg1000_exp/kblink.h index 561c1b79455..5a051921685 100644 --- a/src/devices/bus/sg1000_exp/kblink.h +++ b/src/devices/bus/sg1000_exp/kblink.h @@ -31,7 +31,7 @@ class sk1100_link_cable_device : public device_t, { public: // construction/destruction - sk1100_link_cable_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sk1100_link_cable_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/sg1000_exp/sg1000exp.cpp b/src/devices/bus/sg1000_exp/sg1000exp.cpp index ad568d7cb27..fd3ff0c2514 100644 --- a/src/devices/bus/sg1000_exp/sg1000exp.cpp +++ b/src/devices/bus/sg1000_exp/sg1000exp.cpp @@ -55,7 +55,7 @@ device_sg1000_expansion_slot_interface::~device_sg1000_expansion_slot_interface( // sg1000_expansion_slot_device - constructor //------------------------------------------------- -sg1000_expansion_slot_device::sg1000_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sg1000_expansion_slot_device::sg1000_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SG1000_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_sg1000_expansion_slot_interface>(mconfig, *this), m_device(nullptr) diff --git a/src/devices/bus/sg1000_exp/sg1000exp.h b/src/devices/bus/sg1000_exp/sg1000exp.h index d297e255d97..d2af7bff3ab 100644 --- a/src/devices/bus/sg1000_exp/sg1000exp.h +++ b/src/devices/bus/sg1000_exp/sg1000exp.h @@ -29,7 +29,7 @@ public: // construction/destruction template <typename T> sg1000_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt, bool const fixed) - : sg1000_expansion_slot_device(mconfig, tag, owner, 0) + : sg1000_expansion_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -37,7 +37,7 @@ public: set_fixed(fixed); } - sg1000_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sg1000_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~sg1000_expansion_slot_device(); uint8_t read(offs_t offset); diff --git a/src/devices/bus/sg1000_exp/sk1100.cpp b/src/devices/bus/sg1000_exp/sk1100.cpp index e5a2ae238c9..0b60be32db9 100644 --- a/src/devices/bus/sg1000_exp/sk1100.cpp +++ b/src/devices/bus/sg1000_exp/sk1100.cpp @@ -182,7 +182,7 @@ void sega_sk1100_device::device_add_mconfig(machine_config &config) // sega_sk1100_device - constructor //------------------------------------------------- -sega_sk1100_device::sega_sk1100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_sk1100_device::sega_sk1100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SEGA_SK1100, tag, owner, clock), device_sg1000_expansion_slot_interface(mconfig, *this), m_cassette(*this, "cassette"), diff --git a/src/devices/bus/sg1000_exp/sk1100.h b/src/devices/bus/sg1000_exp/sk1100.h index f2e94920e22..e48c47745cb 100644 --- a/src/devices/bus/sg1000_exp/sk1100.h +++ b/src/devices/bus/sg1000_exp/sk1100.h @@ -33,7 +33,7 @@ class sega_sk1100_device : public device_t, { public: // construction/destruction - sega_sk1100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega_sk1100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sg1000_exp/sk1100prn.cpp b/src/devices/bus/sg1000_exp/sk1100prn.cpp index 8f80306588b..a5a6c4946fc 100644 --- a/src/devices/bus/sg1000_exp/sk1100prn.cpp +++ b/src/devices/bus/sg1000_exp/sk1100prn.cpp @@ -54,7 +54,7 @@ device_sk1100_printer_port_interface::~device_sk1100_printer_port_interface() // sk1100_printer_port_device - constructor //------------------------------------------------- -sk1100_printer_port_device::sk1100_printer_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sk1100_printer_port_device::sk1100_printer_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SK1100_PRINTER_PORT, tag, owner, clock), device_single_card_slot_interface<device_sk1100_printer_port_interface>(mconfig, *this), m_device(nullptr) diff --git a/src/devices/bus/sg1000_exp/sk1100prn.h b/src/devices/bus/sg1000_exp/sk1100prn.h index 8e1988102c8..4c2d83cb917 100644 --- a/src/devices/bus/sg1000_exp/sk1100prn.h +++ b/src/devices/bus/sg1000_exp/sk1100prn.h @@ -29,7 +29,7 @@ public: // construction/destruction template <typename T> sk1100_printer_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : sk1100_printer_port_device(mconfig, tag, owner, 0) + : sk1100_printer_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -37,7 +37,7 @@ public: set_fixed(false); } - sk1100_printer_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + sk1100_printer_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~sk1100_printer_port_device(); DECLARE_READ_LINE_MEMBER(fault_r); diff --git a/src/devices/bus/sgikbd/hlekbd.cpp b/src/devices/bus/sgikbd/hlekbd.cpp index 42ffb0eb76c..e4d736b1777 100644 --- a/src/devices/bus/sgikbd/hlekbd.cpp +++ b/src/devices/bus/sgikbd/hlekbd.cpp @@ -160,7 +160,7 @@ INPUT_PORTS_END } // anonymous namespace -hle_device::hle_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +hle_device::hle_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SGI_HLE_KEYBOARD, tag, owner, clock) , device_buffered_serial_interface(mconfig, *this) , device_sgi_keyboard_port_interface(mconfig, *this) diff --git a/src/devices/bus/sgikbd/hlekbd.h b/src/devices/bus/sgikbd/hlekbd.h index ce066e90c55..9c93eadeb1b 100644 --- a/src/devices/bus/sgikbd/hlekbd.h +++ b/src/devices/bus/sgikbd/hlekbd.h @@ -20,7 +20,7 @@ class hle_device : public device_t { public: // constructor/destructor - hle_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + hle_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual ~hle_device() override; diff --git a/src/devices/bus/sgikbd/sgikbd.cpp b/src/devices/bus/sgikbd/sgikbd.cpp index 80138f1d7a3..4486e95c718 100644 --- a/src/devices/bus/sgikbd/sgikbd.cpp +++ b/src/devices/bus/sgikbd/sgikbd.cpp @@ -8,12 +8,12 @@ DEFINE_DEVICE_TYPE(SGIKBD_PORT, sgi_keyboard_port_device, "sgikbd", "SGI Keyboard Port") -sgi_keyboard_port_device::sgi_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +sgi_keyboard_port_device::sgi_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : sgi_keyboard_port_device(mconfig, SGIKBD_PORT, tag, owner, clock) { } -sgi_keyboard_port_device::sgi_keyboard_port_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock) +sgi_keyboard_port_device::sgi_keyboard_port_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_single_card_slot_interface<device_sgi_keyboard_port_interface>(mconfig, *this) , m_rxd(0) diff --git a/src/devices/bus/sgikbd/sgikbd.h b/src/devices/bus/sgikbd/sgikbd.h index bf64fd34b6a..2635e3448e0 100644 --- a/src/devices/bus/sgikbd/sgikbd.h +++ b/src/devices/bus/sgikbd/sgikbd.h @@ -16,14 +16,14 @@ class sgi_keyboard_port_device : public device_t, public device_single_card_slot public: template <typename T> sgi_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : sgi_keyboard_port_device(mconfig, tag, owner, 0) + : sgi_keyboard_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sgi_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + sgi_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~sgi_keyboard_port_device(); // configuration helpers @@ -34,7 +34,7 @@ public: DECLARE_READ_LINE_MEMBER( rxd_r ) { return m_rxd; } protected: - sgi_keyboard_port_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock); + sgi_keyboard_port_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); virtual void device_config_complete() override; virtual void device_resolve_objects() override; diff --git a/src/devices/bus/sms_ctrl/graphic.cpp b/src/devices/bus/sms_ctrl/graphic.cpp index 1ada76748e7..2d94267d26b 100644 --- a/src/devices/bus/sms_ctrl/graphic.cpp +++ b/src/devices/bus/sms_ctrl/graphic.cpp @@ -76,7 +76,7 @@ ioport_constructor sms_graphic_device::device_input_ports() const // sms_graphic_device - constructor //------------------------------------------------- -sms_graphic_device::sms_graphic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sms_graphic_device::sms_graphic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_GRAPHIC, tag, owner, clock) , device_sms_control_port_interface(mconfig, *this) , m_buttons(*this, "BUTTONS") diff --git a/src/devices/bus/sms_ctrl/graphic.h b/src/devices/bus/sms_ctrl/graphic.h index 036f4660033..ca9c25f9f1f 100644 --- a/src/devices/bus/sms_ctrl/graphic.h +++ b/src/devices/bus/sms_ctrl/graphic.h @@ -27,7 +27,7 @@ class sms_graphic_device : public device_t, { public: // construction/destruction - sms_graphic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_graphic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sms_ctrl/joypad.cpp b/src/devices/bus/sms_ctrl/joypad.cpp index 4cd664a952e..e298357a9e1 100644 --- a/src/devices/bus/sms_ctrl/joypad.cpp +++ b/src/devices/bus/sms_ctrl/joypad.cpp @@ -65,7 +65,7 @@ ioport_constructor sms_joypad_device::device_input_ports() const // sms_joypad_device - constructor //------------------------------------------------- -sms_joypad_device::sms_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_joypad_device::sms_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_JOYPAD, tag, owner, clock), device_sms_control_port_interface(mconfig, *this), m_joypad(*this, "JOYPAD") diff --git a/src/devices/bus/sms_ctrl/joypad.h b/src/devices/bus/sms_ctrl/joypad.h index 60b4fe9f4c0..475b501e1e5 100644 --- a/src/devices/bus/sms_ctrl/joypad.h +++ b/src/devices/bus/sms_ctrl/joypad.h @@ -27,7 +27,7 @@ class sms_joypad_device : public device_t, { public: // construction/destruction - sms_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sms_ctrl/lphaser.cpp b/src/devices/bus/sms_ctrl/lphaser.cpp index 7e64e7c7236..655c7e83cb7 100644 --- a/src/devices/bus/sms_ctrl/lphaser.cpp +++ b/src/devices/bus/sms_ctrl/lphaser.cpp @@ -84,7 +84,7 @@ ioport_constructor sms_light_phaser_device::device_input_ports() const // sms_light_phaser_device - constructor //------------------------------------------------- -sms_light_phaser_device::sms_light_phaser_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_light_phaser_device::sms_light_phaser_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_LIGHT_PHASER, tag, owner, clock), device_sms_control_port_interface(mconfig, *this), m_lphaser_pins(*this, "CTRL_PORT"), diff --git a/src/devices/bus/sms_ctrl/lphaser.h b/src/devices/bus/sms_ctrl/lphaser.h index a75f4a0d042..ac2333dfb47 100644 --- a/src/devices/bus/sms_ctrl/lphaser.h +++ b/src/devices/bus/sms_ctrl/lphaser.h @@ -27,7 +27,7 @@ class sms_light_phaser_device : public device_t, { public: // construction/destruction - sms_light_phaser_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_light_phaser_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sms_ctrl/multitap.cpp b/src/devices/bus/sms_ctrl/multitap.cpp index 74d6c749cb5..96e4990bc90 100644 --- a/src/devices/bus/sms_ctrl/multitap.cpp +++ b/src/devices/bus/sms_ctrl/multitap.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(SMS_MULTITAP, sms_multitap_device, "sms_multitap", "Furrtek S // sms_multitap_device - constructor //------------------------------------------------- -sms_multitap_device::sms_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_multitap_device::sms_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_MULTITAP, tag, owner, clock), device_sms_control_port_interface(mconfig, *this), m_subctrl1_port(*this, "ctrl1"), diff --git a/src/devices/bus/sms_ctrl/multitap.h b/src/devices/bus/sms_ctrl/multitap.h index 6a2351c48f5..1d9adec2737 100644 --- a/src/devices/bus/sms_ctrl/multitap.h +++ b/src/devices/bus/sms_ctrl/multitap.h @@ -27,7 +27,7 @@ class sms_multitap_device : public device_t, { public: // construction/destruction - sms_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/sms_ctrl/paddle.cpp b/src/devices/bus/sms_ctrl/paddle.cpp index 06f1c9bfa16..88e55a2c152 100644 --- a/src/devices/bus/sms_ctrl/paddle.cpp +++ b/src/devices/bus/sms_ctrl/paddle.cpp @@ -90,7 +90,7 @@ ioport_constructor sms_paddle_device::device_input_ports() const // sms_paddle_device - constructor //------------------------------------------------- -sms_paddle_device::sms_paddle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_paddle_device::sms_paddle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_PADDLE, tag, owner, clock), device_sms_control_port_interface(mconfig, *this), m_paddle_pins(*this, "CTRL_PORT"), diff --git a/src/devices/bus/sms_ctrl/paddle.h b/src/devices/bus/sms_ctrl/paddle.h index 21604a882ed..3dcce109a21 100644 --- a/src/devices/bus/sms_ctrl/paddle.h +++ b/src/devices/bus/sms_ctrl/paddle.h @@ -27,7 +27,7 @@ class sms_paddle_device : public device_t, { public: // construction/destruction - sms_paddle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_paddle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sms_ctrl/rfu.cpp b/src/devices/bus/sms_ctrl/rfu.cpp index d28a2ded703..8800c349077 100644 --- a/src/devices/bus/sms_ctrl/rfu.cpp +++ b/src/devices/bus/sms_ctrl/rfu.cpp @@ -63,7 +63,7 @@ ioport_constructor sms_rapid_fire_device::device_input_ports() const // sms_rapid_fire_device - constructor //------------------------------------------------- -sms_rapid_fire_device::sms_rapid_fire_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_rapid_fire_device::sms_rapid_fire_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_RAPID_FIRE, tag, owner, clock), device_sms_control_port_interface(mconfig, *this), m_rfire_sw(*this, "rfu_sw"), diff --git a/src/devices/bus/sms_ctrl/rfu.h b/src/devices/bus/sms_ctrl/rfu.h index f37b70b1c92..49bf5dc62f8 100644 --- a/src/devices/bus/sms_ctrl/rfu.h +++ b/src/devices/bus/sms_ctrl/rfu.h @@ -27,7 +27,7 @@ class sms_rapid_fire_device : public device_t, { public: // construction/destruction - sms_rapid_fire_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_rapid_fire_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/sms_ctrl/smsctrl.cpp b/src/devices/bus/sms_ctrl/smsctrl.cpp index cec153b863e..8476c6ae56d 100644 --- a/src/devices/bus/sms_ctrl/smsctrl.cpp +++ b/src/devices/bus/sms_ctrl/smsctrl.cpp @@ -63,7 +63,7 @@ device_sms_control_port_interface::~device_sms_control_port_interface() // sms_control_port_device - constructor //------------------------------------------------- -sms_control_port_device::sms_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_control_port_device::sms_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_CONTROL_PORT, tag, owner, clock), device_slot_interface(mconfig, *this), m_screen(*this, finder_base::DUMMY_TAG), diff --git a/src/devices/bus/sms_ctrl/smsctrl.h b/src/devices/bus/sms_ctrl/smsctrl.h index cee1daa0cb9..c002f6ad84d 100644 --- a/src/devices/bus/sms_ctrl/smsctrl.h +++ b/src/devices/bus/sms_ctrl/smsctrl.h @@ -32,7 +32,7 @@ public: // construction/destruction template <typename T> sms_control_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : sms_control_port_device(mconfig, tag, owner, 0) + : sms_control_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -40,7 +40,7 @@ public: set_fixed(false); } - sms_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~sms_control_port_device(); // static configuration helpers diff --git a/src/devices/bus/sms_ctrl/sports.cpp b/src/devices/bus/sms_ctrl/sports.cpp index d58cfb68095..96e6a0c293e 100644 --- a/src/devices/bus/sms_ctrl/sports.cpp +++ b/src/devices/bus/sms_ctrl/sports.cpp @@ -151,7 +151,7 @@ ioport_constructor sms_sports_pad_device::device_input_ports() const // sms_sports_pad_device - constructor //------------------------------------------------- -sms_sports_pad_device::sms_sports_pad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_sports_pad_device::sms_sports_pad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_SPORTS_PAD, tag, owner, clock), device_sms_control_port_interface(mconfig, *this), m_sports_in(*this, "SPORTS_IN"), diff --git a/src/devices/bus/sms_ctrl/sports.h b/src/devices/bus/sms_ctrl/sports.h index cdf1202befd..c8aaa7e2624 100644 --- a/src/devices/bus/sms_ctrl/sports.h +++ b/src/devices/bus/sms_ctrl/sports.h @@ -27,7 +27,7 @@ class sms_sports_pad_device : public device_t, { public: // construction/destruction - sms_sports_pad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_sports_pad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sms_ctrl/sportsjp.cpp b/src/devices/bus/sms_ctrl/sportsjp.cpp index a0c2a69d2ad..892b7032367 100644 --- a/src/devices/bus/sms_ctrl/sportsjp.cpp +++ b/src/devices/bus/sms_ctrl/sportsjp.cpp @@ -103,7 +103,7 @@ ioport_constructor sms_sports_pad_jp_device::device_input_ports() const // sms_sports_pad_jp_device - constructor //------------------------------------------------- -sms_sports_pad_jp_device::sms_sports_pad_jp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_sports_pad_jp_device::sms_sports_pad_jp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_SPORTS_PAD_JP, tag, owner, clock), device_sms_control_port_interface(mconfig, *this), m_sports_jp_in(*this, "SPORTS_JP_IN"), diff --git a/src/devices/bus/sms_ctrl/sportsjp.h b/src/devices/bus/sms_ctrl/sportsjp.h index 92ee2ccd70c..63a5caee291 100644 --- a/src/devices/bus/sms_ctrl/sportsjp.h +++ b/src/devices/bus/sms_ctrl/sportsjp.h @@ -27,7 +27,7 @@ class sms_sports_pad_jp_device : public device_t, { public: // construction/destruction - sms_sports_pad_jp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_sports_pad_jp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/sms_exp/gender.cpp b/src/devices/bus/sms_exp/gender.cpp index 87bb97ea7a2..3c5c0155386 100644 --- a/src/devices/bus/sms_exp/gender.cpp +++ b/src/devices/bus/sms_exp/gender.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(SMS_GENDER_ADAPTER, sms_gender_adapter_device, "sms_gender_ad // sms_gender_adapter_device - constructor //------------------------------------------------- -sms_gender_adapter_device::sms_gender_adapter_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_gender_adapter_device::sms_gender_adapter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_GENDER_ADAPTER, tag, owner, clock), device_sms_expansion_slot_interface(mconfig, *this), m_subslot(*this, "subslot") diff --git a/src/devices/bus/sms_exp/gender.h b/src/devices/bus/sms_exp/gender.h index 7620d5c5cec..286b357d18b 100644 --- a/src/devices/bus/sms_exp/gender.h +++ b/src/devices/bus/sms_exp/gender.h @@ -28,7 +28,7 @@ class sms_gender_adapter_device : public device_t, { public: // construction/destruction - sms_gender_adapter_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sms_gender_adapter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_sms_expansion_slot_interface overrides virtual uint8_t read(offs_t offset) override; diff --git a/src/devices/bus/sms_exp/smsexp.cpp b/src/devices/bus/sms_exp/smsexp.cpp index 0d330f888b6..ec348d46646 100644 --- a/src/devices/bus/sms_exp/smsexp.cpp +++ b/src/devices/bus/sms_exp/smsexp.cpp @@ -55,7 +55,7 @@ device_sms_expansion_slot_interface::~device_sms_expansion_slot_interface() // sms_expansion_slot_device - constructor //------------------------------------------------- -sms_expansion_slot_device::sms_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sms_expansion_slot_device::sms_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMS_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_sms_expansion_slot_interface>(mconfig, *this), m_device(nullptr) diff --git a/src/devices/bus/sms_exp/smsexp.h b/src/devices/bus/sms_exp/smsexp.h index 1fb6a709468..a210444e06e 100644 --- a/src/devices/bus/sms_exp/smsexp.h +++ b/src/devices/bus/sms_exp/smsexp.h @@ -50,14 +50,14 @@ public: // construction/destruction template <typename T> sms_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : sms_expansion_slot_device(mconfig, tag, owner, 0) + : sms_expansion_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sms_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sms_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~sms_expansion_slot_device(); // reading and writing diff --git a/src/devices/bus/snes/bsx.cpp b/src/devices/bus/snes/bsx.cpp index 6aacaa3ed2c..8b776ac3d45 100644 --- a/src/devices/bus/snes/bsx.cpp +++ b/src/devices/bus/snes/bsx.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(SNS_HIROM_BSX, sns_rom_bsxhi_device, "sns_rom_bsxhi", "SNE DEFINE_DEVICE_TYPE(SNS_BSMEMPAK, sns_rom_bsmempak_device, "sns_bsmempak", "SNES BS-X Memory packs") -sns_rom_bsx_device::sns_rom_bsx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sns_rom_bsx_device::sns_rom_bsx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, type, tag, owner, clock) , m_base_unit(nullptr) , access_00_1f(0) @@ -37,24 +37,24 @@ sns_rom_bsx_device::sns_rom_bsx_device(const machine_config &mconfig, device_typ { } -sns_rom_bsx_device::sns_rom_bsx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_bsx_device::sns_rom_bsx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_bsx_device(mconfig, SNS_ROM_BSX, tag, owner, clock) { } -sns_rom_bsxlo_device::sns_rom_bsxlo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_bsxlo_device::sns_rom_bsxlo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_BSX, tag, owner, clock) , m_slot(*this, "bs_slot") { } -sns_rom_bsxhi_device::sns_rom_bsxhi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_bsxhi_device::sns_rom_bsxhi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom21_device(mconfig, SNS_HIROM_BSX, tag, owner, clock) , m_slot(*this, "bs_slot") { } -sns_rom_bsmempak_device::sns_rom_bsmempak_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_bsmempak_device::sns_rom_bsmempak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_BSMEMPAK, tag, owner, clock) , m_command(0), m_write_old(0), m_write_new(0), m_flash_enable(0), m_read_enable(0), m_write_enable(0) { diff --git a/src/devices/bus/snes/bsx.h b/src/devices/bus/snes/bsx.h index e144ff118ff..ad556887300 100644 --- a/src/devices/bus/snes/bsx.h +++ b/src/devices/bus/snes/bsx.h @@ -15,7 +15,7 @@ class sns_rom_bsx_device : public sns_rom_device { public: // construction/destruction - sns_rom_bsx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_bsx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional reading and writing virtual uint8_t read_l(offs_t offset) override; @@ -47,7 +47,7 @@ protected: running_machine& m_machine; }; - sns_rom_bsx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sns_rom_bsx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -81,7 +81,7 @@ class sns_rom_bsxlo_device : public sns_rom_device { public: // construction/destruction - sns_rom_bsxlo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_bsxlo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional reading and writing virtual uint8_t read_l(offs_t offset) override; @@ -103,7 +103,7 @@ class sns_rom_bsxhi_device : public sns_rom21_device { public: // construction/destruction - sns_rom_bsxhi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_bsxhi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional reading and writing virtual uint8_t read_l(offs_t offset) override; @@ -126,7 +126,7 @@ class sns_rom_bsmempak_device : public sns_rom_device { public: // construction/destruction - sns_rom_bsmempak_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_bsmempak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional reading and writing virtual uint8_t read_l(offs_t offset) override; diff --git a/src/devices/bus/snes/event.cpp b/src/devices/bus/snes/event.cpp index 5ce5bbca97c..6f0fb541634 100644 --- a/src/devices/bus/snes/event.cpp +++ b/src/devices/bus/snes/event.cpp @@ -20,7 +20,7 @@ DEFINE_DEVICE_TYPE(SNS_PFEST94, sns_pfest94_device, "sns_pfest94", "SNES Powerfest '94") -sns_pfest94_device::sns_pfest94_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_pfest94_device::sns_pfest94_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNS_PFEST94, tag, owner, clock) , device_sns_cart_interface(mconfig, *this) , m_upd7725(*this, "dsp") @@ -222,7 +222,7 @@ void sns_pfest94_device::dsp_data_map_lorom(address_map &map) void sns_pfest94_device::device_add_mconfig(machine_config &config) { - UPD7725(config, m_upd7725, 8000000); + UPD7725(config, m_upd7725, XTAL::u(8000000)); m_upd7725->set_addrmap(AS_PROGRAM, &sns_pfest94_device::dsp_prg_map_lorom); m_upd7725->set_addrmap(AS_DATA, &sns_pfest94_device::dsp_data_map_lorom); } diff --git a/src/devices/bus/snes/event.h b/src/devices/bus/snes/event.h index 5c075b50b27..bc22060bff9 100644 --- a/src/devices/bus/snes/event.h +++ b/src/devices/bus/snes/event.h @@ -16,7 +16,7 @@ class sns_pfest94_device : public device_t, { public: // construction/destruction - sns_pfest94_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_pfest94_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/snes/rom.cpp b/src/devices/bus/snes/rom.cpp index 0bfa07ac6af..d774a125a33 100644 --- a/src/devices/bus/snes/rom.cpp +++ b/src/devices/bus/snes/rom.cpp @@ -29,17 +29,17 @@ DEFINE_DEVICE_TYPE(SNS_LOROM_MCPIR2, sns_rom_mcpirate2_device, "sns_rom_mcpira DEFINE_DEVICE_TYPE(SNS_LOROM_20COL, sns_rom_20col_device, "sns_rom_20col", "SNES Super 20 Collection") -sns_rom_device::sns_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sns_rom_device::sns_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_sns_cart_interface(mconfig, *this) { } -sns_rom_device::sns_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_device::sns_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM, tag, owner, clock) { } -sns_rom_obc1_device::sns_rom_obc1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_obc1_device::sns_rom_obc1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_OBC1, tag, owner, clock), m_address(0), m_offset(0), m_shift(0) { } @@ -47,43 +47,43 @@ sns_rom_obc1_device::sns_rom_obc1_device(const machine_config &mconfig, const ch // Pirate LoROM 'mappers' -sns_rom_pokemon_device::sns_rom_pokemon_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_pokemon_device::sns_rom_pokemon_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_POKEMON, tag, owner, clock), m_latch(0) { } -sns_rom_tekken2_device::sns_rom_tekken2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_tekken2_device::sns_rom_tekken2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_TEKKEN2, tag, owner, clock), m_prot(0) { } -sns_rom_soulblad_device::sns_rom_soulblad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_soulblad_device::sns_rom_soulblad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_SOULBLAD, tag, owner, clock) { } -sns_rom_banana_device::sns_rom_banana_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_banana_device::sns_rom_banana_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_BANANA, tag, owner, clock) { } -sns_rom_bugs_device::sns_rom_bugs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_bugs_device::sns_rom_bugs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_BUGSLIFE, tag, owner, clock) { } // Multigame LoROM 'mappers' -sns_rom_mcpirate1_device::sns_rom_mcpirate1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_mcpirate1_device::sns_rom_mcpirate1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_MCPIR1, tag, owner, clock), m_base_bank(0) { } -sns_rom_mcpirate2_device::sns_rom_mcpirate2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_mcpirate2_device::sns_rom_mcpirate2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_MCPIR2, tag, owner, clock), m_base_bank(0) { } -sns_rom_20col_device::sns_rom_20col_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_20col_device::sns_rom_20col_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_20COL, tag, owner, clock), m_base_bank(0) { } diff --git a/src/devices/bus/snes/rom.h b/src/devices/bus/snes/rom.h index d2a09b774c1..0a47f00dc8f 100644 --- a/src/devices/bus/snes/rom.h +++ b/src/devices/bus/snes/rom.h @@ -14,14 +14,14 @@ class sns_rom_device : public device_t, public device_sns_cart_interface { public: // construction/destruction - sns_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_l(offs_t offset) override; virtual uint8_t read_h(offs_t offset) override; protected: - sns_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sns_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -33,7 +33,7 @@ class sns_rom_obc1_device : public sns_rom_device { public: // construction/destruction - sns_rom_obc1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_obc1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional reading and writing virtual uint8_t chip_read(offs_t offset) override; @@ -58,7 +58,7 @@ class sns_rom_pokemon_device : public sns_rom_device { public: // construction/destruction - sns_rom_pokemon_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_pokemon_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing (protection device) virtual uint8_t chip_read(offs_t offset) override; @@ -78,7 +78,7 @@ class sns_rom_tekken2_device : public sns_rom_device { public: // construction/destruction - sns_rom_tekken2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_tekken2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing (protection device) virtual uint8_t chip_read(offs_t offset) override; @@ -102,7 +102,7 @@ class sns_rom_soulblad_device : public sns_rom_device { public: // construction/destruction - sns_rom_soulblad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_soulblad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing (protection device) virtual uint8_t chip_read(offs_t offset) override; @@ -114,7 +114,7 @@ class sns_rom_mcpirate1_device : public sns_rom_device { public: // construction/destruction - sns_rom_mcpirate1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_mcpirate1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_l(offs_t offset) override; @@ -135,7 +135,7 @@ class sns_rom_mcpirate2_device : public sns_rom_device { public: // construction/destruction - sns_rom_mcpirate2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_mcpirate2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_l(offs_t offset) override; @@ -156,7 +156,7 @@ class sns_rom_20col_device : public sns_rom_device { public: // construction/destruction - sns_rom_20col_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_20col_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_l(offs_t offset) override; @@ -176,7 +176,7 @@ class sns_rom_banana_device : public sns_rom_device { public: // construction/destruction - sns_rom_banana_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_banana_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing (protection device) virtual uint8_t chip_read(offs_t offset) override; @@ -196,7 +196,7 @@ class sns_rom_bugs_device : public sns_rom_device { public: // construction/destruction - sns_rom_bugs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_bugs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing (protection device) virtual uint8_t chip_read(offs_t offset) override; diff --git a/src/devices/bus/snes/rom21.cpp b/src/devices/bus/snes/rom21.cpp index 9bf43d05894..36aff77badb 100644 --- a/src/devices/bus/snes/rom21.cpp +++ b/src/devices/bus/snes/rom21.cpp @@ -19,17 +19,17 @@ DEFINE_DEVICE_TYPE(SNS_HIROM, sns_rom21_device, "sns_rom21", "SNES DEFINE_DEVICE_TYPE(SNS_HIROM_SRTC, sns_rom21_srtc_device, "sns_rom21_rtc", "SNES Cart (HiROM) + S-RTC") -sns_rom21_device::sns_rom21_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sns_rom21_device::sns_rom21_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_sns_cart_interface( mconfig, *this ) { } -sns_rom21_device::sns_rom21_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom21_device::sns_rom21_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom21_device(mconfig, SNS_HIROM, tag, owner, clock) { } -sns_rom21_srtc_device::sns_rom21_srtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom21_srtc_device::sns_rom21_srtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom21_device(mconfig, SNS_HIROM_SRTC, tag, owner, clock), m_mode(0), m_index(0) { } diff --git a/src/devices/bus/snes/rom21.h b/src/devices/bus/snes/rom21.h index fb9b0b6c65a..b8935031de9 100644 --- a/src/devices/bus/snes/rom21.h +++ b/src/devices/bus/snes/rom21.h @@ -15,14 +15,14 @@ class sns_rom21_device : public device_t, { public: // construction/destruction - sns_rom21_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom21_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_l(offs_t offset) override; virtual uint8_t read_h(offs_t offset) override; protected: - sns_rom21_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sns_rom21_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -35,7 +35,7 @@ class sns_rom21_srtc_device : public sns_rom21_device { public: // construction/destruction - sns_rom21_srtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom21_srtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t chip_read(offs_t offset) override; diff --git a/src/devices/bus/snes/sa1.cpp b/src/devices/bus/snes/sa1.cpp index 65ff3d5b251..7f3a12e5b38 100644 --- a/src/devices/bus/snes/sa1.cpp +++ b/src/devices/bus/snes/sa1.cpp @@ -86,7 +86,7 @@ DEFINE_DEVICE_TYPE(SNS_LOROM_SA1, sns_sa1_device, "sns_rom_sa1", "SNES Cart + SA-1") -sns_sa1_device::sns_sa1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sns_sa1_device::sns_sa1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNS_LOROM_SA1, tag, owner, clock) , device_sns_cart_interface(mconfig, *this) , m_sa1(*this, "sa1cpu") diff --git a/src/devices/bus/snes/sa1.h b/src/devices/bus/snes/sa1.h index 8b68820a826..15a5397c24d 100644 --- a/src/devices/bus/snes/sa1.h +++ b/src/devices/bus/snes/sa1.h @@ -17,7 +17,7 @@ class sns_sa1_device : public device_t, { public: // construction/destruction - sns_sa1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sns_sa1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/snes/sdd1.cpp b/src/devices/bus/snes/sdd1.cpp index 3b60be87609..e7ed3b92c28 100644 --- a/src/devices/bus/snes/sdd1.cpp +++ b/src/devices/bus/snes/sdd1.cpp @@ -411,14 +411,14 @@ void sns_rom_sdd1_device::SDD1_emu::SDD1emu_decompress(uint8_t *ROM, uint32_t *m DEFINE_DEVICE_TYPE(SNS_LOROM_SDD1, sns_rom_sdd1_device, "sns_rom_sdd1", "SNES Cart + S-DD1") -sns_rom_sdd1_device::sns_rom_sdd1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sns_rom_sdd1_device::sns_rom_sdd1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sns_cart_interface(mconfig, *this) , m_sdd1_enable(0), m_xfer_enable(0), m_sdd1emu(nullptr) { } -sns_rom_sdd1_device::sns_rom_sdd1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_sdd1_device::sns_rom_sdd1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_sdd1_device(mconfig, SNS_LOROM_SDD1, tag, owner, clock) { } diff --git a/src/devices/bus/snes/sdd1.h b/src/devices/bus/snes/sdd1.h index 5164a169f65..f38ee93f0d0 100644 --- a/src/devices/bus/snes/sdd1.h +++ b/src/devices/bus/snes/sdd1.h @@ -16,7 +16,7 @@ class sns_rom_sdd1_device : public device_t, { public: // construction/destruction - sns_rom_sdd1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_sdd1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_l(offs_t offset) override; @@ -27,7 +27,7 @@ public: virtual void chip_write(offs_t offset, uint8_t data) override; protected: - sns_rom_sdd1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sns_rom_sdd1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/snes/sfx.cpp b/src/devices/bus/snes/sfx.cpp index 8051fe9c8f8..af535799ea5 100644 --- a/src/devices/bus/snes/sfx.cpp +++ b/src/devices/bus/snes/sfx.cpp @@ -18,18 +18,18 @@ DEFINE_DEVICE_TYPE(SNS_LOROM_SUPERFX1, sns_rom_superfx1_device, "sns_rom_superfx DEFINE_DEVICE_TYPE(SNS_LOROM_SUPERFX2, sns_rom_superfx2_device, "sns_rom_superfx2", "SNES Cart (LoROM) + SuperFX 2") -sns_rom_superfx_device::sns_rom_superfx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sns_rom_superfx_device::sns_rom_superfx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, type, tag, owner, clock) , m_superfx(*this, "superfx") { } -sns_rom_superfx1_device::sns_rom_superfx1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_superfx1_device::sns_rom_superfx1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_superfx_device(mconfig, SNS_LOROM_SUPERFX1, tag, owner, clock) { } -sns_rom_superfx2_device::sns_rom_superfx2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_superfx2_device::sns_rom_superfx2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_superfx_device(mconfig, SNS_LOROM_SUPERFX2, tag, owner, clock) { } diff --git a/src/devices/bus/snes/sfx.h b/src/devices/bus/snes/sfx.h index 54df5a8018b..e7a614d0923 100644 --- a/src/devices/bus/snes/sfx.h +++ b/src/devices/bus/snes/sfx.h @@ -14,7 +14,7 @@ class sns_rom_superfx_device : public sns_rom_device { protected: // construction/destruction - sns_rom_superfx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sns_rom_superfx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -48,7 +48,7 @@ class sns_rom_superfx1_device : public sns_rom_superfx_device { public: // construction/destruction - sns_rom_superfx1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_superfx1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -58,7 +58,7 @@ class sns_rom_superfx2_device : public sns_rom_superfx_device { public: // construction/destruction - sns_rom_superfx2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_superfx2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/snes/sgb.cpp b/src/devices/bus/snes/sgb.cpp index 8ce9ebfab65..84392ef3e02 100644 --- a/src/devices/bus/snes/sgb.cpp +++ b/src/devices/bus/snes/sgb.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(SNS_LOROM_SUPERGB, sns_rom_sgb1_device, "sns_rom_sgb", "SNE DEFINE_DEVICE_TYPE(SNS_LOROM_SUPERGB2, sns_rom_sgb2_device, "sns_rom_sgb2", "SNES Super Game Boy 2 Cart") -sns_rom_sgb_device::sns_rom_sgb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +sns_rom_sgb_device::sns_rom_sgb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, type, tag, owner, clock), m_sgb_cpu(*this, "sgb_cpu"), m_sgb_apu(*this, "sgb_apu"), @@ -50,13 +50,13 @@ sns_rom_sgb_device::sns_rom_sgb_device(const machine_config &mconfig, device_typ } -sns_rom_sgb1_device::sns_rom_sgb1_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +sns_rom_sgb1_device::sns_rom_sgb1_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : sns_rom_sgb_device(mconfig, SNS_LOROM_SUPERGB, tag, owner, clock) { } -sns_rom_sgb2_device::sns_rom_sgb2_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +sns_rom_sgb2_device::sns_rom_sgb2_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : sns_rom_sgb_device(mconfig, SNS_LOROM_SUPERGB2, tag, owner, clock) { } @@ -134,14 +134,14 @@ void sns_rom_sgb_device::gb_timer_callback(uint8_t data) void sns_rom_sgb1_device::device_add_mconfig(machine_config &config) { - LR35902(config, m_sgb_cpu, 4295454); /* 4.295454 MHz */ + LR35902(config, m_sgb_cpu, XTAL::u(4295454)); /* 4.295454 MHz */ m_sgb_cpu->set_addrmap(AS_PROGRAM, &sns_rom_sgb1_device::supergb_map); m_sgb_cpu->timer_cb().set(FUNC(sns_rom_sgb_device::gb_timer_callback)); m_sgb_cpu->set_halt_bug(true); SGB_PPU(config, m_sgb_ppu, m_sgb_cpu); - DMG_APU(config, m_sgb_apu, 4295454); + DMG_APU(config, m_sgb_apu, XTAL::u(4295454)); GB_CART_SLOT(config, m_cartslot, gameboy_cartridges, nullptr); m_cartslot->set_space(m_sgb_cpu, AS_PROGRAM); diff --git a/src/devices/bus/snes/sgb.h b/src/devices/bus/snes/sgb.h index 46d600a704b..c783971c404 100644 --- a/src/devices/bus/snes/sgb.h +++ b/src/devices/bus/snes/sgb.h @@ -23,7 +23,7 @@ public: protected: // construction/destruction - sns_rom_sgb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sns_rom_sgb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -77,7 +77,7 @@ class sns_rom_sgb1_device : public sns_rom_sgb_device { public: // construction/destruction - sns_rom_sgb1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_sgb1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -90,7 +90,7 @@ class sns_rom_sgb2_device : public sns_rom_sgb_device { public: // construction/destruction - sns_rom_sgb2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_sgb2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/snes/snes_slot.cpp b/src/devices/bus/snes/snes_slot.cpp index 7d9dbf5e9a2..e7af9baba7e 100644 --- a/src/devices/bus/snes/snes_slot.cpp +++ b/src/devices/bus/snes/snes_slot.cpp @@ -219,7 +219,7 @@ offs_t device_sns_cart_interface::address_r() //------------------------------------------------- // base_sns_cart_slot_device - constructor //------------------------------------------------- -base_sns_cart_slot_device::base_sns_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +base_sns_cart_slot_device::base_sns_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_slot_interface(mconfig, *this), @@ -231,17 +231,17 @@ base_sns_cart_slot_device::base_sns_cart_slot_device(const machine_config &mconf { } -sns_cart_slot_device::sns_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sns_cart_slot_device::sns_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : base_sns_cart_slot_device(mconfig, SNS_CART_SLOT, tag, owner, clock) { } -sns_sufami_cart_slot_device::sns_sufami_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sns_sufami_cart_slot_device::sns_sufami_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : base_sns_cart_slot_device(mconfig, SNS_SUFAMI_CART_SLOT, tag, owner, clock) { } -sns_bsx_cart_slot_device::sns_bsx_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sns_bsx_cart_slot_device::sns_bsx_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : base_sns_cart_slot_device(mconfig, SNS_BSX_CART_SLOT, tag, owner, clock) { } diff --git a/src/devices/bus/snes/snes_slot.h b/src/devices/bus/snes/snes_slot.h index ec777ee8cc1..4077d64be1f 100644 --- a/src/devices/bus/snes/snes_slot.h +++ b/src/devices/bus/snes/snes_slot.h @@ -234,7 +234,7 @@ public: device_sns_cart_interface* m_cart; protected: - base_sns_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + base_sns_cart_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -253,7 +253,7 @@ class sns_cart_slot_device : public base_sns_cart_slot_device public: // construction/destruction template <typename T> - sns_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&opts, const char *dflt) + sns_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : sns_cart_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -261,7 +261,7 @@ public: set_default_option(dflt); set_fixed(false); } - sns_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "snes_cart"; } virtual const char *file_extensions() const noexcept override { return "sfc"; } }; @@ -274,14 +274,14 @@ public: // construction/destruction template <typename T> sns_sufami_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : sns_sufami_cart_slot_device(mconfig, tag, owner, 0) + : sns_sufami_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sns_sufami_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_sufami_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "st_cart"; } virtual const char *file_extensions() const noexcept override { return "st"; } }; @@ -294,14 +294,14 @@ public: // construction/destruction template <typename T> sns_bsx_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : sns_bsx_cart_slot_device(mconfig, tag, owner, 0) + : sns_bsx_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sns_bsx_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_bsx_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual const char *image_interface() const noexcept override { return "bspack"; } virtual const char *file_extensions() const noexcept override { return "bs"; } }; diff --git a/src/devices/bus/snes/spc7110.cpp b/src/devices/bus/snes/spc7110.cpp index 20d59dc681a..9c975d17bee 100644 --- a/src/devices/bus/snes/spc7110.cpp +++ b/src/devices/bus/snes/spc7110.cpp @@ -42,7 +42,7 @@ DEFINE_DEVICE_TYPE(SNS_HIROM_SPC7110, sns_rom_spc7110_device, "sns_rom_sp DEFINE_DEVICE_TYPE(SNS_HIROM_SPC7110_RTC, sns_rom_spc7110rtc_device, "sns_rom_spc7110rtc", "SNES Cart + SPC7110 + RTC") -sns_rom_spc7110_device::sns_rom_spc7110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sns_rom_spc7110_device::sns_rom_spc7110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sns_rom21_device(mconfig, type, tag, owner, clock) , m_r4801(0), m_r4802(0), m_r4803(0), m_r4804(0), m_r4805(0), m_r4806(0), m_r4807(0), m_r4808(0), m_r4809(0), m_r480a(0), m_r480b(0), m_r480c(0) , m_decomp(nullptr) @@ -55,12 +55,12 @@ sns_rom_spc7110_device::sns_rom_spc7110_device(const machine_config &mconfig, de { } -sns_rom_spc7110_device::sns_rom_spc7110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_spc7110_device::sns_rom_spc7110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_spc7110_device(mconfig, SNS_HIROM_SPC7110, tag, owner, clock) { } -sns_rom_spc7110rtc_device::sns_rom_spc7110rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_spc7110rtc_device::sns_rom_spc7110rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_spc7110_device(mconfig, SNS_HIROM_SPC7110_RTC, tag, owner, clock) { } diff --git a/src/devices/bus/snes/spc7110.h b/src/devices/bus/snes/spc7110.h index a7c798244c1..d364c26dfc3 100644 --- a/src/devices/bus/snes/spc7110.h +++ b/src/devices/bus/snes/spc7110.h @@ -15,7 +15,7 @@ class sns_rom_spc7110_device : public sns_rom21_device { public: // construction/destruction - sns_rom_spc7110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_spc7110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_l(offs_t offset) override; @@ -27,7 +27,7 @@ public: virtual void chip_write(offs_t offset, uint8_t data) override; protected: - sns_rom_spc7110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sns_rom_spc7110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -194,7 +194,7 @@ class sns_rom_spc7110rtc_device : public sns_rom_spc7110_device { public: // construction/destruction - sns_rom_spc7110rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_spc7110rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing diff --git a/src/devices/bus/snes/sufami.cpp b/src/devices/bus/snes/sufami.cpp index 7589fb84fa4..42d1154d630 100644 --- a/src/devices/bus/snes/sufami.cpp +++ b/src/devices/bus/snes/sufami.cpp @@ -24,14 +24,14 @@ DEFINE_DEVICE_TYPE(SNS_LOROM_SUFAMI, sns_rom_sufami_device, "sns_rom_sufami", "S DEFINE_DEVICE_TYPE(SNS_STROM, sns_rom_strom_device, "sns_strom", "SNES Sufami Turbo Minicart") -sns_rom_sufami_device::sns_rom_sufami_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_sufami_device::sns_rom_sufami_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_LOROM_SUFAMI, tag, owner, clock) , m_slot1(*this, "st_slot1") , m_slot2(*this, "st_slot2") { } -sns_rom_strom_device::sns_rom_strom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_strom_device::sns_rom_strom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, SNS_STROM, tag, owner, clock) { } diff --git a/src/devices/bus/snes/sufami.h b/src/devices/bus/snes/sufami.h index 1b231131a2b..6ab2e6f2d5b 100644 --- a/src/devices/bus/snes/sufami.h +++ b/src/devices/bus/snes/sufami.h @@ -15,7 +15,7 @@ class sns_rom_sufami_device : public sns_rom_device { public: // construction/destruction - sns_rom_sufami_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_sufami_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional reading and writing virtual uint8_t read_l(offs_t offset) override; @@ -40,7 +40,7 @@ class sns_rom_strom_device : public sns_rom_device { public: // construction/destruction - sns_rom_strom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_strom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional reading and writing virtual uint8_t read_l(offs_t offset) override; diff --git a/src/devices/bus/snes/upd.cpp b/src/devices/bus/snes/upd.cpp index 476a1b42544..dd97cdf6626 100644 --- a/src/devices/bus/snes/upd.cpp +++ b/src/devices/bus/snes/upd.cpp @@ -32,37 +32,37 @@ DEFINE_DEVICE_TYPE(SNS_LOROM_SETA10, sns_rom_seta10dsp_device, "sns_rom_seta10", DEFINE_DEVICE_TYPE(SNS_LOROM_SETA11, sns_rom_seta11dsp_device, "sns_rom_seta11", "SNES Cart (LoROM) + Seta ST011 DSP") -sns_rom20_necdsp_device::sns_rom20_necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sns_rom20_necdsp_device::sns_rom20_necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, type, tag, owner, clock), m_upd7725(*this, "dsp") { } -sns_rom20_necdsp_device::sns_rom20_necdsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom20_necdsp_device::sns_rom20_necdsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom20_necdsp_device(mconfig, SNS_LOROM_NECDSP, tag, owner, clock) { } -sns_rom21_necdsp_device::sns_rom21_necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sns_rom21_necdsp_device::sns_rom21_necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sns_rom21_device(mconfig, type, tag, owner, clock), m_upd7725(*this, "dsp") { } -sns_rom21_necdsp_device::sns_rom21_necdsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom21_necdsp_device::sns_rom21_necdsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom21_necdsp_device(mconfig, SNS_HIROM_NECDSP, tag, owner, clock) { } -sns_rom_setadsp_device::sns_rom_setadsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sns_rom_setadsp_device::sns_rom_setadsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_device(mconfig, type, tag, owner, clock), m_upd96050(*this, "dsp") { } -sns_rom_seta10dsp_device::sns_rom_seta10dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_seta10dsp_device::sns_rom_seta10dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_setadsp_device(mconfig, SNS_LOROM_SETA10, tag, owner, clock) { } -sns_rom_seta11dsp_device::sns_rom_seta11dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_seta11dsp_device::sns_rom_seta11dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_setadsp_device(mconfig, SNS_LOROM_SETA11, tag, owner, clock) { } @@ -134,7 +134,7 @@ void sns_rom20_necdsp_device::dsp_data_map_lorom(address_map &map) void sns_rom20_necdsp_device::device_add_mconfig(machine_config &config) { - UPD7725(config, m_upd7725, 8000000); + UPD7725(config, m_upd7725, XTAL::u(8000000)); m_upd7725->set_addrmap(AS_PROGRAM, &sns_rom20_necdsp_device::dsp_prg_map_lorom); m_upd7725->set_addrmap(AS_DATA, &sns_rom20_necdsp_device::dsp_data_map_lorom); } @@ -192,7 +192,7 @@ void sns_rom21_necdsp_device::dsp_data_map_hirom(address_map &map) void sns_rom21_necdsp_device::device_add_mconfig(machine_config &config) { - UPD7725(config, m_upd7725, 8000000); + UPD7725(config, m_upd7725, XTAL::u(8000000)); m_upd7725->set_addrmap(AS_PROGRAM, &sns_rom21_necdsp_device::dsp_prg_map_hirom); m_upd7725->set_addrmap(AS_DATA, &sns_rom21_necdsp_device::dsp_data_map_hirom); } @@ -304,7 +304,7 @@ void sns_rom_setadsp_device::st01x_data_map(address_map &map) void sns_rom_seta10dsp_device::device_add_mconfig(machine_config &config) { - UPD96050(config, m_upd96050, 10000000); + UPD96050(config, m_upd96050, XTAL::u(10000000)); m_upd96050->set_addrmap(AS_PROGRAM, &sns_rom_seta10dsp_device::st01x_prg_map); m_upd96050->set_addrmap(AS_DATA, &sns_rom_seta10dsp_device::st01x_data_map); } @@ -312,7 +312,7 @@ void sns_rom_seta10dsp_device::device_add_mconfig(machine_config &config) void sns_rom_seta11dsp_device::device_add_mconfig(machine_config &config) { - UPD96050(config, m_upd96050, 15000000); + UPD96050(config, m_upd96050, XTAL::u(15000000)); m_upd96050->set_addrmap(AS_PROGRAM, &sns_rom_seta11dsp_device::st01x_prg_map); m_upd96050->set_addrmap(AS_DATA, &sns_rom_seta11dsp_device::st01x_data_map); } @@ -368,42 +368,42 @@ DEFINE_DEVICE_TYPE(SNS_LOROM_SETA10_LEG, sns_rom_seta10dsp_legacy_device, "sn DEFINE_DEVICE_TYPE(SNS_LOROM_SETA11_LEG, sns_rom_seta11dsp_legacy_device, "sns_seta11leg", "SNES Cart (LoROM) + SETA ST011 DSP Legacy") -sns_rom20_necdsp1_legacy_device::sns_rom20_necdsp1_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom20_necdsp1_legacy_device::sns_rom20_necdsp1_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom20_necdsp_device(mconfig, SNS_LOROM_NECDSP1_LEG, tag, owner, clock) { } -sns_rom20_necdsp1b_legacy_device::sns_rom20_necdsp1b_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom20_necdsp1b_legacy_device::sns_rom20_necdsp1b_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom20_necdsp_device(mconfig, SNS_LOROM_NECDSP1B_LEG, tag, owner, clock) { } -sns_rom20_necdsp2_legacy_device::sns_rom20_necdsp2_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom20_necdsp2_legacy_device::sns_rom20_necdsp2_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom20_necdsp_device(mconfig, SNS_LOROM_NECDSP2_LEG, tag, owner, clock) { } -sns_rom20_necdsp3_legacy_device::sns_rom20_necdsp3_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom20_necdsp3_legacy_device::sns_rom20_necdsp3_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom20_necdsp_device(mconfig, SNS_LOROM_NECDSP3_LEG, tag, owner, clock) { } -sns_rom20_necdsp4_legacy_device::sns_rom20_necdsp4_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom20_necdsp4_legacy_device::sns_rom20_necdsp4_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom20_necdsp_device(mconfig, SNS_LOROM_NECDSP4_LEG, tag, owner, clock) { } -sns_rom21_necdsp1_legacy_device::sns_rom21_necdsp1_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom21_necdsp1_legacy_device::sns_rom21_necdsp1_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom21_necdsp_device(mconfig, SNS_HIROM_NECDSP1_LEG, tag, owner, clock) { } -sns_rom_seta10dsp_legacy_device::sns_rom_seta10dsp_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_seta10dsp_legacy_device::sns_rom_seta10dsp_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_setadsp_device(mconfig, SNS_LOROM_SETA10_LEG, tag, owner, clock) { } -sns_rom_seta11dsp_legacy_device::sns_rom_seta11dsp_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sns_rom_seta11dsp_legacy_device::sns_rom_seta11dsp_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sns_rom_setadsp_device(mconfig, SNS_LOROM_SETA11_LEG, tag, owner, clock) { } @@ -411,56 +411,56 @@ sns_rom_seta11dsp_legacy_device::sns_rom_seta11dsp_legacy_device(const machine_c void sns_rom20_necdsp1_legacy_device::device_add_mconfig(machine_config &config) { - UPD7725(config, m_upd7725, 8000000); + UPD7725(config, m_upd7725, XTAL::u(8000000)); m_upd7725->set_addrmap(AS_PROGRAM, &sns_rom20_necdsp1_legacy_device::dsp_prg_map_lorom); m_upd7725->set_addrmap(AS_DATA, &sns_rom20_necdsp1_legacy_device::dsp_data_map_lorom); } void sns_rom20_necdsp1b_legacy_device::device_add_mconfig(machine_config &config) { - UPD7725(config, m_upd7725, 8000000); + UPD7725(config, m_upd7725, XTAL::u(8000000)); m_upd7725->set_addrmap(AS_PROGRAM, &sns_rom20_necdsp1b_legacy_device::dsp_prg_map_lorom); m_upd7725->set_addrmap(AS_DATA, &sns_rom20_necdsp1b_legacy_device::dsp_data_map_lorom); } void sns_rom20_necdsp2_legacy_device::device_add_mconfig(machine_config &config) { - UPD7725(config, m_upd7725, 8000000); + UPD7725(config, m_upd7725, XTAL::u(8000000)); m_upd7725->set_addrmap(AS_PROGRAM, &sns_rom20_necdsp2_legacy_device::dsp_prg_map_lorom); m_upd7725->set_addrmap(AS_DATA, &sns_rom20_necdsp2_legacy_device::dsp_data_map_lorom); } void sns_rom20_necdsp3_legacy_device::device_add_mconfig(machine_config &config) { - UPD7725(config, m_upd7725, 8000000); + UPD7725(config, m_upd7725, XTAL::u(8000000)); m_upd7725->set_addrmap(AS_PROGRAM, &sns_rom20_necdsp3_legacy_device::dsp_prg_map_lorom); m_upd7725->set_addrmap(AS_DATA, &sns_rom20_necdsp3_legacy_device::dsp_data_map_lorom); } void sns_rom20_necdsp4_legacy_device::device_add_mconfig(machine_config &config) { - UPD7725(config, m_upd7725, 8000000); + UPD7725(config, m_upd7725, XTAL::u(8000000)); m_upd7725->set_addrmap(AS_PROGRAM, &sns_rom20_necdsp4_legacy_device::dsp_prg_map_lorom); m_upd7725->set_addrmap(AS_DATA, &sns_rom20_necdsp4_legacy_device::dsp_data_map_lorom); } void sns_rom21_necdsp1_legacy_device::device_add_mconfig(machine_config &config) { - UPD7725(config, m_upd7725, 8000000); + UPD7725(config, m_upd7725, XTAL::u(8000000)); m_upd7725->set_addrmap(AS_PROGRAM, &sns_rom21_necdsp1_legacy_device::dsp_prg_map_hirom); m_upd7725->set_addrmap(AS_DATA, &sns_rom21_necdsp1_legacy_device::dsp_data_map_hirom); } void sns_rom_seta10dsp_legacy_device::device_add_mconfig(machine_config &config) { - UPD96050(config, m_upd96050, 10000000); + UPD96050(config, m_upd96050, XTAL::u(10000000)); m_upd96050->set_addrmap(AS_PROGRAM, &sns_rom_seta10dsp_legacy_device::st01x_prg_map); m_upd96050->set_addrmap(AS_DATA, &sns_rom_seta10dsp_legacy_device::st01x_data_map); } void sns_rom_seta11dsp_legacy_device::device_add_mconfig(machine_config &config) { - UPD96050(config, m_upd96050, 15000000); + UPD96050(config, m_upd96050, XTAL::u(15000000)); m_upd96050->set_addrmap(AS_PROGRAM, &sns_rom_seta11dsp_legacy_device::st01x_prg_map); m_upd96050->set_addrmap(AS_DATA, &sns_rom_seta11dsp_legacy_device::st01x_data_map); } diff --git a/src/devices/bus/snes/upd.h b/src/devices/bus/snes/upd.h index 65dd780c725..cdeffeca499 100644 --- a/src/devices/bus/snes/upd.h +++ b/src/devices/bus/snes/upd.h @@ -16,10 +16,10 @@ class sns_rom20_necdsp_device : public sns_rom_device { public: // construction/destruction - sns_rom20_necdsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom20_necdsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - sns_rom20_necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sns_rom20_necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -50,10 +50,10 @@ class sns_rom21_necdsp_device : public sns_rom21_device { public: // construction/destruction - sns_rom21_necdsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom21_necdsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - sns_rom21_necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sns_rom21_necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -87,7 +87,7 @@ public: protected: // construction/destruction - sns_rom_setadsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sns_rom_setadsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -115,7 +115,7 @@ class sns_rom_seta10dsp_device : public sns_rom_setadsp_device { public: // construction/destruction - sns_rom_seta10dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_seta10dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -128,7 +128,7 @@ class sns_rom_seta11dsp_device : public sns_rom_setadsp_device { public: // construction/destruction - sns_rom_seta11dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_seta11dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -150,7 +150,7 @@ class sns_rom20_necdsp1_legacy_device : public sns_rom20_necdsp_device { public: // construction/destruction - sns_rom20_necdsp1_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom20_necdsp1_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -162,7 +162,7 @@ class sns_rom20_necdsp1b_legacy_device : public sns_rom20_necdsp_device { public: // construction/destruction - sns_rom20_necdsp1b_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom20_necdsp1b_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -174,7 +174,7 @@ class sns_rom20_necdsp2_legacy_device : public sns_rom20_necdsp_device { public: // construction/destruction - sns_rom20_necdsp2_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom20_necdsp2_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -186,7 +186,7 @@ class sns_rom20_necdsp3_legacy_device : public sns_rom20_necdsp_device { public: // construction/destruction - sns_rom20_necdsp3_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom20_necdsp3_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -198,7 +198,7 @@ class sns_rom20_necdsp4_legacy_device : public sns_rom20_necdsp_device { public: // construction/destruction - sns_rom20_necdsp4_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom20_necdsp4_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -210,7 +210,7 @@ class sns_rom21_necdsp1_legacy_device : public sns_rom21_necdsp_device { public: // construction/destruction - sns_rom21_necdsp1_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom21_necdsp1_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -222,7 +222,7 @@ class sns_rom_seta10dsp_legacy_device : public sns_rom_setadsp_device { public: // construction/destruction - sns_rom_seta10dsp_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_seta10dsp_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -234,7 +234,7 @@ class sns_rom_seta11dsp_legacy_device : public sns_rom_setadsp_device { public: // construction/destruction - sns_rom_seta11dsp_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sns_rom_seta11dsp_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/snes_ctrl/bcbattle.cpp b/src/devices/bus/snes_ctrl/bcbattle.cpp index c5d78bc04b3..aea7e65ffdb 100644 --- a/src/devices/bus/snes_ctrl/bcbattle.cpp +++ b/src/devices/bus/snes_ctrl/bcbattle.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(SNES_BARCODE_BATTLER, snes_bcbattle_device, "snes_bcbattle", void snes_bcbattle_device::device_add_mconfig(machine_config &config) { - BARCODE_READER(config, "battler", 0); + BARCODE_READER(config, "battler"); } @@ -71,7 +71,7 @@ TIMER_CALLBACK_MEMBER(snes_bcbattle_device::scan_tick) // snes_bcbattle_device - constructor //------------------------------------------------- -snes_bcbattle_device::snes_bcbattle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +snes_bcbattle_device::snes_bcbattle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNES_BARCODE_BATTLER, tag, owner, clock), device_snes_control_port_interface(mconfig, *this), m_reader(*this, "battler"), diff --git a/src/devices/bus/snes_ctrl/bcbattle.h b/src/devices/bus/snes_ctrl/bcbattle.h index a7073ac4ba0..45b7eb21ffd 100644 --- a/src/devices/bus/snes_ctrl/bcbattle.h +++ b/src/devices/bus/snes_ctrl/bcbattle.h @@ -26,7 +26,7 @@ class snes_bcbattle_device : public device_t, { public: // construction/destruction - snes_bcbattle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snes_bcbattle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/snes_ctrl/ctrl.cpp b/src/devices/bus/snes_ctrl/ctrl.cpp index 68e69ee0a8b..f8cb2b98708 100644 --- a/src/devices/bus/snes_ctrl/ctrl.cpp +++ b/src/devices/bus/snes_ctrl/ctrl.cpp @@ -59,7 +59,7 @@ device_snes_control_port_interface::~device_snes_control_port_interface() // snes_control_port_device - constructor //------------------------------------------------- -snes_control_port_device::snes_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +snes_control_port_device::snes_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNES_CONTROL_PORT, tag, owner, clock), device_single_card_slot_interface<device_snes_control_port_interface>(mconfig, *this), m_onscreen_cb(*this), diff --git a/src/devices/bus/snes_ctrl/ctrl.h b/src/devices/bus/snes_ctrl/ctrl.h index b6e6ddc869e..9fd5a81a481 100644 --- a/src/devices/bus/snes_ctrl/ctrl.h +++ b/src/devices/bus/snes_ctrl/ctrl.h @@ -52,14 +52,14 @@ public: // construction/destruction template <typename T> snes_control_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : snes_control_port_device(mconfig, tag, owner, 0) + : snes_control_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - snes_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + snes_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~snes_control_port_device(); template <typename... T> void set_onscreen_callback(T &&... args) { m_onscreen_cb.set(std::forward<T>(args)...); } diff --git a/src/devices/bus/snes_ctrl/joypad.cpp b/src/devices/bus/snes_ctrl/joypad.cpp index b421ba1de11..61fd75e8c80 100644 --- a/src/devices/bus/snes_ctrl/joypad.cpp +++ b/src/devices/bus/snes_ctrl/joypad.cpp @@ -53,7 +53,7 @@ ioport_constructor snes_joypad_device::device_input_ports() const // snes_joypad_device - constructor //------------------------------------------------- -snes_joypad_device::snes_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +snes_joypad_device::snes_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNES_JOYPAD, tag, owner, clock), device_snes_control_port_interface(mconfig, *this), m_joypad(*this, "JOYPAD"), diff --git a/src/devices/bus/snes_ctrl/joypad.h b/src/devices/bus/snes_ctrl/joypad.h index 204cceac6d5..07207ec37d0 100644 --- a/src/devices/bus/snes_ctrl/joypad.h +++ b/src/devices/bus/snes_ctrl/joypad.h @@ -25,7 +25,7 @@ class snes_joypad_device : public device_t, { public: // construction/destruction - snes_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snes_joypad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/snes_ctrl/miracle.cpp b/src/devices/bus/snes_ctrl/miracle.cpp index f20647a10b4..fb51444523b 100644 --- a/src/devices/bus/snes_ctrl/miracle.cpp +++ b/src/devices/bus/snes_ctrl/miracle.cpp @@ -48,7 +48,7 @@ TIMER_CALLBACK_MEMBER(snes_miracle_device::strobe_tick) // snes_miracle_device - constructor //------------------------------------------------- -snes_miracle_device::snes_miracle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +snes_miracle_device::snes_miracle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNES_MIRACLE, tag, owner, clock), device_serial_interface(mconfig, *this), device_snes_control_port_interface(mconfig, *this), @@ -89,8 +89,8 @@ void snes_miracle_device::device_reset() // set standard MIDI parameters set_data_frame(1, 8, PARITY_NONE, STOP_BITS_1); - set_rcv_rate(31250); - set_tra_rate(31250); + set_rcv_rate(XTAL::u(31250)); + set_tra_rate(XTAL::u(31250)); m_xmit_read = m_xmit_write = 0; m_recv_read = m_recv_write = 0; diff --git a/src/devices/bus/snes_ctrl/miracle.h b/src/devices/bus/snes_ctrl/miracle.h index b2bf08d2a49..79bd86caca9 100644 --- a/src/devices/bus/snes_ctrl/miracle.h +++ b/src/devices/bus/snes_ctrl/miracle.h @@ -28,7 +28,7 @@ class snes_miracle_device : public device_t, { public: // construction/destruction - snes_miracle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snes_miracle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: static constexpr int XMIT_RING_SIZE = 64; diff --git a/src/devices/bus/snes_ctrl/mouse.cpp b/src/devices/bus/snes_ctrl/mouse.cpp index 24e3e13ba23..fc829b1975a 100644 --- a/src/devices/bus/snes_ctrl/mouse.cpp +++ b/src/devices/bus/snes_ctrl/mouse.cpp @@ -59,7 +59,7 @@ ioport_constructor snes_mouse_device::device_input_ports() const // snes_mouse_device - constructor //------------------------------------------------- -snes_mouse_device::snes_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +snes_mouse_device::snes_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNES_MOUSE, tag, owner, clock), device_snes_control_port_interface(mconfig, *this), m_buttons(*this, "BUTTONS"), diff --git a/src/devices/bus/snes_ctrl/mouse.h b/src/devices/bus/snes_ctrl/mouse.h index cd6f3839950..40174e899c7 100644 --- a/src/devices/bus/snes_ctrl/mouse.h +++ b/src/devices/bus/snes_ctrl/mouse.h @@ -25,7 +25,7 @@ class snes_mouse_device : public device_t, { public: // construction/destruction - snes_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snes_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/snes_ctrl/multitap.cpp b/src/devices/bus/snes_ctrl/multitap.cpp index ef630439276..b6d4b60ba6e 100644 --- a/src/devices/bus/snes_ctrl/multitap.cpp +++ b/src/devices/bus/snes_ctrl/multitap.cpp @@ -64,7 +64,7 @@ void snes_multitap_device::device_add_mconfig(machine_config &config) // snes_multitap_device - constructor //------------------------------------------------- -snes_multitap_device::snes_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +snes_multitap_device::snes_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNES_MULTITAP, tag, owner, clock), device_snes_control_port_interface(mconfig, *this), m_port1(*this, "port1"), diff --git a/src/devices/bus/snes_ctrl/multitap.h b/src/devices/bus/snes_ctrl/multitap.h index 779744fe753..e29189d06e2 100644 --- a/src/devices/bus/snes_ctrl/multitap.h +++ b/src/devices/bus/snes_ctrl/multitap.h @@ -25,7 +25,7 @@ class snes_multitap_device : public device_t, { public: // construction/destruction - snes_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snes_multitap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/snes_ctrl/pachinko.cpp b/src/devices/bus/snes_ctrl/pachinko.cpp index 010385e6459..36a40ee1eb5 100644 --- a/src/devices/bus/snes_ctrl/pachinko.cpp +++ b/src/devices/bus/snes_ctrl/pachinko.cpp @@ -45,7 +45,7 @@ ioport_constructor snes_pachinko_device::device_input_ports() const // snes_pachinko_device - constructor //------------------------------------------------- -snes_pachinko_device::snes_pachinko_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +snes_pachinko_device::snes_pachinko_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNES_PACHINKO, tag, owner, clock), device_snes_control_port_interface(mconfig, *this), m_dial(*this, "DIAL"), diff --git a/src/devices/bus/snes_ctrl/pachinko.h b/src/devices/bus/snes_ctrl/pachinko.h index 0fffa05767a..9fea189f060 100644 --- a/src/devices/bus/snes_ctrl/pachinko.h +++ b/src/devices/bus/snes_ctrl/pachinko.h @@ -25,7 +25,7 @@ class snes_pachinko_device : public device_t, { public: // construction/destruction - snes_pachinko_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snes_pachinko_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/snes_ctrl/sscope.cpp b/src/devices/bus/snes_ctrl/sscope.cpp index 71a049adb82..6ae8097a616 100644 --- a/src/devices/bus/snes_ctrl/sscope.cpp +++ b/src/devices/bus/snes_ctrl/sscope.cpp @@ -54,7 +54,7 @@ ioport_constructor snes_sscope_device::device_input_ports() const // snes_sscope_device - constructor //------------------------------------------------- -snes_sscope_device::snes_sscope_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +snes_sscope_device::snes_sscope_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNES_SUPERSCOPE, tag, owner, clock), device_snes_control_port_interface(mconfig, *this), m_buttons(*this, "BUTTONS"), diff --git a/src/devices/bus/snes_ctrl/sscope.h b/src/devices/bus/snes_ctrl/sscope.h index b81afda179d..742f88c402d 100644 --- a/src/devices/bus/snes_ctrl/sscope.h +++ b/src/devices/bus/snes_ctrl/sscope.h @@ -25,7 +25,7 @@ class snes_sscope_device : public device_t, { public: // construction/destruction - snes_sscope_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snes_sscope_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/snes_ctrl/twintap.cpp b/src/devices/bus/snes_ctrl/twintap.cpp index 25327786b10..d59317687e4 100644 --- a/src/devices/bus/snes_ctrl/twintap.cpp +++ b/src/devices/bus/snes_ctrl/twintap.cpp @@ -50,7 +50,7 @@ ioport_constructor snes_twintap_device::device_input_ports() const // snes_twintap_device - constructor //------------------------------------------------- -snes_twintap_device::snes_twintap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +snes_twintap_device::snes_twintap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNES_TWINTAP, tag, owner, clock), device_snes_control_port_interface(mconfig, *this), m_inputs(*this, "INPUTS"), diff --git a/src/devices/bus/snes_ctrl/twintap.h b/src/devices/bus/snes_ctrl/twintap.h index ccd1d4cfef8..c745b169729 100644 --- a/src/devices/bus/snes_ctrl/twintap.h +++ b/src/devices/bus/snes_ctrl/twintap.h @@ -25,7 +25,7 @@ class snes_twintap_device : public device_t, { public: // construction/destruction - snes_twintap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snes_twintap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/spc1000/exp.cpp b/src/devices/bus/spc1000/exp.cpp index ba8b22c1456..12575e10f2a 100644 --- a/src/devices/bus/spc1000/exp.cpp +++ b/src/devices/bus/spc1000/exp.cpp @@ -35,7 +35,7 @@ device_spc1000_card_interface::~device_spc1000_card_interface() //------------------------------------------------- // spc1000_exp_device - constructor //------------------------------------------------- -spc1000_exp_device::spc1000_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spc1000_exp_device::spc1000_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPC1000_EXP_SLOT, tag, owner, clock), device_single_card_slot_interface<device_spc1000_card_interface>(mconfig, *this), m_card(nullptr) diff --git a/src/devices/bus/spc1000/exp.h b/src/devices/bus/spc1000/exp.h index e2b1baeb958..7042058ebd4 100644 --- a/src/devices/bus/spc1000/exp.h +++ b/src/devices/bus/spc1000/exp.h @@ -30,14 +30,14 @@ public: // construction/destruction template <typename T> spc1000_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts) - : spc1000_exp_device(mconfig, tag, owner, (uint32_t)0) + : spc1000_exp_device(mconfig, tag, owner) { opts(*this); set_default_option(nullptr); set_fixed(false); } - spc1000_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spc1000_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~spc1000_exp_device(); // reading and writing diff --git a/src/devices/bus/spc1000/fdd.cpp b/src/devices/bus/spc1000/fdd.cpp index fe668127328..8129c1751d2 100644 --- a/src/devices/bus/spc1000/fdd.cpp +++ b/src/devices/bus/spc1000/fdd.cpp @@ -138,7 +138,7 @@ DEFINE_DEVICE_TYPE(SPC1000_FDD_EXP, spc1000_fdd_exp_device, "spc1000_fdd_exp", " // spc1000_fdd_exp_device - constructor //------------------------------------------------- -spc1000_fdd_exp_device::spc1000_fdd_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spc1000_fdd_exp_device::spc1000_fdd_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPC1000_FDD_EXP, tag, owner, clock), device_spc1000_card_interface(mconfig, *this), m_cpu(*this, "fdccpu"), diff --git a/src/devices/bus/spc1000/fdd.h b/src/devices/bus/spc1000/fdd.h index 1275f1b9bfb..235f8e65fde 100644 --- a/src/devices/bus/spc1000/fdd.h +++ b/src/devices/bus/spc1000/fdd.h @@ -21,7 +21,7 @@ class spc1000_fdd_exp_device : public device_t, public device_spc1000_card_inter { public: // construction/destruction - spc1000_fdd_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spc1000_fdd_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spc1000/vdp.cpp b/src/devices/bus/spc1000/vdp.cpp index f85a64f59b9..4f6147d8e00 100644 --- a/src/devices/bus/spc1000/vdp.cpp +++ b/src/devices/bus/spc1000/vdp.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(SPC1000_VDP_EXP, spc1000_vdp_exp_device, "spc1000_vdp_exp", " // spc1000_vdp_exp_device - constructor //------------------------------------------------- -spc1000_vdp_exp_device::spc1000_vdp_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spc1000_vdp_exp_device::spc1000_vdp_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPC1000_VDP_EXP, tag, owner, clock) , device_spc1000_card_interface(mconfig, *this) , m_vdp(*this, "tms") diff --git a/src/devices/bus/spc1000/vdp.h b/src/devices/bus/spc1000/vdp.h index 989b25d5a90..c18aa6c228d 100644 --- a/src/devices/bus/spc1000/vdp.h +++ b/src/devices/bus/spc1000/vdp.h @@ -19,7 +19,7 @@ class spc1000_vdp_exp_device : public device_t, public device_spc1000_card_inter { public: // construction/destruction - spc1000_vdp_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spc1000_vdp_exp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/beta.cpp b/src/devices/bus/spectrum/beta.cpp index 8578cf46b3d..c9aea116a63 100644 --- a/src/devices/bus/spectrum/beta.cpp +++ b/src/devices/bus/spectrum/beta.cpp @@ -311,7 +311,7 @@ void spectrum_gamma_device::device_add_mconfig(machine_config& config) m_centronics->busy_handler().set([this](u8 data) { m_centronics_busy = data; }); m_centronics->set_output_latch(cent_data_out); - ACIA6850(config, m_acia, 0); // schematics missing, wiring unknown + ACIA6850(config, m_acia); // schematics missing, wiring unknown } const tiny_rom_entry *spectrum_betav2_device::device_rom_region() const @@ -353,7 +353,7 @@ const tiny_rom_entry *spectrum_gamma_device::device_rom_region() const // spectrum_betav2_device - constructor //------------------------------------------------- -spectrum_betav2_device::spectrum_betav2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_betav2_device::spectrum_betav2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") @@ -364,54 +364,54 @@ spectrum_betav2_device::spectrum_betav2_device(const machine_config &mconfig, de { } -spectrum_betav2_device::spectrum_betav2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_betav2_device::spectrum_betav2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_betav2_device(mconfig, SPECTRUM_BETAV2, tag, owner, clock) { } -spectrum_betav3_device::spectrum_betav3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_betav3_device::spectrum_betav3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : spectrum_betav2_device(mconfig, type, tag, owner, clock) { } -spectrum_betav3_device::spectrum_betav3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_betav3_device::spectrum_betav3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_betav3_device(mconfig, SPECTRUM_BETAV3, tag, owner, clock) { } -spectrum_betaplus_device::spectrum_betaplus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_betaplus_device::spectrum_betaplus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : spectrum_betav3_device(mconfig, type, tag, owner, clock) { } -spectrum_betaplus_device::spectrum_betaplus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_betaplus_device::spectrum_betaplus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_betaplus_device(mconfig, SPECTRUM_BETAPLUS, tag, owner, clock) { } -spectrum_betaclone_device::spectrum_betaclone_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_betaclone_device::spectrum_betaclone_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : spectrum_betaplus_device(mconfig, type, tag, owner, clock) { } -spectrum_betaclone_device::spectrum_betaclone_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_betaclone_device::spectrum_betaclone_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_betaclone_device(mconfig, SPECTRUM_BETACLONE, tag, owner, clock) { } -spectrum_betacbi_device::spectrum_betacbi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_betacbi_device::spectrum_betacbi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : spectrum_betaclone_device(mconfig, type, tag, owner, clock) , m_centronics(*this, "centronics") , m_centronics_busy(0) { } -spectrum_betacbi_device::spectrum_betacbi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_betacbi_device::spectrum_betacbi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_betacbi_device(mconfig, SPECTRUM_BETACBI, tag, owner, clock) { } -spectrum_gamma_device::spectrum_gamma_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_gamma_device::spectrum_gamma_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : spectrum_betaplus_device(mconfig, type, tag, owner, clock) , m_ppi(*this, "ppi") , m_acia(*this, "acia") @@ -420,7 +420,7 @@ spectrum_gamma_device::spectrum_gamma_device(const machine_config &mconfig, devi { } -spectrum_gamma_device::spectrum_gamma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_gamma_device::spectrum_gamma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_gamma_device(mconfig, SPECTRUM_GAMMA, tag, owner, clock) { } diff --git a/src/devices/bus/spectrum/beta.h b/src/devices/bus/spectrum/beta.h index 1827c741355..90837ac6d1b 100644 --- a/src/devices/bus/spectrum/beta.h +++ b/src/devices/bus/spectrum/beta.h @@ -28,8 +28,8 @@ class spectrum_betav2_device : { public: // construction/destruction - spectrum_betav2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); - spectrum_betav2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_betav2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + spectrum_betav2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); @@ -75,8 +75,8 @@ class spectrum_betav3_device : { public: // construction/destruction - spectrum_betav3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); - spectrum_betav3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_betav3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + spectrum_betav3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -91,8 +91,8 @@ class spectrum_betaplus_device : { public: // construction/destruction - spectrum_betaplus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); - spectrum_betaplus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_betaplus_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + spectrum_betaplus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(magic_button); @@ -107,8 +107,8 @@ class spectrum_betaclone_device : { public: // construction/destruction - spectrum_betaclone_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); - spectrum_betaclone_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_betaclone_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + spectrum_betaclone_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual uint8_t mreq_r(offs_t offset) override; @@ -121,8 +121,8 @@ class spectrum_betacbi_device : { public: // construction/destruction - spectrum_betacbi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); - spectrum_betacbi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_betacbi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + spectrum_betacbi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -142,8 +142,8 @@ class spectrum_gamma_device : { public: // construction/destruction - spectrum_gamma_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); - spectrum_gamma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_gamma_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + spectrum_gamma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_CUSTOM_INPUT_MEMBER(busy_r) { return !m_centronics_busy; } protected: diff --git a/src/devices/bus/spectrum/beta128.cpp b/src/devices/bus/spectrum/beta128.cpp index 09b95763a27..e79c6b72930 100644 --- a/src/devices/bus/spectrum/beta128.cpp +++ b/src/devices/bus/spectrum/beta128.cpp @@ -131,7 +131,7 @@ const tiny_rom_entry *spectrum_beta128_device::device_rom_region() const // spectrum_beta128_device - constructor //------------------------------------------------- -spectrum_beta128_device::spectrum_beta128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_beta128_device::spectrum_beta128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_BETA128, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") diff --git a/src/devices/bus/spectrum/beta128.h b/src/devices/bus/spectrum/beta128.h index bcbc889c94d..fe4a58042e9 100644 --- a/src/devices/bus/spectrum/beta128.h +++ b/src/devices/bus/spectrum/beta128.h @@ -25,7 +25,7 @@ class spectrum_beta128_device : { public: // construction/destruction - spectrum_beta128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_beta128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); DECLARE_INPUT_CHANGED_MEMBER(magic_button); diff --git a/src/devices/bus/spectrum/d40.cpp b/src/devices/bus/spectrum/d40.cpp index 9a7811b7936..f7b95a56337 100644 --- a/src/devices/bus/spectrum/d40.cpp +++ b/src/devices/bus/spectrum/d40.cpp @@ -145,7 +145,7 @@ const tiny_rom_entry *spectrum_d80v2_device::device_rom_region() const // spectrum_d40base_device - constructor //------------------------------------------------- -spectrum_d40base_device::spectrum_d40base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_d40base_device::spectrum_d40base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") @@ -154,26 +154,26 @@ spectrum_d40base_device::spectrum_d40base_device(const machine_config &mconfig, { } -spectrum_d40_device::spectrum_d40_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_d40_device::spectrum_d40_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_d40base_device(mconfig, SPECTRUM_D40, tag, owner, clock) , m_fdc(*this, "fdc") , m_floppy(*this, "fdc:%u", 0) { } -spectrum_d40_device::spectrum_d40_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_d40_device::spectrum_d40_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) :spectrum_d40base_device(mconfig, type, tag, owner, clock) , m_fdc(*this, "fdc") , m_floppy(*this, "fdc:%u", 0) { } -spectrum_d80_device::spectrum_d80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_d80_device::spectrum_d80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_d40_device(mconfig, SPECTRUM_D80, tag, owner, clock) { } -spectrum_d80v2_device::spectrum_d80v2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_d80v2_device::spectrum_d80v2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_d40base_device(mconfig, SPECTRUM_D80V2, tag, owner, clock) , m_fdc(*this, "fdc") , m_floppy(*this, "fdc:%u", 0) diff --git a/src/devices/bus/spectrum/d40.h b/src/devices/bus/spectrum/d40.h index 250b2feccd8..ca1fd9161bf 100644 --- a/src/devices/bus/spectrum/d40.h +++ b/src/devices/bus/spectrum/d40.h @@ -29,7 +29,7 @@ public: DECLARE_INPUT_CHANGED_MEMBER(snapshot_button); protected: - spectrum_d40base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_d40base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -66,10 +66,10 @@ class spectrum_d40_device : public spectrum_d40base_device { public: - spectrum_d40_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_d40_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - spectrum_d40_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_d40_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; virtual const tiny_rom_entry *device_rom_region() const override; @@ -95,7 +95,7 @@ class spectrum_d80_device : public spectrum_d40_device { public: - spectrum_d80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_d80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -105,7 +105,7 @@ class spectrum_d80v2_device : public spectrum_d40base_device { public: - spectrum_d80v2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_d80v2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/spectrum/exp.cpp b/src/devices/bus/spectrum/exp.cpp index a0c79eeaec8..2359f555463 100644 --- a/src/devices/bus/spectrum/exp.cpp +++ b/src/devices/bus/spectrum/exp.cpp @@ -40,7 +40,7 @@ device_spectrum_expansion_interface::device_spectrum_expansion_interface(const m // spectrum_expansion_slot_device - constructor //------------------------------------------------- -spectrum_expansion_slot_device::spectrum_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spectrum_expansion_slot_device::spectrum_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_spectrum_expansion_interface>(mconfig, *this), m_card(nullptr), diff --git a/src/devices/bus/spectrum/exp.h b/src/devices/bus/spectrum/exp.h index 04e3e942889..86ba437c48f 100644 --- a/src/devices/bus/spectrum/exp.h +++ b/src/devices/bus/spectrum/exp.h @@ -71,7 +71,7 @@ public: set_fixed(false); } - spectrum_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + spectrum_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // callbacks auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/bus/spectrum/floppyone.cpp b/src/devices/bus/spectrum/floppyone.cpp index 4291199501d..22ec40a2588 100644 --- a/src/devices/bus/spectrum/floppyone.cpp +++ b/src/devices/bus/spectrum/floppyone.cpp @@ -148,7 +148,7 @@ const tiny_rom_entry *spectrum_flpone_device::device_rom_region() const // spectrum_flpone_device - constructor //------------------------------------------------- -spectrum_flpone_device::spectrum_flpone_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_flpone_device::spectrum_flpone_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_FLPONE, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") diff --git a/src/devices/bus/spectrum/floppyone.h b/src/devices/bus/spectrum/floppyone.h index 8eeea6bad0f..6916c2933d4 100644 --- a/src/devices/bus/spectrum/floppyone.h +++ b/src/devices/bus/spectrum/floppyone.h @@ -28,7 +28,7 @@ class spectrum_flpone_device : { public: // construction/destruction - spectrum_flpone_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_flpone_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); DECLARE_INPUT_CHANGED_MEMBER(snapshot_button) { m_slot->nmi_w(newval ? ASSERT_LINE : CLEAR_LINE); } diff --git a/src/devices/bus/spectrum/fuller.cpp b/src/devices/bus/spectrum/fuller.cpp index 0346a806171..95dd6cc83c7 100644 --- a/src/devices/bus/spectrum/fuller.cpp +++ b/src/devices/bus/spectrum/fuller.cpp @@ -66,7 +66,7 @@ void spectrum_fuller_device::device_add_mconfig(machine_config &config) // spectrum_fuller_device - constructor //------------------------------------------------- -spectrum_fuller_device::spectrum_fuller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_fuller_device::spectrum_fuller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_FULLER, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_exp(*this, "exp") diff --git a/src/devices/bus/spectrum/fuller.h b/src/devices/bus/spectrum/fuller.h index fa16ec01579..00239d1abce 100644 --- a/src/devices/bus/spectrum/fuller.h +++ b/src/devices/bus/spectrum/fuller.h @@ -27,7 +27,7 @@ class spectrum_fuller_device : { public: // construction/destruction - spectrum_fuller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_fuller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/intf1.cpp b/src/devices/bus/spectrum/intf1.cpp index df40de1f9d6..ee821c657ee 100644 --- a/src/devices/bus/spectrum/intf1.cpp +++ b/src/devices/bus/spectrum/intf1.cpp @@ -72,7 +72,7 @@ const tiny_rom_entry *spectrum_intf1_device::device_rom_region() const // spectrum_intf1_device - constructor //------------------------------------------------- -spectrum_intf1_device::spectrum_intf1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_intf1_device::spectrum_intf1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_INTF1, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_exp(*this, "exp") diff --git a/src/devices/bus/spectrum/intf1.h b/src/devices/bus/spectrum/intf1.h index 787c64b843d..5700e66d222 100644 --- a/src/devices/bus/spectrum/intf1.h +++ b/src/devices/bus/spectrum/intf1.h @@ -25,7 +25,7 @@ class spectrum_intf1_device: { public: // construction/destruction - spectrum_intf1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_intf1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK | feature::LAN; } diff --git a/src/devices/bus/spectrum/intf2.cpp b/src/devices/bus/spectrum/intf2.cpp index 5b407d88df3..f0f32a8c359 100644 --- a/src/devices/bus/spectrum/intf2.cpp +++ b/src/devices/bus/spectrum/intf2.cpp @@ -72,7 +72,7 @@ void spectrum_intf2_device::device_add_mconfig(machine_config &config) // spectrum_intf2_device - constructor //------------------------------------------------- -spectrum_intf2_device::spectrum_intf2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_intf2_device::spectrum_intf2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_INTF2, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_cart(*this, "cartslot") diff --git a/src/devices/bus/spectrum/intf2.h b/src/devices/bus/spectrum/intf2.h index 4faecbae93a..5597f8d6ff1 100644 --- a/src/devices/bus/spectrum/intf2.h +++ b/src/devices/bus/spectrum/intf2.h @@ -25,7 +25,7 @@ class spectrum_intf2_device: { public: // construction/destruction - spectrum_intf2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_intf2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/spectrum/kempdisc.cpp b/src/devices/bus/spectrum/kempdisc.cpp index 32573ebf969..96dd410e352 100644 --- a/src/devices/bus/spectrum/kempdisc.cpp +++ b/src/devices/bus/spectrum/kempdisc.cpp @@ -118,7 +118,7 @@ const tiny_rom_entry *spectrum_spdos_device::device_rom_region() const // spectrum_kempdisc_device - constructor //------------------------------------------------- -spectrum_kempdisc_device::spectrum_kempdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_kempdisc_device::spectrum_kempdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") @@ -129,12 +129,12 @@ spectrum_kempdisc_device::spectrum_kempdisc_device(const machine_config &mconfig { } -spectrum_kempdisc_device::spectrum_kempdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_kempdisc_device::spectrum_kempdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_kempdisc_device(mconfig, SPECTRUM_KEMPDISC, tag, owner, clock) { } -spectrum_spdos_device::spectrum_spdos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_spdos_device::spectrum_spdos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_kempdisc_device(mconfig, SPECTRUM_SPDOS, tag, owner, clock) { } diff --git a/src/devices/bus/spectrum/kempdisc.h b/src/devices/bus/spectrum/kempdisc.h index 3a3b5118402..c8914264e59 100644 --- a/src/devices/bus/spectrum/kempdisc.h +++ b/src/devices/bus/spectrum/kempdisc.h @@ -25,12 +25,12 @@ class spectrum_kempdisc_device : { public: // construction/destruction - spectrum_kempdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_kempdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); protected: - spectrum_kempdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_kempdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; virtual void device_reset() override; @@ -65,7 +65,7 @@ class spectrum_spdos_device : { public: // construction/destruction - spectrum_spdos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_spdos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides diff --git a/src/devices/bus/spectrum/kempjoy.cpp b/src/devices/bus/spectrum/kempjoy.cpp index 4dee6eabba0..ef6d980254c 100644 --- a/src/devices/bus/spectrum/kempjoy.cpp +++ b/src/devices/bus/spectrum/kempjoy.cpp @@ -48,7 +48,7 @@ ioport_constructor spectrum_kempjoy_device::device_input_ports() const // spectrum_kempjoy_device - constructor //------------------------------------------------- -spectrum_kempjoy_device::spectrum_kempjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_kempjoy_device::spectrum_kempjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_KEMPJOY, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_joy(*this, "JOY") diff --git a/src/devices/bus/spectrum/kempjoy.h b/src/devices/bus/spectrum/kempjoy.h index 466dceb7517..35bff2c8775 100644 --- a/src/devices/bus/spectrum/kempjoy.h +++ b/src/devices/bus/spectrum/kempjoy.h @@ -26,7 +26,7 @@ class spectrum_kempjoy_device : { public: // construction/destruction - spectrum_kempjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_kempjoy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/logitek.cpp b/src/devices/bus/spectrum/logitek.cpp index 6406231ce47..8d75701439d 100644 --- a/src/devices/bus/spectrum/logitek.cpp +++ b/src/devices/bus/spectrum/logitek.cpp @@ -66,7 +66,7 @@ ROM_END void spectrum_proceed_device::device_add_mconfig(machine_config &config) { - Z80PIO(config, m_z80pio, 3500000); + Z80PIO(config, m_z80pio, XTAL::u(3500000)); m_z80pio->out_pa_callback().set(FUNC(spectrum_proceed_device::pioa_w)); m_z80pio->in_pb_callback().set(FUNC(spectrum_proceed_device::piob_r)); m_z80pio->out_pb_callback().set(FUNC(spectrum_proceed_device::piob_w)); @@ -92,7 +92,7 @@ const tiny_rom_entry *spectrum_proceed_device::device_rom_region() const // spectrum_proceed_device - constructor //------------------------------------------------- -spectrum_proceed_device::spectrum_proceed_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_proceed_device::spectrum_proceed_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_PROCEED, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") diff --git a/src/devices/bus/spectrum/logitek.h b/src/devices/bus/spectrum/logitek.h index a6d807d7236..aa023f50eac 100644 --- a/src/devices/bus/spectrum/logitek.h +++ b/src/devices/bus/spectrum/logitek.h @@ -26,7 +26,7 @@ class spectrum_proceed_device : { public: // construction/destruction - spectrum_proceed_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_proceed_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/spectrum/lprint.cpp b/src/devices/bus/spectrum/lprint.cpp index 912c26d6c74..2a8b82e0736 100644 --- a/src/devices/bus/spectrum/lprint.cpp +++ b/src/devices/bus/spectrum/lprint.cpp @@ -142,7 +142,7 @@ const tiny_rom_entry *spectrum_kempcentreu_device::device_rom_region() const // spectrum_lprint_device - constructors //------------------------------------------------- -spectrum_lprint_device::spectrum_lprint_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_lprint_device::spectrum_lprint_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_LPRINT, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") @@ -150,7 +150,7 @@ spectrum_lprint_device::spectrum_lprint_device(const machine_config &mconfig, co { } -spectrum_lprint3_device::spectrum_lprint3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_lprint3_device::spectrum_lprint3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_LPRINT3, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") @@ -160,14 +160,14 @@ spectrum_lprint3_device::spectrum_lprint3_device(const machine_config &mconfig, { } -spectrum_kempcentrs_device::spectrum_kempcentrs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_kempcentrs_device::spectrum_kempcentrs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_KEMPCENTRS, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_centronics(*this, "centronics") { } -spectrum_kempcentre_device::spectrum_kempcentre_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_kempcentre_device::spectrum_kempcentre_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") @@ -175,12 +175,12 @@ spectrum_kempcentre_device::spectrum_kempcentre_device(const machine_config &mco { } -spectrum_kempcentre_device::spectrum_kempcentre_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_kempcentre_device::spectrum_kempcentre_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_kempcentre_device(mconfig, SPECTRUM_KEMPCENTREF, tag, owner, clock) { } -spectrum_kempcentreu_device::spectrum_kempcentreu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_kempcentreu_device::spectrum_kempcentreu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_kempcentre_device(mconfig, SPECTRUM_KEMPCENTREU, tag, owner, clock) { } diff --git a/src/devices/bus/spectrum/lprint.h b/src/devices/bus/spectrum/lprint.h index d58793607c6..a0ca51f2b0a 100644 --- a/src/devices/bus/spectrum/lprint.h +++ b/src/devices/bus/spectrum/lprint.h @@ -23,7 +23,7 @@ class spectrum_lprint_device : { public: // construction/destruction - spectrum_lprint_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_lprint_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -57,7 +57,7 @@ class spectrum_lprint3_device : { public: // construction/destruction - spectrum_lprint3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_lprint3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -98,7 +98,7 @@ class spectrum_kempcentrs_device : { public: // construction/destruction - spectrum_kempcentrs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_kempcentrs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -125,10 +125,10 @@ class spectrum_kempcentre_device : { public: // construction/destruction - spectrum_kempcentre_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_kempcentre_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - spectrum_kempcentre_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_kempcentre_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -160,7 +160,7 @@ class spectrum_kempcentreu_device : { public: // construction/destruction - spectrum_kempcentreu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_kempcentreu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/melodik.cpp b/src/devices/bus/spectrum/melodik.cpp index 0b77635c051..72c09910877 100644 --- a/src/devices/bus/spectrum/melodik.cpp +++ b/src/devices/bus/spectrum/melodik.cpp @@ -43,7 +43,7 @@ void spectrum_melodik_device::device_add_mconfig(machine_config &config) // spectrum_melodik_device - constructor //------------------------------------------------- -spectrum_melodik_device::spectrum_melodik_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_melodik_device::spectrum_melodik_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_MELODIK, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_exp(*this, "exp") diff --git a/src/devices/bus/spectrum/melodik.h b/src/devices/bus/spectrum/melodik.h index 6c0d4f6b3fd..5a41f9fe8ad 100644 --- a/src/devices/bus/spectrum/melodik.h +++ b/src/devices/bus/spectrum/melodik.h @@ -27,7 +27,7 @@ class spectrum_melodik_device : { public: // construction/destruction - spectrum_melodik_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_melodik_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/mface.cpp b/src/devices/bus/spectrum/mface.cpp index 693b3eb4fcf..9a2d04bff1c 100644 --- a/src/devices/bus/spectrum/mface.cpp +++ b/src/devices/bus/spectrum/mface.cpp @@ -354,7 +354,7 @@ const tiny_rom_entry *spectrum_mprint_device::device_rom_region() const // spectrum_mface_base_device - constructor //------------------------------------------------- -spectrum_mface_base_device::spectrum_mface_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface_base_device::spectrum_mface_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") @@ -362,64 +362,64 @@ spectrum_mface_base_device::spectrum_mface_base_device(const machine_config &mco { } -spectrum_mface1v2_device::spectrum_mface1v2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface1v2_device::spectrum_mface1v2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface_base_device(mconfig, type, tag, owner, clock) , m_joy(*this, "JOY") , m_hwconfig(*this, "CONFIG") { } -spectrum_mface1v2_device::spectrum_mface1v2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface1v2_device::spectrum_mface1v2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface1v2_device(mconfig, SPECTRUM_MFACE1V2, tag, owner, clock) { } -spectrum_mface1v1_device::spectrum_mface1v1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface1v1_device::spectrum_mface1v1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface1v2_device(mconfig, SPECTRUM_MFACE1V1, tag, owner, clock) { } -spectrum_mface1v3_device::spectrum_mface1v3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface1v3_device::spectrum_mface1v3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface1v2_device(mconfig, type, tag, owner, clock) { } -spectrum_mface1v3_device::spectrum_mface1v3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface1v3_device::spectrum_mface1v3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface1v3_device(mconfig, SPECTRUM_MFACE1V3, tag, owner, clock) { } -spectrum_mface1_device::spectrum_mface1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface1_device::spectrum_mface1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface1v3_device(mconfig, SPECTRUM_MFACE1, tag, owner, clock) { } -spectrum_mface128_base_device::spectrum_mface128_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface128_base_device::spectrum_mface128_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface_base_device(mconfig, type, tag, owner, clock) { } -spectrum_mface128v1_device::spectrum_mface128v1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface128v1_device::spectrum_mface128v1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface128_base_device(mconfig, type, tag, owner, clock) { } -spectrum_mface128v1_device::spectrum_mface128v1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface128v1_device::spectrum_mface128v1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface128v1_device(mconfig, SPECTRUM_MFACE128V1, tag, owner, clock) { } -spectrum_mface128_device::spectrum_mface128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface128_device::spectrum_mface128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface128v1_device(mconfig, SPECTRUM_MFACE128, tag, owner, clock) { } -spectrum_mface3_device::spectrum_mface3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_mface3_device::spectrum_mface3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface128_base_device(mconfig, SPECTRUM_MFACE3, tag, owner, clock) { } -spectrum_mprint_device::spectrum_mprint_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_mprint_device::spectrum_mprint_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_mface128_base_device(mconfig, SPECTRUM_MPRINT, tag, owner, clock) , m_centronics(*this, "centronics") { diff --git a/src/devices/bus/spectrum/mface.h b/src/devices/bus/spectrum/mface.h index 7b3fbf03e72..0f379119f17 100644 --- a/src/devices/bus/spectrum/mface.h +++ b/src/devices/bus/spectrum/mface.h @@ -21,12 +21,12 @@ class spectrum_mface_base_device : { public: // construction/destruction - spectrum_mface_base_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual DECLARE_INPUT_CHANGED_MEMBER(magic_button) { m_slot->nmi_w(newval ? CLEAR_LINE : ASSERT_LINE); } protected: - spectrum_mface_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -61,12 +61,12 @@ protected: class spectrum_mface1v2_device : public spectrum_mface_base_device { public: - spectrum_mface1v2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface1v2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(magic_button) override; protected: - spectrum_mface1v2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface1v2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -85,7 +85,7 @@ protected: class spectrum_mface1v1_device : public spectrum_mface1v2_device { public: - spectrum_mface1v1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface1v1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -101,10 +101,10 @@ protected: class spectrum_mface1v3_device : public spectrum_mface1v2_device { public: - spectrum_mface1v3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface1v3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - spectrum_mface1v3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface1v3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -116,7 +116,7 @@ protected: class spectrum_mface1_device : public spectrum_mface1v3_device { public: - spectrum_mface1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(magic_button) override; @@ -132,12 +132,12 @@ protected: class spectrum_mface128_base_device : public spectrum_mface_base_device { public: - spectrum_mface128_base_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface128_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(magic_button) override; protected: - spectrum_mface128_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface128_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -149,10 +149,10 @@ protected: class spectrum_mface128v1_device : public spectrum_mface128_base_device { public: - spectrum_mface128v1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface128v1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - spectrum_mface128v1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface128v1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -169,7 +169,7 @@ protected: class spectrum_mface128_device : public spectrum_mface128v1_device { public: - spectrum_mface128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // optional information overrides @@ -183,7 +183,7 @@ protected: class spectrum_mface3_device : public spectrum_mface128_base_device { public: - spectrum_mface3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mface3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(magic_button) override; @@ -207,7 +207,7 @@ private: class spectrum_mprint_device : public spectrum_mface128_base_device { public: - spectrum_mprint_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mprint_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/mgt.cpp b/src/devices/bus/spectrum/mgt.cpp index 581a748dcea..0f54be726cc 100644 --- a/src/devices/bus/spectrum/mgt.cpp +++ b/src/devices/bus/spectrum/mgt.cpp @@ -329,7 +329,7 @@ const tiny_rom_entry *spectrum_disciple_device::device_rom_region() const // spectrum_plusd_device - constructor //------------------------------------------------- -spectrum_plusd_device::spectrum_plusd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_plusd_device::spectrum_plusd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") @@ -340,7 +340,7 @@ spectrum_plusd_device::spectrum_plusd_device(const machine_config &mconfig, devi { } -spectrum_plusd_device::spectrum_plusd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_plusd_device::spectrum_plusd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_plusd_device(mconfig, SPECTRUM_PLUSD, tag, owner, clock) { } @@ -349,7 +349,7 @@ spectrum_plusd_device::spectrum_plusd_device(const machine_config &mconfig, cons // spectrum_disciple_device - constructor //------------------------------------------------- -spectrum_disciple_device::spectrum_disciple_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_disciple_device::spectrum_disciple_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_plusd_device(mconfig, SPECTRUM_DISCIPLE, tag, owner, clock) , m_exp(*this, "exp") , m_joy1(*this, "JOY1") diff --git a/src/devices/bus/spectrum/mgt.h b/src/devices/bus/spectrum/mgt.h index 35d168b10ae..a58502a76a6 100644 --- a/src/devices/bus/spectrum/mgt.h +++ b/src/devices/bus/spectrum/mgt.h @@ -29,13 +29,13 @@ class spectrum_plusd_device: public device_t, public device_spectrum_expansion_i { public: // construction/destruction - spectrum_plusd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_plusd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); DECLARE_INPUT_CHANGED_MEMBER(snapshot_button); protected: - spectrum_plusd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_plusd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -69,7 +69,7 @@ class spectrum_disciple_device: public spectrum_plusd_device { public: // construction/destruction - spectrum_disciple_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_disciple_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(inhibit_button) { if (!newval) m_romcs = 0; } diff --git a/src/devices/bus/spectrum/mikroplus.cpp b/src/devices/bus/spectrum/mikroplus.cpp index 9f46bc1b7db..4b99263a312 100644 --- a/src/devices/bus/spectrum/mikroplus.cpp +++ b/src/devices/bus/spectrum/mikroplus.cpp @@ -67,7 +67,7 @@ const tiny_rom_entry *spectrum_mikroplus_device::device_rom_region() const // spectrum_mikroplus_device - constructor //------------------------------------------------- -spectrum_mikroplus_device::spectrum_mikroplus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_mikroplus_device::spectrum_mikroplus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_MIKROPLUS, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") diff --git a/src/devices/bus/spectrum/mikroplus.h b/src/devices/bus/spectrum/mikroplus.h index e06cb38bb2c..a66939af1fc 100644 --- a/src/devices/bus/spectrum/mikroplus.h +++ b/src/devices/bus/spectrum/mikroplus.h @@ -26,7 +26,7 @@ class spectrum_mikroplus_device : { public: // construction/destruction - spectrum_mikroplus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mikroplus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/mpoker.cpp b/src/devices/bus/spectrum/mpoker.cpp index c2d84d13c1b..40304099e4d 100644 --- a/src/devices/bus/spectrum/mpoker.cpp +++ b/src/devices/bus/spectrum/mpoker.cpp @@ -99,7 +99,7 @@ const tiny_rom_entry *spectrum_mpoker_device::device_rom_region() const // spectrum_mpoker_device - constructor //------------------------------------------------- -spectrum_mpoker_device::spectrum_mpoker_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_mpoker_device::spectrum_mpoker_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_MPOKER, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") diff --git a/src/devices/bus/spectrum/mpoker.h b/src/devices/bus/spectrum/mpoker.h index 27f7cef19b0..b043f20349a 100644 --- a/src/devices/bus/spectrum/mpoker.h +++ b/src/devices/bus/spectrum/mpoker.h @@ -21,7 +21,7 @@ class spectrum_mpoker_device : public device_t, public device_spectrum_expansion { public: // construction/destruction - spectrum_mpoker_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_mpoker_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(freeze_button); diff --git a/src/devices/bus/spectrum/opus.cpp b/src/devices/bus/spectrum/opus.cpp index 37eff23bce6..d41050ef063 100644 --- a/src/devices/bus/spectrum/opus.cpp +++ b/src/devices/bus/spectrum/opus.cpp @@ -91,7 +91,7 @@ void spectrum_opus_device::device_add_mconfig(machine_config &config) m_centronics->busy_handler().set(FUNC(spectrum_opus_device::busy_w)); /* pia */ - PIA6821(config, m_pia, 0); + PIA6821(config, m_pia); m_pia->writepa_handler().set(FUNC(spectrum_opus_device::pia_out_a)); m_pia->writepb_handler().set(FUNC(spectrum_opus_device::pia_out_b)); m_pia->cb2_handler().set("centronics", FUNC(centronics_device::write_strobe)); @@ -119,7 +119,7 @@ const tiny_rom_entry *spectrum_opus_device::device_rom_region() const // spectrum_opus_device - constructor //------------------------------------------------- -spectrum_opus_device::spectrum_opus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_opus_device::spectrum_opus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_OPUS, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_joy(*this, "JOY") diff --git a/src/devices/bus/spectrum/opus.h b/src/devices/bus/spectrum/opus.h index 2c175621820..a308e8c12bd 100644 --- a/src/devices/bus/spectrum/opus.h +++ b/src/devices/bus/spectrum/opus.h @@ -28,7 +28,7 @@ class spectrum_opus_device: { public: // construction/destruction - spectrum_opus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_opus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); diff --git a/src/devices/bus/spectrum/plus2test.cpp b/src/devices/bus/spectrum/plus2test.cpp index 3d90ed4dee3..a5b744f162d 100644 --- a/src/devices/bus/spectrum/plus2test.cpp +++ b/src/devices/bus/spectrum/plus2test.cpp @@ -42,7 +42,7 @@ const tiny_rom_entry *spectrum_plus2test_device::device_rom_region() const // spectrum_plus2test_device - constructor //------------------------------------------------- -spectrum_plus2test_device::spectrum_plus2test_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_plus2test_device::spectrum_plus2test_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_PLUS2TEST, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") diff --git a/src/devices/bus/spectrum/plus2test.h b/src/devices/bus/spectrum/plus2test.h index f8caad2fa26..3d596a43674 100644 --- a/src/devices/bus/spectrum/plus2test.h +++ b/src/devices/bus/spectrum/plus2test.h @@ -26,7 +26,7 @@ class spectrum_plus2test_device : { public: // construction/destruction - spectrum_plus2test_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_plus2test_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/protek.cpp b/src/devices/bus/spectrum/protek.cpp index 6e21268682e..7b6a33ec1b2 100644 --- a/src/devices/bus/spectrum/protek.cpp +++ b/src/devices/bus/spectrum/protek.cpp @@ -50,7 +50,7 @@ ioport_constructor spectrum_protek_device::device_input_ports() const // spectrum_protek_device - constructor //------------------------------------------------- -spectrum_protek_device::spectrum_protek_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_protek_device::spectrum_protek_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_PROTEK, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_exp_line3(*this, "LINE3") diff --git a/src/devices/bus/spectrum/protek.h b/src/devices/bus/spectrum/protek.h index 9edd5a82f29..248c6ecf63e 100644 --- a/src/devices/bus/spectrum/protek.h +++ b/src/devices/bus/spectrum/protek.h @@ -26,7 +26,7 @@ class spectrum_protek_device : { public: // construction/destruction - spectrum_protek_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_protek_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/sdi.cpp b/src/devices/bus/spectrum/sdi.cpp index ab8becb80f8..356b9098cfd 100644 --- a/src/devices/bus/spectrum/sdi.cpp +++ b/src/devices/bus/spectrum/sdi.cpp @@ -66,7 +66,7 @@ const tiny_rom_entry *spectrum_sdi_device::device_rom_region() const // spectrum_sdi_device - constructor //------------------------------------------------- -spectrum_sdi_device::spectrum_sdi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_sdi_device::spectrum_sdi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_SDI, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") diff --git a/src/devices/bus/spectrum/sdi.h b/src/devices/bus/spectrum/sdi.h index 619ec52f44f..1f2c26efe7d 100644 --- a/src/devices/bus/spectrum/sdi.h +++ b/src/devices/bus/spectrum/sdi.h @@ -24,7 +24,7 @@ class spectrum_sdi_device : { public: // construction/destruction - spectrum_sdi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_sdi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/spectrum/sixword.cpp b/src/devices/bus/spectrum/sixword.cpp index c85a9347dc9..247e93e9a4e 100644 --- a/src/devices/bus/spectrum/sixword.cpp +++ b/src/devices/bus/spectrum/sixword.cpp @@ -193,7 +193,7 @@ const tiny_rom_entry *spectrum_swiftdisc2_device::device_rom_region() const // spectrum_swiftdisc_device - constructor //------------------------------------------------- -spectrum_swiftdisc_device::spectrum_swiftdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spectrum_swiftdisc_device::spectrum_swiftdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") @@ -205,12 +205,12 @@ spectrum_swiftdisc_device::spectrum_swiftdisc_device(const machine_config &mconf { } -spectrum_swiftdisc_device::spectrum_swiftdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_swiftdisc_device::spectrum_swiftdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_swiftdisc_device(mconfig, SPECTRUM_SWIFTDISC, tag, owner, clock) { } -spectrum_swiftdisc2_device::spectrum_swiftdisc2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_swiftdisc2_device::spectrum_swiftdisc2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spectrum_swiftdisc_device(mconfig, SPECTRUM_SWIFTDISC2, tag, owner, clock) , m_centronics(*this, "centronics") , m_conf(*this, "CONF") diff --git a/src/devices/bus/spectrum/sixword.h b/src/devices/bus/spectrum/sixword.h index c11108454f6..893c5aaab36 100644 --- a/src/devices/bus/spectrum/sixword.h +++ b/src/devices/bus/spectrum/sixword.h @@ -27,13 +27,13 @@ class spectrum_swiftdisc_device : { public: // construction/destruction - spectrum_swiftdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_swiftdisc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); DECLARE_INPUT_CHANGED_MEMBER(nmi_button) { m_rombank |= newval << 12; m_slot->nmi_w(newval ? ASSERT_LINE : CLEAR_LINE); } protected: - spectrum_swiftdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spectrum_swiftdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -75,7 +75,7 @@ class spectrum_swiftdisc2_device : { public: // construction/destruction - spectrum_swiftdisc2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_swiftdisc2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/speccydos.cpp b/src/devices/bus/spectrum/speccydos.cpp index 1afbb52da26..b13ddcfe4d8 100644 --- a/src/devices/bus/spectrum/speccydos.cpp +++ b/src/devices/bus/spectrum/speccydos.cpp @@ -131,7 +131,7 @@ const tiny_rom_entry *spectrum_speccydos_device::device_rom_region() const // spectrum_speccydos_device - constructor //------------------------------------------------- -spectrum_speccydos_device::spectrum_speccydos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_speccydos_device::spectrum_speccydos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_SPECCYDOS, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") diff --git a/src/devices/bus/spectrum/speccydos.h b/src/devices/bus/spectrum/speccydos.h index 3cdb29b7b38..19004176bc5 100644 --- a/src/devices/bus/spectrum/speccydos.h +++ b/src/devices/bus/spectrum/speccydos.h @@ -25,7 +25,7 @@ class spectrum_speccydos_device : { public: // construction/destruction - spectrum_speccydos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_speccydos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); DECLARE_INPUT_CHANGED_MEMBER(magic_button) { m_slot->nmi_w(newval ? ASSERT_LINE : CLEAR_LINE); } diff --git a/src/devices/bus/spectrum/specdrum.cpp b/src/devices/bus/spectrum/specdrum.cpp index 49764da5da5..221898db24c 100644 --- a/src/devices/bus/spectrum/specdrum.cpp +++ b/src/devices/bus/spectrum/specdrum.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(SPECTRUM_SPECDRUM, spectrum_specdrum_device, "spectrum_specdr void spectrum_specdrum_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "speaker").front_center(); - ZN428E(config, m_dac, 0).add_route(ALL_OUTPUTS, "speaker", 0.5); + ZN428E(config, m_dac).add_route(ALL_OUTPUTS, "speaker", 0.5); } @@ -37,7 +37,7 @@ void spectrum_specdrum_device::device_add_mconfig(machine_config &config) // spectrum_specdrum_device - constructor //------------------------------------------------- -spectrum_specdrum_device::spectrum_specdrum_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_specdrum_device::spectrum_specdrum_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_SPECDRUM, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_dac(*this, "dac") diff --git a/src/devices/bus/spectrum/specdrum.h b/src/devices/bus/spectrum/specdrum.h index 7412a8509c0..9d4e1992dc5 100644 --- a/src/devices/bus/spectrum/specdrum.h +++ b/src/devices/bus/spectrum/specdrum.h @@ -28,7 +28,7 @@ class spectrum_specdrum_device : { public: // construction/destruction - spectrum_specdrum_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_specdrum_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/specmate.cpp b/src/devices/bus/spectrum/specmate.cpp index 4177a74f814..95c7f0f786d 100644 --- a/src/devices/bus/spectrum/specmate.cpp +++ b/src/devices/bus/spectrum/specmate.cpp @@ -120,7 +120,7 @@ const tiny_rom_entry *spectrum_specmate_device::device_rom_region() const // spectrum_specmate_device - constructor //------------------------------------------------- -spectrum_specmate_device::spectrum_specmate_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_specmate_device::spectrum_specmate_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_SPECMATE, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_rom(*this, "rom") diff --git a/src/devices/bus/spectrum/specmate.h b/src/devices/bus/spectrum/specmate.h index cc361b49171..192918b3339 100644 --- a/src/devices/bus/spectrum/specmate.h +++ b/src/devices/bus/spectrum/specmate.h @@ -21,7 +21,7 @@ class spectrum_specmate_device : public device_t, public device_spectrum_expansi { public: // construction/destruction - spectrum_specmate_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_specmate_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(freeze_button) { m_slot->nmi_w(newval ? CLEAR_LINE : ASSERT_LINE); } diff --git a/src/devices/bus/spectrum/uslot.cpp b/src/devices/bus/spectrum/uslot.cpp index eeef849a8fe..3b08cb3f222 100644 --- a/src/devices/bus/spectrum/uslot.cpp +++ b/src/devices/bus/spectrum/uslot.cpp @@ -40,7 +40,7 @@ void spectrum_uslot_device::device_add_mconfig(machine_config &config) // spectrum_uslot_device - constructor //------------------------------------------------- -spectrum_uslot_device::spectrum_uslot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_uslot_device::spectrum_uslot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_USLOT, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_exp1(*this, "exp1") diff --git a/src/devices/bus/spectrum/uslot.h b/src/devices/bus/spectrum/uslot.h index 0764d014147..119203c8d22 100644 --- a/src/devices/bus/spectrum/uslot.h +++ b/src/devices/bus/spectrum/uslot.h @@ -26,7 +26,7 @@ class spectrum_uslot_device : { public: // construction/destruction - spectrum_uslot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_uslot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/usource.cpp b/src/devices/bus/spectrum/usource.cpp index 3c368297fef..37e263f858d 100644 --- a/src/devices/bus/spectrum/usource.cpp +++ b/src/devices/bus/spectrum/usource.cpp @@ -46,7 +46,7 @@ const tiny_rom_entry *spectrum_usource_device::device_rom_region() const // spectrum_usource_device - constructor //------------------------------------------------- -spectrum_usource_device::spectrum_usource_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spectrum_usource_device::spectrum_usource_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_USOURCE, tag, owner, clock), device_spectrum_expansion_interface(mconfig, *this), m_rom(*this, "rom") diff --git a/src/devices/bus/spectrum/usource.h b/src/devices/bus/spectrum/usource.h index 1f0d7d44e58..092a4bcc2a5 100644 --- a/src/devices/bus/spectrum/usource.h +++ b/src/devices/bus/spectrum/usource.h @@ -28,7 +28,7 @@ class spectrum_usource_device : { public: // construction/destruction - spectrum_usource_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_usource_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/uspeech.cpp b/src/devices/bus/spectrum/uspeech.cpp index 06e48dca0fd..0261570d1af 100644 --- a/src/devices/bus/spectrum/uspeech.cpp +++ b/src/devices/bus/spectrum/uspeech.cpp @@ -61,7 +61,7 @@ void spectrum_uspeech_device::device_add_mconfig(machine_config &config) // spectrum_uspeech_device - constructor //------------------------------------------------- -spectrum_uspeech_device::spectrum_uspeech_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spectrum_uspeech_device::spectrum_uspeech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_USPEECH, tag, owner, clock), device_spectrum_expansion_interface(mconfig, *this), m_nsp(*this, "sp0256"), @@ -151,12 +151,12 @@ void spectrum_uspeech_device::mreq_w(offs_t offset, uint8_t data) case 0x3000: // intonation low - m_nsp->set_clock(3050000); // oscillator frequency read from hardware + m_nsp->set_clock(XTAL::u(3050000)); // oscillator frequency read from hardware break; case 0x3001: // intonation high - m_nsp->set_clock(3260000); // oscillator frequency read from hardware + m_nsp->set_clock(XTAL::u(3260000)); // oscillator frequency read from hardware break; } } diff --git a/src/devices/bus/spectrum/uspeech.h b/src/devices/bus/spectrum/uspeech.h index 078e33599af..8a9946e6156 100644 --- a/src/devices/bus/spectrum/uspeech.h +++ b/src/devices/bus/spectrum/uspeech.h @@ -29,7 +29,7 @@ class spectrum_uspeech_device : { public: // construction/destruction - spectrum_uspeech_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_uspeech_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/spectrum/wafa.cpp b/src/devices/bus/spectrum/wafa.cpp index c5af195289c..ced9ac85ac0 100644 --- a/src/devices/bus/spectrum/wafa.cpp +++ b/src/devices/bus/spectrum/wafa.cpp @@ -71,7 +71,7 @@ const tiny_rom_entry *spectrum_wafa_device::device_rom_region() const // spectrum_wafa_device - constructor //------------------------------------------------- -spectrum_wafa_device::spectrum_wafa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spectrum_wafa_device::spectrum_wafa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPECTRUM_WAFA, tag, owner, clock) , device_spectrum_expansion_interface(mconfig, *this) , m_exp(*this, "exp") diff --git a/src/devices/bus/spectrum/wafa.h b/src/devices/bus/spectrum/wafa.h index 6ca1f4d256a..3797a3ca667 100644 --- a/src/devices/bus/spectrum/wafa.h +++ b/src/devices/bus/spectrum/wafa.h @@ -27,7 +27,7 @@ class spectrum_wafa_device: { public: // construction/destruction - spectrum_wafa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spectrum_wafa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK | feature::LAN; } diff --git a/src/devices/bus/ss50/dc5.cpp b/src/devices/bus/ss50/dc5.cpp index d3c105bc2a8..16c574ca3b7 100644 --- a/src/devices/bus/ss50/dc5.cpp +++ b/src/devices/bus/ss50/dc5.cpp @@ -40,7 +40,7 @@ class ss50_dc5_device : public device_t, public ss50_card_interface { public: - ss50_dc5_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + ss50_dc5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SS50_DC5, tag, owner, clock) , ss50_card_interface(mconfig, *this) , m_fdc(*this, "fdc") @@ -786,7 +786,7 @@ void ss50_dc5_device::register_write(offs_t offset, uint8_t data) uint32_t expected_clock_div = m_expected_clock->read(); if (expected_clock_div && clock_div != expected_clock_div) { - logerror("%s Unexpected clock rate of %dHz expected %dHz.\n", machine().describe_context(), 12'000'000 / clock_div, 12'000'000 / expected_clock_div); + logerror("%s Unexpected clock rate of %dHz expected %dHz.\n", machine().describe_context(), XTAL::u(12'000'000) / clock_div, 12'000'000 / expected_clock_div); clock_div = expected_clock_div; } diff --git a/src/devices/bus/ss50/interface.cpp b/src/devices/bus/ss50/interface.cpp index a3100585a76..123bdeb32c2 100644 --- a/src/devices/bus/ss50/interface.cpp +++ b/src/devices/bus/ss50/interface.cpp @@ -103,7 +103,7 @@ DEFINE_DEVICE_TYPE(SS50_INTERFACE, ss50_interface_port_device, "ss50_interface", // ss50_interface_port_device - construction //------------------------------------------------- -ss50_interface_port_device::ss50_interface_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +ss50_interface_port_device::ss50_interface_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SS50_INTERFACE, tag, owner, clock), device_single_card_slot_interface<ss50_card_interface>(mconfig, *this), m_irq_cb(*this), diff --git a/src/devices/bus/ss50/interface.h b/src/devices/bus/ss50/interface.h index 28e8f82c8c9..79e209f51cc 100644 --- a/src/devices/bus/ss50/interface.h +++ b/src/devices/bus/ss50/interface.h @@ -29,7 +29,7 @@ public: // construction/destruction template <typename T> ss50_interface_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : ss50_interface_port_device(mconfig, tag, owner, 0) + : ss50_interface_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -37,7 +37,7 @@ public: set_fixed(false); } - ss50_interface_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + ss50_interface_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // static configuration auto irq_cb() { return m_irq_cb.bind(); } diff --git a/src/devices/bus/ss50/mpc.cpp b/src/devices/bus/ss50/mpc.cpp index 99c476684b3..dbea6e692b4 100644 --- a/src/devices/bus/ss50/mpc.cpp +++ b/src/devices/bus/ss50/mpc.cpp @@ -24,7 +24,7 @@ class ss50_mpc_device : public device_t, public ss50_card_interface { public: // construction/destruction - ss50_mpc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + ss50_mpc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SS50_MPC, tag, owner, clock) , ss50_card_interface(mconfig, *this) , m_pia(*this, "pia") @@ -101,7 +101,7 @@ DEVICE_INPUT_DEFAULTS_END void ss50_mpc_device::device_add_mconfig(machine_config &config) { - PIA6821(config, m_pia, 0); // actually MC6820 + PIA6821(config, m_pia); // actually MC6820 m_pia->writepa_handler().set("outgate", FUNC(input_merger_device::in_w<0>)).bit(0); m_pia->cb2_handler().set(FUNC(ss50_mpc_device::reader_control_w)); m_pia->readpb_handler().set_ioport("STOP").mask(0x01).lshift(6); diff --git a/src/devices/bus/ss50/mps.cpp b/src/devices/bus/ss50/mps.cpp index b79d1dddbc0..3220ae97ec6 100644 --- a/src/devices/bus/ss50/mps.cpp +++ b/src/devices/bus/ss50/mps.cpp @@ -22,7 +22,7 @@ class ss50_mps_device : public device_t, public ss50_card_interface { public: // construction/destruction - ss50_mps_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + ss50_mps_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SS50_MPS, tag, owner, clock) , ss50_card_interface(mconfig, *this) , m_acia(*this, "acia") @@ -109,7 +109,7 @@ DEVICE_INPUT_DEFAULTS_END void ss50_mps_device::device_add_mconfig(machine_config &config) { - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set("rs232", FUNC(rs232_port_device::write_txd)); //m_acia->rts_handler().set(FUNC(ss50_mps_device::reader_control_w)); m_acia->irq_handler().set(FUNC(ss50_mps_device::acia_irq_w)); diff --git a/src/devices/bus/ss50/mps2.cpp b/src/devices/bus/ss50/mps2.cpp index f0d9350bfb8..28bce3c6b4c 100644 --- a/src/devices/bus/ss50/mps2.cpp +++ b/src/devices/bus/ss50/mps2.cpp @@ -24,7 +24,7 @@ class ss50_mps2_device : public device_t, public ss50_card_interface { public: // construction/destruction - ss50_mps2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + ss50_mps2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SS50_MPS2, tag, owner, clock) , ss50_card_interface(mconfig, *this) , m_acia_upper(*this, "acia_upper") @@ -130,7 +130,7 @@ DEVICE_INPUT_DEFAULTS_END void ss50_mps2_device::device_add_mconfig(machine_config &config) { - ACIA6850(config, m_acia_upper, 0); + ACIA6850(config, m_acia_upper); m_acia_upper->txd_handler().set("rs232_upper", FUNC(rs232_port_device::write_txd)); m_acia_upper->rts_handler().set("rs232_upper", FUNC(rs232_port_device::write_rts)); m_acia_upper->irq_handler().set("irq", FUNC(input_merger_device::in_w<0>)); @@ -141,7 +141,7 @@ void ss50_mps2_device::device_add_mconfig(machine_config &config) rs232_upper.dcd_handler().set(m_acia_upper, FUNC(acia6850_device::write_dcd)); rs232_upper.set_option_device_input_defaults("terminal", DEVICE_INPUT_DEFAULTS_NAME(terminal_upper)); - ACIA6850(config, m_acia_lower, 0); + ACIA6850(config, m_acia_lower); m_acia_lower->txd_handler().set("rs232_lower", FUNC(rs232_port_device::write_txd)); m_acia_lower->rts_handler().set("rs232_lower", FUNC(rs232_port_device::write_rts)); m_acia_lower->irq_handler().set("irq", FUNC(input_merger_device::in_w<1>)); diff --git a/src/devices/bus/ss50/mpt.cpp b/src/devices/bus/ss50/mpt.cpp index f9078aee4ac..3513856336e 100644 --- a/src/devices/bus/ss50/mpt.cpp +++ b/src/devices/bus/ss50/mpt.cpp @@ -17,7 +17,7 @@ class ss50_mpt_device : public device_t, public ss50_card_interface { public: - ss50_mpt_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + ss50_mpt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SS50_MPT, tag, owner, clock) , ss50_card_interface(mconfig, *this) , m_pia(*this, "pia") @@ -80,7 +80,7 @@ ioport_constructor ss50_mpt_device::device_input_ports() const void ss50_mpt_device::device_add_mconfig(machine_config &config) { - PIA6821(config, m_pia, 0); + PIA6821(config, m_pia); m_pia->writepb_handler().set(FUNC(ss50_mpt_device::pia_b_w)); m_pia->cb1_w(0); m_pia->irqa_handler().set(FUNC(ss50_mpt_device::pia_irqa_w)); diff --git a/src/devices/bus/ss50/piaide.cpp b/src/devices/bus/ss50/piaide.cpp index a8ac76efdf6..b7e62c8dd97 100644 --- a/src/devices/bus/ss50/piaide.cpp +++ b/src/devices/bus/ss50/piaide.cpp @@ -49,7 +49,7 @@ class ss50_piaide_device : public device_t, public ss50_card_interface { public: // construction/destruction - ss50_piaide_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + ss50_piaide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SS50_PIAIDE, tag, owner, clock) , ss50_card_interface(mconfig, *this) , m_pia(*this, "pia") @@ -93,7 +93,7 @@ void ss50_piaide_device::device_start() void ss50_piaide_device::device_add_mconfig(machine_config &config) { - PIA6821(config, m_pia, 0); + PIA6821(config, m_pia); m_pia->readpa_handler().set(FUNC(ss50_piaide_device::pia_a_r)); m_pia->readpb_handler().set(FUNC(ss50_piaide_device::pia_b_r)); m_pia->writepa_handler().set(FUNC(ss50_piaide_device::pia_a_w)); diff --git a/src/devices/bus/sunkbd/sunkbd.h b/src/devices/bus/sunkbd/sunkbd.h index 8a210025912..f38f9c10ffa 100644 --- a/src/devices/bus/sunkbd/sunkbd.h +++ b/src/devices/bus/sunkbd/sunkbd.h @@ -18,14 +18,14 @@ class sun_keyboard_port_device : public device_t, public device_single_card_slot public: template <typename T> sun_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : sun_keyboard_port_device(mconfig, tag, owner, 0) + : sun_keyboard_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sun_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + sun_keyboard_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~sun_keyboard_port_device(); // configuration helpers @@ -36,7 +36,7 @@ public: DECLARE_READ_LINE_MEMBER( rxd_r ) { return m_rxd; } protected: - sun_keyboard_port_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock); + sun_keyboard_port_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); virtual void device_config_complete() override; virtual void device_resolve_objects() override; diff --git a/src/devices/bus/sunmouse/sunmouse.h b/src/devices/bus/sunmouse/sunmouse.h index e665529bdfe..1de841a01bb 100644 --- a/src/devices/bus/sunmouse/sunmouse.h +++ b/src/devices/bus/sunmouse/sunmouse.h @@ -18,14 +18,14 @@ class sun_mouse_port_device : public device_t, public device_single_card_slot_in public: template <typename T> sun_mouse_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : sun_mouse_port_device(mconfig, tag, owner, 0) + : sun_mouse_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - sun_mouse_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0); + sun_mouse_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~sun_mouse_port_device(); // configuration helpers @@ -36,7 +36,7 @@ public: DECLARE_READ_LINE_MEMBER( rxd_r ) { return m_rxd; } protected: - sun_mouse_port_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock); + sun_mouse_port_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); virtual void device_config_complete() override; virtual void device_resolve_objects() override; diff --git a/src/devices/bus/svi3x8/expander/expander.cpp b/src/devices/bus/svi3x8/expander/expander.cpp index ea1fab43f93..7fadb19858e 100644 --- a/src/devices/bus/svi3x8/expander/expander.cpp +++ b/src/devices/bus/svi3x8/expander/expander.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(SVI_EXPANDER, svi_expander_device, "svi_expander", "SVI 318/3 // svi_expander_device - constructor //------------------------------------------------- -svi_expander_device::svi_expander_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +svi_expander_device::svi_expander_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SVI_EXPANDER, tag, owner, clock), device_single_card_slot_interface<device_svi_expander_interface>(mconfig, *this), m_module(nullptr), diff --git a/src/devices/bus/svi3x8/expander/expander.h b/src/devices/bus/svi3x8/expander/expander.h index f7bba16eba3..36c1a9bac3f 100644 --- a/src/devices/bus/svi3x8/expander/expander.h +++ b/src/devices/bus/svi3x8/expander/expander.h @@ -54,7 +54,7 @@ public: // construction/destruction template <typename T> svi_expander_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts) - : svi_expander_device(mconfig, tag, owner, uint32_t(0)) + : svi_expander_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -62,7 +62,7 @@ public: set_fixed(false); } - svi_expander_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + svi_expander_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~svi_expander_device(); // callbacks diff --git a/src/devices/bus/svi3x8/expander/sv601.cpp b/src/devices/bus/svi3x8/expander/sv601.cpp index 662f3cb0c2e..9a200c27cc6 100644 --- a/src/devices/bus/svi3x8/expander/sv601.cpp +++ b/src/devices/bus/svi3x8/expander/sv601.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(SV601, sv601_device, "sv601", "SV-601 Super Expander") void sv601_device::device_add_mconfig(machine_config &config) { - SVI_SLOT_BUS(config, m_slotbus, 0); + SVI_SLOT_BUS(config, m_slotbus); m_slotbus->int_handler().set(FUNC(sv601_device::int_w)); m_slotbus->romdis_handler().set(FUNC(sv601_device::romdis_w)); m_slotbus->ramdis_handler().set(FUNC(sv601_device::ramdis_w)); @@ -44,7 +44,7 @@ void sv601_device::device_add_mconfig(machine_config &config) // sv601_device - constructor //------------------------------------------------- -sv601_device::sv601_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sv601_device::sv601_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SV601, tag, owner, clock), device_svi_expander_interface(mconfig, *this), m_slotbus(*this, "slotbus") diff --git a/src/devices/bus/svi3x8/expander/sv601.h b/src/devices/bus/svi3x8/expander/sv601.h index 692191a7ea9..7b83ebfecc1 100644 --- a/src/devices/bus/svi3x8/expander/sv601.h +++ b/src/devices/bus/svi3x8/expander/sv601.h @@ -25,7 +25,7 @@ class sv601_device : public device_t, public device_svi_expander_interface { public: // construction/destruction - sv601_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sv601_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from slots WRITE_LINE_MEMBER( int_w ); diff --git a/src/devices/bus/svi3x8/expander/sv602.cpp b/src/devices/bus/svi3x8/expander/sv602.cpp index 1f5d0c0d352..8d68ff4780f 100644 --- a/src/devices/bus/svi3x8/expander/sv602.cpp +++ b/src/devices/bus/svi3x8/expander/sv602.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(SV602, sv602_device, "sv602", "SV-602 Single Slot Expander") void sv602_device::device_add_mconfig(machine_config &config) { - SVI_SLOT_BUS(config, m_slotbus, 0); + SVI_SLOT_BUS(config, m_slotbus); m_slotbus->int_handler().set(FUNC(sv602_device::int_w)); m_slotbus->romdis_handler().set(FUNC(sv602_device::romdis_w)); m_slotbus->ramdis_handler().set(FUNC(sv602_device::ramdis_w)); @@ -38,7 +38,7 @@ void sv602_device::device_add_mconfig(machine_config &config) // sv602_device - constructor //------------------------------------------------- -sv602_device::sv602_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sv602_device::sv602_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SV602, tag, owner, clock), device_svi_expander_interface(mconfig, *this), m_slotbus(*this, "slotbus") diff --git a/src/devices/bus/svi3x8/expander/sv602.h b/src/devices/bus/svi3x8/expander/sv602.h index 607d1cf6c17..3a1fd9a1e67 100644 --- a/src/devices/bus/svi3x8/expander/sv602.h +++ b/src/devices/bus/svi3x8/expander/sv602.h @@ -25,7 +25,7 @@ class sv602_device : public device_t, public device_svi_expander_interface { public: // construction/destruction - sv602_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sv602_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual uint8_t mreq_r(offs_t offset) override; diff --git a/src/devices/bus/svi3x8/expander/sv603.cpp b/src/devices/bus/svi3x8/expander/sv603.cpp index fb0fd3428f9..7d9f56a9236 100644 --- a/src/devices/bus/svi3x8/expander/sv603.cpp +++ b/src/devices/bus/svi3x8/expander/sv603.cpp @@ -61,7 +61,7 @@ void sv603_device::device_add_mconfig(machine_config &config) // sv603_device - constructor //------------------------------------------------- -sv603_device::sv603_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sv603_device::sv603_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SV603, tag, owner, clock), device_svi_expander_interface(mconfig, *this), m_bios(*this, "bios"), diff --git a/src/devices/bus/svi3x8/expander/sv603.h b/src/devices/bus/svi3x8/expander/sv603.h index a6b3fde21b8..5dc9a3e8e55 100644 --- a/src/devices/bus/svi3x8/expander/sv603.h +++ b/src/devices/bus/svi3x8/expander/sv603.h @@ -27,7 +27,7 @@ class sv603_device : public device_t, public device_svi_expander_interface { public: // construction/destruction - sv603_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sv603_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // from host virtual uint8_t mreq_r(offs_t offset) override; diff --git a/src/devices/bus/svi3x8/slot/slot.cpp b/src/devices/bus/svi3x8/slot/slot.cpp index 705734dea4c..3de46842122 100644 --- a/src/devices/bus/svi3x8/slot/slot.cpp +++ b/src/devices/bus/svi3x8/slot/slot.cpp @@ -20,7 +20,7 @@ DEFINE_DEVICE_TYPE(SVI_SLOT_BUS, svi_slot_bus_device, "svislotbus", "SVI Slot Bu // svi_slot_bus_device - constructor //------------------------------------------------- -svi_slot_bus_device::svi_slot_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +svi_slot_bus_device::svi_slot_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SVI_SLOT_BUS, tag, owner, clock) , m_int_handler(*this) , m_romdis_handler(*this) @@ -196,7 +196,7 @@ DEFINE_DEVICE_TYPE(SVI_SLOT, svi_slot_device, "svislot", "SVI Slot") // svi_slot_device - constructor //------------------------------------------------- -svi_slot_device::svi_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +svi_slot_device::svi_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SVI_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_svi_slot_interface>(mconfig, *this) , m_bus(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/bus/svi3x8/slot/slot.h b/src/devices/bus/svi3x8/slot/slot.h index 11b94d07e5d..854c89739ee 100644 --- a/src/devices/bus/svi3x8/slot/slot.h +++ b/src/devices/bus/svi3x8/slot/slot.h @@ -53,7 +53,7 @@ class svi_slot_bus_device : public device_t { public: // construction/destruction - svi_slot_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + svi_slot_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~svi_slot_bus_device(); // callbacks @@ -101,7 +101,7 @@ public: // construction/destruction template <typename T, typename U> svi_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bus, U &&opts, char const *dflt) - : svi_slot_device(mconfig, tag, owner, 0) + : svi_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -110,7 +110,7 @@ public: set_bus(std::forward<T>(bus)); } - svi_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + svi_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_bus(T &&tag) { m_bus.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/bus/svi3x8/slot/sv801.cpp b/src/devices/bus/svi3x8/slot/sv801.cpp index 5695cfd5957..1433773b93c 100644 --- a/src/devices/bus/svi3x8/slot/sv801.cpp +++ b/src/devices/bus/svi3x8/slot/sv801.cpp @@ -54,7 +54,7 @@ void sv801_device::device_add_mconfig(machine_config &config) // sv801_device - constructor //------------------------------------------------- -sv801_device::sv801_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sv801_device::sv801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SV801, tag, owner, clock), device_svi_slot_interface(mconfig, *this), m_fdc(*this, "fdc"), diff --git a/src/devices/bus/svi3x8/slot/sv801.h b/src/devices/bus/svi3x8/slot/sv801.h index 5651e519fb7..8d594b66d14 100644 --- a/src/devices/bus/svi3x8/slot/sv801.h +++ b/src/devices/bus/svi3x8/slot/sv801.h @@ -26,7 +26,7 @@ class sv801_device : public device_t, public device_svi_slot_interface { public: // construction/destruction - sv801_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sv801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t iorq_r(offs_t offset) override; virtual void iorq_w(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/svi3x8/slot/sv802.cpp b/src/devices/bus/svi3x8/slot/sv802.cpp index 909ed2fa712..7aa33750963 100644 --- a/src/devices/bus/svi3x8/slot/sv802.cpp +++ b/src/devices/bus/svi3x8/slot/sv802.cpp @@ -38,7 +38,7 @@ void sv802_device::device_add_mconfig(machine_config &config) // sv802_device - constructor //------------------------------------------------- -sv802_device::sv802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sv802_device::sv802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SV802, tag, owner, clock), device_svi_slot_interface(mconfig, *this), m_centronics(*this, "centronics"), diff --git a/src/devices/bus/svi3x8/slot/sv802.h b/src/devices/bus/svi3x8/slot/sv802.h index aabea33bbaf..06fb433245d 100644 --- a/src/devices/bus/svi3x8/slot/sv802.h +++ b/src/devices/bus/svi3x8/slot/sv802.h @@ -26,7 +26,7 @@ class sv802_device : public device_t, public device_svi_slot_interface { public: // construction/destruction - sv802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sv802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t iorq_r(offs_t offset) override; virtual void iorq_w(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/svi3x8/slot/sv803.cpp b/src/devices/bus/svi3x8/slot/sv803.cpp index 6adc07fd193..af094eb68c5 100644 --- a/src/devices/bus/svi3x8/slot/sv803.cpp +++ b/src/devices/bus/svi3x8/slot/sv803.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(SV803, sv803_device, "sv803", "SV-803 16k RAM Cartridge") // sv803_device - constructor //------------------------------------------------- -sv803_device::sv803_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sv803_device::sv803_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SV803, tag, owner, clock), device_svi_slot_interface(mconfig, *this) { diff --git a/src/devices/bus/svi3x8/slot/sv803.h b/src/devices/bus/svi3x8/slot/sv803.h index 8cae18acf64..cb6359d0ac2 100644 --- a/src/devices/bus/svi3x8/slot/sv803.h +++ b/src/devices/bus/svi3x8/slot/sv803.h @@ -24,7 +24,7 @@ class sv803_device : public device_t, public device_svi_slot_interface { public: // construction/destruction - sv803_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sv803_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t mreq_r(offs_t offset) override; virtual void mreq_w(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/svi3x8/slot/sv805.cpp b/src/devices/bus/svi3x8/slot/sv805.cpp index a5ceadf3577..1f4f9324617 100644 --- a/src/devices/bus/svi3x8/slot/sv805.cpp +++ b/src/devices/bus/svi3x8/slot/sv805.cpp @@ -44,7 +44,7 @@ void sv805_device::device_add_mconfig(machine_config &config) // sv805_device - constructor //------------------------------------------------- -sv805_device::sv805_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sv805_device::sv805_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SV805, tag, owner, clock), device_svi_slot_interface(mconfig, *this), m_uart(*this, "uart"), diff --git a/src/devices/bus/svi3x8/slot/sv805.h b/src/devices/bus/svi3x8/slot/sv805.h index 892dc23b432..3e43a4eb9dc 100644 --- a/src/devices/bus/svi3x8/slot/sv805.h +++ b/src/devices/bus/svi3x8/slot/sv805.h @@ -26,7 +26,7 @@ class sv805_device : public device_t, public device_svi_slot_interface { public: // construction/destruction - sv805_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sv805_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t iorq_r(offs_t offset) override; virtual void iorq_w(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/svi3x8/slot/sv806.cpp b/src/devices/bus/svi3x8/slot/sv806.cpp index 5a7d858d38b..34d05a75746 100644 --- a/src/devices/bus/svi3x8/slot/sv806.cpp +++ b/src/devices/bus/svi3x8/slot/sv806.cpp @@ -64,7 +64,7 @@ void sv806_device::device_add_mconfig(machine_config &config) // sv806_device - constructor //------------------------------------------------- -sv806_device::sv806_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sv806_device::sv806_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SV806, tag, owner, clock), device_svi_slot_interface(mconfig, *this), m_crtc(*this, "crtc"), diff --git a/src/devices/bus/svi3x8/slot/sv806.h b/src/devices/bus/svi3x8/slot/sv806.h index 095e8291acc..3b70ff36796 100644 --- a/src/devices/bus/svi3x8/slot/sv806.h +++ b/src/devices/bus/svi3x8/slot/sv806.h @@ -26,7 +26,7 @@ class sv806_device : public device_t, public device_svi_slot_interface { public: // construction/destruction - sv806_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sv806_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t mreq_r(offs_t offset) override; virtual void mreq_w(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/svi3x8/slot/sv807.cpp b/src/devices/bus/svi3x8/slot/sv807.cpp index 281b7845c64..c223495bea7 100644 --- a/src/devices/bus/svi3x8/slot/sv807.cpp +++ b/src/devices/bus/svi3x8/slot/sv807.cpp @@ -76,7 +76,7 @@ ioport_constructor sv807_device::device_input_ports() const // sv807_device - constructor //------------------------------------------------- -sv807_device::sv807_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sv807_device::sv807_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SV807, tag, owner, clock), device_svi_slot_interface(mconfig, *this), m_switch(*this, "S"), diff --git a/src/devices/bus/svi3x8/slot/sv807.h b/src/devices/bus/svi3x8/slot/sv807.h index 8d12befff79..a373cea15f2 100644 --- a/src/devices/bus/svi3x8/slot/sv807.h +++ b/src/devices/bus/svi3x8/slot/sv807.h @@ -24,7 +24,7 @@ class sv807_device : public device_t, public device_svi_slot_interface { public: // construction/destruction - sv807_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sv807_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/tanbus/bullsnd.cpp b/src/devices/bus/tanbus/bullsnd.cpp index 3dcd7a9897b..937113f2a65 100644 --- a/src/devices/bus/tanbus/bullsnd.cpp +++ b/src/devices/bus/tanbus/bullsnd.cpp @@ -40,7 +40,7 @@ void tanbus_bullsnd_device::device_add_mconfig(machine_config &config) // tanbus_bullsnd_device - constructor //------------------------------------------------- -tanbus_bullsnd_device::tanbus_bullsnd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_bullsnd_device::tanbus_bullsnd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_BULLSND, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_ay8910(*this, "ay8910%u", 0) diff --git a/src/devices/bus/tanbus/bullsnd.h b/src/devices/bus/tanbus/bullsnd.h index 1573eab6351..5a645b88fa0 100644 --- a/src/devices/bus/tanbus/bullsnd.h +++ b/src/devices/bus/tanbus/bullsnd.h @@ -25,7 +25,7 @@ class tanbus_bullsnd_device : { public: // construction/destruction - tanbus_bullsnd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_bullsnd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tanbus/mpvdu.cpp b/src/devices/bus/tanbus/mpvdu.cpp index 43c303dff4b..dbd015f87b3 100644 --- a/src/devices/bus/tanbus/mpvdu.cpp +++ b/src/devices/bus/tanbus/mpvdu.cpp @@ -57,7 +57,7 @@ void tanbus_mpvdu_device::device_add_mconfig(machine_config &config) // tanbus_mpvdu_device - constructor //------------------------------------------------- -tanbus_mpvdu_device::tanbus_mpvdu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_mpvdu_device::tanbus_mpvdu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_MPVDU, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_screen(*this, "screen") diff --git a/src/devices/bus/tanbus/mpvdu.h b/src/devices/bus/tanbus/mpvdu.h index ddde01e0611..141159aa59f 100644 --- a/src/devices/bus/tanbus/mpvdu.h +++ b/src/devices/bus/tanbus/mpvdu.h @@ -29,7 +29,7 @@ public: static constexpr feature_type imperfect_features() { return feature::GRAPHICS; } // construction/destruction - tanbus_mpvdu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_mpvdu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tanbus/ra32k.cpp b/src/devices/bus/tanbus/ra32k.cpp index 9b83afc96f0..1d3aee47fe7 100644 --- a/src/devices/bus/tanbus/ra32k.cpp +++ b/src/devices/bus/tanbus/ra32k.cpp @@ -138,7 +138,7 @@ const tiny_rom_entry *tanbus_ra32k_device::device_rom_region() const // tanbus_ra32k_device - constructor //------------------------------------------------- -tanbus_ra32k_device::tanbus_ra32k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_ra32k_device::tanbus_ra32k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_RA32K, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_rom(*this, "rom") diff --git a/src/devices/bus/tanbus/ra32k.h b/src/devices/bus/tanbus/ra32k.h index a67e9c859bb..7e16bd9152f 100644 --- a/src/devices/bus/tanbus/ra32k.h +++ b/src/devices/bus/tanbus/ra32k.h @@ -25,7 +25,7 @@ class tanbus_ra32k_device : { public: // construction/destruction - tanbus_ra32k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_ra32k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tanbus/radisc.cpp b/src/devices/bus/tanbus/radisc.cpp index b302e33c80d..f612a4c6ca4 100644 --- a/src/devices/bus/tanbus/radisc.cpp +++ b/src/devices/bus/tanbus/radisc.cpp @@ -58,7 +58,7 @@ void tanbus_radisc_device::device_add_mconfig(machine_config &config) /* audio hardware */ SPEAKER(config, "mono").front_center(); - BEEP(config, m_beeper, 1000); // TODO: unknown frequency + BEEP(config, m_beeper, XTAL::u(1000)); // TODO: unknown frequency m_beeper->add_route(ALL_OUTPUTS, "mono", 1.0); } @@ -70,7 +70,7 @@ void tanbus_radisc_device::device_add_mconfig(machine_config &config) // tanbus_radisc_device - constructor //------------------------------------------------- -tanbus_radisc_device::tanbus_radisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_radisc_device::tanbus_radisc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_RADISC, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_fdc(*this, "fdc") diff --git a/src/devices/bus/tanbus/radisc.h b/src/devices/bus/tanbus/radisc.h index bbcfc2298ac..2fc5391c599 100644 --- a/src/devices/bus/tanbus/radisc.h +++ b/src/devices/bus/tanbus/radisc.h @@ -30,7 +30,7 @@ class tanbus_radisc_device : { public: // construction/destruction - tanbus_radisc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_radisc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); diff --git a/src/devices/bus/tanbus/ravdu.cpp b/src/devices/bus/tanbus/ravdu.cpp index 43cd6ff45ab..7d1e6068949 100644 --- a/src/devices/bus/tanbus/ravdu.cpp +++ b/src/devices/bus/tanbus/ravdu.cpp @@ -59,7 +59,7 @@ void tanbus_ravdu_device::device_add_mconfig(machine_config &config) // tanbus_ravdu_device - constructor //------------------------------------------------- -tanbus_ravdu_device::tanbus_ravdu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_ravdu_device::tanbus_ravdu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_RAVDU, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_screen(*this, "screen") diff --git a/src/devices/bus/tanbus/ravdu.h b/src/devices/bus/tanbus/ravdu.h index f21dc73c4f5..f85d63ad9ff 100644 --- a/src/devices/bus/tanbus/ravdu.h +++ b/src/devices/bus/tanbus/ravdu.h @@ -29,7 +29,7 @@ public: static constexpr feature_type imperfect_features() { return feature::GRAPHICS; } // construction/destruction - tanbus_ravdu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_ravdu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tanbus/tanbus.cpp b/src/devices/bus/tanbus/tanbus.cpp index b84d625c80f..7feb8ad9564 100644 --- a/src/devices/bus/tanbus/tanbus.cpp +++ b/src/devices/bus/tanbus/tanbus.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(TANBUS_SLOT, tanbus_slot_device, "tanbus_slot", "Microtan Bus //------------------------------------------------- // tanbus_slot_device - constructor //------------------------------------------------- -tanbus_slot_device::tanbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_slot_device::tanbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_SLOT, tag, owner, clock) , device_single_card_slot_interface<device_tanbus_interface>(mconfig, *this) , m_tanbus(*this, DEVICE_SELF_OWNER) @@ -58,7 +58,7 @@ DEFINE_DEVICE_TYPE(TANBUS, tanbus_device, "tanbus", "Microtan Bus") // tanbus_device - constructor //------------------------------------------------- -tanbus_device::tanbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_device::tanbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS, tag, owner, clock) , m_out_irq_cb(*this) , m_out_nmi_cb(*this) diff --git a/src/devices/bus/tanbus/tanbus.h b/src/devices/bus/tanbus/tanbus.h index 7f5e87eb0aa..ddfb4377df3 100644 --- a/src/devices/bus/tanbus/tanbus.h +++ b/src/devices/bus/tanbus/tanbus.h @@ -39,7 +39,7 @@ public: set_fixed(false); set_tanbus_slot(num); } - tanbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration void set_tanbus_slot(int num) { m_bus_num = num; } @@ -65,7 +65,7 @@ class tanbus_device : public device_t { public: // construction/destruction - tanbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~tanbus_device() { m_device_list.detach_all(); } // inline configuration diff --git a/src/devices/bus/tanbus/tandos.cpp b/src/devices/bus/tanbus/tandos.cpp index ae971913254..9855b6ffd44 100644 --- a/src/devices/bus/tanbus/tandos.cpp +++ b/src/devices/bus/tanbus/tandos.cpp @@ -74,7 +74,7 @@ const tiny_rom_entry *tanbus_tandos_device::device_rom_region() const // tanbus_tandos_device - constructor //------------------------------------------------- -tanbus_tandos_device::tanbus_tandos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_tandos_device::tanbus_tandos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_TANDOS, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_dos_rom(*this, "dos_rom") diff --git a/src/devices/bus/tanbus/tandos.h b/src/devices/bus/tanbus/tandos.h index 60a157809f8..2489aebe63c 100644 --- a/src/devices/bus/tanbus/tandos.h +++ b/src/devices/bus/tanbus/tandos.h @@ -28,7 +28,7 @@ public: static constexpr feature_type imperfect_features() { return feature::DISK; } // construction/destruction - tanbus_tandos_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_tandos_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void floppy_formats(format_registration &fr); diff --git a/src/devices/bus/tanbus/tanex.cpp b/src/devices/bus/tanbus/tanex.cpp index f99a9d6cdf4..82b362a1f2b 100644 --- a/src/devices/bus/tanbus/tanex.cpp +++ b/src/devices/bus/tanbus/tanex.cpp @@ -103,7 +103,7 @@ void tanbus_tanex_device::device_add_mconfig(machine_config &config) INPUT_MERGER_ANY_HIGH(config, m_irq_line).output_handler().set(FUNC(tanbus_tanex_device::bus_irq_w)); /* acia */ - MOS6551(config, m_acia, 0); + MOS6551(config, m_acia); m_acia->set_xtal(1.8432_MHz_XTAL); m_acia->txd_handler().set(m_rs232, FUNC(rs232_port_device::write_txd)); m_acia->rts_handler().set(m_rs232, FUNC(rs232_port_device::write_rts)); @@ -165,7 +165,7 @@ const tiny_rom_entry *tanbus_tanex_device::device_rom_region() const // tanbus_tanex_device - constructor //------------------------------------------------- -tanbus_tanex_device::tanbus_tanex_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_tanex_device::tanbus_tanex_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_TANEX, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_rom_tanex(*this, "rom_tanex") diff --git a/src/devices/bus/tanbus/tanex.h b/src/devices/bus/tanbus/tanex.h index ec3f75fb344..f1e491d0b8f 100644 --- a/src/devices/bus/tanbus/tanex.h +++ b/src/devices/bus/tanbus/tanex.h @@ -32,7 +32,7 @@ class tanbus_tanex_device : { public: // construction/destruction - tanbus_tanex_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_tanex_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tanbus/tanhrg.cpp b/src/devices/bus/tanbus/tanhrg.cpp index b857e84ac69..d3edbceb2b6 100644 --- a/src/devices/bus/tanbus/tanhrg.cpp +++ b/src/devices/bus/tanbus/tanhrg.cpp @@ -161,7 +161,7 @@ void tanbus_tanhrgc_device::device_add_mconfig(machine_config &config) // tanbus_tanhrg_device - constructor //------------------------------------------------- -tanbus_tanhrg_device::tanbus_tanhrg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_tanhrg_device::tanbus_tanhrg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_TANHRG, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_dsw(*this, "DSW") @@ -171,7 +171,7 @@ tanbus_tanhrg_device::tanbus_tanhrg_device(const machine_config &mconfig, const } -tanbus_tanhrgc_device::tanbus_tanhrgc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_tanhrgc_device::tanbus_tanhrgc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_TANHRGC, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_dsw(*this, "DSW_%u", 1) diff --git a/src/devices/bus/tanbus/tanhrg.h b/src/devices/bus/tanbus/tanhrg.h index bce2c68bd78..cfb6b4b64b8 100644 --- a/src/devices/bus/tanbus/tanhrg.h +++ b/src/devices/bus/tanbus/tanhrg.h @@ -26,7 +26,7 @@ class tanbus_tanhrg_device : { public: // construction/destruction - tanbus_tanhrg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_tanhrg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -57,7 +57,7 @@ class tanbus_tanhrgc_device : { public: // construction/destruction - tanbus_tanhrgc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_tanhrgc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tanbus/tanram.cpp b/src/devices/bus/tanbus/tanram.cpp index 0e3dadf9d15..791a822bd08 100644 --- a/src/devices/bus/tanbus/tanram.cpp +++ b/src/devices/bus/tanbus/tanram.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(TANBUS_TANRAM, tanbus_tanram_device, "tanbus_tanram", "Tanger // tanbus_tanram_device - constructor //------------------------------------------------- -tanbus_tanram_device::tanbus_tanram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_tanram_device::tanbus_tanram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_TANRAM, tag, owner, clock) , device_tanbus_interface(mconfig, *this) { diff --git a/src/devices/bus/tanbus/tanram.h b/src/devices/bus/tanbus/tanram.h index 9cdf7970c77..acb78ab353e 100644 --- a/src/devices/bus/tanbus/tanram.h +++ b/src/devices/bus/tanbus/tanram.h @@ -24,7 +24,7 @@ class tanbus_tanram_device : { public: // construction/destruction - tanbus_tanram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_tanram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tanbus/tug64k.cpp b/src/devices/bus/tanbus/tug64k.cpp index 3f5d834cd92..a3ae1437b33 100644 --- a/src/devices/bus/tanbus/tug64k.cpp +++ b/src/devices/bus/tanbus/tug64k.cpp @@ -83,7 +83,7 @@ ioport_constructor tanbus_tug64k_device::device_input_ports() const // tanbus_tug64k_device - constructor //------------------------------------------------- -tanbus_tug64k_device::tanbus_tug64k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_tug64k_device::tanbus_tug64k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_TUG64K, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_dsw(*this, "SW%u", 1) diff --git a/src/devices/bus/tanbus/tug64k.h b/src/devices/bus/tanbus/tug64k.h index e6163d7a187..afc77911a17 100644 --- a/src/devices/bus/tanbus/tug64k.h +++ b/src/devices/bus/tanbus/tug64k.h @@ -24,7 +24,7 @@ class tanbus_tug64k_device : { public: // construction/destruction - tanbus_tug64k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_tug64k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tanbus/tug8082.cpp b/src/devices/bus/tanbus/tug8082.cpp index 582ab726c8e..8cf0d9c0427 100644 --- a/src/devices/bus/tanbus/tug8082.cpp +++ b/src/devices/bus/tanbus/tug8082.cpp @@ -113,12 +113,12 @@ void tanbus_tug8082_device::device_add_mconfig(machine_config &config) M6502(config, m_maincpu, DERIVED_CLOCK(1, 4)); m_maincpu->set_addrmap(AS_PROGRAM, &tanbus_tug8082_device::vid8082_map); - I8212(config, m_iop[0], 0); + I8212(config, m_iop[0]); //m_iop[0]->md_rd_callback().set(CONSTANT(0)); m_iop[0]->int_wr_callback().set(FUNC(tanbus_tug8082_device::bus_irq_w)); //m_iop->do_wr_callback().set(FUNC(tanbus_tug8082_device::write)); - I8212(config, m_iop[1], 0); + I8212(config, m_iop[1]); //m_iop[1]->md_rd_callback().set(CONSTANT(0)); m_iop[1]->int_wr_callback().set(FUNC(tanbus_tug8082_device::vdu_irq_w)); //m_iop->di_rd_callback().set(FUNC(tanbus_tug8082_device::read)); @@ -150,7 +150,7 @@ const tiny_rom_entry *tanbus_tug8082_device::device_rom_region() const // tanbus_tug8082_device - constructor //------------------------------------------------- -tanbus_tug8082_device::tanbus_tug8082_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_tug8082_device::tanbus_tug8082_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_TUG8082, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_maincpu(*this, "maincpu") diff --git a/src/devices/bus/tanbus/tug8082.h b/src/devices/bus/tanbus/tug8082.h index 979e47180e5..ee04e7a6c08 100644 --- a/src/devices/bus/tanbus/tug8082.h +++ b/src/devices/bus/tanbus/tug8082.h @@ -31,7 +31,7 @@ public: static constexpr feature_type imperfect_features() { return feature::GRAPHICS; } // construction/destruction - tanbus_tug8082_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_tug8082_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tanbus/tugpgm.cpp b/src/devices/bus/tanbus/tugpgm.cpp index e97b0853f64..160c9fb2111 100644 --- a/src/devices/bus/tanbus/tugpgm.cpp +++ b/src/devices/bus/tanbus/tugpgm.cpp @@ -55,7 +55,7 @@ ioport_constructor tanbus_tugpgm_device::device_input_ports() const // tanbus_tugpgm_device - constructor //------------------------------------------------- -tanbus_tugpgm_device::tanbus_tugpgm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tanbus_tugpgm_device::tanbus_tugpgm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TANBUS_TUGPGM, tag, owner, clock) , device_tanbus_interface(mconfig, *this) , m_links(*this, "LINKS") diff --git a/src/devices/bus/tanbus/tugpgm.h b/src/devices/bus/tanbus/tugpgm.h index 215f66a397c..1c44903ae0b 100644 --- a/src/devices/bus/tanbus/tugpgm.h +++ b/src/devices/bus/tanbus/tugpgm.h @@ -26,7 +26,7 @@ public: static constexpr feature_type imperfect_features() { return feature::GRAPHICS; } // construction/destruction - tanbus_tugpgm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tanbus_tugpgm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/thomson/cd90_015.cpp b/src/devices/bus/thomson/cd90_015.cpp index 6f9b2822647..b8ee6b1eea5 100644 --- a/src/devices/bus/thomson/cd90_015.cpp +++ b/src/devices/bus/thomson/cd90_015.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(CD90_015, cd90_015_device, "cd90_015", "Thomson CD90-015 floppy drive selectler") -cd90_015_device::cd90_015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cd90_015_device::cd90_015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CD90_015, tag, owner, clock), thomson_extension_interface(mconfig, *this), m_fdc(*this, "fdc"), diff --git a/src/devices/bus/thomson/cd90_015.h b/src/devices/bus/thomson/cd90_015.h index b2a4069e8cc..c17e8ae2f4c 100644 --- a/src/devices/bus/thomson/cd90_015.h +++ b/src/devices/bus/thomson/cd90_015.h @@ -15,7 +15,7 @@ class cd90_015_device : public device_t, public thomson_extension_interface { public: - cd90_015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + cd90_015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~cd90_015_device() = default; virtual void rom_map(address_map &map) override; diff --git a/src/devices/bus/thomson/cd90_351.cpp b/src/devices/bus/thomson/cd90_351.cpp index 44962c00115..a4904dfb7a4 100644 --- a/src/devices/bus/thomson/cd90_351.cpp +++ b/src/devices/bus/thomson/cd90_351.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(CD90_351, cd90_351_device, "cd90_351", "Thomson CD90-351 floppy drive controller") -cd90_351_device::cd90_351_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cd90_351_device::cd90_351_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CD90_351, tag, owner, 16000000), thomson_extension_interface(mconfig, *this), m_floppy(*this, "%u", 0U), diff --git a/src/devices/bus/thomson/cd90_351.h b/src/devices/bus/thomson/cd90_351.h index 6609eddf7a8..580c0e7c923 100644 --- a/src/devices/bus/thomson/cd90_351.h +++ b/src/devices/bus/thomson/cd90_351.h @@ -15,7 +15,7 @@ class cd90_351_device : public device_t, public thomson_extension_interface { public: - cd90_351_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 16000000); + cd90_351_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = 16000000); virtual ~cd90_351_device() = default; virtual void rom_map(address_map &map) override; diff --git a/src/devices/bus/thomson/cd90_640.cpp b/src/devices/bus/thomson/cd90_640.cpp index 4cae4efb97a..9a153849b22 100644 --- a/src/devices/bus/thomson/cd90_640.cpp +++ b/src/devices/bus/thomson/cd90_640.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(CD90_640, cd90_640_device, "cd90_640", "Thomson CD90-640 floppy drive controller") -cd90_640_device::cd90_640_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cd90_640_device::cd90_640_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CD90_640, tag, owner, clock), thomson_extension_interface(mconfig, *this), m_fdc(*this, "fdc"), diff --git a/src/devices/bus/thomson/cd90_640.h b/src/devices/bus/thomson/cd90_640.h index 5598a71546d..7bcd9f39238 100644 --- a/src/devices/bus/thomson/cd90_640.h +++ b/src/devices/bus/thomson/cd90_640.h @@ -15,7 +15,7 @@ class cd90_640_device : public device_t, public thomson_extension_interface { public: - cd90_640_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + cd90_640_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~cd90_640_device() = default; virtual void rom_map(address_map &map) override; diff --git a/src/devices/bus/thomson/cq90_028.cpp b/src/devices/bus/thomson/cq90_028.cpp index fd14c5302f7..347fbc28935 100644 --- a/src/devices/bus/thomson/cq90_028.cpp +++ b/src/devices/bus/thomson/cq90_028.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(CQ90_028, cq90_028_device, "cq90_028", "Thomson CQ90-028 QDD controller") -cq90_028_device::cq90_028_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cq90_028_device::cq90_028_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CQ90_028, tag, owner, clock), thomson_extension_interface(mconfig, *this), m_serial(*this, "serial"), diff --git a/src/devices/bus/thomson/cq90_028.h b/src/devices/bus/thomson/cq90_028.h index d0a44448e38..e91eb475a55 100644 --- a/src/devices/bus/thomson/cq90_028.h +++ b/src/devices/bus/thomson/cq90_028.h @@ -14,7 +14,7 @@ class cq90_028_device : public device_t, public thomson_extension_interface { public: - cq90_028_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + cq90_028_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~cq90_028_device() = default; static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/thomson/extension.cpp b/src/devices/bus/thomson/extension.cpp index 12462b9898a..ad99ef2c310 100644 --- a/src/devices/bus/thomson/extension.cpp +++ b/src/devices/bus/thomson/extension.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(THOMSON_EXTENSION, thomson_extension_device, "thomson_extension", "Thomson TO*/MO* extension port") -thomson_extension_device::thomson_extension_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +thomson_extension_device::thomson_extension_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, THOMSON_EXTENSION, tag, owner, clock), device_single_card_slot_interface<thomson_extension_interface>(mconfig, *this) { diff --git a/src/devices/bus/thomson/extension.h b/src/devices/bus/thomson/extension.h index bbe9db92915..6682acef364 100644 --- a/src/devices/bus/thomson/extension.h +++ b/src/devices/bus/thomson/extension.h @@ -24,7 +24,7 @@ public: class thomson_extension_device : public device_t, public device_single_card_slot_interface<thomson_extension_interface> { public: - thomson_extension_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + thomson_extension_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~thomson_extension_device() = default; void rom_map(address_space_installer &space, offs_t start, offs_t end); diff --git a/src/devices/bus/thomson/nanoreseau.cpp b/src/devices/bus/thomson/nanoreseau.cpp index 418d9ce59e5..3b8e7d0d510 100644 --- a/src/devices/bus/thomson/nanoreseau.cpp +++ b/src/devices/bus/thomson/nanoreseau.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(NANORESEAU_TO, nanoreseau_to_device, "nanoreseau_to", "Nanoreseau controller (TO rom)") DEFINE_DEVICE_TYPE(NANORESEAU_MO, nanoreseau_mo_device, "nanoreseau_mo", "Nanoreseau controller (MO rom)") - nanoreseau_device::nanoreseau_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool no_id) : + nanoreseau_device::nanoreseau_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool no_id) : device_t(mconfig, type, tag, owner, clock), thomson_extension_interface(mconfig, *this), m_mc6854(*this, "mc6854"), @@ -21,12 +21,12 @@ DEFINE_DEVICE_TYPE(NANORESEAU_MO, nanoreseau_mo_device, "nanoreseau_mo", "Nanore { } -nanoreseau_to_device::nanoreseau_to_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, bool no_id) : +nanoreseau_to_device::nanoreseau_to_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool no_id) : nanoreseau_device(mconfig, NANORESEAU_TO, tag, owner, clock) { } -nanoreseau_mo_device::nanoreseau_mo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, bool no_id) : +nanoreseau_mo_device::nanoreseau_mo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool no_id) : nanoreseau_device(mconfig, NANORESEAU_MO, tag, owner, clock) { } diff --git a/src/devices/bus/thomson/nanoreseau.h b/src/devices/bus/thomson/nanoreseau.h index 1d7cde2ce9a..406932970e8 100644 --- a/src/devices/bus/thomson/nanoreseau.h +++ b/src/devices/bus/thomson/nanoreseau.h @@ -14,7 +14,7 @@ class nanoreseau_device : public device_t, public thomson_extension_interface { public: - nanoreseau_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool no_id = false); + nanoreseau_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool no_id = false); virtual ~nanoreseau_device() = default; virtual void rom_map(address_map &map) override; @@ -44,7 +44,7 @@ private: class nanoreseau_mo_device : public nanoreseau_device { public: - nanoreseau_mo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0, bool no_id = false); + nanoreseau_mo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL(), bool no_id = false); virtual ~nanoreseau_mo_device() = default; protected: @@ -54,7 +54,7 @@ protected: class nanoreseau_to_device : public nanoreseau_device { public: - nanoreseau_to_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0, bool no_id = false); + nanoreseau_to_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL(), bool no_id = false); virtual ~nanoreseau_to_device() = default; protected: diff --git a/src/devices/bus/ti8x/bitsocket.cpp b/src/devices/bus/ti8x/bitsocket.cpp index 1c4feb4ed4f..bf0853c0e44 100644 --- a/src/devices/bus/ti8x/bitsocket.cpp +++ b/src/devices/bus/ti8x/bitsocket.cpp @@ -23,7 +23,7 @@ class bit_socket_device , public device_ti8x_link_port_interface { public: - bit_socket_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + bit_socket_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -58,7 +58,7 @@ bit_socket_device::bit_socket_device( void bit_socket_device::device_add_mconfig(machine_config &config) { - BITBANGER(config, m_stream, 0); + BITBANGER(config, m_stream); } diff --git a/src/devices/bus/ti8x/graphlinkhle.cpp b/src/devices/bus/ti8x/graphlinkhle.cpp index 6322f2b422d..a9a22ddf78e 100644 --- a/src/devices/bus/ti8x/graphlinkhle.cpp +++ b/src/devices/bus/ti8x/graphlinkhle.cpp @@ -19,7 +19,7 @@ class graph_link_hle_device , public device_serial_interface { public: - graph_link_hle_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + graph_link_hle_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; @@ -75,7 +75,7 @@ void graph_link_hle_device::device_start() void graph_link_hle_device::device_reset() { set_data_frame(1, 8, PARITY_NONE, STOP_BITS_1); - set_rate(9600); + set_rate(XTAL::u(9600)); receive_register_reset(); transmit_register_reset(); diff --git a/src/devices/bus/ti8x/teeconn.cpp b/src/devices/bus/ti8x/teeconn.cpp index b0774684dc7..ce2e4f2a35a 100644 --- a/src/devices/bus/ti8x/teeconn.cpp +++ b/src/devices/bus/ti8x/teeconn.cpp @@ -13,7 +13,7 @@ namespace { class tee_connector_device : public device_t, public device_ti8x_link_port_interface { public: - tee_connector_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock); + tee_connector_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/ti8x/ti8x.h b/src/devices/bus/ti8x/ti8x.h index 759b3523eb1..045200ccb6e 100644 --- a/src/devices/bus/ti8x/ti8x.h +++ b/src/devices/bus/ti8x/ti8x.h @@ -50,14 +50,14 @@ class ti8x_link_port_device : public device_t, public device_single_card_slot_in public: template <typename T> ti8x_link_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : ti8x_link_port_device(mconfig, tag, owner, 0) + : ti8x_link_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - ti8x_link_port_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + ti8x_link_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // static configuration helpers auto tip_handler() { return m_tip_handler.bind(); } diff --git a/src/devices/bus/ti8x/tispeaker.cpp b/src/devices/bus/ti8x/tispeaker.cpp index 2aa5afdcf7d..d64ad6ae185 100644 --- a/src/devices/bus/ti8x/tispeaker.cpp +++ b/src/devices/bus/ti8x/tispeaker.cpp @@ -32,9 +32,9 @@ protected: SPEAKER(config, "outl").front_left(); SPEAKER(config, "outr").front_right(); - SPEAKER_SOUND(config, m_left_speaker, 0).add_route(ALL_OUTPUTS, "outl", 0.50); + SPEAKER_SOUND(config, m_left_speaker).add_route(ALL_OUTPUTS, "outl", 0.50); - SPEAKER_SOUND(config, m_right_speaker, 0).add_route(ALL_OUTPUTS, "outr", 0.50); + SPEAKER_SOUND(config, m_right_speaker).add_route(ALL_OUTPUTS, "outr", 0.50); } virtual void device_start() override @@ -79,7 +79,7 @@ protected: { SPEAKER(config, "mono").front_center(); - SPEAKER_SOUND(config, m_speaker, 0).add_route(ALL_OUTPUTS, "mono", 0.50); + SPEAKER_SOUND(config, m_speaker).add_route(ALL_OUTPUTS, "mono", 0.50); } virtual void device_start() override diff --git a/src/devices/bus/ti99/colorbus/busmouse.cpp b/src/devices/bus/ti99/colorbus/busmouse.cpp index ccaf9c66f25..5a28d449701 100644 --- a/src/devices/bus/ti99/colorbus/busmouse.cpp +++ b/src/devices/bus/ti99/colorbus/busmouse.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(V9938_BUSMOUSE, bus::ti99::colorbus::v9938_busmouse_device, " namespace bus::ti99::colorbus { -v9938_busmouse_device::v9938_busmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v9938_busmouse_device::v9938_busmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, V9938_BUSMOUSE, tag, owner, clock), device_v9938_colorbus_interface(mconfig, *this), m_buttons(*this, "MOUSEBUT"), diff --git a/src/devices/bus/ti99/colorbus/busmouse.h b/src/devices/bus/ti99/colorbus/busmouse.h index d12e550fa11..b9332181acd 100644 --- a/src/devices/bus/ti99/colorbus/busmouse.h +++ b/src/devices/bus/ti99/colorbus/busmouse.h @@ -22,7 +22,7 @@ namespace bus::ti99::colorbus { class v9938_busmouse_device : public device_t, public device_v9938_colorbus_interface { public: - v9938_busmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v9938_busmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER( mouse_button_changed ); DECLARE_INPUT_CHANGED_MEMBER( mouse_pos_changed ); diff --git a/src/devices/bus/ti99/colorbus/colorbus.cpp b/src/devices/bus/ti99/colorbus/colorbus.cpp index e3decb6ba61..8453494c203 100644 --- a/src/devices/bus/ti99/colorbus/colorbus.cpp +++ b/src/devices/bus/ti99/colorbus/colorbus.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(V9938_COLORBUS, bus::ti99::colorbus::v9938_colorbus_device, " namespace bus::ti99::colorbus { -v9938_colorbus_device::v9938_colorbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v9938_colorbus_device::v9938_colorbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, V9938_COLORBUS, tag, owner, clock), device_single_card_slot_interface<device_v9938_colorbus_interface>(mconfig, *this), m_v9938(*owner, TIGEN_V9938_TAG), diff --git a/src/devices/bus/ti99/colorbus/colorbus.h b/src/devices/bus/ti99/colorbus/colorbus.h index edd088b480a..973daca2d27 100644 --- a/src/devices/bus/ti99/colorbus/colorbus.h +++ b/src/devices/bus/ti99/colorbus/colorbus.h @@ -45,7 +45,7 @@ class v9938_colorbus_device : public device_t, public device_single_card_slot_in { public: template <typename U> - v9938_colorbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, U &&opts, const char *dflt) + v9938_colorbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, U &&opts, const char *dflt) : v9938_colorbus_device(mconfig, tag, owner, clock) { option_reset(); @@ -54,7 +54,7 @@ public: set_fixed(false); } - v9938_colorbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v9938_colorbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // For the extra button (V9938 only handles 2) auto extra_button_cb() { return m_extra_button.bind(); } diff --git a/src/devices/bus/ti99/gromport/cartridges.cpp b/src/devices/bus/ti99/gromport/cartridges.cpp index 6ed6d19366f..d8571ab96f4 100644 --- a/src/devices/bus/ti99/gromport/cartridges.cpp +++ b/src/devices/bus/ti99/gromport/cartridges.cpp @@ -90,7 +90,7 @@ static const pcb_type sw_pcbdefs[] = { 0, nullptr} }; -ti99_cartridge_device::ti99_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti99_cartridge_device::ti99_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_CART, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), m_pcbtype(0), diff --git a/src/devices/bus/ti99/gromport/cartridges.h b/src/devices/bus/ti99/gromport/cartridges.h index 68593bf1ac8..43e47c39b3d 100644 --- a/src/devices/bus/ti99/gromport/cartridges.h +++ b/src/devices/bus/ti99/gromport/cartridges.h @@ -26,7 +26,7 @@ class ti99_cartridge_pcb; class ti99_cartridge_device : public device_t, public device_cartrom_image_interface { public: - ti99_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti99_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value); void write(offs_t offset, uint8_t data); diff --git a/src/devices/bus/ti99/gromport/gkracker.cpp b/src/devices/bus/ti99/gromport/gkracker.cpp index 212207665e2..09285a10cf3 100644 --- a/src/devices/bus/ti99/gromport/gkracker.cpp +++ b/src/devices/bus/ti99/gromport/gkracker.cpp @@ -132,7 +132,7 @@ enum #define GKRACKER_NVRAM_TAG "gkracker_nvram" #define GKRACKER_ROM_TAG "gkracker_rom" -ti99_gkracker_device::ti99_gkracker_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti99_gkracker_device::ti99_gkracker_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cartridge_connector_device(mconfig, TI99_GROMPORT_GK, tag, owner, clock), device_nvram_interface(mconfig, *this), m_romspace_selected(false), @@ -439,7 +439,7 @@ const tiny_rom_entry *ti99_gkracker_device::device_rom_region() const void ti99_gkracker_device::device_add_mconfig(machine_config &config) { - TI99_CART(config, "cartridge", 0); + TI99_CART(config, "cartridge"); } INPUT_PORTS_START(gkracker) diff --git a/src/devices/bus/ti99/gromport/gkracker.h b/src/devices/bus/ti99/gromport/gkracker.h index 76bc457a11e..fd47a47762e 100644 --- a/src/devices/bus/ti99/gromport/gkracker.h +++ b/src/devices/bus/ti99/gromport/gkracker.h @@ -15,7 +15,7 @@ namespace bus::ti99::gromport { class ti99_gkracker_device : public cartridge_connector_device, public device_nvram_interface { public: - ti99_gkracker_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti99_gkracker_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/gromport/gromport.cpp b/src/devices/bus/ti99/gromport/gromport.cpp index 1a53362416c..0b188c6b26b 100644 --- a/src/devices/bus/ti99/gromport/gromport.cpp +++ b/src/devices/bus/ti99/gromport/gromport.cpp @@ -125,7 +125,7 @@ DEFINE_DEVICE_TYPE(TI99_GROMPORT, bus::ti99::gromport::gromport_device, "grompor namespace bus::ti99::gromport { -gromport_device::gromport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gromport_device::gromport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_GROMPORT, tag, owner, clock), device_slot_interface(mconfig, *this), m_connector(nullptr), @@ -272,7 +272,7 @@ ioport_constructor gromport_device::device_input_ports() const ***************************************************************************/ -cartridge_connector_device::cartridge_connector_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +cartridge_connector_device::cartridge_connector_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_gromport(nullptr) { diff --git a/src/devices/bus/ti99/gromport/gromport.h b/src/devices/bus/ti99/gromport/gromport.h index 74c844d7ed7..64f58be536c 100644 --- a/src/devices/bus/ti99/gromport/gromport.h +++ b/src/devices/bus/ti99/gromport/gromport.h @@ -29,7 +29,7 @@ class gromport_device : public device_t, public device_slot_interface { public: template <typename U> - gromport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, U &&opts, const char *dflt) + gromport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, U &&opts, const char *dflt) : gromport_device(mconfig, tag, owner, clock) { option_reset(); @@ -38,7 +38,7 @@ public: set_fixed(false); } - gromport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gromport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value); void write(offs_t offset, uint8_t data); @@ -95,7 +95,7 @@ public: virtual bool is_grom_idle() = 0; protected: - cartridge_connector_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cartridge_connector_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_config_complete() override; gromport_device* m_gromport; diff --git a/src/devices/bus/ti99/gromport/multiconn.cpp b/src/devices/bus/ti99/gromport/multiconn.cpp index 595a6ab1a29..037c091ad5d 100644 --- a/src/devices/bus/ti99/gromport/multiconn.cpp +++ b/src/devices/bus/ti99/gromport/multiconn.cpp @@ -55,7 +55,7 @@ namespace bus::ti99::gromport { #define AUTO -1 -ti99_multi_cart_conn_device::ti99_multi_cart_conn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti99_multi_cart_conn_device::ti99_multi_cart_conn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cartridge_connector_device(mconfig, TI99_GROMPORT_MULTI, tag, owner, clock), m_active_slot(0), m_fixed_slot(0), @@ -303,10 +303,10 @@ void ti99_multi_cart_conn_device::device_reset(void) void ti99_multi_cart_conn_device::device_add_mconfig(machine_config &config) { - TI99_CART(config, "cartridge1", 0); - TI99_CART(config, "cartridge2", 0); - TI99_CART(config, "cartridge3", 0); - TI99_CART(config, "cartridge4", 0); + TI99_CART(config, "cartridge1"); + TI99_CART(config, "cartridge2"); + TI99_CART(config, "cartridge3"); + TI99_CART(config, "cartridge4"); } INPUT_CHANGED_MEMBER( ti99_multi_cart_conn_device::switch_changed ) diff --git a/src/devices/bus/ti99/gromport/multiconn.h b/src/devices/bus/ti99/gromport/multiconn.h index 517224eff14..1cfcef62963 100644 --- a/src/devices/bus/ti99/gromport/multiconn.h +++ b/src/devices/bus/ti99/gromport/multiconn.h @@ -20,7 +20,7 @@ namespace bus::ti99::gromport { class ti99_multi_cart_conn_device : public cartridge_connector_device { public: - ti99_multi_cart_conn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti99_multi_cart_conn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/gromport/singleconn.cpp b/src/devices/bus/ti99/gromport/singleconn.cpp index e24a3ba416a..3bf6f6caa9d 100644 --- a/src/devices/bus/ti99/gromport/singleconn.cpp +++ b/src/devices/bus/ti99/gromport/singleconn.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(TI99_GROMPORT_SINGLE, bus::ti99::gromport::ti99_single_cart_c namespace bus::ti99::gromport { -ti99_single_cart_conn_device::ti99_single_cart_conn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti99_single_cart_conn_device::ti99_single_cart_conn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cartridge_connector_device(mconfig, TI99_GROMPORT_SINGLE, tag, owner, clock), m_cartridge(nullptr) { @@ -85,7 +85,7 @@ void ti99_single_cart_conn_device::device_reset() void ti99_single_cart_conn_device::device_add_mconfig(machine_config &config) { - TI99_CART(config, "cartridge", 0); + TI99_CART(config, "cartridge"); } } // end namespace bus::ti99::gromport diff --git a/src/devices/bus/ti99/gromport/singleconn.h b/src/devices/bus/ti99/gromport/singleconn.h index 40627a07867..2ea8437e3b7 100644 --- a/src/devices/bus/ti99/gromport/singleconn.h +++ b/src/devices/bus/ti99/gromport/singleconn.h @@ -16,7 +16,7 @@ namespace bus::ti99::gromport { class ti99_single_cart_conn_device : public cartridge_connector_device { public: - ti99_single_cart_conn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti99_single_cart_conn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/internal/992board.cpp b/src/devices/bus/ti99/internal/992board.cpp index 7dae38759ee..a1df885841c 100644 --- a/src/devices/bus/ti99/internal/992board.cpp +++ b/src/devices/bus/ti99/internal/992board.cpp @@ -139,7 +139,7 @@ DEFINE_DEVICE_TYPE(TI992_RAM32K, bus::ti99::internal::ti992_expram_device, "ti99 namespace bus::ti99::internal { -video992_device::video992_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +video992_device::video992_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), m_mem_read_cb(*this), @@ -149,13 +149,13 @@ video992_device::video992_device(const machine_config &mconfig, device_type type { } -video992_24_device::video992_24_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +video992_24_device::video992_24_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : video992_device(mconfig, VIDEO99224, tag, owner, clock) { m_beol = 0x70; } -video992_32_device::video992_32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +video992_32_device::video992_32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : video992_device(mconfig, VIDEO99232, tag, owner, clock) { m_beol = 0x7f; @@ -354,7 +354,7 @@ void video992_device::device_reset() [3] I/O Controller CF40051, Preliminary specification, Texas Instruments */ -io992_device::io992_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +io992_device::io992_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : bus::hexbus::hexbus_chained_device(mconfig, type, tag, owner, clock), m_hexbus(*owner, TI992_HEXBUS_TAG), m_cassette(*owner, TI992_CASSETTE), @@ -366,13 +366,13 @@ io992_device::io992_device(const machine_config &mconfig, device_type type, cons { } -io992_24_device::io992_24_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +io992_24_device::io992_24_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : io992_device(mconfig, IO99224, tag, owner, clock) { m_have_banked_rom = false; } -io992_32_device::io992_32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +io992_32_device::io992_32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : io992_device(mconfig, IO99232, tag, owner, clock) { m_have_banked_rom = true; @@ -608,7 +608,7 @@ ioport_constructor io992_device::device_input_ports() const Expansion port ********************************************************************/ -ti992_expport_device::ti992_expport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti992_expport_device::ti992_expport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI992_EXPPORT, tag, owner, clock), device_slot_interface(mconfig, *this), m_connected(nullptr) @@ -637,7 +637,7 @@ void ti992_expport_device::device_config_complete() Maps at 6000 - DFFF This is the only known expansion device */ -ti992_expram_device::ti992_expram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ti992_expram_device::ti992_expram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ti992_expport_attached_device(mconfig, TI992_RAM32K, tag, owner, clock), m_ram(*this, "ram32k") { @@ -671,7 +671,7 @@ void ti992_expram_device::write(offs_t offset, uint8_t value) void ti992_expram_device::device_add_mconfig(machine_config &config) { - RAM(config, m_ram, 0); + RAM(config, m_ram); m_ram->set_default_size("32k"); m_ram->set_default_value(0); } diff --git a/src/devices/bus/ti99/internal/992board.h b/src/devices/bus/ti99/internal/992board.h index 5a6ab8b5a8f..0d948491230 100644 --- a/src/devices/bus/ti99/internal/992board.h +++ b/src/devices/bus/ti99/internal/992board.h @@ -54,7 +54,7 @@ public: auto int_cb() { return m_int_cb.bind(); } protected: - video992_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + video992_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); int m_beol; virtual void device_start() override; @@ -89,14 +89,14 @@ private: class video992_24_device : public video992_device { public: - video992_24_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + video992_24_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; /* Variant for TI-99/2 32K */ class video992_32_device : public video992_device { public: - video992_32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + video992_32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; /* @@ -105,14 +105,14 @@ public: class io992_device : public bus::hexbus::hexbus_chained_device { public: - io992_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + io992_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t cruread(offs_t offset); void cruwrite(offs_t offset, uint8_t data); auto rombank_cb() { return m_set_rom_bank.bind(); } protected: - io992_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + io992_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); bool m_have_banked_rom; virtual void device_start() override; @@ -141,14 +141,14 @@ private: class io992_24_device : public io992_device { public: - io992_24_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + io992_24_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; /* Variant for TI-99/2 32K */ class io992_32_device : public io992_device { public: - io992_32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + io992_32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; /******************************************************************** @@ -166,7 +166,7 @@ public: class ti992_expport_attached_device : public device_t { public: - ti992_expport_attached_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : + ti992_expport_attached_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) { } @@ -181,7 +181,7 @@ class ti992_expport_device : public device_t, public device_slot_interface public: template <typename U> - ti992_expport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, U &&opts, const char *dflt) + ti992_expport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, U &&opts, const char *dflt) : ti992_expport_device(mconfig, tag, owner, clock) { option_reset(); @@ -190,7 +190,7 @@ public: set_fixed(false); } - ti992_expport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti992_expport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Methods called from the console // More methods should be added, once we can find further 99/2 cartridges @@ -210,7 +210,7 @@ private: class ti992_expram_device : public ti992_expport_attached_device { public: - ti992_expram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti992_expram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void readz(offs_t offset, uint8_t *value) override; virtual void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/internal/998board.cpp b/src/devices/bus/ti99/internal/998board.cpp index bebd7762ec4..7f155423e50 100644 --- a/src/devices/bus/ti99/internal/998board.cpp +++ b/src/devices/bus/ti99/internal/998board.cpp @@ -145,7 +145,7 @@ enum VIDSEL = 16 }; -mainboard8_device::mainboard8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mainboard8_device::mainboard8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_MAINBOARD8, tag, owner, clock), m_A14_set(false), m_pending_write(false), @@ -1068,10 +1068,10 @@ void mainboard8_device::device_reset() void mainboard8_device::device_add_mconfig(machine_config &config) { - TI99_VAQUERRO(config, TI998_VAQUERRO_TAG, 0); - TI99_MOFETTA(config, TI998_MOFETTA_TAG, 0); - TI99_AMIGO(config, TI998_AMIGO_TAG, 0); - TI99_OSO(config, TI998_OSO_TAG, 0); + TI99_VAQUERRO(config, TI998_VAQUERRO_TAG); + TI99_MOFETTA(config, TI998_MOFETTA_TAG); + TI99_AMIGO(config, TI998_AMIGO_TAG); + TI99_OSO(config, TI998_OSO_TAG); } /*************************************************************************** @@ -1150,7 +1150,7 @@ void mainboard8_device::device_add_mconfig(machine_config &config) ***************************************************************************/ -vaquerro_device::vaquerro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vaquerro_device::vaquerro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_VAQUERRO, tag, owner, clock), m_crus(ASSERT_LINE), m_crugl(ASSERT_LINE), @@ -1601,7 +1601,7 @@ enum INTERNAL }; -mofetta_device::mofetta_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mofetta_device::mofetta_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_MOFETTA, tag, owner, clock), m_gotfirstword(false) { @@ -1896,7 +1896,7 @@ void mofetta_device::device_reset() ***************************************************************************/ -amigo_device::amigo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +amigo_device::amigo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_AMIGO, tag, owner, clock), m_logical_space(true), m_crus(ASSERT_LINE) @@ -2268,7 +2268,7 @@ void amigo_device::device_reset() ****************************************************************************/ -oso_device::oso_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +oso_device::oso_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bus::hexbus::hexbus_chained_device(mconfig, TI99_OSO, tag, owner, clock), m_int(*this), m_hexbusout(*this, ":" TI998_HEXBUS_TAG), diff --git a/src/devices/bus/ti99/internal/998board.h b/src/devices/bus/ti99/internal/998board.h index f699b8d02cf..0e92529c64e 100644 --- a/src/devices/bus/ti99/internal/998board.h +++ b/src/devices/bus/ti99/internal/998board.h @@ -98,7 +98,7 @@ class mainboard8_device; class vaquerro_device : public device_t { public: - vaquerro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vaquerro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void device_start() override; void device_reset() override; @@ -246,7 +246,7 @@ private: class mofetta_device : public device_t { public: - mofetta_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mofetta_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void device_start() override; void device_reset() override; @@ -333,7 +333,7 @@ private: class amigo_device : public device_t { public: - amigo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + amigo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void device_start() override; void device_reset() override; @@ -454,7 +454,7 @@ typedef enum class oso_device : public bus::hexbus::hexbus_chained_device { public: - oso_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + oso_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); void device_start() override; @@ -540,7 +540,7 @@ private: class mainboard8_device : public device_t { public: - mainboard8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mainboard8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Memory space uint8_t read(offs_t offset); diff --git a/src/devices/bus/ti99/internal/buffram.cpp b/src/devices/bus/ti99/internal/buffram.cpp index 2747db9dd92..699408bbdab 100644 --- a/src/devices/bus/ti99/internal/buffram.cpp +++ b/src/devices/bus/ti99/internal/buffram.cpp @@ -23,7 +23,7 @@ namespace bus::ti99::internal { // ========== Buffered SRAM ============ -buffered_ram_device::buffered_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +buffered_ram_device::buffered_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BUFF_RAM, tag, owner, clock), device_nvram_interface(mconfig, *this), m_size(0), diff --git a/src/devices/bus/ti99/internal/buffram.h b/src/devices/bus/ti99/internal/buffram.h index 646716d665b..e852b8eba94 100644 --- a/src/devices/bus/ti99/internal/buffram.h +++ b/src/devices/bus/ti99/internal/buffram.h @@ -20,7 +20,7 @@ namespace bus::ti99::internal { class buffered_ram_device : public device_t, public device_nvram_interface { public: - buffered_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + buffered_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); buffered_ram_device &set_size(int size) { m_size = size; return *this; } // read/write diff --git a/src/devices/bus/ti99/internal/datamux.cpp b/src/devices/bus/ti99/internal/datamux.cpp index 95412e296e9..0eb9b6c349f 100644 --- a/src/devices/bus/ti99/internal/datamux.cpp +++ b/src/devices/bus/ti99/internal/datamux.cpp @@ -89,7 +89,7 @@ namespace bus::ti99::internal { /* Constructor */ -datamux_device::datamux_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +datamux_device::datamux_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_DATAMUX, tag, owner, clock), m_video(*owner, TI99_VDP_TAG), m_sound(*owner, TI99_SOUNDCHIP_TAG), diff --git a/src/devices/bus/ti99/internal/datamux.h b/src/devices/bus/ti99/internal/datamux.h index 8fb9a7a8c08..b705034d21c 100644 --- a/src/devices/bus/ti99/internal/datamux.h +++ b/src/devices/bus/ti99/internal/datamux.h @@ -43,7 +43,7 @@ namespace bus::ti99::internal { class datamux_device : public device_t { public: - datamux_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + datamux_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t read(offs_t offset); void write(offs_t offset, uint16_t data); void setaddress(offs_t offset, uint16_t busctrl); diff --git a/src/devices/bus/ti99/internal/evpcconn.cpp b/src/devices/bus/ti99/internal/evpcconn.cpp index 2b7647d52dd..f1f88dac7d8 100644 --- a/src/devices/bus/ti99/internal/evpcconn.cpp +++ b/src/devices/bus/ti99/internal/evpcconn.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(TI99_EVPCCONN, bus::ti99::internal::evpc_clock_connector, "ti namespace bus::ti99::internal { -evpc_clock_connector::evpc_clock_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +evpc_clock_connector::evpc_clock_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_EVPCCONN, tag, owner, clock), m_vdpint(*this) { diff --git a/src/devices/bus/ti99/internal/evpcconn.h b/src/devices/bus/ti99/internal/evpcconn.h index 4216b7e0028..eb138d8d353 100644 --- a/src/devices/bus/ti99/internal/evpcconn.h +++ b/src/devices/bus/ti99/internal/evpcconn.h @@ -18,7 +18,7 @@ namespace bus::ti99::internal { class evpc_clock_connector : public device_t { public: - evpc_clock_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + evpc_clock_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( vclock_line ); void device_start() override; diff --git a/src/devices/bus/ti99/internal/genboard.cpp b/src/devices/bus/ti99/internal/genboard.cpp index e22bb72caa8..a64a404d34b 100644 --- a/src/devices/bus/ti99/internal/genboard.cpp +++ b/src/devices/bus/ti99/internal/genboard.cpp @@ -440,7 +440,7 @@ DEFINE_DEVICE_TYPE(GENEVE_PAL, bus::ti99::internal::geneve_pal_device, "g namespace bus::ti99::internal { -geneve_gate_array_device::geneve_gate_array_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +geneve_gate_array_device::geneve_gate_array_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_have_waitstate(false), m_have_extra_waitstate(false), @@ -473,7 +473,7 @@ geneve_gate_array_device::geneve_gate_array_device(const machine_config &mconfig { } -geneve_gate_array_device::geneve_gate_array_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +geneve_gate_array_device::geneve_gate_array_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : geneve_gate_array_device(mconfig, GENEVE_GATE_ARRAY, tag, owner, clock) { } @@ -1173,7 +1173,7 @@ void geneve_gate_array_device::device_reset() ======================================================================== */ -geneve_pal_device::geneve_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +geneve_pal_device::geneve_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GENEVE_PAL, tag, owner, clock), m_pin3(true), m_pin4(true), @@ -1409,7 +1409,7 @@ void geneve_pal_device::device_start() ********************************************************************/ -genmod_decoder_device::genmod_decoder_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +genmod_decoder_device::genmod_decoder_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GENMOD_DECODER, tag, owner, clock), m_debug(false), m_turbo(false), diff --git a/src/devices/bus/ti99/internal/genboard.h b/src/devices/bus/ti99/internal/genboard.h index 4b5dd21124e..592bbc5027e 100644 --- a/src/devices/bus/ti99/internal/genboard.h +++ b/src/devices/bus/ti99/internal/genboard.h @@ -55,7 +55,7 @@ class geneve_gate_array_device : public device_t // friend class genmod_decoder_device; public: - geneve_gate_array_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + geneve_gate_array_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Set the internal state and output lines according to the address void setaddress(offs_t offset, uint8_t busctrl); @@ -113,7 +113,7 @@ public: int get_function() { return m_debug? m_decdebug.function : m_decoded.function; } private: - geneve_gate_array_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + geneve_gate_array_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void common_reset(); // Mapper function @@ -250,7 +250,7 @@ private: class geneve_pal_device : public device_t { public: - geneve_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + geneve_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( gaready_in ); DECLARE_WRITE_LINE_MEMBER( csw_in ); @@ -289,7 +289,7 @@ private: class genmod_decoder_device : public device_t { public: - genmod_decoder_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + genmod_decoder_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Set the internal state and output lines according to the address void set_function(int func, int page); diff --git a/src/devices/bus/ti99/internal/genkbd.cpp b/src/devices/bus/ti99/internal/genkbd.cpp index 5e22f27ee33..7f334436e3c 100644 --- a/src/devices/bus/ti99/internal/genkbd.cpp +++ b/src/devices/bus/ti99/internal/genkbd.cpp @@ -188,7 +188,7 @@ ioport_constructor geneve_xt_101_hle_keyboard_device::device_input_ports() const // ibm_pc_xt_83_keyboard_device - constructor //------------------------------------------------- -geneve_xt_101_hle_keyboard_device::geneve_xt_101_hle_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +geneve_xt_101_hle_keyboard_device::geneve_xt_101_hle_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, KBD_GENEVE_XT_101_HLE, tag, owner, clock), device_pc_kbd_interface(mconfig, *this), m_keys(*this, "KEY%u", 0), diff --git a/src/devices/bus/ti99/internal/genkbd.h b/src/devices/bus/ti99/internal/genkbd.h index cf67ea8ee6c..45d2a473d90 100644 --- a/src/devices/bus/ti99/internal/genkbd.h +++ b/src/devices/bus/ti99/internal/genkbd.h @@ -25,7 +25,7 @@ class geneve_xt_101_hle_keyboard_device : public device_t, public device_pc_kbd_ { public: // construction/destruction - geneve_xt_101_hle_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + geneve_xt_101_hle_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(reset_line); protected: diff --git a/src/devices/bus/ti99/internal/ioport.cpp b/src/devices/bus/ti99/internal/ioport.cpp index 4ab42b201b4..63972212364 100644 --- a/src/devices/bus/ti99/internal/ioport.cpp +++ b/src/devices/bus/ti99/internal/ioport.cpp @@ -84,7 +84,7 @@ DEFINE_DEVICE_TYPE(TI99_IOPORT, bus::ti99::internal::ioport_device, "ti99_ioport namespace bus::ti99::internal { -ioport_device::ioport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ioport_device::ioport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_IOPORT, tag, owner, clock), device_slot_interface(mconfig, *this), m_console_extint(*this), diff --git a/src/devices/bus/ti99/internal/ioport.h b/src/devices/bus/ti99/internal/ioport.h index 5c08beec760..1977a1e9c87 100644 --- a/src/devices/bus/ti99/internal/ioport.h +++ b/src/devices/bus/ti99/internal/ioport.h @@ -23,7 +23,7 @@ class ioport_device; class ioport_attached_device : public device_t { public: - ioport_attached_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : + ioport_attached_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_ioport(nullptr) { } @@ -59,7 +59,7 @@ class ioport_device : public device_t, public device_slot_interface public: template <typename U> - ioport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, U &&opts, const char *dflt) + ioport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, U &&opts, const char *dflt) : ioport_device(mconfig, tag, owner, clock) { option_reset(); @@ -68,7 +68,7 @@ public: set_fixed(false); } - ioport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ioport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Methods called from the console void readz(offs_t offset, uint8_t *value); diff --git a/src/devices/bus/ti99/joyport/handset.cpp b/src/devices/bus/ti99/joyport/handset.cpp index 046873f5fe6..2a6b84fb72b 100644 --- a/src/devices/bus/ti99/joyport/handset.cpp +++ b/src/devices/bus/ti99/joyport/handset.cpp @@ -54,7 +54,7 @@ DEFINE_DEVICE_TYPE(TI99_HANDSET, bus::ti99::joyport::ti99_handset_device, "ti99_ namespace bus::ti99::joyport { -ti99_handset_device::ti99_handset_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti99_handset_device::ti99_handset_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_HANDSET, tag, owner, clock) , device_ti99_joyport_interface(mconfig, *this) , m_joyx(*this, "JOYX%u", 0U) @@ -506,7 +506,7 @@ INPUT_PORTS_START( joysticks ) PORT_BIT(0x01, IP_ACTIVE_LOW, IPT_BUTTON1/*, "(2FIRE)", CODE_NONE, OSD_JOY2_FIRE, 0*/) PORT_PLAYER(2) INPUT_PORTS_END -ti99_twin_joystick_device::ti99_twin_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti99_twin_joystick_device::ti99_twin_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_JOYSTICK, tag, owner, clock), device_ti99_joyport_interface(mconfig, *this) , m_joystick(0) , m_joys(*this, "JOY%u", 1U) diff --git a/src/devices/bus/ti99/joyport/handset.h b/src/devices/bus/ti99/joyport/handset.h index 344f74bed7a..caa12d8ff31 100644 --- a/src/devices/bus/ti99/joyport/handset.h +++ b/src/devices/bus/ti99/joyport/handset.h @@ -26,7 +26,7 @@ namespace bus::ti99::joyport { class ti99_handset_device : public device_t, public device_ti99_joyport_interface { public: - ti99_handset_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti99_handset_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read_dev() override; void write_dev(uint8_t data) override; @@ -68,7 +68,7 @@ private: class ti99_twin_joystick_device : public device_t, public device_ti99_joyport_interface { public: - ti99_twin_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti99_twin_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; uint8_t read_dev() override; diff --git a/src/devices/bus/ti99/joyport/joyport.cpp b/src/devices/bus/ti99/joyport/joyport.cpp index 77825e85f96..b3669226720 100644 --- a/src/devices/bus/ti99/joyport/joyport.cpp +++ b/src/devices/bus/ti99/joyport/joyport.cpp @@ -50,7 +50,7 @@ device_ti99_joyport_interface::device_ti99_joyport_interface(const machine_confi { } -joyport_device::joyport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +joyport_device::joyport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_JOYPORT, tag, owner, clock), device_single_card_slot_interface<device_ti99_joyport_interface>(mconfig, *this), m_interrupt(*this), diff --git a/src/devices/bus/ti99/joyport/joyport.h b/src/devices/bus/ti99/joyport/joyport.h index 40f7b358ac6..3b7996bd4e3 100644 --- a/src/devices/bus/ti99/joyport/joyport.h +++ b/src/devices/bus/ti99/joyport/joyport.h @@ -59,7 +59,7 @@ class joyport_device : public device_t, public device_single_card_slot_interface { public: template <typename U> - joyport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, U &&opts, const char *dflt) + joyport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, U &&opts, const char *dflt) : joyport_device(mconfig, tag, owner, clock) { option_reset(); @@ -68,7 +68,7 @@ public: set_fixed(false); } - joyport_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + joyport_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read_port(); void write_port(int data); void set_interrupt(int state); diff --git a/src/devices/bus/ti99/joyport/mecmouse.cpp b/src/devices/bus/ti99/joyport/mecmouse.cpp index 68e17da3ec1..781b7b9d35e 100644 --- a/src/devices/bus/ti99/joyport/mecmouse.cpp +++ b/src/devices/bus/ti99/joyport/mecmouse.cpp @@ -55,7 +55,7 @@ DEFINE_DEVICE_TYPE(TI99_MECMOUSE, bus::ti99::joyport::mecmouse_device, "ti99_mec namespace bus::ti99::joyport { -mecmouse_device::mecmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mecmouse_device::mecmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_MECMOUSE, tag, owner, clock) , device_ti99_joyport_interface(mconfig, *this) , m_mousex(*this, "MOUSEX") diff --git a/src/devices/bus/ti99/joyport/mecmouse.h b/src/devices/bus/ti99/joyport/mecmouse.h index 0ee23ade546..393bfcb26da 100644 --- a/src/devices/bus/ti99/joyport/mecmouse.h +++ b/src/devices/bus/ti99/joyport/mecmouse.h @@ -21,7 +21,7 @@ namespace bus::ti99::joyport { class mecmouse_device : public device_t, public device_ti99_joyport_interface { public: - mecmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mecmouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read_dev() override; void write_dev(uint8_t data) override; diff --git a/src/devices/bus/ti99/peb/bwg.cpp b/src/devices/bus/ti99/peb/bwg.cpp index 4950943a8a8..8d2526fbe4b 100644 --- a/src/devices/bus/ti99/peb/bwg.cpp +++ b/src/devices/bus/ti99/peb/bwg.cpp @@ -79,7 +79,7 @@ namespace bus::ti99::peb { Modern implementation */ -snug_bwg_device::snug_bwg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +snug_bwg_device::snug_bwg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, TI99_BWG, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_DRQ(), m_IRQ(), @@ -637,7 +637,7 @@ void snug_bwg_device::device_add_mconfig(machine_config& config) m_crulatch8_15->q_out_cb<2>().set(FUNC(snug_bwg_device::dden_w)); // TODO: Replace this by the actual 74HC4538 - TTL74123(config, m_motormf, 0); + TTL74123(config, m_motormf); m_motormf->out_cb().set(FUNC(snug_bwg_device::motorona_w)); m_motormf->set_connection_type(TTL74123_GROUNDED); m_motormf->set_resistor_value(RES_K(200)); diff --git a/src/devices/bus/ti99/peb/bwg.h b/src/devices/bus/ti99/peb/bwg.h index 671f584dc9a..2dfdd61a59a 100644 --- a/src/devices/bus/ti99/peb/bwg.h +++ b/src/devices/bus/ti99/peb/bwg.h @@ -29,7 +29,7 @@ namespace bus::ti99::peb { class snug_bwg_device : public device_t, public device_ti99_peribox_card_interface { public: - snug_bwg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snug_bwg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/peb/cc_fdc.cpp b/src/devices/bus/ti99/peb/cc_fdc.cpp index 6762dea8a05..f66600182ee 100644 --- a/src/devices/bus/ti99/peb/cc_fdc.cpp +++ b/src/devices/bus/ti99/peb/cc_fdc.cpp @@ -72,7 +72,7 @@ namespace bus::ti99::peb { // ---------------------------------- -corcomp_fdc_device::corcomp_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock): +corcomp_fdc_device::corcomp_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, type, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_wdc(*this, WDC_TAG), @@ -490,7 +490,7 @@ void corcomp_fdc_device::common_config(machine_config& config) m_wdc->drq_wr_callback().set(FUNC(corcomp_fdc_device::fdc_drq_w)); m_wdc->hld_wr_callback().set(FUNC(corcomp_fdc_device::fdc_hld_w)); - TMS9901(config, m_tms9901, 0); + TMS9901(config, m_tms9901); m_tms9901->read_cb().set(FUNC(corcomp_fdc_device::tms9901_input)); // Outputs @@ -519,7 +519,7 @@ void corcomp_fdc_device::common_config(machine_config& config) m_tms9901->p_out_cb(11).set(FUNC(corcomp_fdc_device::select_bank)); // Motor monoflop - TTL74123(config, m_motormf, 0); + TTL74123(config, m_motormf); m_motormf->set_connection_type(TTL74123_GROUNDED); m_motormf->set_resistor_value(RES_K(100)); m_motormf->set_capacitor_value(CAP_U(47)); @@ -541,7 +541,7 @@ void corcomp_fdc_device::common_config(machine_config& config) // Original CorComp Disk Controller Card (PEB-DCC) // ============================================================================ -corcomp_dcc_device::corcomp_dcc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +corcomp_dcc_device::corcomp_dcc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): corcomp_fdc_device(mconfig, TI99_CCDCC, tag, owner, clock) { } @@ -555,8 +555,8 @@ void corcomp_dcc_device::device_add_mconfig(machine_config& config) m_tms9901->p_out_cb(3).set(WDC_TAG, FUNC(wd_fdc_device_base::hlt_w)); // PAL circuits are connected in device_config_complete - CCDCC_PALU2(config, CCDCC_PALU2_TAG, 0); - CCDCC_PALU1(config, CCDCC_PALU1_TAG, 0); + CCDCC_PALU2(config, CCDCC_PALU2_TAG); + CCDCC_PALU1(config, CCDCC_PALU1_TAG); } ROM_START( cc_dcc ) @@ -586,14 +586,14 @@ const tiny_rom_entry *corcomp_dcc_device::device_rom_region() const // PAL circuits on the CorComp board // ======================================================================== -ccfdc_dec_pal_device::ccfdc_dec_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ccfdc_dec_pal_device::ccfdc_dec_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_board(nullptr), m_tms9901(*owner, TMS9901_TAG) { } -ccfdc_sel_pal_device::ccfdc_sel_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ccfdc_sel_pal_device::ccfdc_sel_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_board(nullptr), m_decpal(nullptr), @@ -677,12 +677,12 @@ READ_LINE_MEMBER( ccfdc_sel_pal_device::selectdsr ) // selector PAL u1. // ======================================================================== -ccdcc_palu2_device::ccdcc_palu2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ccdcc_palu2_device::ccdcc_palu2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ccfdc_dec_pal_device(mconfig, CCDCC_PALU2, tag, owner, clock) { } -ccdcc_palu1_device::ccdcc_palu1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ccdcc_palu1_device::ccdcc_palu1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ccfdc_sel_pal_device(mconfig, CCDCC_PALU1, tag, owner, clock) { } @@ -715,7 +715,7 @@ void ccdcc_palu1_device::device_config_complete() // Revised CorComp floppy disk controller card REV A // ============================================================================ -corcomp_fdca_device::corcomp_fdca_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +corcomp_fdca_device::corcomp_fdca_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): corcomp_fdc_device(mconfig, TI99_CCFDC, tag, owner, clock) { } @@ -726,8 +726,8 @@ void corcomp_fdca_device::device_add_mconfig(machine_config& config) common_config(config); // PAL circuits are connected in device_config_complete - CCFDC_PALU12(config, CCFDC_PALU12_TAG, 0); - CCFDC_PALU6(config, CCFDC_PALU6_TAG, 0); + CCFDC_PALU12(config, CCFDC_PALU12_TAG); + CCFDC_PALU6(config, CCFDC_PALU6_TAG); } /* @@ -764,7 +764,7 @@ const tiny_rom_entry *corcomp_fdca_device::device_rom_region() const // selector PAL u6. // ======================================================================== -ccfdc_palu12_device::ccfdc_palu12_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ccfdc_palu12_device::ccfdc_palu12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ccfdc_dec_pal_device(mconfig, CCFDC_PALU12, tag, owner, clock) { } @@ -778,7 +778,7 @@ READ_LINE_MEMBER( ccfdc_palu12_device::address9901 ) return ((m_board->get_address() & 0xffc0)==0x1100)? ASSERT_LINE : CLEAR_LINE; } -ccfdc_palu6_device::ccfdc_palu6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ccfdc_palu6_device::ccfdc_palu6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ccfdc_sel_pal_device(mconfig, CCFDC_PALU6, tag, owner, clock) { } diff --git a/src/devices/bus/ti99/peb/cc_fdc.h b/src/devices/bus/ti99/peb/cc_fdc.h index e72bfa3ea57..cc7ad85a924 100644 --- a/src/devices/bus/ti99/peb/cc_fdc.h +++ b/src/devices/bus/ti99/peb/cc_fdc.h @@ -57,7 +57,7 @@ public: DECLARE_WRITE_LINE_MEMBER( select_bank ); protected: - corcomp_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + corcomp_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void device_start() override; void device_reset() override; @@ -130,7 +130,7 @@ protected: class corcomp_dcc_device : public corcomp_fdc_device { public: - corcomp_dcc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + corcomp_dcc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: void device_add_mconfig(machine_config &config) override; void device_config_complete() override; @@ -147,7 +147,7 @@ public: virtual DECLARE_READ_LINE_MEMBER(address9901); protected: - ccfdc_dec_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ccfdc_dec_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void device_start() override { } void device_config_complete() override; @@ -167,7 +167,7 @@ public: virtual DECLARE_READ_LINE_MEMBER(ready_out) =0; protected: - ccfdc_sel_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ccfdc_sel_pal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void device_start() override { } virtual void device_config_complete() override =0; @@ -184,7 +184,7 @@ protected: class ccdcc_palu2_device : public ccfdc_dec_pal_device { public: - ccdcc_palu2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ccdcc_palu2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // =========== Specific selector PAL circuit of the CCDCC ================ @@ -192,7 +192,7 @@ public: class ccdcc_palu1_device : public ccfdc_sel_pal_device { public: - ccdcc_palu1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ccdcc_palu1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_READ_LINE_MEMBER(ready_out) override; private: @@ -208,7 +208,7 @@ class corcomp_fdca_device : public corcomp_fdc_device friend class ccfdc_palu6_device; public: - corcomp_fdca_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + corcomp_fdca_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: void device_add_mconfig(machine_config &config) override; void device_config_complete() override; @@ -221,7 +221,7 @@ private: class ccfdc_palu12_device : public ccfdc_dec_pal_device { public: - ccfdc_palu12_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ccfdc_palu12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_READ_LINE_MEMBER(address9901) override; }; @@ -230,7 +230,7 @@ public: class ccfdc_palu6_device : public ccfdc_sel_pal_device { public: - ccfdc_palu6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ccfdc_palu6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_READ_LINE_MEMBER(selectwdc) override; DECLARE_READ_LINE_MEMBER(selectdsr) override; diff --git a/src/devices/bus/ti99/peb/evpc.cpp b/src/devices/bus/ti99/peb/evpc.cpp index 974d786d8ee..df8352bffd0 100644 --- a/src/devices/bus/ti99/peb/evpc.cpp +++ b/src/devices/bus/ti99/peb/evpc.cpp @@ -61,7 +61,7 @@ namespace bus::ti99::peb { #define EVPC_CRU_BASE 0x1400 #define SOUNDCHIP_TAG "soundchip" -snug_enhanced_video_device::snug_enhanced_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +snug_enhanced_video_device::snug_enhanced_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, TI99_EVPC, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/bus/ti99/peb/evpc.h b/src/devices/bus/ti99/peb/evpc.h index 683933a5780..cea096e7507 100644 --- a/src/devices/bus/ti99/peb/evpc.h +++ b/src/devices/bus/ti99/peb/evpc.h @@ -29,7 +29,7 @@ namespace bus::ti99::peb { class snug_enhanced_video_device : public device_t, public device_ti99_peribox_card_interface, public device_nvram_interface { public: - snug_enhanced_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snug_enhanced_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; void setaddress_dbin(offs_t offset, int state) override; diff --git a/src/devices/bus/ti99/peb/forti.cpp b/src/devices/bus/ti99/peb/forti.cpp index 0ee053a740c..b573ea5556d 100644 --- a/src/devices/bus/ti99/peb/forti.cpp +++ b/src/devices/bus/ti99/peb/forti.cpp @@ -45,7 +45,7 @@ DEFINE_DEVICE_TYPE(TI99_FORTI, bus::ti99::peb::forti_device, "ti99_forti", "FORT namespace bus::ti99::peb { -forti_device::forti_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +forti_device::forti_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, TI99_FORTI, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_generator1(*this, FORTI_GEN1_TAG), diff --git a/src/devices/bus/ti99/peb/forti.h b/src/devices/bus/ti99/peb/forti.h index 69ad6ddfcab..991640621d0 100644 --- a/src/devices/bus/ti99/peb/forti.h +++ b/src/devices/bus/ti99/peb/forti.h @@ -25,7 +25,7 @@ namespace bus::ti99::peb { class forti_device : public device_t, public device_ti99_peribox_card_interface { public: - forti_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + forti_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint8_t data) override; void readz(offs_t offset, uint8_t *value) override; void crureadz(offs_t offset, uint8_t *value) override { } diff --git a/src/devices/bus/ti99/peb/hfdc.cpp b/src/devices/bus/ti99/peb/hfdc.cpp index d760f09da20..e7e5c244c38 100644 --- a/src/devices/bus/ti99/peb/hfdc.cpp +++ b/src/devices/bus/ti99/peb/hfdc.cpp @@ -95,7 +95,7 @@ namespace bus::ti99::peb { /* Constructor for the HFDC card. */ -myarc_hfdc_device::myarc_hfdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +myarc_hfdc_device::myarc_hfdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, TI99_HFDC, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_motor_on_timer(nullptr), @@ -1070,7 +1070,7 @@ ROM_END void myarc_hfdc_device::device_add_mconfig(machine_config& config) { - HDC9234(config, m_hdc9234, 0); + HDC9234(config, m_hdc9234); m_hdc9234->intrq_cb().set(FUNC(myarc_hfdc_device::intrq_w)); m_hdc9234->dmarq_cb().set(FUNC(myarc_hfdc_device::dmarq_w)); m_hdc9234->dip_cb().set(FUNC(myarc_hfdc_device::dip_w)); @@ -1089,7 +1089,7 @@ void myarc_hfdc_device::device_add_mconfig(machine_config& config) MFM_HD_CONNECTOR(config, "h2", hfdc_harddisks, nullptr, MFM_BYTE, 3000, 20, MFMHD_GEN_FORMAT); MFM_HD_CONNECTOR(config, "h3", hfdc_harddisks, nullptr, MFM_BYTE, 3000, 20, MFMHD_GEN_FORMAT); - MM58274C(config, CLOCK_TAG, 0).set_mode_and_day(1, 0); // 24h, sunday + MM58274C(config, CLOCK_TAG).set_mode_and_day(1, 0); // 24h, sunday RAM(config, BUFFER).set_default_size("32K").set_default_value(0); } diff --git a/src/devices/bus/ti99/peb/hfdc.h b/src/devices/bus/ti99/peb/hfdc.h index ee167421e48..4eeb5cc823d 100644 --- a/src/devices/bus/ti99/peb/hfdc.h +++ b/src/devices/bus/ti99/peb/hfdc.h @@ -35,7 +35,7 @@ namespace bus::ti99::peb { class myarc_hfdc_device : public device_t, public device_ti99_peribox_card_interface { public: - myarc_hfdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + myarc_hfdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void readz(offs_t offset, uint8_t *value) override; virtual void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/peb/horizon.cpp b/src/devices/bus/ti99/peb/horizon.cpp index 4f45d0021e9..aaba4095e6c 100644 --- a/src/devices/bus/ti99/peb/horizon.cpp +++ b/src/devices/bus/ti99/peb/horizon.cpp @@ -150,7 +150,7 @@ namespace bus::ti99::peb { #define OPT32K_TAG "m32_ram" #define RAM16M_TAG "m31_m0_ram" -horizon_ramdisk_device::horizon_ramdisk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +horizon_ramdisk_device::horizon_ramdisk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, TI99_HORIZON, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/bus/ti99/peb/horizon.h b/src/devices/bus/ti99/peb/horizon.h index 77643cd9ba3..bb13b7a9987 100644 --- a/src/devices/bus/ti99/peb/horizon.h +++ b/src/devices/bus/ti99/peb/horizon.h @@ -25,7 +25,7 @@ namespace bus::ti99::peb { class horizon_ramdisk_device : public device_t, public device_ti99_peribox_card_interface, public device_nvram_interface { public: - horizon_ramdisk_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + horizon_ramdisk_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/peb/hsgpl.cpp b/src/devices/bus/ti99/peb/hsgpl.cpp index fc687b25785..70086b2bec4 100644 --- a/src/devices/bus/ti99/peb/hsgpl.cpp +++ b/src/devices/bus/ti99/peb/hsgpl.cpp @@ -151,7 +151,7 @@ namespace bus::ti99::peb { #define GROM_A_EEPROM "u1_grom" #define ROM6_EEPROM "u6_rom6" -snug_high_speed_gpl_device::snug_high_speed_gpl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +snug_high_speed_gpl_device::snug_high_speed_gpl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_HSGPL, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_dsr_eeprom(*this, DSR_EEPROM), diff --git a/src/devices/bus/ti99/peb/hsgpl.h b/src/devices/bus/ti99/peb/hsgpl.h index 6d946b1ac64..3f229c63363 100644 --- a/src/devices/bus/ti99/peb/hsgpl.h +++ b/src/devices/bus/ti99/peb/hsgpl.h @@ -27,7 +27,7 @@ namespace bus::ti99::peb { class snug_high_speed_gpl_device : public device_t, public device_ti99_peribox_card_interface { public: - snug_high_speed_gpl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snug_high_speed_gpl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/peb/memex.cpp b/src/devices/bus/ti99/peb/memex.cpp index 1ee9bf423e1..5de2aa8bf2d 100644 --- a/src/devices/bus/ti99/peb/memex.cpp +++ b/src/devices/bus/ti99/peb/memex.cpp @@ -43,7 +43,7 @@ enum MDIP8 = 0x80 }; -geneve_memex_device::geneve_memex_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +geneve_memex_device::geneve_memex_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_MEMEX, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_ram(*this, RAMREGION) @@ -171,7 +171,7 @@ INPUT_PORTS_END void geneve_memex_device::device_add_mconfig(machine_config &config) { - RAM(config, m_ram, 0); + RAM(config, m_ram); m_ram->set_default_size("2M"); m_ram->set_default_value(0); } diff --git a/src/devices/bus/ti99/peb/memex.h b/src/devices/bus/ti99/peb/memex.h index 32c56326d47..114e61d4cae 100644 --- a/src/devices/bus/ti99/peb/memex.h +++ b/src/devices/bus/ti99/peb/memex.h @@ -23,7 +23,7 @@ namespace bus::ti99::peb { class geneve_memex_device : public device_t, public device_ti99_peribox_card_interface { public: - geneve_memex_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + geneve_memex_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/peb/myarcfdc.cpp b/src/devices/bus/ti99/peb/myarcfdc.cpp index 7df7cf0d261..560213d39d1 100644 --- a/src/devices/bus/ti99/peb/myarcfdc.cpp +++ b/src/devices/bus/ti99/peb/myarcfdc.cpp @@ -54,7 +54,7 @@ namespace bus::ti99::peb { // ---------------------------------- -myarc_fdc_device::myarc_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +myarc_fdc_device::myarc_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, TI99_DDCC1, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_wdc(nullptr), @@ -456,7 +456,7 @@ void myarc_fdc_device::device_add_mconfig(machine_config& config) RAM(config, BUFFER_TAG).set_default_size("2k").set_default_value(0); // PAL circuit - DDCC1_PAL(config, PAL_TAG, 0); + DDCC1_PAL(config, PAL_TAG); // Floppy drives FLOPPY_CONNECTOR(config, "0", myarc_ddcc_floppies, "525dd", myarc_fdc_device::floppy_formats).enable_sound(true); @@ -479,7 +479,7 @@ const tiny_rom_entry *myarc_fdc_device::device_rom_region() const // PAL circuit on the DDCC-1 board // ======================================================================== -ddcc1_pal_device::ddcc1_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ddcc1_pal_device::ddcc1_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DDCC1_PAL, tag, owner, clock), m_board(nullptr) { diff --git a/src/devices/bus/ti99/peb/myarcfdc.h b/src/devices/bus/ti99/peb/myarcfdc.h index 89106b73e5a..156a5a9a2fd 100644 --- a/src/devices/bus/ti99/peb/myarcfdc.h +++ b/src/devices/bus/ti99/peb/myarcfdc.h @@ -29,7 +29,7 @@ class myarc_fdc_device : public device_t, public device_ti99_peribox_card_interf friend class ddcc1_pal_device; public: - myarc_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + myarc_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; @@ -112,7 +112,7 @@ private: class ddcc1_pal_device : public device_t { public: - ddcc1_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ddcc1_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Selector output lines of the PAL bool ramsel(); diff --git a/src/devices/bus/ti99/peb/myarcmem.cpp b/src/devices/bus/ti99/peb/myarcmem.cpp index edee7601c80..09c2aeb14f2 100644 --- a/src/devices/bus/ti99/peb/myarcmem.cpp +++ b/src/devices/bus/ti99/peb/myarcmem.cpp @@ -44,7 +44,7 @@ enum SIZE_512 }; -myarc_memory_expansion_device::myarc_memory_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +myarc_memory_expansion_device::myarc_memory_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, TI99_MYARCMEM, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_ram(*this, RAM_TAG), diff --git a/src/devices/bus/ti99/peb/myarcmem.h b/src/devices/bus/ti99/peb/myarcmem.h index b641dfafcc3..641c4a8cb7b 100644 --- a/src/devices/bus/ti99/peb/myarcmem.h +++ b/src/devices/bus/ti99/peb/myarcmem.h @@ -23,7 +23,7 @@ namespace bus::ti99::peb { class myarc_memory_expansion_device : public device_t, public device_ti99_peribox_card_interface { public: - myarc_memory_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + myarc_memory_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/peb/pcode.cpp b/src/devices/bus/ti99/peb/pcode.cpp index 0c5e4e4fb57..867b97f4d5b 100644 --- a/src/devices/bus/ti99/peb/pcode.cpp +++ b/src/devices/bus/ti99/peb/pcode.cpp @@ -97,7 +97,7 @@ namespace bus::ti99::peb { #define CRU_BASE 0x1f00 -ti_pcode_card_device::ti_pcode_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ti_pcode_card_device::ti_pcode_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_P_CODE, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_groms(*this, "grom%u", 0U), diff --git a/src/devices/bus/ti99/peb/pcode.h b/src/devices/bus/ti99/peb/pcode.h index dd1ce542d1a..0ae6811c2ff 100644 --- a/src/devices/bus/ti99/peb/pcode.h +++ b/src/devices/bus/ti99/peb/pcode.h @@ -26,7 +26,7 @@ namespace bus::ti99::peb { class ti_pcode_card_device : public device_t, public device_ti99_peribox_card_interface { public: - ti_pcode_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti_pcode_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; void crureadz(offs_t offset, uint8_t *value) override; diff --git a/src/devices/bus/ti99/peb/peribox.cpp b/src/devices/bus/ti99/peb/peribox.cpp index cc8b07500f0..f110de2c535 100644 --- a/src/devices/bus/ti99/peb/peribox.cpp +++ b/src/devices/bus/ti99/peb/peribox.cpp @@ -243,7 +243,7 @@ namespace bus::ti99::peb { /* Constructor called from subclasses. */ -peribox_device::peribox_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock): +peribox_device::peribox_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock): bus::ti99::internal::ioport_attached_device(mconfig, type, tag, owner, clock), m_slot1_inta(*this), m_slot1_intb(*this), @@ -268,7 +268,7 @@ peribox_device::peribox_device(const machine_config &mconfig, device_type type, for (int i=2; i <= 8; i++) m_slot[i] = nullptr; } -peribox_device::peribox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +peribox_device::peribox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : peribox_device(mconfig, TI99_PERIBOX, tag, owner, clock) { // The address prefix represents a set of pull-up resistors for the @@ -522,7 +522,7 @@ void peribox_device::device_add_mconfig(machine_config &config) A variant of the box used for the TI-99/4A with EVPC. *****************************************************************************/ -peribox_ev_device::peribox_ev_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +peribox_ev_device::peribox_ev_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : peribox_device(mconfig, TI99_PERIBOX_EV, tag, owner, clock) { m_address_prefix = 0x70000; @@ -569,7 +569,7 @@ void peribox_ev_device::device_add_mconfig(machine_config &config) A variant of the box used for the Geneve. *****************************************************************************/ -peribox_gen_device::peribox_gen_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock): +peribox_gen_device::peribox_gen_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock): peribox_device(mconfig, type, tag, owner, clock) { // The Geneve sits in slot 1; there is no prefix here - it can control @@ -578,12 +578,12 @@ peribox_gen_device::peribox_gen_device(const machine_config &mconfig, device_typ m_address_prefix = 0x00000; } -peribox_gen_device::peribox_gen_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +peribox_gen_device::peribox_gen_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : peribox_gen_device(mconfig, TI99_PERIBOX_GEN, tag, owner, clock) { } -peribox_genmod_device::peribox_genmod_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +peribox_genmod_device::peribox_genmod_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : peribox_gen_device(mconfig, TI99_PERIBOX_GENMOD, tag, owner, clock) { } @@ -638,7 +638,7 @@ void peribox_genmod_device::device_add_mconfig(machine_config &config) A variant of the box used for the SGCPU (aka TI-99/4P). *****************************************************************************/ -peribox_sg_device::peribox_sg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +peribox_sg_device::peribox_sg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : peribox_device(mconfig, TI99_PERIBOX_SG, tag, owner, clock) { // The SGCPU card contains pull-up registers for the AMA/AMB/AMC lines @@ -685,7 +685,7 @@ void peribox_sg_device::device_add_mconfig(machine_config &config) Implementation of a slot within the box. ****************************************************************************/ -peribox_slot_device::peribox_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +peribox_slot_device::peribox_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_PERIBOX_SLOT, tag, owner, clock), device_single_card_slot_interface<device_ti99_peribox_card_interface>(mconfig, *this), m_card(nullptr), diff --git a/src/devices/bus/ti99/peb/peribox.h b/src/devices/bus/ti99/peb/peribox.h index b54467f1055..803431dd97a 100644 --- a/src/devices/bus/ti99/peb/peribox.h +++ b/src/devices/bus/ti99/peb/peribox.h @@ -34,7 +34,7 @@ class peribox_device : public bus::ti99::internal::ioport_attached_device { friend class peribox_slot_device; public: - peribox_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + peribox_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Next eight methods are called from the console void readz(offs_t offset, uint8_t *value) override; @@ -63,7 +63,7 @@ public: auto lcp_cb() { return m_slot1_lcp.bind(); } protected: - peribox_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + peribox_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_config_complete() override; @@ -122,7 +122,7 @@ protected: class peribox_sg_device : public peribox_device { public: - peribox_sg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + peribox_sg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void device_add_mconfig(machine_config &config) override; @@ -134,7 +134,7 @@ protected: class peribox_ev_device : public peribox_device { public: - peribox_ev_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + peribox_ev_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void device_add_mconfig(machine_config &config) override; @@ -147,10 +147,10 @@ protected: class peribox_gen_device : public peribox_device { public: - peribox_gen_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + peribox_gen_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - peribox_gen_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + peribox_gen_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; }; @@ -160,7 +160,7 @@ protected: class peribox_genmod_device : public peribox_gen_device { public: - peribox_genmod_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + peribox_genmod_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void device_add_mconfig(machine_config &config) override; @@ -217,7 +217,7 @@ class peribox_slot_device : public device_t, public device_single_card_slot_inte public: template <typename U> peribox_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, int slot, U &&opts, const char *dflt) - : peribox_slot_device(mconfig, tag, owner, 0) + : peribox_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -226,7 +226,7 @@ public: m_slotnumber = slot; } - peribox_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + peribox_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Called from the box (direction to card) void readz(offs_t offset, uint8_t *value); diff --git a/src/devices/bus/ti99/peb/pgram.cpp b/src/devices/bus/ti99/peb/pgram.cpp index c6ece9407a0..e01781b52b6 100644 --- a/src/devices/bus/ti99/peb/pgram.cpp +++ b/src/devices/bus/ti99/peb/pgram.cpp @@ -145,7 +145,7 @@ DEFINE_DEVICE_TYPE(TI99_PGRAM, bus::ti99::peb::pgram_device, "ti99_pgram", "PGRA namespace bus::ti99::peb { -pgram_device::pgram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +pgram_device::pgram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, TI99_PGRAM, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_gram3(*this, GRAM3_TAG), @@ -500,12 +500,12 @@ void pgram_device::device_add_mconfig(machine_config& config) LS259(config, m_crulatch); // u14 // Bank switch - TTL7474(config, m_bankff, 0); + TTL7474(config, m_bankff); // We allocate the space for PGRAM+ - BUFF_RAM(config, GRAM4567_TAG, 0).set_size(128*1024); - BUFF_RAM(config, GRAM3_TAG, 0).set_size(32*1024); - BUFF_RAM(config, DSRRAM_TAG, 0).set_size(32*1024); + BUFF_RAM(config, GRAM4567_TAG).set_size(128*1024); + BUFF_RAM(config, GRAM3_TAG).set_size(32*1024); + BUFF_RAM(config, DSRRAM_TAG).set_size(32*1024); // Real-time clock MM58167(config, CLOCK_TAG, 32.768_kHz_XTAL); diff --git a/src/devices/bus/ti99/peb/pgram.h b/src/devices/bus/ti99/peb/pgram.h index d050c3deac7..1c5ef98343a 100644 --- a/src/devices/bus/ti99/peb/pgram.h +++ b/src/devices/bus/ti99/peb/pgram.h @@ -29,7 +29,7 @@ namespace bus::ti99::peb { class pgram_device : public device_t, public device_ti99_peribox_card_interface { public: - pgram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pgram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint8_t data) override; void readz(offs_t offset, uint8_t *value) override; void crureadz(offs_t offset, uint8_t *value) override { } diff --git a/src/devices/bus/ti99/peb/samsmem.cpp b/src/devices/bus/ti99/peb/samsmem.cpp index d38f877fc9f..497f33439a0 100644 --- a/src/devices/bus/ti99/peb/samsmem.cpp +++ b/src/devices/bus/ti99/peb/samsmem.cpp @@ -34,7 +34,7 @@ namespace bus::ti99::peb { #define SAMS_CRU_BASE 0x1e00 -sams_memory_expansion_device::sams_memory_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sams_memory_expansion_device::sams_memory_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_SAMSMEM, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_ram(*this, RAM_TAG), diff --git a/src/devices/bus/ti99/peb/samsmem.h b/src/devices/bus/ti99/peb/samsmem.h index 8cf3105cc85..4bc8fd745dd 100644 --- a/src/devices/bus/ti99/peb/samsmem.h +++ b/src/devices/bus/ti99/peb/samsmem.h @@ -26,7 +26,7 @@ namespace bus::ti99::peb { class sams_memory_expansion_device : public device_t, public device_ti99_peribox_card_interface { public: - sams_memory_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sams_memory_expansion_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/peb/scsicard.cpp b/src/devices/bus/ti99/peb/scsicard.cpp index 5f9dfbf19e6..ec612ee3018 100644 --- a/src/devices/bus/ti99/peb/scsicard.cpp +++ b/src/devices/bus/ti99/peb/scsicard.cpp @@ -141,7 +141,7 @@ DEFINE_DEVICE_TYPE(WHTSCSI_PLD, bus::ti99::peb::whtscsi_pld_device, PLD_TAG, "WH namespace bus::ti99::peb { -whtech_scsi_card_device::whtech_scsi_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +whtech_scsi_card_device::whtech_scsi_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_WHTSCSI, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_buffer_ram(*this, BUFFER), @@ -373,7 +373,7 @@ void whtech_scsi_card_device::device_add_mconfig(machine_config &config) RAM(config, BUFFER).set_default_size("32K").set_default_value(0); // PLD circuit - WHTSCSI_PLD(config, PLD_TAG, 0); + WHTSCSI_PLD(config, PLD_TAG); // SCSI bus NSCSI_BUS(config, m_scsibus); @@ -487,7 +487,7 @@ ioport_constructor whtech_scsi_card_device::device_input_ports() const // PLD circuit on the board // ======================================================================== -whtscsi_pld_device::whtscsi_pld_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +whtscsi_pld_device::whtscsi_pld_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WHTSCSI_PLD, tag, owner, clock), m_board(nullptr), m_selected(false), diff --git a/src/devices/bus/ti99/peb/scsicard.h b/src/devices/bus/ti99/peb/scsicard.h index a55ad228886..998879005c0 100644 --- a/src/devices/bus/ti99/peb/scsicard.h +++ b/src/devices/bus/ti99/peb/scsicard.h @@ -27,7 +27,7 @@ class whtech_scsi_card_device : public device_t, public device_ti99_peribox_card friend class whtscsi_pld_device; public: - whtech_scsi_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + whtech_scsi_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; void setaddress_dbin(offs_t offset, int state) override; @@ -91,7 +91,7 @@ private: class whtscsi_pld_device : public device_t { public: - whtscsi_pld_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + whtscsi_pld_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void crureadz(offs_t offset, uint8_t *value); void cruwrite(offs_t offset, uint8_t data); diff --git a/src/devices/bus/ti99/peb/sidmaster.cpp b/src/devices/bus/ti99/peb/sidmaster.cpp index 9b6eb0af129..8a3aa2b6ca6 100644 --- a/src/devices/bus/ti99/peb/sidmaster.cpp +++ b/src/devices/bus/ti99/peb/sidmaster.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(TI99_SIDMASTER, bus::ti99::peb::sidmaster_device, "ti99_sidma namespace bus::ti99::peb { -sidmaster_device::sidmaster_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sidmaster_device::sidmaster_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_SIDMASTER, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_sid(*this, "sid") diff --git a/src/devices/bus/ti99/peb/sidmaster.h b/src/devices/bus/ti99/peb/sidmaster.h index 63965c9c5d0..8f1622d8aea 100644 --- a/src/devices/bus/ti99/peb/sidmaster.h +++ b/src/devices/bus/ti99/peb/sidmaster.h @@ -24,7 +24,7 @@ namespace bus::ti99::peb { class sidmaster_device : public device_t, public device_ti99_peribox_card_interface { public: - sidmaster_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sidmaster_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override { }; // No read void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/peb/spchsyn.cpp b/src/devices/bus/ti99/peb/spchsyn.cpp index 302758f3f4e..230139e5a3c 100644 --- a/src/devices/bus/ti99/peb/spchsyn.cpp +++ b/src/devices/bus/ti99/peb/spchsyn.cpp @@ -42,7 +42,7 @@ namespace bus::ti99::peb { /****************************************************************************/ -ti_speech_synthesizer_device::ti_speech_synthesizer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ti_speech_synthesizer_device::ti_speech_synthesizer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_SPEECH, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_vsp(*this, "vsp"), @@ -154,7 +154,7 @@ ROM_END void ti_speech_synthesizer_device::device_add_mconfig(machine_config& config) { - SPEECHROM(config, "vsm", 0).set_reverse_bit_order(true); + SPEECHROM(config, "vsm").set_reverse_bit_order(true); SPEAKER(config, "speech_out").front_center(); CD2501E(config, m_vsp, 640000L); m_vsp->set_speechrom_tag("vsm"); diff --git a/src/devices/bus/ti99/peb/spchsyn.h b/src/devices/bus/ti99/peb/spchsyn.h index 5bf71658e4b..10844cccedd 100644 --- a/src/devices/bus/ti99/peb/spchsyn.h +++ b/src/devices/bus/ti99/peb/spchsyn.h @@ -24,7 +24,7 @@ namespace bus::ti99::peb { class ti_speech_synthesizer_device : public device_t, public device_ti99_peribox_card_interface { public: - ti_speech_synthesizer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti_speech_synthesizer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; void setaddress_dbin(offs_t offset, int state) override; diff --git a/src/devices/bus/ti99/peb/ti_32kmem.cpp b/src/devices/bus/ti99/peb/ti_32kmem.cpp index 1f9404bd1e1..22b02ace4dc 100644 --- a/src/devices/bus/ti99/peb/ti_32kmem.cpp +++ b/src/devices/bus/ti99/peb/ti_32kmem.cpp @@ -37,7 +37,7 @@ namespace bus::ti99::peb { #define RAMREGION "ram32k" -ti_32k_expcard_device::ti_32k_expcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ti_32k_expcard_device::ti_32k_expcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_32KMEM, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_ram(*this, RAMREGION) @@ -102,7 +102,7 @@ void ti_32k_expcard_device::device_start() void ti_32k_expcard_device::device_add_mconfig(machine_config &config) { - RAM(config, m_ram, 0); + RAM(config, m_ram); m_ram->set_default_size("32k"); m_ram->set_default_value(0); } diff --git a/src/devices/bus/ti99/peb/ti_32kmem.h b/src/devices/bus/ti99/peb/ti_32kmem.h index 275f85fc6a7..469d2e6ba45 100644 --- a/src/devices/bus/ti99/peb/ti_32kmem.h +++ b/src/devices/bus/ti99/peb/ti_32kmem.h @@ -24,7 +24,7 @@ namespace bus::ti99::peb { class ti_32k_expcard_device : public device_t, public device_ti99_peribox_card_interface { public: - ti_32k_expcard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti_32k_expcard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99/peb/ti_fdc.cpp b/src/devices/bus/ti99/peb/ti_fdc.cpp index b68147a8193..36ecf8a907c 100644 --- a/src/devices/bus/ti99/peb/ti_fdc.cpp +++ b/src/devices/bus/ti99/peb/ti_fdc.cpp @@ -42,7 +42,7 @@ namespace bus::ti99::peb { #define TI_FDC_TAG "ti_dssd_controller" -ti_fdc_device::ti_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ti_fdc_device::ti_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_FDC, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_address(0), @@ -418,7 +418,7 @@ void ti_fdc_device::device_add_mconfig(machine_config& config) m_crulatch->q_out_cb<6>().set(FUNC(ti_fdc_device::dsel3_w)); m_crulatch->q_out_cb<7>().set(FUNC(ti_fdc_device::sidsel_w)); - TTL74123(config, m_motormf, 0); + TTL74123(config, m_motormf); m_motormf->out_cb().set(FUNC(ti_fdc_device::dvena_w)); m_motormf->set_connection_type(TTL74123_GROUNDED); m_motormf->set_resistor_value(RES_K(200)); diff --git a/src/devices/bus/ti99/peb/ti_fdc.h b/src/devices/bus/ti99/peb/ti_fdc.h index 81c2324dbc9..3fe56cc0d0e 100644 --- a/src/devices/bus/ti99/peb/ti_fdc.h +++ b/src/devices/bus/ti99/peb/ti_fdc.h @@ -27,7 +27,7 @@ namespace bus::ti99::peb { class ti_fdc_device : public device_t, public device_ti99_peribox_card_interface { public: - ti_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; void setaddress_dbin(offs_t offset, int state) override; diff --git a/src/devices/bus/ti99/peb/ti_rs232.cpp b/src/devices/bus/ti99/peb/ti_rs232.cpp index 841acf44ac7..2c9f8e8c7d6 100644 --- a/src/devices/bus/ti99/peb/ti_rs232.cpp +++ b/src/devices/bus/ti99/peb/ti_rs232.cpp @@ -140,7 +140,7 @@ namespace bus::ti99::peb { #define SERDEV1 "serdev1" #define PIODEV "piodev" -ti_rs232_pio_device::ti_rs232_pio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ti_rs232_pio_device::ti_rs232_pio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_RS232, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_crulatch(*this, "crulatch"), @@ -170,14 +170,14 @@ ti_rs232_pio_device::ti_rs232_pio_device(const machine_config &mconfig, const ch /**************************************************************************/ /* Ports */ -ti_rs232_attached_device::ti_rs232_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti_rs232_attached_device::ti_rs232_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_RS232_DEV, tag, owner, clock), device_image_interface(mconfig, *this), m_uart(nullptr) { } -ti_pio_attached_device::ti_pio_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti_pio_attached_device::ti_pio_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_PIO_DEV, tag, owner, clock), device_image_interface(mconfig, *this) { @@ -1092,22 +1092,22 @@ INPUT_PORTS_END void ti_rs232_pio_device::device_add_mconfig(machine_config &config) { - TMS9902(config, m_uart0, 3000000); + TMS9902(config, m_uart0, XTAL::u(3000000)); m_uart0->int_cb().set(FUNC(ti_rs232_pio_device::int0_callback)); m_uart0->rcv_cb().set(FUNC(ti_rs232_pio_device::rcv0_callback)); m_uart0->xmit_cb().set(FUNC(ti_rs232_pio_device::xmit0_callback)); m_uart0->ctrl_cb().set(FUNC(ti_rs232_pio_device::ctrl0_callback)); - TMS9902(config, m_uart1, 3000000); + TMS9902(config, m_uart1, XTAL::u(3000000)); m_uart1->int_cb().set(FUNC(ti_rs232_pio_device::int1_callback)); m_uart1->rcv_cb().set(FUNC(ti_rs232_pio_device::rcv1_callback)); m_uart1->xmit_cb().set(FUNC(ti_rs232_pio_device::xmit1_callback)); m_uart1->ctrl_cb().set(FUNC(ti_rs232_pio_device::ctrl1_callback)); - TI99_RS232_DEV(config, m_serdev0, 0); + TI99_RS232_DEV(config, m_serdev0); m_serdev0->connect(m_uart0); - TI99_RS232_DEV(config, m_serdev1, 0); + TI99_RS232_DEV(config, m_serdev1); m_serdev1->connect(m_uart1); - TI99_PIO_DEV(config, m_piodev, 0); + TI99_PIO_DEV(config, m_piodev); LS259(config, m_crulatch); // U12 m_crulatch->q_out_cb<0>().set(FUNC(ti_rs232_pio_device::selected_w)); diff --git a/src/devices/bus/ti99/peb/ti_rs232.h b/src/devices/bus/ti99/peb/ti_rs232.h index e7970538504..e22725dab95 100644 --- a/src/devices/bus/ti99/peb/ti_rs232.h +++ b/src/devices/bus/ti99/peb/ti_rs232.h @@ -30,7 +30,7 @@ class ti_rs232_pio_device : public device_t, public device_ti99_peribox_card_int friend class ti_rs232_attached_device; public: - ti_rs232_pio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti_rs232_pio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; @@ -131,7 +131,7 @@ private: class ti_rs232_attached_device : public device_t, public device_image_interface { public: - ti_rs232_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti_rs232_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); bool is_readable() const noexcept override { return true; } bool is_writeable() const noexcept override { return true; } @@ -160,7 +160,7 @@ private: class ti_pio_attached_device : public device_t, public device_image_interface { public: - ti_pio_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti_pio_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); bool is_readable() const noexcept override { return true; } bool is_writeable() const noexcept override { return true; } diff --git a/src/devices/bus/ti99/peb/tipi.cpp b/src/devices/bus/ti99/peb/tipi.cpp index 92f45710d33..ebe63388352 100644 --- a/src/devices/bus/ti99/peb/tipi.cpp +++ b/src/devices/bus/ti99/peb/tipi.cpp @@ -95,7 +95,7 @@ DEFINE_DEVICE_TYPE(TI99_TIPI_RPI, bus::ti99::peb::tipi_attached_device, "ti99_ti namespace bus::ti99::peb { -tipi_card_device::tipi_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tipi_card_device::tipi_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_TIPI, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_rpi(*this, RASPI), @@ -643,7 +643,7 @@ INPUT_PORTS_END void tipi_card_device::device_add_mconfig(machine_config &config) { - TI99_TIPI_RPI(config, m_rpi, 0); + TI99_TIPI_RPI(config, m_rpi); } ROM_START( tipi ) @@ -666,7 +666,7 @@ ioport_constructor tipi_card_device::device_input_ports() const /* Connection to the external device, a Raspberry PI */ -tipi_attached_device::tipi_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tipi_attached_device::tipi_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_TIPI_RPI, tag, owner, clock), device_image_interface(mconfig, *this) { diff --git a/src/devices/bus/ti99/peb/tipi.h b/src/devices/bus/ti99/peb/tipi.h index 3703e246599..b4c5c8de1b0 100644 --- a/src/devices/bus/ti99/peb/tipi.h +++ b/src/devices/bus/ti99/peb/tipi.h @@ -28,7 +28,7 @@ class tipi_card_device : public device_t, public device_ti99_peribox_card_interf { public: - tipi_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tipi_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; void setaddress_dbin(offs_t offset, int state) override; @@ -101,7 +101,7 @@ private: class tipi_attached_device : public device_t, public device_image_interface { public: - tipi_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tipi_attached_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); bool is_readable() const noexcept override { return true; } bool is_writeable() const noexcept override { return true; } diff --git a/src/devices/bus/ti99/peb/tn_ide.cpp b/src/devices/bus/ti99/peb/tn_ide.cpp index f4ae600ce67..a47c8787824 100644 --- a/src/devices/bus/ti99/peb/tn_ide.cpp +++ b/src/devices/bus/ti99/peb/tn_ide.cpp @@ -163,7 +163,7 @@ enum RTC52 }; -nouspikel_ide_card_device::nouspikel_ide_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nouspikel_ide_card_device::nouspikel_ide_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_IDE, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_rtc65(*this, CLOCK65_TAG), @@ -621,10 +621,10 @@ WRITE_LINE_MEMBER(nouspikel_ide_card_device::resetdr_callback) void nouspikel_ide_card_device::device_add_mconfig(machine_config &config) { // Choice of RTC chips - RTC65271(config, m_rtc65, 0); - BQ4847(config, m_rtc47, 0); - BQ4842(config, m_rtc42, 0); - BQ4852(config, m_rtc52, 0); + RTC65271(config, m_rtc65); + BQ4847(config, m_rtc47); + BQ4842(config, m_rtc42); + BQ4852(config, m_rtc52); m_rtc65->interrupt_cb().set(FUNC(nouspikel_ide_card_device::rtc_int_callback<RTC65>)).invert(); m_rtc47->int_handler().set(FUNC(nouspikel_ide_card_device::rtc_int_callback<RTC47>)); @@ -634,18 +634,18 @@ void nouspikel_ide_card_device::device_add_mconfig(machine_config &config) ATA_INTERFACE(config, m_ata).options(ata_devices, "hdd", nullptr, false); m_ata->irq_handler().set(FUNC(nouspikel_ide_card_device::ide_interrupt_callback)); - TTL74543(config, m_latch0_7, 0); + TTL74543(config, m_latch0_7); m_latch0_7->set_ceab_pin_value(0); m_latch0_7->set_ceba_pin_value(0); - TTL74543(config, m_latch8_15, 0); + TTL74543(config, m_latch8_15); m_latch8_15->set_ceab_pin_value(0); m_latch8_15->set_ceba_pin_value(0); LS259(config, m_crulatch); m_crulatch->q_out_cb<7>().set(FUNC(nouspikel_ide_card_device::resetdr_callback)); - BUFF_RAM(config, RAM512_TAG, 0).set_size(512*1024); + BUFF_RAM(config, RAM512_TAG).set_size(512*1024); } void nouspikel_ide_card_device::device_start() diff --git a/src/devices/bus/ti99/peb/tn_ide.h b/src/devices/bus/ti99/peb/tn_ide.h index f3174e2c0ee..32fe4f174cc 100644 --- a/src/devices/bus/ti99/peb/tn_ide.h +++ b/src/devices/bus/ti99/peb/tn_ide.h @@ -29,7 +29,7 @@ namespace bus::ti99::peb { class nouspikel_ide_card_device : public device_t, public device_ti99_peribox_card_interface { public: - nouspikel_ide_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nouspikel_ide_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; void crureadz(offs_t offset, uint8_t *value) override; diff --git a/src/devices/bus/ti99/peb/tn_usbsm.cpp b/src/devices/bus/ti99/peb/tn_usbsm.cpp index 5a2a266661b..36d3935665d 100644 --- a/src/devices/bus/ti99/peb/tn_usbsm.cpp +++ b/src/devices/bus/ti99/peb/tn_usbsm.cpp @@ -65,7 +65,7 @@ enum FEEPROM_WRITE_ENABLE = 0x10 }; -nouspikel_usb_smartmedia_device::nouspikel_usb_smartmedia_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nouspikel_usb_smartmedia_device::nouspikel_usb_smartmedia_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99_USBSM, tag, owner, clock), device_ti99_peribox_card_interface(mconfig, *this), m_feeprom_page(0), @@ -357,8 +357,8 @@ INPUT_PORTS_END void nouspikel_usb_smartmedia_device::device_add_mconfig(machine_config &config) { - SMARTMEDIA(config, "smartmedia", 0); - STRATAFLASH(config, STRATA_TAG, 0); + SMARTMEDIA(config, "smartmedia"); + STRATAFLASH(config, STRATA_TAG); RAM(config, RAM1_TAG).set_default_size("512K").set_default_value(0); RAM(config, RAM2_TAG).set_default_size("512K").set_default_value(0); } diff --git a/src/devices/bus/ti99/peb/tn_usbsm.h b/src/devices/bus/ti99/peb/tn_usbsm.h index 314e9ec5a5a..e5b0b479026 100644 --- a/src/devices/bus/ti99/peb/tn_usbsm.h +++ b/src/devices/bus/ti99/peb/tn_usbsm.h @@ -26,7 +26,7 @@ namespace bus::ti99::peb { class nouspikel_usb_smartmedia_device : public device_t, public device_ti99_peribox_card_interface { public: - nouspikel_usb_smartmedia_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nouspikel_usb_smartmedia_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void readz(offs_t offset, uint8_t *value) override; void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/ti99x/990_dk.cpp b/src/devices/bus/ti99x/990_dk.cpp index f9815b2302a..6d1b5ca358c 100644 --- a/src/devices/bus/ti99x/990_dk.cpp +++ b/src/devices/bus/ti99x/990_dk.cpp @@ -42,7 +42,7 @@ enum DEFINE_DEVICE_TYPE(TI99X_FD800, fd800_legacy_device, "ti99x_fd800", "TI FD800 Diablo floppy disk controller") -fd800_legacy_device::fd800_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fd800_legacy_device::fd800_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI99X_FD800, tag, owner, clock), m_recv_buf(0), m_stat_reg(0), m_xmit_buf(0), m_cmd_reg(0), m_interrupt_f_f(0), m_int_line(*this), m_buf_pos(0), m_buf_mode(), m_unit(0), m_sector(0) diff --git a/src/devices/bus/ti99x/990_dk.h b/src/devices/bus/ti99x/990_dk.h index f5079462ccc..809864e0f9f 100644 --- a/src/devices/bus/ti99x/990_dk.h +++ b/src/devices/bus/ti99x/990_dk.h @@ -14,7 +14,7 @@ DECLARE_DEVICE_TYPE(TI99X_FD800, fd800_legacy_device) class fd800_legacy_device : public device_t { public: - fd800_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd800_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t cru_r(offs_t offset); void cru_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/ti99x/990_hd.cpp b/src/devices/bus/ti99x/990_hd.cpp index d9a35d67b30..f94079ba9e4 100644 --- a/src/devices/bus/ti99x/990_hd.cpp +++ b/src/devices/bus/ti99x/990_hd.cpp @@ -959,7 +959,7 @@ void ti990_hdc_device::write(offs_t offset, uint16_t data, uint16_t mem_mask) DEFINE_DEVICE_TYPE(TI990_HDC, ti990_hdc_device, "ti990_hdc", "Generic TI-990 Hard Disk Controller") -ti990_hdc_device::ti990_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti990_hdc_device::ti990_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI990_HDC, tag, owner, clock) , m_memory_space(*this, finder_base::DUMMY_TAG, -1) , m_interrupt_callback(*this) diff --git a/src/devices/bus/ti99x/990_hd.h b/src/devices/bus/ti99x/990_hd.h index f934775654e..aed1e78395f 100644 --- a/src/devices/bus/ti99x/990_hd.h +++ b/src/devices/bus/ti99x/990_hd.h @@ -13,7 +13,7 @@ class ti990_hdc_device : public device_t { public: - ti990_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti990_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t read(offs_t offset); void write(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/bus/ti99x/990_tap.cpp b/src/devices/bus/ti99x/990_tap.cpp index dff4f68a7a0..f1b23e56993 100644 --- a/src/devices/bus/ti99x/990_tap.cpp +++ b/src/devices/bus/ti99x/990_tap.cpp @@ -893,7 +893,7 @@ class ti990_tape_image_device : public magtape_image_device { public: // construction/destruction - ti990_tape_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti990_tape_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // image-level overrides virtual const char *file_extensions() const noexcept override { return "tap"; } @@ -911,7 +911,7 @@ private: DEFINE_DEVICE_TYPE(TI990_TAPE, ti990_tape_image_device, "ti990_tape_image", "TI-990 Magnetic Tape") -ti990_tape_image_device::ti990_tape_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti990_tape_image_device::ti990_tape_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : magtape_image_device(mconfig, TI990_TAPE, tag, owner, clock) { } @@ -955,7 +955,7 @@ void ti990_tape_image_device::call_unload() DEFINE_DEVICE_TYPE(TI990_TAPE_CTRL, tap_990_device, "ti990_tap", "Generic TI-900 Tape Controller") -tap_990_device::tap_990_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tap_990_device::tap_990_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TI990_TAPE_CTRL, tag, owner, clock) , m_memory_space(*this, finder_base::DUMMY_TAG, -1) , m_int_line(*this) @@ -984,8 +984,8 @@ void tap_990_device::device_start() void tap_990_device::device_add_mconfig(machine_config &config) { - TI990_TAPE(config, "tape0", 0); - TI990_TAPE(config, "tape1", 0); - TI990_TAPE(config, "tape2", 0); - TI990_TAPE(config, "tape3", 0); + TI990_TAPE(config, "tape0"); + TI990_TAPE(config, "tape1"); + TI990_TAPE(config, "tape2"); + TI990_TAPE(config, "tape3"); } diff --git a/src/devices/bus/ti99x/990_tap.h b/src/devices/bus/ti99x/990_tap.h index 00168cd896b..bc6db4c5cb6 100644 --- a/src/devices/bus/ti99x/990_tap.h +++ b/src/devices/bus/ti99x/990_tap.h @@ -13,7 +13,7 @@ DECLARE_DEVICE_TYPE(TI990_TAPE_CTRL, tap_990_device) class tap_990_device : public device_t { public: - tap_990_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tap_990_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t read(offs_t offset); void write(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/bus/tiki100/8088.cpp b/src/devices/bus/tiki100/8088.cpp index 28fd3e16c0d..39628b91d90 100644 --- a/src/devices/bus/tiki100/8088.cpp +++ b/src/devices/bus/tiki100/8088.cpp @@ -73,7 +73,7 @@ void tiki100_8088_device::i8088_io(address_map &map) void tiki100_8088_device::device_add_mconfig(machine_config &config) { - I8088(config, m_maincpu, 6000000); + I8088(config, m_maincpu, XTAL::u(6000000)); m_maincpu->set_addrmap(AS_PROGRAM, &tiki100_8088_device::i8088_mem); m_maincpu->set_addrmap(AS_IO, &tiki100_8088_device::i8088_io); } @@ -88,7 +88,7 @@ void tiki100_8088_device::device_add_mconfig(machine_config &config) // tiki100_8088_device - constructor //------------------------------------------------- -tiki100_8088_device::tiki100_8088_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tiki100_8088_device::tiki100_8088_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TIKI100_8088, tag, owner, clock), device_tiki100bus_card_interface(mconfig, *this), m_maincpu(*this, I8088_TAG), diff --git a/src/devices/bus/tiki100/8088.h b/src/devices/bus/tiki100/8088.h index a997389ddf4..3d85637d2e7 100644 --- a/src/devices/bus/tiki100/8088.h +++ b/src/devices/bus/tiki100/8088.h @@ -27,7 +27,7 @@ class tiki100_8088_device : public device_t, { public: // construction/destruction - tiki100_8088_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tiki100_8088_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tiki100/exp.cpp b/src/devices/bus/tiki100/exp.cpp index fee968f40d7..f5c3943c9c5 100644 --- a/src/devices/bus/tiki100/exp.cpp +++ b/src/devices/bus/tiki100/exp.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(TIKI100_BUS_SLOT, tiki100_bus_slot_device, "tiki100bus_slot", // tiki100_bus_slot_device - constructor //------------------------------------------------- -tiki100_bus_slot_device::tiki100_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tiki100_bus_slot_device::tiki100_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TIKI100_BUS_SLOT, tag, owner, clock), device_single_card_slot_interface<device_tiki100bus_card_interface>(mconfig, *this), device_z80daisy_interface(mconfig, *this), @@ -53,7 +53,7 @@ void tiki100_bus_slot_device::device_start() // tiki100_bus_device - constructor //------------------------------------------------- -tiki100_bus_device::tiki100_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tiki100_bus_device::tiki100_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TIKI100_BUS, tag, owner, clock), m_irq_cb(*this), m_nmi_cb(*this), diff --git a/src/devices/bus/tiki100/exp.h b/src/devices/bus/tiki100/exp.h index 7625971a47d..cb807f5dff5 100644 --- a/src/devices/bus/tiki100/exp.h +++ b/src/devices/bus/tiki100/exp.h @@ -78,7 +78,7 @@ public: // construction/destruction template <typename T, typename U> tiki100_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&bus, U &&opts, const char *dflt) - : tiki100_bus_slot_device(mconfig, tag, owner, 0) + : tiki100_bus_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -87,7 +87,7 @@ public: set_bus(std::forward<T>(bus)); } - tiki100_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + tiki100_bus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> void set_bus(T &&tag) { m_bus.set_tag(std::forward<T>(tag)); } @@ -117,7 +117,7 @@ class tiki100_bus_device : public device_t { public: // construction/destruction - tiki100_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tiki100_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~tiki100_bus_device() { m_device_list.detach_all(); } auto irq_wr_callback() { return m_irq_cb.bind(); } diff --git a/src/devices/bus/tiki100/hdc.cpp b/src/devices/bus/tiki100/hdc.cpp index a351d83daca..3adde10dc32 100644 --- a/src/devices/bus/tiki100/hdc.cpp +++ b/src/devices/bus/tiki100/hdc.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(TIKI100_HDC, tiki100_hdc_device, "tiki100_hdc", "TIKI-100 Win void tiki100_hdc_device::device_add_mconfig(machine_config & config) { - WD2010(config, m_hdc, 5000000); + WD2010(config, m_hdc, XTAL::u(5000000)); //m_hdc->out_intr_callback().set(); m_hdc->in_drdy_callback().set_constant(1); m_hdc->in_index_callback().set_constant(1); @@ -40,8 +40,8 @@ void tiki100_hdc_device::device_add_mconfig(machine_config & config) m_hdc->in_tk000_callback().set_constant(1); m_hdc->in_sc_callback().set_constant(1); - HARDDISK(config, "hard0", 0); - HARDDISK(config, "hard1", 0); + HARDDISK(config, "hard0"); + HARDDISK(config, "hard1"); } @@ -54,7 +54,7 @@ void tiki100_hdc_device::device_add_mconfig(machine_config & config) // tiki100_hdc_device - constructor //------------------------------------------------- -tiki100_hdc_device::tiki100_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tiki100_hdc_device::tiki100_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TIKI100_HDC, tag, owner, clock), device_tiki100bus_card_interface(mconfig, *this), m_hdc(*this, WD1010_TAG) diff --git a/src/devices/bus/tiki100/hdc.h b/src/devices/bus/tiki100/hdc.h index d38927ff004..d089d3390da 100644 --- a/src/devices/bus/tiki100/hdc.h +++ b/src/devices/bus/tiki100/hdc.h @@ -27,7 +27,7 @@ class tiki100_hdc_device : public device_t, public device_tiki100bus_card_interf { public: // construction/destruction - tiki100_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tiki100_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tmc600/euro.cpp b/src/devices/bus/tmc600/euro.cpp index 9da4cf80227..df7490941c5 100644 --- a/src/devices/bus/tmc600/euro.cpp +++ b/src/devices/bus/tmc600/euro.cpp @@ -38,7 +38,7 @@ device_tmc600_eurobus_card_interface::device_tmc600_eurobus_card_interface(const // tmc600_eurobus_slot_device - constructor //------------------------------------------------- -tmc600_eurobus_slot_device::tmc600_eurobus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tmc600_eurobus_slot_device::tmc600_eurobus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMC600_EUROBUS_SLOT, tag, owner, clock), device_single_card_slot_interface<device_tmc600_eurobus_card_interface>(mconfig, *this) { diff --git a/src/devices/bus/tmc600/euro.h b/src/devices/bus/tmc600/euro.h index 699de5b8383..9d941ae7b42 100644 --- a/src/devices/bus/tmc600/euro.h +++ b/src/devices/bus/tmc600/euro.h @@ -77,7 +77,7 @@ public: // construction/destruction template <typename T> tmc600_eurobus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : tmc600_eurobus_slot_device(mconfig, tag, owner, 0) + : tmc600_eurobus_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -85,7 +85,7 @@ public: set_fixed(false); } - tmc600_eurobus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + tmc600_eurobus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device-level overrides diff --git a/src/devices/bus/tvc/hbf.cpp b/src/devices/bus/tvc/hbf.cpp index c12b4ab90cc..0b803f618aa 100644 --- a/src/devices/bus/tvc/hbf.cpp +++ b/src/devices/bus/tvc/hbf.cpp @@ -55,7 +55,7 @@ DEFINE_DEVICE_TYPE(TVC_HBF, tvc_hbf_device, "tvc_hbf", "HBF floppy interface") // tvc_hbf_device - constructor //------------------------------------------------- -tvc_hbf_device::tvc_hbf_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tvc_hbf_device::tvc_hbf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TVC_HBF, tag, owner, clock), device_tvcexp_interface( mconfig, *this ), m_fdc(*this, "fdc"), m_rom(nullptr), m_ram(nullptr), m_rom_bank(0) diff --git a/src/devices/bus/tvc/hbf.h b/src/devices/bus/tvc/hbf.h index b53a3b7520d..27e38c06344 100644 --- a/src/devices/bus/tvc/hbf.h +++ b/src/devices/bus/tvc/hbf.h @@ -23,7 +23,7 @@ class tvc_hbf_device : { public: // construction/destruction - tvc_hbf_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tvc_hbf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/tvc/tvc.cpp b/src/devices/bus/tvc/tvc.cpp index d3b4cee5652..3d466bc0f3c 100644 --- a/src/devices/bus/tvc/tvc.cpp +++ b/src/devices/bus/tvc/tvc.cpp @@ -51,7 +51,7 @@ device_tvcexp_interface::~device_tvcexp_interface() //------------------------------------------------- // tvcexp_slot_device - constructor //------------------------------------------------- -tvcexp_slot_device::tvcexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tvcexp_slot_device::tvcexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TVCEXP_SLOT, tag, owner, clock), device_single_card_slot_interface<device_tvcexp_interface>(mconfig, *this), m_out_irq_cb(*this), diff --git a/src/devices/bus/tvc/tvc.h b/src/devices/bus/tvc/tvc.h index bf184967685..38adeaa9913 100644 --- a/src/devices/bus/tvc/tvc.h +++ b/src/devices/bus/tvc/tvc.h @@ -92,7 +92,7 @@ public: // construction/destruction template <typename T> tvcexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : tvcexp_slot_device(mconfig, tag, owner, 0) + : tvcexp_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -100,7 +100,7 @@ public: set_fixed(false); } - tvcexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + tvcexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~tvcexp_slot_device(); auto out_irq_callback() { return m_out_irq_cb.bind(); } diff --git a/src/devices/bus/uts_kbd/400kbd.cpp b/src/devices/bus/uts_kbd/400kbd.cpp index 37d54c7d670..20884abefce 100644 --- a/src/devices/bus/uts_kbd/400kbd.cpp +++ b/src/devices/bus/uts_kbd/400kbd.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(UTS_400_KEYBOARD, uts_400_keyboard_device, "uts_400kbd", "UTS 400-Format Keyboard (F3621-04-000)") -uts_400_keyboard_device::uts_400_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +uts_400_keyboard_device::uts_400_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UTS_400_KEYBOARD, tag, owner, clock) , device_uts_keyboard_interface(mconfig, *this) , m_keys(*this, "KEY%X", 0U) diff --git a/src/devices/bus/uts_kbd/400kbd.h b/src/devices/bus/uts_kbd/400kbd.h index 8e73bc10dbd..1d919ce0317 100644 --- a/src/devices/bus/uts_kbd/400kbd.h +++ b/src/devices/bus/uts_kbd/400kbd.h @@ -11,7 +11,7 @@ class uts_400_keyboard_device : public device_t, public device_uts_keyboard_interface { public: - uts_400_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + uts_400_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual DECLARE_WRITE_LINE_MEMBER(ready_w) override; diff --git a/src/devices/bus/uts_kbd/extw.cpp b/src/devices/bus/uts_kbd/extw.cpp index 950d8b244f2..712cc659397 100644 --- a/src/devices/bus/uts_kbd/extw.cpp +++ b/src/devices/bus/uts_kbd/extw.cpp @@ -37,7 +37,7 @@ DEFINE_DEVICE_TYPE(UTS_EXTW_KEYBOARD, uts_extw_keyboard_device, "uts_extw", "UTS Expanded Typewriter Keyboard (F4725-25)") -uts_extw_keyboard_device::uts_extw_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +uts_extw_keyboard_device::uts_extw_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UTS_EXTW_KEYBOARD, tag, owner, clock) , device_uts_keyboard_interface(mconfig, *this) , m_keys(*this, "KEY%X", 0U) diff --git a/src/devices/bus/uts_kbd/extw.h b/src/devices/bus/uts_kbd/extw.h index 21599139ec1..eddff8ab82d 100644 --- a/src/devices/bus/uts_kbd/extw.h +++ b/src/devices/bus/uts_kbd/extw.h @@ -11,7 +11,7 @@ class uts_extw_keyboard_device : public device_t, public device_uts_keyboard_interface { public: - uts_extw_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + uts_extw_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual DECLARE_WRITE_LINE_MEMBER(ready_w) override; diff --git a/src/devices/bus/uts_kbd/uts_kbd.cpp b/src/devices/bus/uts_kbd/uts_kbd.cpp index 8a379b69f0c..efce4bbeb63 100644 --- a/src/devices/bus/uts_kbd/uts_kbd.cpp +++ b/src/devices/bus/uts_kbd/uts_kbd.cpp @@ -37,7 +37,7 @@ DEFINE_DEVICE_TYPE(UTS_KEYBOARD, uts_keyboard_port_device, "uts_kbd", "UTS Keyboard Port") -uts_keyboard_port_device::uts_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +uts_keyboard_port_device::uts_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UTS_KEYBOARD, tag, owner, clock) , device_single_card_slot_interface<device_uts_keyboard_interface>(mconfig, *this) , m_rxd_callback(*this) diff --git a/src/devices/bus/uts_kbd/uts_kbd.h b/src/devices/bus/uts_kbd/uts_kbd.h index c0d6d9b0824..28afe2ccb8c 100644 --- a/src/devices/bus/uts_kbd/uts_kbd.h +++ b/src/devices/bus/uts_kbd/uts_kbd.h @@ -27,10 +27,10 @@ class uts_keyboard_port_device : public device_t, public device_single_card_slot public: // construction/destruction - uts_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + uts_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> uts_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : uts_keyboard_port_device(mconfig, tag, owner, 0U) + : uts_keyboard_port_device(mconfig, tag, owner) { option_reset(); opts(*this); diff --git a/src/devices/bus/vboy/rom.cpp b/src/devices/bus/vboy/rom.cpp index d2ee88d09e8..d2ca0b80473 100644 --- a/src/devices/bus/vboy/rom.cpp +++ b/src/devices/bus/vboy/rom.cpp @@ -26,13 +26,13 @@ DEFINE_DEVICE_TYPE(VBOY_FLAT_ROM_SRAM, vboy_flat_rom_sram_device, "vboy_flatrom_ // vboy_flat_rom_device //************************************************************************** -vboy_flat_rom_device::vboy_flat_rom_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : +vboy_flat_rom_device::vboy_flat_rom_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : vboy_flat_rom_device(mconfig, VBOY_FLAT_ROM, tag, owner, clock) { } -vboy_flat_rom_device::vboy_flat_rom_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) : +vboy_flat_rom_device::vboy_flat_rom_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_vboy_cart_interface(mconfig, *this) { @@ -91,7 +91,7 @@ void vboy_flat_rom_device::device_start() // vboy_flat_rom_sram_device //************************************************************************** -vboy_flat_rom_sram_device::vboy_flat_rom_sram_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : +vboy_flat_rom_sram_device::vboy_flat_rom_sram_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : vboy_flat_rom_device(mconfig, VBOY_FLAT_ROM_SRAM, tag, owner, clock) { } diff --git a/src/devices/bus/vboy/rom.h b/src/devices/bus/vboy/rom.h index 79ad95f2e9a..a6665da029c 100644 --- a/src/devices/bus/vboy/rom.h +++ b/src/devices/bus/vboy/rom.h @@ -15,13 +15,13 @@ class vboy_flat_rom_device : public device_t, public device_vboy_cart_interface { public: - vboy_flat_rom_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + vboy_flat_rom_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // device_vboy_cart_interface implementation virtual image_init_result load() override ATTR_COLD; protected: - vboy_flat_rom_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + vboy_flat_rom_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device_t implementation virtual void device_start() override ATTR_COLD; @@ -31,7 +31,7 @@ protected: class vboy_flat_rom_sram_device : public vboy_flat_rom_device { public: - vboy_flat_rom_sram_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + vboy_flat_rom_sram_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // device_vboy_cart_interface implementation virtual image_init_result load() override ATTR_COLD; diff --git a/src/devices/bus/vboy/slot.cpp b/src/devices/bus/vboy/slot.cpp index 65ecdfa8f88..09b9037fd93 100644 --- a/src/devices/bus/vboy/slot.cpp +++ b/src/devices/bus/vboy/slot.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(VBOY_CART_SLOT, vboy_cart_slot_device, "vboy_cart_slot", "Nin // vboy_cart_slot_device //************************************************************************** -vboy_cart_slot_device::vboy_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : +vboy_cart_slot_device::vboy_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VBOY_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_vboy_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/vboy/slot.h b/src/devices/bus/vboy/slot.h index b628db8af0d..f413b2b943a 100644 --- a/src/devices/bus/vboy/slot.h +++ b/src/devices/bus/vboy/slot.h @@ -89,14 +89,14 @@ class vboy_cart_slot_device : public: template <typename T> vboy_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) : - vboy_cart_slot_device(mconfig, tag, owner, 0U) + vboy_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - vboy_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0U); + vboy_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration auto intcro() { return m_intcro.bind(); } diff --git a/src/devices/bus/vc4000/rom.cpp b/src/devices/bus/vc4000/rom.cpp index ffd9a21ffb5..8d17e587897 100644 --- a/src/devices/bus/vc4000/rom.cpp +++ b/src/devices/bus/vc4000/rom.cpp @@ -198,27 +198,27 @@ DEFINE_DEVICE_TYPE(VC4000_ROM_RAM1K, vc4000_ram1k_device, "vc4000_ram1k", "VC DEFINE_DEVICE_TYPE(VC4000_ROM_CHESS2, vc4000_chess2_device, "vc4000_chess2", "VC 4000 Chess II Cart") -vc4000_rom_device::vc4000_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vc4000_rom_device::vc4000_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_vc4000_cart_interface(mconfig, *this) { } -vc4000_rom_device::vc4000_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vc4000_rom_device::vc4000_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vc4000_rom_device(mconfig, VC4000_ROM_STD, tag, owner, clock) { } -vc4000_rom4k_device::vc4000_rom4k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vc4000_rom4k_device::vc4000_rom4k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vc4000_rom_device(mconfig, VC4000_ROM_ROM4K, tag, owner, clock) { } -vc4000_ram1k_device::vc4000_ram1k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vc4000_ram1k_device::vc4000_ram1k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vc4000_rom_device(mconfig, VC4000_ROM_RAM1K, tag, owner, clock) { } -vc4000_chess2_device::vc4000_chess2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vc4000_chess2_device::vc4000_chess2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vc4000_rom_device(mconfig, VC4000_ROM_CHESS2, tag, owner, clock) { } diff --git a/src/devices/bus/vc4000/rom.h b/src/devices/bus/vc4000/rom.h index 623e4c248c9..9b31e62663a 100644 --- a/src/devices/bus/vc4000/rom.h +++ b/src/devices/bus/vc4000/rom.h @@ -13,13 +13,13 @@ class vc4000_rom_device : public device_t, { public: // construction/destruction - vc4000_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vc4000_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; protected: - vc4000_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vc4000_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -32,7 +32,7 @@ class vc4000_rom4k_device : public vc4000_rom_device { public: // construction/destruction - vc4000_rom4k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vc4000_rom4k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> vc4000_ram1k_device @@ -41,7 +41,7 @@ class vc4000_ram1k_device : public vc4000_rom_device { public: // construction/destruction - vc4000_ram1k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vc4000_ram1k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_ram(offs_t offset) override; @@ -54,7 +54,7 @@ class vc4000_chess2_device : public vc4000_rom_device { public: // construction/destruction - vc4000_chess2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vc4000_chess2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t extra_rom(offs_t offset) override; diff --git a/src/devices/bus/vc4000/slot.cpp b/src/devices/bus/vc4000/slot.cpp index 4c8f2dd77c4..d9821be5af4 100644 --- a/src/devices/bus/vc4000/slot.cpp +++ b/src/devices/bus/vc4000/slot.cpp @@ -72,7 +72,7 @@ void device_vc4000_cart_interface::ram_alloc(uint32_t size) //------------------------------------------------- // vc4000_cart_slot_device - constructor //------------------------------------------------- -vc4000_cart_slot_device::vc4000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vc4000_cart_slot_device::vc4000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vc4000_cart_slot_device(mconfig, VC4000_CART_SLOT, tag, owner, clock) { } @@ -113,7 +113,7 @@ void vc4000_cart_slot_device::device_start() // trq h-21 slot //------------------------------------------------- -h21_cart_slot_device::h21_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +h21_cart_slot_device::h21_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vc4000_cart_slot_device(mconfig, H21_CART_SLOT, tag, owner, clock) { } diff --git a/src/devices/bus/vc4000/slot.h b/src/devices/bus/vc4000/slot.h index 90f75232699..50f70b0ca1f 100644 --- a/src/devices/bus/vc4000/slot.h +++ b/src/devices/bus/vc4000/slot.h @@ -59,14 +59,14 @@ public: // construction/destruction template <typename T> vc4000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, char const *dflt) - : vc4000_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : vc4000_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - vc4000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vc4000_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~vc4000_cart_slot_device(); // image-level overrides @@ -111,14 +111,14 @@ public: // construction/destruction template <typename T> h21_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, char const *dflt) - : h21_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : h21_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - h21_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h21_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~h21_cart_slot_device(); virtual const char *image_interface() const noexcept override { return "h21_cart"; } diff --git a/src/devices/bus/vcs/compumat.cpp b/src/devices/bus/vcs/compumat.cpp index ff1beac7287..279e57aee4d 100644 --- a/src/devices/bus/vcs/compumat.cpp +++ b/src/devices/bus/vcs/compumat.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(A26_ROM_COMPUMATE, a26_rom_cm_device, "a2600_cm", "Atari 2600 ROM Cart Compumate") -a26_rom_cm_device::a26_rom_cm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_cm_device::a26_rom_cm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_COMPUMATE, tag, owner, clock) , m_bank(*this, "bank") { diff --git a/src/devices/bus/vcs/compumat.h b/src/devices/bus/vcs/compumat.h index 2d16f24db88..16603404bb1 100644 --- a/src/devices/bus/vcs/compumat.h +++ b/src/devices/bus/vcs/compumat.h @@ -17,7 +17,7 @@ class a26_rom_cm_device : public a26_rom_base_device { public: // construction/destruction - a26_rom_cm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_cm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/vcs/dpc.cpp b/src/devices/bus/vcs/dpc.cpp index deb5ba74748..0cc490a857b 100644 --- a/src/devices/bus/vcs/dpc.cpp +++ b/src/devices/bus/vcs/dpc.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(ATARI_DPC, dpc_device, "atari_dpc", "Atari DPC") -dpc_device::dpc_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +dpc_device::dpc_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, ATARI_DPC, tag, owner, clock), m_movamt(0), m_latch_62(0), @@ -234,7 +234,7 @@ void dpc_device::write(offs_t offset, uint8_t data) DEFINE_DEVICE_TYPE(A26_ROM_DPC, a26_rom_dpc_device, "a2600_dpc", "Atari 2600 ROM Cart Pitfall II") -a26_rom_dpc_device::a26_rom_dpc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_dpc_device::a26_rom_dpc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_f8_device(mconfig, A26_ROM_DPC, tag, owner, clock), m_dpc(*this, "dpc") { } @@ -251,7 +251,7 @@ void a26_rom_dpc_device::setup_addon_ptr(uint8_t *ptr) void a26_rom_dpc_device::device_add_mconfig(machine_config &config) { - ATARI_DPC(config, m_dpc, 0); + ATARI_DPC(config, m_dpc); } void a26_rom_dpc_device::install_memory_handlers(address_space *space) diff --git a/src/devices/bus/vcs/dpc.h b/src/devices/bus/vcs/dpc.h index 9bbf4382b95..c26453da073 100644 --- a/src/devices/bus/vcs/dpc.h +++ b/src/devices/bus/vcs/dpc.h @@ -17,7 +17,7 @@ class dpc_device : public device_t { public: // construction/destruction - dpc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dpc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_display_data(uint8_t *data) { m_displaydata = data; } @@ -67,7 +67,7 @@ DECLARE_DEVICE_TYPE(ATARI_DPC, dpc_device) class a26_rom_dpc_device : public a26_rom_f8_device { public: - a26_rom_dpc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_dpc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); required_device<dpc_device> m_dpc; diff --git a/src/devices/bus/vcs/harmony_melody.cpp b/src/devices/bus/vcs/harmony_melody.cpp index 3b3d5385e4a..04c78933d1c 100644 --- a/src/devices/bus/vcs/harmony_melody.cpp +++ b/src/devices/bus/vcs/harmony_melody.cpp @@ -64,7 +64,7 @@ map: DEFINE_DEVICE_TYPE(A26_ROM_HARMONY, a26_rom_harmony_device, "a2600_harmony", "Atari 2600 ROM Cart HARMONY/MELODY") -a26_rom_harmony_device::a26_rom_harmony_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_harmony_device::a26_rom_harmony_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_HARMONY, tag, owner, clock) , m_cpu(*this, "arm") , m_base_bank(0) @@ -81,7 +81,7 @@ void a26_rom_harmony_device::harmony_arm7_map(address_map &map) void a26_rom_harmony_device::device_add_mconfig(machine_config &config) { - LPC2103(config, m_cpu, 70000000); + LPC2103(config, m_cpu, XTAL::u(70000000)); m_cpu->set_addrmap(AS_PROGRAM, &a26_rom_harmony_device::harmony_arm7_map); } diff --git a/src/devices/bus/vcs/harmony_melody.h b/src/devices/bus/vcs/harmony_melody.h index eb23afcbec3..35b88302731 100644 --- a/src/devices/bus/vcs/harmony_melody.h +++ b/src/devices/bus/vcs/harmony_melody.h @@ -14,7 +14,7 @@ class a26_rom_harmony_device : public a26_rom_base_device { public: - a26_rom_harmony_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_harmony_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; diff --git a/src/devices/bus/vcs/rom.cpp b/src/devices/bus/vcs/rom.cpp index f40591e1173..4f30ac56330 100644 --- a/src/devices/bus/vcs/rom.cpp +++ b/src/devices/bus/vcs/rom.cpp @@ -67,7 +67,7 @@ void a26_rom_base_device::write_ram(offs_t offset, uint8_t data) GAMES: a large majority -------------------------------------------------*/ -a26_rom_2k_4k_device::a26_rom_2k_4k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_2k_4k_device::a26_rom_2k_4k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_2K_4K, tag, owner, clock) { } @@ -92,13 +92,13 @@ void a26_rom_2k_4k_device::install_memory_handlers(address_space *space) -------------------------------------------------*/ -a26_rom_f6_device::a26_rom_f6_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a26_rom_f6_device::a26_rom_f6_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, type, tag, owner, clock) , m_bank(*this, "bank") { } -a26_rom_f6_device::a26_rom_f6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_f6_device::a26_rom_f6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_f6_device(mconfig, A26_ROM_F6, tag, owner, clock) { } @@ -141,7 +141,7 @@ void a26_rom_f6_device::switch_bank(offs_t offset, uint8_t data) GAMES: Fatal Run -------------------------------------------------*/ -a26_rom_f4_device::a26_rom_f4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_f4_device::a26_rom_f4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_f6_device(mconfig, A26_ROM_F4, tag, owner, clock) { } @@ -167,12 +167,12 @@ void a26_rom_f4_device::install_memory_handlers(address_space *space) -------------------------------------------------*/ -a26_rom_f8_device::a26_rom_f8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +a26_rom_f8_device::a26_rom_f8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_f6_device(mconfig, type, tag, owner, clock) { } -a26_rom_f8_device::a26_rom_f8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_f8_device::a26_rom_f8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_f8_device(mconfig, A26_ROM_F8, tag, owner, clock) { } @@ -188,7 +188,7 @@ void a26_rom_f8_device::install_memory_handlers(address_space *space) } -a26_rom_f8_sw_device::a26_rom_f8_sw_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_f8_sw_device::a26_rom_f8_sw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_f8_device(mconfig, A26_ROM_F8_SW, tag, owner, clock) { } @@ -206,7 +206,7 @@ a26_rom_f8_sw_device::a26_rom_f8_sw_device(const machine_config &mconfig, const -------------------------------------------------*/ -a26_rom_fa_device::a26_rom_fa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_fa_device::a26_rom_fa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_f6_device(mconfig, A26_ROM_FA, tag, owner, clock) { } @@ -233,7 +233,7 @@ void a26_rom_fa_device::install_memory_handlers(address_space *space) -------------------------------------------------*/ -a26_rom_fe_device::a26_rom_fe_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_fe_device::a26_rom_fe_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_FE, tag, owner, clock) , m_bank(*this, "bank") , m_trigger_on_next_access(false) @@ -311,7 +311,7 @@ void a26_rom_fe_device::trigger_bank() -------------------------------------------------*/ -a26_rom_3e_device::a26_rom_3e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_3e_device::a26_rom_3e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_3E, tag, owner, clock) , m_rom_bank(*this, "rom_bank") , m_ram_bank(*this, "ram_bank") @@ -374,7 +374,7 @@ void a26_rom_3e_device::select_rom_bank(offs_t address, uint8_t data) -------------------------------------------------*/ -a26_rom_3f_device::a26_rom_3f_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_3f_device::a26_rom_3f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_3F, tag, owner, clock) , m_bank(*this, "bank") , m_bank_mask(0) @@ -415,7 +415,7 @@ void a26_rom_3f_device::select_bank(offs_t offset, uint8_t data) -------------------------------------------------*/ -a26_rom_e0_device::a26_rom_e0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_e0_device::a26_rom_e0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_E0, tag, owner, clock) , m_bank(*this, "bank%u", 0U) { @@ -477,7 +477,7 @@ void a26_rom_e0_device::switch_bank(offs_t offset, uint8_t data) -------------------------------------------------*/ -a26_rom_e7_device::a26_rom_e7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_e7_device::a26_rom_e7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_E7, tag, owner, clock) , m_rom_bank(*this, "rom_bank") , m_lo_ram_bank(*this, "low_ram") @@ -541,7 +541,7 @@ void a26_rom_e7_device::switch_ram_bank(offs_t offset, uint8_t data) -------------------------------------------------*/ -a26_rom_ua_device::a26_rom_ua_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_ua_device::a26_rom_ua_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_UA, tag, owner, clock) , m_bank(*this, "bank") { @@ -579,7 +579,7 @@ void a26_rom_ua_device::change_bank(offs_t offset) -------------------------------------------------*/ -a26_rom_cv_device::a26_rom_cv_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_cv_device::a26_rom_cv_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_CV, tag, owner, clock) { } @@ -603,7 +603,7 @@ void a26_rom_cv_device::install_memory_handlers(address_space *space) -------------------------------------------------*/ -a26_rom_dc_device::a26_rom_dc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_dc_device::a26_rom_dc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_DC, tag, owner, clock) , m_bank(*this, "bank") { @@ -645,7 +645,7 @@ void a26_rom_dc_device::switch_bank(offs_t offset, uint8_t data) -------------------------------------------------*/ -a26_rom_fv_device::a26_rom_fv_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_fv_device::a26_rom_fv_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_FV, tag, owner, clock) , m_bank(*this, "bank") { @@ -682,7 +682,7 @@ void a26_rom_fv_device::switch_bank(offs_t offset, uint8_t data) -------------------------------------------------*/ -a26_rom_jvp_device::a26_rom_jvp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_jvp_device::a26_rom_jvp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_JVP, tag, owner, clock) , m_bank(*this, "bank") { @@ -721,7 +721,7 @@ void a26_rom_jvp_device::change_bank() -------------------------------------------------*/ -a26_rom_4in1_device::a26_rom_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_4in1_device::a26_rom_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_4IN1, tag, owner, clock) , m_bank(*this, "bank") , m_current_game(0) @@ -758,7 +758,7 @@ void a26_rom_4in1_device::install_memory_handlers(address_space *space) -------------------------------------------------*/ -a26_rom_8in1_device::a26_rom_8in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_8in1_device::a26_rom_8in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_8IN1, tag, owner, clock) , m_bank(*this, "bank") { @@ -803,7 +803,7 @@ void a26_rom_8in1_device::switch_bank(offs_t offset, uint8_t data) -------------------------------------------------*/ -a26_rom_32in1_device::a26_rom_32in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_32in1_device::a26_rom_32in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_32IN1, tag, owner, clock) , m_bank(*this, "bank") , m_current_game(0) @@ -838,7 +838,7 @@ void a26_rom_32in1_device::install_memory_handlers(address_space *space) http://blog.kevtris.org/blogfiles/Atari%202600%20Mappers.txt --------------------------------------------------*/ -a26_rom_x07_device::a26_rom_x07_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +a26_rom_x07_device::a26_rom_x07_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_X07, tag, owner, clock) , m_bank(*this, "bank") { diff --git a/src/devices/bus/vcs/rom.h b/src/devices/bus/vcs/rom.h index 039a0d4ca1d..989f3526b44 100644 --- a/src/devices/bus/vcs/rom.h +++ b/src/devices/bus/vcs/rom.h @@ -14,7 +14,7 @@ class a26_rom_base_device : public device_t, public device_vcs_cart_interface { protected: - a26_rom_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + a26_rom_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_vcs_cart_interface(mconfig, *this) { } @@ -41,12 +41,12 @@ public: class a26_rom_f6_device : public a26_rom_base_device { public: - a26_rom_f6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_f6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; protected: - a26_rom_f6_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a26_rom_f6_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void install_super_chip_handlers(address_space *space); virtual void device_reset() override; @@ -62,7 +62,7 @@ protected: class a26_rom_f4_device : public a26_rom_f6_device { public: - a26_rom_f4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_f4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -76,12 +76,12 @@ protected: class a26_rom_f8_device : public a26_rom_f6_device { public: - a26_rom_f8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_f8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; protected: - a26_rom_f8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + a26_rom_f8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; @@ -90,7 +90,7 @@ protected: class a26_rom_f8_sw_device : public a26_rom_f8_device { public: - a26_rom_f8_sw_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_f8_sw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // Snow White proto starts from bank 1 @@ -103,7 +103,7 @@ protected: class a26_rom_fa_device : public a26_rom_f6_device { public: - a26_rom_fa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_fa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; }; @@ -114,7 +114,7 @@ public: class a26_rom_fe_device : public a26_rom_base_device { public: - a26_rom_fe_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_fe_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -135,7 +135,7 @@ protected: class a26_rom_3e_device : public a26_rom_base_device { public: - a26_rom_3e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_3e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -157,7 +157,7 @@ protected: class a26_rom_3f_device : public a26_rom_base_device { public: - a26_rom_3f_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_3f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -175,7 +175,7 @@ protected: class a26_rom_e0_device : public a26_rom_base_device { public: - a26_rom_e0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_e0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -192,7 +192,7 @@ protected: class a26_rom_e7_device : public a26_rom_base_device { public: - a26_rom_e7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_e7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -213,7 +213,7 @@ protected: class a26_rom_ua_device : public a26_rom_base_device { public: - a26_rom_ua_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_ua_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -230,7 +230,7 @@ protected: class a26_rom_cv_device : public a26_rom_base_device { public: - a26_rom_cv_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_cv_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; }; @@ -241,7 +241,7 @@ public: class a26_rom_dc_device : public a26_rom_base_device { public: - a26_rom_dc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_dc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -259,7 +259,7 @@ protected: class a26_rom_fv_device : public a26_rom_base_device { public: - a26_rom_fv_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_fv_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -276,7 +276,7 @@ protected: class a26_rom_jvp_device : public a26_rom_base_device { public: - a26_rom_jvp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_jvp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -293,7 +293,7 @@ protected: class a26_rom_4in1_device : public a26_rom_base_device { public: - a26_rom_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_4in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -311,7 +311,7 @@ protected: class a26_rom_8in1_device : public a26_rom_base_device { public: - a26_rom_8in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_8in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -330,7 +330,7 @@ protected: class a26_rom_32in1_device : public a26_rom_base_device { public: - a26_rom_32in1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_32in1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; @@ -348,7 +348,7 @@ protected: class a26_rom_x07_device : public a26_rom_base_device { public: - a26_rom_x07_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_x07_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; diff --git a/src/devices/bus/vcs/scharger.cpp b/src/devices/bus/vcs/scharger.cpp index 1aa1b143328..d337893309a 100644 --- a/src/devices/bus/vcs/scharger.cpp +++ b/src/devices/bus/vcs/scharger.cpp @@ -44,7 +44,7 @@ DEFINE_DEVICE_TYPE(A26_ROM_SUPERCHARGER, a26_rom_ss_device, "a2600_ss", "Atari 2600 ROM Cart Supercharger") -a26_rom_ss_device::a26_rom_ss_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +a26_rom_ss_device::a26_rom_ss_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a26_rom_base_device(mconfig, A26_ROM_SUPERCHARGER, tag, owner, clock), m_cassette(*this, "cassette"), m_data(0), diff --git a/src/devices/bus/vcs/scharger.h b/src/devices/bus/vcs/scharger.h index 25544868ab4..66e4543cfe6 100644 --- a/src/devices/bus/vcs/scharger.h +++ b/src/devices/bus/vcs/scharger.h @@ -17,7 +17,7 @@ class a26_rom_ss_device : public a26_rom_base_device { public: - a26_rom_ss_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + a26_rom_ss_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void install_memory_handlers(address_space *space) override; uint8_t read_lo(offs_t offset); diff --git a/src/devices/bus/vcs/vcs_slot.cpp b/src/devices/bus/vcs/vcs_slot.cpp index 7b9e620c740..4ec8c5552a3 100644 --- a/src/devices/bus/vcs/vcs_slot.cpp +++ b/src/devices/bus/vcs/vcs_slot.cpp @@ -104,7 +104,7 @@ void device_vcs_cart_interface::ram_alloc(uint32_t size) //------------------------------------------------- // vcs_cart_slot_device - constructor //------------------------------------------------- -vcs_cart_slot_device::vcs_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vcs_cart_slot_device::vcs_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VCS_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_vcs_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/vcs/vcs_slot.h b/src/devices/bus/vcs/vcs_slot.h index 4595602961a..b57ef66f575 100644 --- a/src/devices/bus/vcs/vcs_slot.h +++ b/src/devices/bus/vcs/vcs_slot.h @@ -19,14 +19,14 @@ public: // construction/destruction template <typename T> vcs_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : vcs_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : vcs_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - vcs_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + vcs_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~vcs_cart_slot_device(); template <typename T> void set_address_space(T &&tag, int no) { m_address_space.set_tag(std::forward<T>(tag), no); } diff --git a/src/devices/bus/vcs_ctrl/ctrl.cpp b/src/devices/bus/vcs_ctrl/ctrl.cpp index 248fcf2b584..64cf822c7aa 100644 --- a/src/devices/bus/vcs_ctrl/ctrl.cpp +++ b/src/devices/bus/vcs_ctrl/ctrl.cpp @@ -43,7 +43,7 @@ device_vcs_control_port_interface::device_vcs_control_port_interface(const machi // vcs_control_port_device - constructor //------------------------------------------------- -vcs_control_port_device::vcs_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vcs_control_port_device::vcs_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VCS_CONTROL_PORT, tag, owner, clock), device_slot_interface(mconfig, *this), m_device(nullptr), m_write_trigger(*this) diff --git a/src/devices/bus/vcs_ctrl/ctrl.h b/src/devices/bus/vcs_ctrl/ctrl.h index 6e129ba62c9..6b766968e79 100644 --- a/src/devices/bus/vcs_ctrl/ctrl.h +++ b/src/devices/bus/vcs_ctrl/ctrl.h @@ -63,7 +63,7 @@ public: set_default_option(dflt); set_fixed(false); } - vcs_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + vcs_control_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // static configuration helpers auto trigger_wr_callback() { return m_write_trigger.bind(); } diff --git a/src/devices/bus/vcs_ctrl/joybooster.cpp b/src/devices/bus/vcs_ctrl/joybooster.cpp index 933928a0dd0..e3aeb527db2 100644 --- a/src/devices/bus/vcs_ctrl/joybooster.cpp +++ b/src/devices/bus/vcs_ctrl/joybooster.cpp @@ -57,7 +57,7 @@ ioport_constructor vcs_joystick_booster_device::device_input_ports() const // vcs_joystick_booster_device - constructor //------------------------------------------------- -vcs_joystick_booster_device::vcs_joystick_booster_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vcs_joystick_booster_device::vcs_joystick_booster_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VCS_JOYSTICK_BOOSTER, tag, owner, clock), device_vcs_control_port_interface(mconfig, *this), m_joy(*this, "JOY"), diff --git a/src/devices/bus/vcs_ctrl/joybooster.h b/src/devices/bus/vcs_ctrl/joybooster.h index 23f97fdb7a7..2927f8bf43b 100644 --- a/src/devices/bus/vcs_ctrl/joybooster.h +++ b/src/devices/bus/vcs_ctrl/joybooster.h @@ -27,7 +27,7 @@ class vcs_joystick_booster_device : public device_t, { public: // construction/destruction - vcs_joystick_booster_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vcs_joystick_booster_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_vcs_control_port_interface overrides virtual uint8_t vcs_joy_r() override; diff --git a/src/devices/bus/vcs_ctrl/joystick.cpp b/src/devices/bus/vcs_ctrl/joystick.cpp index e68ec423d67..05a3130d041 100644 --- a/src/devices/bus/vcs_ctrl/joystick.cpp +++ b/src/devices/bus/vcs_ctrl/joystick.cpp @@ -48,7 +48,7 @@ ioport_constructor vcs_joystick_device::device_input_ports() const // vcs_joystick_device - constructor //------------------------------------------------- -vcs_joystick_device::vcs_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vcs_joystick_device::vcs_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VCS_JOYSTICK, tag, owner, clock), device_vcs_control_port_interface(mconfig, *this), m_joy(*this, "JOY") diff --git a/src/devices/bus/vcs_ctrl/joystick.h b/src/devices/bus/vcs_ctrl/joystick.h index 1c8f941a633..7f6627b43eb 100644 --- a/src/devices/bus/vcs_ctrl/joystick.h +++ b/src/devices/bus/vcs_ctrl/joystick.h @@ -26,7 +26,7 @@ class vcs_joystick_device : public device_t, { public: // construction/destruction - vcs_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vcs_joystick_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_vcs_control_port_interface overrides virtual uint8_t vcs_joy_r() override; diff --git a/src/devices/bus/vcs_ctrl/keypad.cpp b/src/devices/bus/vcs_ctrl/keypad.cpp index 888cae738f5..5e6644281f2 100644 --- a/src/devices/bus/vcs_ctrl/keypad.cpp +++ b/src/devices/bus/vcs_ctrl/keypad.cpp @@ -54,7 +54,7 @@ ioport_constructor vcs_keypad_device::device_input_ports() const // vcs_keypad_device - constructor //------------------------------------------------- -vcs_keypad_device::vcs_keypad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vcs_keypad_device::vcs_keypad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VCS_KEYPAD, tag, owner, clock), device_vcs_control_port_interface(mconfig, *this), m_keypad(*this, "KEYPAD"), diff --git a/src/devices/bus/vcs_ctrl/keypad.h b/src/devices/bus/vcs_ctrl/keypad.h index 13218b0bf0c..397922687ad 100644 --- a/src/devices/bus/vcs_ctrl/keypad.h +++ b/src/devices/bus/vcs_ctrl/keypad.h @@ -26,7 +26,7 @@ class vcs_keypad_device : public device_t, { public: // construction/destruction - vcs_keypad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vcs_keypad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_vcs_control_port_interface overrides virtual uint8_t vcs_joy_r() override { return ~read_keys(2); } diff --git a/src/devices/bus/vcs_ctrl/lightpen.cpp b/src/devices/bus/vcs_ctrl/lightpen.cpp index b79f447a809..cec693992cd 100644 --- a/src/devices/bus/vcs_ctrl/lightpen.cpp +++ b/src/devices/bus/vcs_ctrl/lightpen.cpp @@ -57,7 +57,7 @@ ioport_constructor vcs_lightpen_device::device_input_ports() const // vcs_lightpen_device - constructor //------------------------------------------------- -vcs_lightpen_device::vcs_lightpen_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vcs_lightpen_device::vcs_lightpen_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VCS_LIGHTPEN, tag, owner, clock), device_vcs_control_port_interface(mconfig, *this), m_joy(*this, "JOY"), diff --git a/src/devices/bus/vcs_ctrl/lightpen.h b/src/devices/bus/vcs_ctrl/lightpen.h index 82c4f06c5aa..8583fbf61a9 100644 --- a/src/devices/bus/vcs_ctrl/lightpen.h +++ b/src/devices/bus/vcs_ctrl/lightpen.h @@ -26,7 +26,7 @@ class vcs_lightpen_device : public device_t, { public: // construction/destruction - vcs_lightpen_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vcs_lightpen_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_vcs_control_port_interface overrides virtual uint8_t vcs_joy_r() override; diff --git a/src/devices/bus/vcs_ctrl/mouse.cpp b/src/devices/bus/vcs_ctrl/mouse.cpp index c1087bb32c1..31a72697e14 100644 --- a/src/devices/bus/vcs_ctrl/mouse.cpp +++ b/src/devices/bus/vcs_ctrl/mouse.cpp @@ -58,7 +58,7 @@ ioport_constructor vcs_mouse_device::device_input_ports() const // vcs_mouse_device - constructor //------------------------------------------------- -vcs_mouse_device::vcs_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vcs_mouse_device::vcs_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VCS_MOUSE, tag, owner, clock), device_vcs_control_port_interface(mconfig, *this), m_joy(*this, "JOY"), diff --git a/src/devices/bus/vcs_ctrl/mouse.h b/src/devices/bus/vcs_ctrl/mouse.h index e90f413f8b3..9f56299174e 100644 --- a/src/devices/bus/vcs_ctrl/mouse.h +++ b/src/devices/bus/vcs_ctrl/mouse.h @@ -26,7 +26,7 @@ class vcs_mouse_device : public device_t, { public: // construction/destruction - vcs_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vcs_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_vcs_control_port_interface overrides virtual uint8_t vcs_joy_r() override; diff --git a/src/devices/bus/vcs_ctrl/paddles.cpp b/src/devices/bus/vcs_ctrl/paddles.cpp index c1dffd6152b..682b7171a15 100644 --- a/src/devices/bus/vcs_ctrl/paddles.cpp +++ b/src/devices/bus/vcs_ctrl/paddles.cpp @@ -67,7 +67,7 @@ ioport_constructor vcs_paddles_device::device_input_ports() const // vcs_paddles_device - constructor //------------------------------------------------- -vcs_paddles_device::vcs_paddles_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vcs_paddles_device::vcs_paddles_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VCS_PADDLES, tag, owner, clock), device_vcs_control_port_interface(mconfig, *this), m_joy(*this, "JOY"), diff --git a/src/devices/bus/vcs_ctrl/paddles.h b/src/devices/bus/vcs_ctrl/paddles.h index 941bea3fc5a..28a1a2c0c24 100644 --- a/src/devices/bus/vcs_ctrl/paddles.h +++ b/src/devices/bus/vcs_ctrl/paddles.h @@ -26,7 +26,7 @@ class vcs_paddles_device : public device_t, { public: // construction/destruction - vcs_paddles_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vcs_paddles_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void reverse_players(device_t *device) { downcast<vcs_paddles_device &>(*device).m_reverse_players = true; } diff --git a/src/devices/bus/vcs_ctrl/wheel.cpp b/src/devices/bus/vcs_ctrl/wheel.cpp index 57c5c9863ed..711c0a07f21 100644 --- a/src/devices/bus/vcs_ctrl/wheel.cpp +++ b/src/devices/bus/vcs_ctrl/wheel.cpp @@ -47,7 +47,7 @@ ioport_constructor vcs_wheel_device::device_input_ports() const // vcs_wheel_device - constructor //------------------------------------------------- -vcs_wheel_device::vcs_wheel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vcs_wheel_device::vcs_wheel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VCS_WHEEL, tag, owner, clock), device_vcs_control_port_interface(mconfig, *this), m_joy(*this, "JOY"), diff --git a/src/devices/bus/vcs_ctrl/wheel.h b/src/devices/bus/vcs_ctrl/wheel.h index 8919e2d2888..8d08c3bf046 100644 --- a/src/devices/bus/vcs_ctrl/wheel.h +++ b/src/devices/bus/vcs_ctrl/wheel.h @@ -26,7 +26,7 @@ class vcs_wheel_device : public device_t, { public: // construction/destruction - vcs_wheel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vcs_wheel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_vcs_control_port_interface overrides virtual uint8_t vcs_joy_r() override; diff --git a/src/devices/bus/vectrex/rom.cpp b/src/devices/bus/vectrex/rom.cpp index 04410dd5623..5d26afabfe5 100644 --- a/src/devices/bus/vectrex/rom.cpp +++ b/src/devices/bus/vectrex/rom.cpp @@ -25,22 +25,22 @@ DEFINE_DEVICE_TYPE(VECTREX_ROM_64K, vectrex_rom64k_device, "vectrex_64k", "Vec DEFINE_DEVICE_TYPE(VECTREX_ROM_SRAM, vectrex_sram_device, "vectrex_sram", "Vectrex Carts w/SRAM") -vectrex_rom_device::vectrex_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vectrex_rom_device::vectrex_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_vectrex_cart_interface(mconfig, *this) { } -vectrex_rom_device::vectrex_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vectrex_rom_device::vectrex_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vectrex_rom_device(mconfig, VECTREX_ROM_STD, tag, owner, clock) { } -vectrex_rom64k_device::vectrex_rom64k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vectrex_rom64k_device::vectrex_rom64k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vectrex_rom_device(mconfig, VECTREX_ROM_64K, tag, owner, clock), m_bank(0) { } -vectrex_sram_device::vectrex_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vectrex_sram_device::vectrex_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vectrex_rom_device(mconfig, VECTREX_ROM_SRAM, tag, owner, clock) { } diff --git a/src/devices/bus/vectrex/rom.h b/src/devices/bus/vectrex/rom.h index dd83f54042c..7fe203fbb6e 100644 --- a/src/devices/bus/vectrex/rom.h +++ b/src/devices/bus/vectrex/rom.h @@ -15,13 +15,13 @@ class vectrex_rom_device : public device_t, { public: // construction/destruction - vectrex_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vectrex_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; protected: - vectrex_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vectrex_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override { } @@ -34,7 +34,7 @@ class vectrex_rom64k_device : public vectrex_rom_device { public: // construction/destruction - vectrex_rom64k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vectrex_rom64k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint8_t read_rom(offs_t offset) override; @@ -55,7 +55,7 @@ class vectrex_sram_device : public vectrex_rom_device { public: // construction/destruction - vectrex_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vectrex_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual void write_ram(offs_t offset, uint8_t data) override; diff --git a/src/devices/bus/vectrex/slot.cpp b/src/devices/bus/vectrex/slot.cpp index 0b527eaeb27..60dddce4280 100644 --- a/src/devices/bus/vectrex/slot.cpp +++ b/src/devices/bus/vectrex/slot.cpp @@ -61,7 +61,7 @@ void device_vectrex_cart_interface::rom_alloc(uint32_t size) //------------------------------------------------- // vectrex_cart_slot_device - constructor //------------------------------------------------- -vectrex_cart_slot_device::vectrex_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vectrex_cart_slot_device::vectrex_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VECTREX_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_vectrex_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/vectrex/slot.h b/src/devices/bus/vectrex/slot.h index 577338f80fa..b559fbc4ad6 100644 --- a/src/devices/bus/vectrex/slot.h +++ b/src/devices/bus/vectrex/slot.h @@ -64,7 +64,7 @@ class vectrex_cart_slot_device : public device_t, { public: // construction/destruction - vectrex_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vectrex_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~vectrex_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/vic10/exp.cpp b/src/devices/bus/vic10/exp.cpp index c09651066ba..3543474c756 100644 --- a/src/devices/bus/vic10/exp.cpp +++ b/src/devices/bus/vic10/exp.cpp @@ -53,7 +53,7 @@ device_vic10_expansion_card_interface::~device_vic10_expansion_card_interface() // vic10_expansion_slot_device - constructor //------------------------------------------------- -vic10_expansion_slot_device::vic10_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vic10_expansion_slot_device::vic10_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC10_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_vic10_expansion_card_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/vic10/exp.h b/src/devices/bus/vic10/exp.h index 36098dfc2cf..aa32f8a7252 100644 --- a/src/devices/bus/vic10/exp.h +++ b/src/devices/bus/vic10/exp.h @@ -55,7 +55,7 @@ class vic10_expansion_slot_device : public device_t, public: // construction/destruction template <typename T> - vic10_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) + vic10_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts, char const *dflt) : vic10_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -63,7 +63,7 @@ public: set_default_option(dflt); set_fixed(false); } - vic10_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic10_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_callback() { return m_write_irq.bind(); } auto res_callback() { return m_write_res.bind(); } diff --git a/src/devices/bus/vic10/multimax.cpp b/src/devices/bus/vic10/multimax.cpp index 98f67a48187..dfef6373aa4 100644 --- a/src/devices/bus/vic10/multimax.cpp +++ b/src/devices/bus/vic10/multimax.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(VIC10_MULTIMAX, vic10_multimax_device, "vic10_multimax", "VIC // vic10_multimax_device - constructor //------------------------------------------------- -vic10_multimax_device::vic10_multimax_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vic10_multimax_device::vic10_multimax_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC10_MULTIMAX, tag, owner, clock), device_vic10_expansion_card_interface(mconfig, *this), m_latch(0) { diff --git a/src/devices/bus/vic10/multimax.h b/src/devices/bus/vic10/multimax.h index 51175fc7bd8..678697c1747 100644 --- a/src/devices/bus/vic10/multimax.h +++ b/src/devices/bus/vic10/multimax.h @@ -25,7 +25,7 @@ class vic10_multimax_device : public device_t, public device_vic10_expansion_car { public: // construction/destruction - vic10_multimax_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic10_multimax_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vic10/std.cpp b/src/devices/bus/vic10/std.cpp index a4eff1853ac..e26e96d3c30 100644 --- a/src/devices/bus/vic10/std.cpp +++ b/src/devices/bus/vic10/std.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(VIC10_STD, vic10_standard_cartridge_device, "vic10_standard", // vic10_standard_cartridge_device - constructor //------------------------------------------------- -vic10_standard_cartridge_device::vic10_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic10_standard_cartridge_device::vic10_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC10_STD, tag, owner, clock), device_vic10_expansion_card_interface(mconfig, *this) { } diff --git a/src/devices/bus/vic10/std.h b/src/devices/bus/vic10/std.h index 3279a58333c..2a14011ae3b 100644 --- a/src/devices/bus/vic10/std.h +++ b/src/devices/bus/vic10/std.h @@ -26,7 +26,7 @@ class vic10_standard_cartridge_device : public device_t, { public: // construction/destruction - vic10_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic10_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vic20/4cga.cpp b/src/devices/bus/vic20/4cga.cpp index f806598433a..0025c44a443 100644 --- a/src/devices/bus/vic20/4cga.cpp +++ b/src/devices/bus/vic20/4cga.cpp @@ -59,7 +59,7 @@ ioport_constructor c64_4cga_device::device_input_ports() const // c64_4cga_device - constructor //------------------------------------------------- -c64_4cga_device::c64_4cga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64_4cga_device::c64_4cga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64_4CGA, tag, owner, clock), device_pet_user_port_interface(mconfig, *this), m_port(0), diff --git a/src/devices/bus/vic20/4cga.h b/src/devices/bus/vic20/4cga.h index b4e1ada9a05..9e63863848e 100644 --- a/src/devices/bus/vic20/4cga.h +++ b/src/devices/bus/vic20/4cga.h @@ -27,7 +27,7 @@ class c64_4cga_device : public device_t, { public: // construction/destruction - c64_4cga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64_4cga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/vic20/exp.cpp b/src/devices/bus/vic20/exp.cpp index 0746b3092da..a84f967499a 100644 --- a/src/devices/bus/vic20/exp.cpp +++ b/src/devices/bus/vic20/exp.cpp @@ -52,7 +52,7 @@ device_vic20_expansion_card_interface::~device_vic20_expansion_card_interface() // vic20_expansion_slot_device - constructor //------------------------------------------------- -vic20_expansion_slot_device::vic20_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vic20_expansion_slot_device::vic20_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC20_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_vic20_expansion_card_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/vic20/exp.h b/src/devices/bus/vic20/exp.h index 124bc7bb9c1..36518a31ce3 100644 --- a/src/devices/bus/vic20/exp.h +++ b/src/devices/bus/vic20/exp.h @@ -54,7 +54,7 @@ class vic20_expansion_slot_device : public device_t, public: // construction/destruction template <typename T> - vic20_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) + vic20_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts, char const *dflt) : vic20_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -62,7 +62,7 @@ public: set_default_option(dflt); set_fixed(false); } - vic20_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic20_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static void add_passthrough(machine_config &config, const char *_tag); diff --git a/src/devices/bus/vic20/fe3.cpp b/src/devices/bus/vic20/fe3.cpp index 230dc076bb4..91a7a9573eb 100644 --- a/src/devices/bus/vic20/fe3.cpp +++ b/src/devices/bus/vic20/fe3.cpp @@ -101,7 +101,7 @@ void vic20_final_expansion_3_device::device_add_mconfig(machine_config &config) // vic20_final_expansion_3_device - constructor //------------------------------------------------- -vic20_final_expansion_3_device::vic20_final_expansion_3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vic20_final_expansion_3_device::vic20_final_expansion_3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC20_FE3, tag, owner, clock), device_vic20_expansion_card_interface(mconfig, *this), m_flash_rom(*this, AM29F040_TAG), diff --git a/src/devices/bus/vic20/fe3.h b/src/devices/bus/vic20/fe3.h index c82fff2f7ee..20619cfb8a0 100644 --- a/src/devices/bus/vic20/fe3.h +++ b/src/devices/bus/vic20/fe3.h @@ -27,7 +27,7 @@ class vic20_final_expansion_3_device : public device_t, { public: // construction/destruction - vic20_final_expansion_3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic20_final_expansion_3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vic20/megacart.cpp b/src/devices/bus/vic20/megacart.cpp index 21171bf4343..44c89fdd62c 100644 --- a/src/devices/bus/vic20/megacart.cpp +++ b/src/devices/bus/vic20/megacart.cpp @@ -35,7 +35,7 @@ void vic20_megacart_device::device_add_mconfig(machine_config &config) // vic20_megacart_device - constructor //------------------------------------------------- -vic20_megacart_device::vic20_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic20_megacart_device::vic20_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC20_MEGACART, tag, owner, clock) , device_vic20_expansion_card_interface(mconfig, *this) , device_nvram_interface(mconfig, *this) diff --git a/src/devices/bus/vic20/megacart.h b/src/devices/bus/vic20/megacart.h index e1c691a9a4b..05adc6ac641 100644 --- a/src/devices/bus/vic20/megacart.h +++ b/src/devices/bus/vic20/megacart.h @@ -27,7 +27,7 @@ class vic20_megacart_device : public device_t, { public: // construction/destruction - vic20_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic20_megacart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vic20/speakeasy.cpp b/src/devices/bus/vic20/speakeasy.cpp index 6128852d540..5401592c783 100644 --- a/src/devices/bus/vic20/speakeasy.cpp +++ b/src/devices/bus/vic20/speakeasy.cpp @@ -37,7 +37,7 @@ void vic20_speakeasy_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "mono").front_center(); - VOTRAX_SC01(config, m_votrax, 720000).add_route(ALL_OUTPUTS, "mono", 0.85); + VOTRAX_SC01(config, m_votrax, XTAL::u(720000)).add_route(ALL_OUTPUTS, "mono", 0.85); } @@ -50,7 +50,7 @@ void vic20_speakeasy_device::device_add_mconfig(machine_config &config) // vic20_speakeasy_device - constructor //------------------------------------------------- -vic20_speakeasy_device::vic20_speakeasy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vic20_speakeasy_device::vic20_speakeasy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC20_SPEAKEASY, tag, owner, clock), device_vic20_expansion_card_interface(mconfig, *this), m_votrax(*this, SC01A_TAG) diff --git a/src/devices/bus/vic20/speakeasy.h b/src/devices/bus/vic20/speakeasy.h index 6df3880d2df..9bbcba26c67 100644 --- a/src/devices/bus/vic20/speakeasy.h +++ b/src/devices/bus/vic20/speakeasy.h @@ -28,7 +28,7 @@ class vic20_speakeasy_device : public device_t, { public: // construction/destruction - vic20_speakeasy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic20_speakeasy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vic20/std.cpp b/src/devices/bus/vic20/std.cpp index 988540719d8..77f1d54eda0 100644 --- a/src/devices/bus/vic20/std.cpp +++ b/src/devices/bus/vic20/std.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(VIC20_STD, vic20_standard_cartridge_device, "vic20_standard", // vic20_standard_cartridge_device - constructor //------------------------------------------------- -vic20_standard_cartridge_device::vic20_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic20_standard_cartridge_device::vic20_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC20_STD, tag, owner, clock), device_vic20_expansion_card_interface(mconfig, *this) { } diff --git a/src/devices/bus/vic20/std.h b/src/devices/bus/vic20/std.h index 0318f80aa54..f07040551e1 100644 --- a/src/devices/bus/vic20/std.h +++ b/src/devices/bus/vic20/std.h @@ -26,7 +26,7 @@ class vic20_standard_cartridge_device : public device_t, { public: // construction/destruction - vic20_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic20_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vic20/vic1010.cpp b/src/devices/bus/vic20/vic1010.cpp index 651ac37156e..a5429a7a51f 100644 --- a/src/devices/bus/vic20/vic1010.cpp +++ b/src/devices/bus/vic20/vic1010.cpp @@ -41,7 +41,7 @@ void vic1010_device::device_add_mconfig(machine_config &config) // vic1010_device - constructor //------------------------------------------------- -vic1010_device::vic1010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic1010_device::vic1010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC1010, tag, owner, clock) , device_vic20_expansion_card_interface(mconfig, *this) , m_expansion_slot(*this, "slot%u", 1) diff --git a/src/devices/bus/vic20/vic1010.h b/src/devices/bus/vic20/vic1010.h index af85f4bfc3c..f4a7bbdf08b 100644 --- a/src/devices/bus/vic20/vic1010.h +++ b/src/devices/bus/vic20/vic1010.h @@ -26,7 +26,7 @@ class vic1010_device : public device_t, { public: // construction/destruction - vic1010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic1010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vic20/vic1011.cpp b/src/devices/bus/vic20/vic1011.cpp index 893536a5b09..bd20cb1b7d1 100644 --- a/src/devices/bus/vic20/vic1011.cpp +++ b/src/devices/bus/vic20/vic1011.cpp @@ -40,7 +40,7 @@ void vic1011_device::device_add_mconfig(machine_config &config) // vic1011_device - constructor //------------------------------------------------- -vic1011_device::vic1011_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic1011_device::vic1011_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC1011, tag, owner, clock) , device_pet_user_port_interface(mconfig, *this) , m_rs232(*this, "rs232") diff --git a/src/devices/bus/vic20/vic1011.h b/src/devices/bus/vic20/vic1011.h index e13bc6550ba..6d3bbfe1dcc 100644 --- a/src/devices/bus/vic20/vic1011.h +++ b/src/devices/bus/vic20/vic1011.h @@ -26,7 +26,7 @@ class vic1011_device : public device_t, public device_pet_user_port_interface { public: // construction/destruction - vic1011_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic1011_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_pet_user_port_interface overrides virtual DECLARE_WRITE_LINE_MEMBER( input_d ) override; diff --git a/src/devices/bus/vic20/vic1110.cpp b/src/devices/bus/vic20/vic1110.cpp index f9ee69fd8b1..efc690509fd 100644 --- a/src/devices/bus/vic20/vic1110.cpp +++ b/src/devices/bus/vic20/vic1110.cpp @@ -66,7 +66,7 @@ ioport_constructor vic1110_device::device_input_ports() const // vic1110_device - constructor //------------------------------------------------- -vic1110_device::vic1110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic1110_device::vic1110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC1110, tag, owner, clock) , device_vic20_expansion_card_interface(mconfig, *this) , m_ram(*this, "ram", 0x2000, ENDIANNESS_LITTLE) diff --git a/src/devices/bus/vic20/vic1110.h b/src/devices/bus/vic20/vic1110.h index 831bc478bf4..bb4e194cdb2 100644 --- a/src/devices/bus/vic20/vic1110.h +++ b/src/devices/bus/vic20/vic1110.h @@ -26,7 +26,7 @@ class vic1110_device : public device_t, { public: // construction/destruction - vic1110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic1110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/vic20/vic1111.cpp b/src/devices/bus/vic20/vic1111.cpp index 4bb3a492ef2..cd56b5780b3 100644 --- a/src/devices/bus/vic20/vic1111.cpp +++ b/src/devices/bus/vic20/vic1111.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(VIC1111, vic1111_device, "vic1111", "VIC-1111 16K RAM Expansi // vic1111_device - constructor //------------------------------------------------- -vic1111_device::vic1111_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic1111_device::vic1111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC1111, tag, owner, clock) , device_vic20_expansion_card_interface(mconfig, *this) , m_ram(*this, "ram", 0x4000, ENDIANNESS_LITTLE) diff --git a/src/devices/bus/vic20/vic1111.h b/src/devices/bus/vic20/vic1111.h index 7d391875732..80b8e1218d8 100644 --- a/src/devices/bus/vic20/vic1111.h +++ b/src/devices/bus/vic20/vic1111.h @@ -26,7 +26,7 @@ class vic1111_device : public device_t, { public: // construction/destruction - vic1111_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic1111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vic20/vic1112.cpp b/src/devices/bus/vic20/vic1112.cpp index ce878ee5f9f..a17638efa44 100644 --- a/src/devices/bus/vic20/vic1112.cpp +++ b/src/devices/bus/vic20/vic1112.cpp @@ -111,7 +111,7 @@ void vic1112_device::device_add_mconfig(machine_config &config) m_via1->cb2_handler().set(IEEE488_TAG, FUNC(ieee488_device::host_eoi_w)); m_via1->irq_handler().set(FUNC(vic1112_device::via1_irq_w)); - IEEE488(config, m_bus, 0); + IEEE488(config, m_bus); ieee488_slot_device::add_cbm_defaults(config, nullptr); m_bus->srq_callback().set(m_via1, FUNC(via6522_device::write_cb1)); } @@ -126,7 +126,7 @@ void vic1112_device::device_add_mconfig(machine_config &config) // vic1112_device - constructor //------------------------------------------------- -vic1112_device::vic1112_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic1112_device::vic1112_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC1112, tag, owner, clock) , device_vic20_expansion_card_interface(mconfig, *this) , m_via0(*this, M6522_0_TAG) diff --git a/src/devices/bus/vic20/vic1112.h b/src/devices/bus/vic20/vic1112.h index 8353ad2390d..37d23586a27 100644 --- a/src/devices/bus/vic20/vic1112.h +++ b/src/devices/bus/vic20/vic1112.h @@ -31,7 +31,7 @@ class vic1112_device : public device_t, { public: // construction/destruction - vic1112_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic1112_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vic20/vic1210.cpp b/src/devices/bus/vic20/vic1210.cpp index 88c94e8fbbd..fe7bfbb1cbd 100644 --- a/src/devices/bus/vic20/vic1210.cpp +++ b/src/devices/bus/vic20/vic1210.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(VIC1210, vic1210_device, "vic1210", "VIC-1210 3K RAM Expansio // vic1210_device - constructor //------------------------------------------------- -vic1210_device::vic1210_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic1210_device::vic1210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC1210, tag, owner, clock) , device_vic20_expansion_card_interface(mconfig, *this) , m_ram(*this, "ram", 0xc00, ENDIANNESS_LITTLE) diff --git a/src/devices/bus/vic20/vic1210.h b/src/devices/bus/vic20/vic1210.h index 9f20f9164ad..7dedfc838bc 100644 --- a/src/devices/bus/vic20/vic1210.h +++ b/src/devices/bus/vic20/vic1210.h @@ -27,7 +27,7 @@ class vic1210_device : public device_t, { public: // construction/destruction - vic1210_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic1210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vic20/videopak.cpp b/src/devices/bus/vic20/videopak.cpp index 542c2fb8320..4a0e4798e23 100644 --- a/src/devices/bus/vic20/videopak.cpp +++ b/src/devices/bus/vic20/videopak.cpp @@ -125,7 +125,7 @@ void vic20_video_pak_device::device_add_mconfig(machine_config &config) // vic20_video_pak_device - constructor //------------------------------------------------- -vic20_video_pak_device::vic20_video_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vic20_video_pak_device::vic20_video_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC20_VIDEO_PAK, tag, owner, clock), device_vic20_expansion_card_interface(mconfig, *this), m_crtc(*this, MC6845_TAG), diff --git a/src/devices/bus/vic20/videopak.h b/src/devices/bus/vic20/videopak.h index d87b04d35c1..75af909654f 100644 --- a/src/devices/bus/vic20/videopak.h +++ b/src/devices/bus/vic20/videopak.h @@ -30,7 +30,7 @@ class vic20_video_pak_device : public device_t, { public: // construction/destruction - vic20_video_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic20_video_pak_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vidbrain/exp.cpp b/src/devices/bus/vidbrain/exp.cpp index 42cd7ebe9ba..ddfa6c75c4b 100644 --- a/src/devices/bus/vidbrain/exp.cpp +++ b/src/devices/bus/vidbrain/exp.cpp @@ -79,7 +79,7 @@ uint8_t* device_videobrain_expansion_card_interface::videobrain_ram_pointer(runn // videobrain_expansion_slot_device - constructor //------------------------------------------------- -videobrain_expansion_slot_device::videobrain_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +videobrain_expansion_slot_device::videobrain_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIDEOBRAIN_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_videobrain_expansion_card_interface>(mconfig, *this), device_cartrom_image_interface(mconfig, *this), diff --git a/src/devices/bus/vidbrain/exp.h b/src/devices/bus/vidbrain/exp.h index a72cc410adc..a0fd3882124 100644 --- a/src/devices/bus/vidbrain/exp.h +++ b/src/devices/bus/vidbrain/exp.h @@ -90,14 +90,14 @@ public: // construction/destruction template <typename T> videobrain_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, char const* dflt) - : videobrain_expansion_slot_device(mconfig, tag, owner, 0) + : videobrain_expansion_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - videobrain_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + videobrain_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto extres_wr_callback() { return m_write_extres.bind(); } diff --git a/src/devices/bus/vidbrain/money_minder.cpp b/src/devices/bus/vidbrain/money_minder.cpp index b0f4826ca5d..690f0ec2424 100644 --- a/src/devices/bus/vidbrain/money_minder.cpp +++ b/src/devices/bus/vidbrain/money_minder.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(VB_MONEY_MINDER, videobrain_money_minder_cartridge_device, "v // videobrain_money_minder_cartridge_device - constructor //------------------------------------------------- -videobrain_money_minder_cartridge_device::videobrain_money_minder_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +videobrain_money_minder_cartridge_device::videobrain_money_minder_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VB_MONEY_MINDER, tag, owner, clock), device_videobrain_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/vidbrain/money_minder.h b/src/devices/bus/vidbrain/money_minder.h index 23f219c4962..5df7cd20669 100644 --- a/src/devices/bus/vidbrain/money_minder.h +++ b/src/devices/bus/vidbrain/money_minder.h @@ -26,7 +26,7 @@ class videobrain_money_minder_cartridge_device : public device_t, { public: // construction/destruction - videobrain_money_minder_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + videobrain_money_minder_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vidbrain/std.cpp b/src/devices/bus/vidbrain/std.cpp index 55b5c3ce22d..598418a96b1 100644 --- a/src/devices/bus/vidbrain/std.cpp +++ b/src/devices/bus/vidbrain/std.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(VB_STD, videobrain_standard_cartridge_device, "vb_std", "Vide // videobrain_standard_cartridge_device - constructor //------------------------------------------------- -videobrain_standard_cartridge_device::videobrain_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +videobrain_standard_cartridge_device::videobrain_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VB_STD, tag, owner, clock), device_videobrain_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/vidbrain/std.h b/src/devices/bus/vidbrain/std.h index 7939501909f..5c6147fd33b 100644 --- a/src/devices/bus/vidbrain/std.h +++ b/src/devices/bus/vidbrain/std.h @@ -26,7 +26,7 @@ class videobrain_standard_cartridge_device : public device_t, { public: // construction/destruction - videobrain_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + videobrain_standard_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vidbrain/timeshare.cpp b/src/devices/bus/vidbrain/timeshare.cpp index 709f16f5c74..29edfaa1858 100644 --- a/src/devices/bus/vidbrain/timeshare.cpp +++ b/src/devices/bus/vidbrain/timeshare.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(VB_TIMESHARE, videobrain_timeshare_cartridge_device, "vb_time // videobrain_timeshare_cartridge_device - constructor //------------------------------------------------- -videobrain_timeshare_cartridge_device::videobrain_timeshare_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +videobrain_timeshare_cartridge_device::videobrain_timeshare_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VB_TIMESHARE, tag, owner, clock), device_videobrain_expansion_card_interface(mconfig, *this) { diff --git a/src/devices/bus/vidbrain/timeshare.h b/src/devices/bus/vidbrain/timeshare.h index 7885772149d..1cdaae9059c 100644 --- a/src/devices/bus/vidbrain/timeshare.h +++ b/src/devices/bus/vidbrain/timeshare.h @@ -26,7 +26,7 @@ class videobrain_timeshare_cartridge_device : public device_t, { public: // construction/destruction - videobrain_timeshare_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + videobrain_timeshare_cartridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vip/byteio.cpp b/src/devices/bus/vip/byteio.cpp index 83236247ae7..744c5016d87 100644 --- a/src/devices/bus/vip/byteio.cpp +++ b/src/devices/bus/vip/byteio.cpp @@ -43,7 +43,7 @@ device_vip_byteio_port_interface::device_vip_byteio_port_interface(const machine // vip_byteio_port_device - constructor //------------------------------------------------- -vip_byteio_port_device::vip_byteio_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vip_byteio_port_device::vip_byteio_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIP_BYTEIO_PORT, tag, owner, clock), device_single_card_slot_interface<device_vip_byteio_port_interface>(mconfig, *this), m_write_inst(*this), diff --git a/src/devices/bus/vip/byteio.h b/src/devices/bus/vip/byteio.h index 5cca82aea45..829d3ed1982 100644 --- a/src/devices/bus/vip/byteio.h +++ b/src/devices/bus/vip/byteio.h @@ -59,7 +59,7 @@ public: // construction/destruction template <typename T> vip_byteio_port_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : vip_byteio_port_device(mconfig, tag, owner, 0) + : vip_byteio_port_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -67,7 +67,7 @@ public: set_fixed(false); } - vip_byteio_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + vip_byteio_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto inst_callback() { return m_write_inst.bind(); } diff --git a/src/devices/bus/vip/exp.cpp b/src/devices/bus/vip/exp.cpp index f6abf579f18..b6751fc26c3 100644 --- a/src/devices/bus/vip/exp.cpp +++ b/src/devices/bus/vip/exp.cpp @@ -51,7 +51,7 @@ device_vip_expansion_card_interface::device_vip_expansion_card_interface(const m // vip_expansion_slot_device - constructor //------------------------------------------------- -vip_expansion_slot_device::vip_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vip_expansion_slot_device::vip_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIP_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_vip_expansion_card_interface>(mconfig, *this), m_write_int(*this), diff --git a/src/devices/bus/vip/exp.h b/src/devices/bus/vip/exp.h index aa50074e9ca..ec7065d6ead 100644 --- a/src/devices/bus/vip/exp.h +++ b/src/devices/bus/vip/exp.h @@ -52,7 +52,7 @@ class vip_expansion_slot_device : public device_t, public device_single_card_slo public: // construction/destruction template <typename T> - vip_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock, T &&opts, char const *dflt) + vip_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, T &&opts, char const *dflt) : vip_expansion_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -60,7 +60,7 @@ public: set_default_option(dflt); set_fixed(false); } - vip_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vip_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto int_wr_callback() { return m_write_int.bind(); } auto dma_out_wr_callback() { return m_write_dma_out.bind(); } diff --git a/src/devices/bus/vip/vp550.cpp b/src/devices/bus/vip/vp550.cpp index 4fc501154da..e3e2e2f88fd 100644 --- a/src/devices/bus/vip/vp550.cpp +++ b/src/devices/bus/vip/vp550.cpp @@ -32,11 +32,11 @@ void vp550_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "mono").front_center(); - CDP1863(config, m_pfg[0], 0); + CDP1863(config, m_pfg[0]); m_pfg[0]->set_clock2(0); m_pfg[0]->add_route(ALL_OUTPUTS, "mono", 1.0); - CDP1863(config, m_pfg[1], 0); + CDP1863(config, m_pfg[1]); m_pfg[1]->set_clock2(0); m_pfg[1]->add_route(ALL_OUTPUTS, "mono", 1.0); } @@ -51,7 +51,7 @@ void vp550_device::device_add_mconfig(machine_config &config) // vp550_device - constructor //------------------------------------------------- -vp550_device::vp550_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vp550_device::vp550_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VP550, tag, owner, clock), device_vip_expansion_card_interface(mconfig, *this), m_pfg(*this, "u%u", 1U), diff --git a/src/devices/bus/vip/vp550.h b/src/devices/bus/vip/vp550.h index c7f629bbf9d..8ef8bc70398 100644 --- a/src/devices/bus/vip/vp550.h +++ b/src/devices/bus/vip/vp550.h @@ -27,7 +27,7 @@ class vp550_device : public device_t, { public: // construction/destruction - vp550_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vp550_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vip/vp570.cpp b/src/devices/bus/vip/vp570.cpp index f2e32dffd35..cd81d9121d9 100644 --- a/src/devices/bus/vip/vp570.cpp +++ b/src/devices/bus/vip/vp570.cpp @@ -60,7 +60,7 @@ ioport_constructor vp570_device::device_input_ports() const // vp570_device - constructor //------------------------------------------------- -vp570_device::vp570_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vp570_device::vp570_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VP570, tag, owner, clock), device_vip_expansion_card_interface(mconfig, *this), m_ram(*this, "ram", 0x1000, ENDIANNESS_LITTLE), diff --git a/src/devices/bus/vip/vp570.h b/src/devices/bus/vip/vp570.h index 2f026bd1eac..0387500bdfa 100644 --- a/src/devices/bus/vip/vp570.h +++ b/src/devices/bus/vip/vp570.h @@ -26,7 +26,7 @@ class vp570_device : public device_t, { public: // construction/destruction - vp570_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vp570_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/vip/vp575.cpp b/src/devices/bus/vip/vp575.cpp index 685c05be7c6..57ba7ba7dd1 100644 --- a/src/devices/bus/vip/vp575.cpp +++ b/src/devices/bus/vip/vp575.cpp @@ -83,7 +83,7 @@ void vp575_device::device_add_mconfig(machine_config &config) // vp575_device - constructor //------------------------------------------------- -vp575_device::vp575_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vp575_device::vp575_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VP575, tag, owner, clock), device_vip_expansion_card_interface(mconfig, *this), m_expansion_slot(*this, "exp%u", 1) diff --git a/src/devices/bus/vip/vp575.h b/src/devices/bus/vip/vp575.h index fb5c22f5628..56ad04fa4a9 100644 --- a/src/devices/bus/vip/vp575.h +++ b/src/devices/bus/vip/vp575.h @@ -26,7 +26,7 @@ class vp575_device : public device_t, { public: // construction/destruction - vp575_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vp575_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vip/vp585.cpp b/src/devices/bus/vip/vp585.cpp index 2112637ae6b..e384d706754 100644 --- a/src/devices/bus/vip/vp585.cpp +++ b/src/devices/bus/vip/vp585.cpp @@ -80,7 +80,7 @@ ioport_constructor vp585_device::device_input_ports() const // vp585_device - constructor //------------------------------------------------- -vp585_device::vp585_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vp585_device::vp585_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VP585, tag, owner, clock), device_vip_expansion_card_interface(mconfig, *this), m_j1(*this, "J1"), diff --git a/src/devices/bus/vip/vp585.h b/src/devices/bus/vip/vp585.h index f32bf055e91..66410ff95a8 100644 --- a/src/devices/bus/vip/vp585.h +++ b/src/devices/bus/vip/vp585.h @@ -26,7 +26,7 @@ class vp585_device : public device_t, { public: // construction/destruction - vp585_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vp585_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/vip/vp590.cpp b/src/devices/bus/vip/vp590.cpp index 296ce70fb8b..acf53f07256 100644 --- a/src/devices/bus/vip/vp590.cpp +++ b/src/devices/bus/vip/vp590.cpp @@ -127,7 +127,7 @@ ioport_constructor vp590_device::device_input_ports() const // vp590_device - constructor //------------------------------------------------- -vp590_device::vp590_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vp590_device::vp590_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VP590, tag, owner, clock), device_vip_expansion_card_interface(mconfig, *this), m_cgc(*this, CDP1862_TAG), diff --git a/src/devices/bus/vip/vp590.h b/src/devices/bus/vip/vp590.h index 9c69762f7be..93e11fdb05f 100644 --- a/src/devices/bus/vip/vp590.h +++ b/src/devices/bus/vip/vp590.h @@ -28,7 +28,7 @@ class vp590_device : public device_t, { public: // construction/destruction - vp590_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vp590_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vip/vp595.cpp b/src/devices/bus/vip/vp595.cpp index 670b0926f90..35f0840ac71 100644 --- a/src/devices/bus/vip/vp595.cpp +++ b/src/devices/bus/vip/vp595.cpp @@ -37,7 +37,7 @@ void vp595_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "mono").front_center(); - CDP1863(config, m_pfg, 0); + CDP1863(config, m_pfg); m_pfg->set_clock2(CDP1863_XTAL); m_pfg->add_route(ALL_OUTPUTS, "mono", 0.25); } @@ -52,7 +52,7 @@ void vp595_device::device_add_mconfig(machine_config &config) // vp595_device - constructor //------------------------------------------------- -vp595_device::vp595_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vp595_device::vp595_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VP595, tag, owner, clock), device_vip_expansion_card_interface(mconfig, *this), m_pfg(*this, CDP1863_TAG) diff --git a/src/devices/bus/vip/vp595.h b/src/devices/bus/vip/vp595.h index 5c98b33fe7c..0d7f9742ea5 100644 --- a/src/devices/bus/vip/vp595.h +++ b/src/devices/bus/vip/vp595.h @@ -27,7 +27,7 @@ class vp595_device : public device_t, { public: // construction/destruction - vp595_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vp595_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vip/vp620.cpp b/src/devices/bus/vip/vp620.cpp index ba6a938f660..189520b4e79 100644 --- a/src/devices/bus/vip/vp620.cpp +++ b/src/devices/bus/vip/vp620.cpp @@ -38,7 +38,7 @@ void vp620_device::kb_w(uint8_t data) void vp620_device::device_add_mconfig(machine_config &config) { - generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, "keyboard", 0)); + generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, "keyboard")); keyboard.set_keyboard_callback(FUNC(vp620_device::kb_w)); } @@ -52,7 +52,7 @@ void vp620_device::device_add_mconfig(machine_config &config) // vp620_device - constructor //------------------------------------------------- -vp620_device::vp620_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vp620_device::vp620_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VP620, tag, owner, clock), device_vip_byteio_port_interface(mconfig, *this), m_keydata(0), diff --git a/src/devices/bus/vip/vp620.h b/src/devices/bus/vip/vp620.h index 3541db5d8e5..62f178320f5 100644 --- a/src/devices/bus/vip/vp620.h +++ b/src/devices/bus/vip/vp620.h @@ -27,7 +27,7 @@ class vp620_device : public device_t, { public: // construction/destruction - vp620_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vp620_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/vip/vp700.cpp b/src/devices/bus/vip/vp700.cpp index f64574a23fc..d07752aa976 100644 --- a/src/devices/bus/vip/vp700.cpp +++ b/src/devices/bus/vip/vp700.cpp @@ -46,7 +46,7 @@ const tiny_rom_entry *vp700_device::device_rom_region() const // vp700_device - constructor //------------------------------------------------- -vp700_device::vp700_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vp700_device::vp700_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VP700, tag, owner, clock), device_vip_expansion_card_interface(mconfig, *this), m_rom(*this, "vp700") diff --git a/src/devices/bus/vip/vp700.h b/src/devices/bus/vip/vp700.h index 4927005742e..b3fc77238c4 100644 --- a/src/devices/bus/vip/vp700.h +++ b/src/devices/bus/vip/vp700.h @@ -27,7 +27,7 @@ class vp700_device : public device_t, { public: // construction/destruction - vp700_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vp700_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/vme/vme.cpp b/src/devices/bus/vme/vme.cpp index 1353f36ae22..f75e47d159a 100644 --- a/src/devices/bus/vme/vme.cpp +++ b/src/devices/bus/vme/vme.cpp @@ -101,12 +101,12 @@ DEFINE_DEVICE_TYPE(VME_SLOT, vme_slot_device, "vme_slot", "VME slot") //------------------------------------------------- // vme_slot_device - constructor //------------------------------------------------- -vme_slot_device::vme_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_slot_device::vme_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_slot_device(mconfig, VME_SLOT, tag, owner, clock) { } -vme_slot_device::vme_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vme_slot_device::vme_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_slot_interface(mconfig, *this) , m_vme(*this, finder_base::DUMMY_TAG) @@ -203,12 +203,12 @@ void vme_device::use_owner_spaces() m_allocspaces = false; } -vme_device::vme_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_device::vme_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_device(mconfig, VME, tag, owner, clock) { } -vme_device::vme_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vme_device::vme_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_a32_config("a32", ENDIANNESS_BIG, 32, 32, 0, address_map_constructor()) diff --git a/src/devices/bus/vme/vme.h b/src/devices/bus/vme/vme.h index e49b23cbbbe..519908b6e2d 100644 --- a/src/devices/bus/vme/vme.h +++ b/src/devices/bus/vme/vme.h @@ -86,7 +86,7 @@ public: // construction/destruction template <typename T, typename U> vme_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt, uint32_t slot_nbr, U &&bus_tag) - : vme_slot_device(mconfig, tag, owner, 0) + : vme_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -95,7 +95,7 @@ public: set_vme_slot(std::forward<U>(bus_tag), slot_nbr); } - vme_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // Callbacks to the board from the VME bus comes through here auto vme_j1_callback() { return m_vme_j1_callback.bind(); } @@ -106,7 +106,7 @@ public: virtual void write8(offs_t offset, uint8_t data); protected: - vme_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vme_slot_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -130,7 +130,7 @@ class vme_device : public device_t, public device_memory_interface { public: - vme_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~vme_device(); // inline configuration @@ -185,7 +185,7 @@ public: void install_device(vme_amod_t amod, offs_t start, offs_t end, read32_delegate rhandler, write32_delegate whandler, uint32_t mask); protected: - vme_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vme_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/bus/vme/vme_cp31.cpp b/src/devices/bus/vme/vme_cp31.cpp index 2a59f92b7ed..53ba901154f 100644 --- a/src/devices/bus/vme/vme_cp31.cpp +++ b/src/devices/bus/vme/vme_cp31.cpp @@ -176,7 +176,7 @@ void vme_cp31_card_device::device_add_mconfig(machine_config &config) m_rtc->out_int_handler().set(m_pit1, FUNC(pit68230_device::h2_w)); // H1 is SYSFAIL and H3 is ACFAIL - PIT68230(config, m_pit1, 8064000); // via c33_txt + PIT68230(config, m_pit1, XTAL::u(8064000)); // via c33_txt m_pit1->pa_in_callback().set_ioport("SA1"); m_pit1->pb_out_callback().set(*this, FUNC(vme_cp31_card_device::pit1_pb_w)); m_pit1->pc_in_callback().set(*this, FUNC(vme_cp31_card_device::pit1_pc_r)); @@ -184,7 +184,7 @@ void vme_cp31_card_device::device_add_mconfig(machine_config &config) m_pit1->timer_irq_callback().set(m_bim, FUNC(bim68153_device::int2_w)); m_pit1->port_irq_callback().set(m_bim, FUNC(bim68153_device::int3_w)); - PIT68230(config, m_pit2, 8064000); // via c33_txt + PIT68230(config, m_pit2, XTAL::u(8064000)); // via c33_txt m_pit2->port_irq_callback().set(m_pit1, FUNC(pit68230_device::h4_w)); } @@ -264,7 +264,7 @@ void vme_cp31_card_device::set_bus_error(uint32_t address, bool rw, uint32_t mem m_bus_error_timer->adjust(m_maincpu->cycles_to_attotime(16)); // let rmw cycles complete } -vme_cp31_card_device::vme_cp31_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vme_cp31_card_device::vme_cp31_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_vme_card_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -281,7 +281,7 @@ vme_cp31_card_device::vme_cp31_card_device(const machine_config &mconfig, device // -vme_cp31_card_device::vme_cp31_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_cp31_card_device::vme_cp31_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_cp31_card_device(mconfig, VME_CP31, tag, owner, clock) { } diff --git a/src/devices/bus/vme/vme_cp31.h b/src/devices/bus/vme/vme_cp31.h index 588ca7fb4fc..4f9dae99bbc 100644 --- a/src/devices/bus/vme/vme_cp31.h +++ b/src/devices/bus/vme/vme_cp31.h @@ -20,10 +20,10 @@ DECLARE_DEVICE_TYPE(VME_CP31, vme_cp31_card_device) class vme_cp31_card_device : public device_t, public device_vme_card_interface { public: - vme_cp31_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_cp31_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_cp31_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vme_cp31_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/vme/vme_fccpu20.cpp b/src/devices/bus/vme/vme_fccpu20.cpp index 6bf01e23b06..2936037f712 100644 --- a/src/devices/bus/vme/vme_fccpu20.cpp +++ b/src/devices/bus/vme/vme_fccpu20.cpp @@ -372,7 +372,7 @@ void vme_fccpu21yb_card_device::device_add_mconfig(machine_config &config) //************************************************************************** // Base Device //************************************************************************** -vme_fccpu20_device::vme_fccpu20_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, fc_board_t board_id) : +vme_fccpu20_device::vme_fccpu20_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, fc_board_t board_id) : device_t(mconfig, type, tag, owner, clock) , device_vme_card_interface(mconfig, *this) , m_maincpu (*this, "maincpu") @@ -389,46 +389,46 @@ vme_fccpu20_device::vme_fccpu20_device(const machine_config &mconfig, device_typ //************************************************************************** // Card Devices //************************************************************************** -vme_fccpu20_card_device::vme_fccpu20_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_fccpu20_card_device::vme_fccpu20_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu20_card_device(mconfig, VME_FCCPU20, tag, owner, clock) { LOG("vme_fccpu20_card_device ctor: %s\n", tag); } -vme_fccpu21s_card_device::vme_fccpu21s_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_fccpu21s_card_device::vme_fccpu21s_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu21s_card_device(mconfig, VME_FCCPU21S, tag, owner, clock) { LOG("vme_fccpu21s_card_device ctor: %s\n", tag); } -vme_fccpu21_card_device::vme_fccpu21_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_fccpu21_card_device::vme_fccpu21_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu21_card_device(mconfig, VME_FCCPU21, tag, owner, clock) { LOG("vme_fccpu21_card_device ctor: %s\n", tag); } -vme_fccpu21a_card_device::vme_fccpu21a_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_fccpu21a_card_device::vme_fccpu21a_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu21a_card_device(mconfig, VME_FCCPU21A, tag, owner, clock) { LOG("vme_fccpu21a_card_device ctor: %s\n", tag); } // TODO: Change to 2MB on board RAM and move FLME memory and find/verify memory map -vme_fccpu21ya_card_device::vme_fccpu21ya_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_fccpu21ya_card_device::vme_fccpu21ya_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu21ya_card_device(mconfig, VME_FCCPU21YA, tag, owner, clock) { LOG("vme_fccpu21ya_card_device ctor: %s\n", tag); } -vme_fccpu21b_card_device::vme_fccpu21b_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_fccpu21b_card_device::vme_fccpu21b_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu21b_card_device(mconfig, VME_FCCPU21B, tag, owner, clock) { LOG("vme_fccpu21b_card_device ctor: %s\n", tag); } // TODO: Change to 2MB on board RAM and move FLME memory and find/verify memory map -vme_fccpu21yb_card_device::vme_fccpu21yb_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_fccpu21yb_card_device::vme_fccpu21yb_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu21yb_card_device(mconfig, VME_FCCPU21YB, tag, owner, clock) { LOG("vme_fccpu21yb_card_device ctor: %s\n", tag); diff --git a/src/devices/bus/vme/vme_fccpu20.h b/src/devices/bus/vme/vme_fccpu20.h index 42569041f87..a10569d2039 100644 --- a/src/devices/bus/vme/vme_fccpu20.h +++ b/src/devices/bus/vme/vme_fccpu20.h @@ -39,7 +39,7 @@ protected: cpu21s }; - vme_fccpu20_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, fc_board_t board_id); + vme_fccpu20_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, fc_board_t board_id); virtual void device_start() override; virtual void device_reset() override; @@ -92,10 +92,10 @@ private: class vme_fccpu20_card_device : public vme_fccpu20_device { public : - vme_fccpu20_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_fccpu20_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_fccpu20_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_fccpu20_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu20_device(mconfig, type, tag, owner, clock, cpu20) { } @@ -106,10 +106,10 @@ protected: class vme_fccpu21s_card_device : public vme_fccpu20_device { public : - vme_fccpu21s_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_fccpu21s_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_fccpu21s_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_fccpu21s_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu20_device(mconfig, type, tag, owner, clock, cpu21s) { } @@ -120,10 +120,10 @@ protected: class vme_fccpu21_card_device : public vme_fccpu20_device { public : - vme_fccpu21_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_fccpu21_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_fccpu21_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_fccpu21_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu20_device(mconfig, type, tag, owner, clock, cpu21) { } @@ -134,10 +134,10 @@ protected: class vme_fccpu21a_card_device : public vme_fccpu20_device { public : - vme_fccpu21a_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_fccpu21a_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_fccpu21a_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_fccpu21a_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu20_device(mconfig, type, tag, owner, clock, cpu21a) { } @@ -148,10 +148,10 @@ protected: class vme_fccpu21ya_card_device : public vme_fccpu20_device { public : - vme_fccpu21ya_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_fccpu21ya_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_fccpu21ya_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_fccpu21ya_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu20_device(mconfig, type, tag, owner, clock, cpu21ya) { } @@ -162,10 +162,10 @@ protected: class vme_fccpu21b_card_device : public vme_fccpu20_device { public : - vme_fccpu21b_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_fccpu21b_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_fccpu21b_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_fccpu21b_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu20_device(mconfig, type, tag, owner, clock, cpu21b) { } @@ -176,10 +176,10 @@ protected: class vme_fccpu21yb_card_device : public vme_fccpu20_device { public : - vme_fccpu21yb_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_fccpu21yb_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_fccpu21yb_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_fccpu21yb_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_fccpu20_device(mconfig, type, tag, owner, clock, cpu21yb) { } diff --git a/src/devices/bus/vme/vme_fcisio.cpp b/src/devices/bus/vme/vme_fcisio.cpp index 9003384ce4d..92965d618a5 100644 --- a/src/devices/bus/vme/vme_fcisio.cpp +++ b/src/devices/bus/vme/vme_fcisio.cpp @@ -292,7 +292,7 @@ void vme_fcisio1_card_device::device_add_mconfig(machine_config &config) #define RS232P8_TAG "rs232p8" DUSCC68562(config, m_duscc0, DUSCC_CLOCK); - m_duscc0->configure_channels(0, 0, 0, 0); + m_duscc0->configure_channels(XTAL(), XTAL(), XTAL(), XTAL()); /* Port 1 on DUSCC 0 Port A */ m_duscc0->out_txda_callback().set(RS232P1_TAG, FUNC(rs232_port_device::write_txd)); m_duscc0->out_dtra_callback().set(RS232P1_TAG, FUNC(rs232_port_device::write_dtr)); @@ -311,7 +311,7 @@ void vme_fcisio1_card_device::device_add_mconfig(machine_config &config) rs232p2.cts_handler().set(m_duscc0, FUNC(duscc68562_device::ctsb_w)); DUSCC68562(config, m_duscc1, DUSCC_CLOCK); - m_duscc1->configure_channels(0, 0, 0, 0); + m_duscc1->configure_channels(XTAL(), XTAL(), XTAL(), XTAL()); /* Port 3 on DUSCC 1 Port A */ m_duscc1->out_txda_callback().set(RS232P3_TAG, FUNC(rs232_port_device::write_txd)); m_duscc1->out_dtra_callback().set(RS232P3_TAG, FUNC(rs232_port_device::write_dtr)); @@ -330,7 +330,7 @@ void vme_fcisio1_card_device::device_add_mconfig(machine_config &config) rs232p4.cts_handler().set(m_duscc1, FUNC(duscc68562_device::ctsb_w)); DUSCC68562(config, m_duscc2, DUSCC_CLOCK); - m_duscc2->configure_channels(0, 0, 0, 0); + m_duscc2->configure_channels(XTAL(), XTAL(), XTAL(), XTAL()); /* Port 5 on DUSCC 2 Port A */ m_duscc2->out_txda_callback().set(RS232P5_TAG, FUNC(rs232_port_device::write_txd)); m_duscc2->out_dtra_callback().set(RS232P5_TAG, FUNC(rs232_port_device::write_dtr)); @@ -349,7 +349,7 @@ void vme_fcisio1_card_device::device_add_mconfig(machine_config &config) rs232p6.cts_handler().set(m_duscc2, FUNC(duscc68562_device::ctsb_w)); DUSCC68562(config, m_duscc3, DUSCC_CLOCK); - m_duscc3->configure_channels(0, 0, 0, 0); + m_duscc3->configure_channels(XTAL(), XTAL(), XTAL(), XTAL()); /* Port 7 on DUSCC 3 Port A */ m_duscc3->out_txda_callback().set(RS232P7_TAG, FUNC(rs232_port_device::write_txd)); m_duscc3->out_dtra_callback().set(RS232P7_TAG, FUNC(rs232_port_device::write_dtr)); @@ -382,7 +382,7 @@ const tiny_rom_entry *vme_fcisio1_card_device::device_rom_region() const //************************************************************************** // LIVE DEVICE //************************************************************************** -vme_fcisio1_card_device::vme_fcisio1_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vme_fcisio1_card_device::vme_fcisio1_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_vme_card_interface(mconfig, *this) , m_maincpu (*this, "maincpu") @@ -396,7 +396,7 @@ vme_fcisio1_card_device::vme_fcisio1_card_device(const machine_config &mconfig, LOG("%s\n", FUNCNAME); } -vme_fcisio1_card_device::vme_fcisio1_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_fcisio1_card_device::vme_fcisio1_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_fcisio1_card_device(mconfig, VME_FCISIO1, tag, owner, clock) { } diff --git a/src/devices/bus/vme/vme_fcisio.h b/src/devices/bus/vme/vme_fcisio.h index 6ffecb0e6af..56d3abfdb31 100644 --- a/src/devices/bus/vme/vme_fcisio.h +++ b/src/devices/bus/vme/vme_fcisio.h @@ -15,10 +15,10 @@ DECLARE_DEVICE_TYPE(VME_FCISIO1, vme_fcisio1_card_device) class vme_fcisio1_card_device : public device_t, public device_vme_card_interface { public: - vme_fcisio1_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_fcisio1_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_fcisio1_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vme_fcisio1_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/vme/vme_fcscsi.cpp b/src/devices/bus/vme/vme_fcscsi.cpp index 92f6cac9791..7bdb17820cb 100644 --- a/src/devices/bus/vme/vme_fcscsi.cpp +++ b/src/devices/bus/vme/vme_fcscsi.cpp @@ -308,7 +308,7 @@ const tiny_rom_entry *vme_fcscsi1_card_device::device_rom_region() const //************************************************************************** // LIVE DEVICE //************************************************************************** -vme_fcscsi1_card_device::vme_fcscsi1_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vme_fcscsi1_card_device::vme_fcscsi1_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_vme_card_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -320,7 +320,7 @@ vme_fcscsi1_card_device::vme_fcscsi1_card_device(const machine_config &mconfig, LOG("%s\n", FUNCNAME); } -vme_fcscsi1_card_device::vme_fcscsi1_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_fcscsi1_card_device::vme_fcscsi1_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_fcscsi1_card_device(mconfig, VME_FCSCSI1, tag, owner, clock) { } diff --git a/src/devices/bus/vme/vme_fcscsi.h b/src/devices/bus/vme/vme_fcscsi.h index 58c57c88fdc..5e00ad42716 100644 --- a/src/devices/bus/vme/vme_fcscsi.h +++ b/src/devices/bus/vme/vme_fcscsi.h @@ -16,10 +16,10 @@ DECLARE_DEVICE_TYPE(VME_FCSCSI1, vme_fcscsi1_card_device) class vme_fcscsi1_card_device : public device_t, public device_vme_card_interface { public: - vme_fcscsi1_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_fcscsi1_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_fcscsi1_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vme_fcscsi1_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/vme/vme_hcpu30.cpp b/src/devices/bus/vme/vme_hcpu30.cpp index a68cdb319f2..db1b7a01500 100644 --- a/src/devices/bus/vme/vme_hcpu30.cpp +++ b/src/devices/bus/vme/vme_hcpu30.cpp @@ -172,14 +172,14 @@ static void hcpu_floppies(device_slot_interface &device) void vme_hcpu30_card_device::device_add_mconfig(machine_config &config) { // I/O CPU - M68020(config, m_maincpu, 16670000); + M68020(config, m_maincpu, XTAL::u(16670000)); m_maincpu->set_addrmap(AS_PROGRAM, &vme_hcpu30_card_device::hcpu30_mem); m_maincpu->set_addrmap(m68000_base_device::AS_CPU_SPACE, &vme_hcpu30_card_device::cpu_space_map); m_maincpu->disable_interrupt_mixer(); // FIXME: functional test expects dtr->dcd, rts->cts connections on both ports and tx->rx connection on port B DUSCC68562(config, m_dusccterm, DUSCC_CLOCK); - m_dusccterm->configure_channels(0, 0, 0, 0); + m_dusccterm->configure_channels(XTAL(), XTAL(), XTAL(), XTAL()); m_dusccterm->out_txda_callback().set(RS232P1_TAG, FUNC(rs232_port_device::write_txd)); m_dusccterm->out_dtra_callback().set(RS232P1_TAG, FUNC(rs232_port_device::write_dtr)); m_dusccterm->out_rtsa_callback().set(RS232P1_TAG, FUNC(rs232_port_device::write_rts)); @@ -526,7 +526,7 @@ void vme_hcpu30_card_device::set_bus_error(uint32_t address, bool rw, uint32_t m m_bus_error_timer->adjust(m_oscpu->cycles_to_attotime(16)); // let rmw cycles complete } -vme_hcpu30_card_device::vme_hcpu30_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vme_hcpu30_card_device::vme_hcpu30_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_vme_card_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -551,7 +551,7 @@ vme_hcpu30_card_device::vme_hcpu30_card_device(const machine_config &mconfig, de // -vme_hcpu30_card_device::vme_hcpu30_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_hcpu30_card_device::vme_hcpu30_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_hcpu30_card_device(mconfig, VME_HCPU30, tag, owner, clock) { } diff --git a/src/devices/bus/vme/vme_hcpu30.h b/src/devices/bus/vme/vme_hcpu30.h index 7592a4dad66..b808b66504e 100644 --- a/src/devices/bus/vme/vme_hcpu30.h +++ b/src/devices/bus/vme/vme_hcpu30.h @@ -25,10 +25,10 @@ DECLARE_DEVICE_TYPE(VME_HCPU30, vme_hcpu30_card_device) class vme_hcpu30_card_device : public device_t, public device_vme_card_interface { public: - vme_hcpu30_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_hcpu30_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_hcpu30_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vme_hcpu30_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/vme/vme_mvme120.cpp b/src/devices/bus/vme/vme_mvme120.cpp index 19ddaf9b391..578798f95d0 100644 --- a/src/devices/bus/vme/vme_mvme120.cpp +++ b/src/devices/bus/vme/vme_mvme120.cpp @@ -125,7 +125,7 @@ ioport_constructor vme_mvme120_device::device_input_ports() const return INPUT_PORTS_NAME(mvme120); } -vme_mvme120_device::vme_mvme120_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, mvme12x_variant board_id) : +vme_mvme120_device::vme_mvme120_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, mvme12x_variant board_id) : device_t(mconfig, type, tag, owner, clock) , device_vme_card_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -139,24 +139,24 @@ vme_mvme120_device::vme_mvme120_device(const machine_config &mconfig, device_typ } -vme_mvme120_card_device::vme_mvme120_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_mvme120_card_device::vme_mvme120_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_mvme120_card_device(mconfig, VME_MVME120, tag, owner, clock) { } -vme_mvme121_card_device::vme_mvme121_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_mvme121_card_device::vme_mvme121_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_mvme121_card_device(mconfig, VME_MVME121, tag, owner, clock) { } -vme_mvme122_card_device::vme_mvme122_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_mvme122_card_device::vme_mvme122_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_mvme122_card_device(mconfig, VME_MVME122, tag, owner, clock) { } -vme_mvme123_card_device::vme_mvme123_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vme_mvme123_card_device::vme_mvme123_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_mvme123_card_device(mconfig, VME_MVME123, tag, owner, clock) { @@ -386,7 +386,7 @@ void vme_mvme120_device::device_add_mconfig(machine_config &config) // Missing: MMU, VMEbus - VME(config, "vme", 0); + VME(config, "vme"); /* // Onboard RAM is always visible to VMEbus. (Decoding controlled by U28.) diff --git a/src/devices/bus/vme/vme_mvme120.h b/src/devices/bus/vme/vme_mvme120.h index 1ecafbcf794..3e02f9061d7 100644 --- a/src/devices/bus/vme/vme_mvme120.h +++ b/src/devices/bus/vme/vme_mvme120.h @@ -31,7 +31,7 @@ public: mvme123_board }; - vme_mvme120_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, mvme12x_variant board_id); + vme_mvme120_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, mvme12x_variant board_id); // Switch and jumper handlers DECLARE_INPUT_CHANGED_MEMBER(s3_autoboot); @@ -95,10 +95,10 @@ protected: class vme_mvme120_card_device : public vme_mvme120_device { public: - vme_mvme120_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_mvme120_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_mvme120_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_mvme120_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_mvme120_device(mconfig, type, tag, owner, clock, mvme120_board) { } @@ -109,10 +109,10 @@ protected: class vme_mvme121_card_device : public vme_mvme120_device { public: - vme_mvme121_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_mvme121_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_mvme121_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_mvme121_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_mvme120_device(mconfig, type, tag, owner, clock, mvme121_board) { } @@ -124,10 +124,10 @@ protected: class vme_mvme122_card_device : public vme_mvme120_device { public: - vme_mvme122_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_mvme122_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_mvme122_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_mvme122_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_mvme120_device(mconfig, type, tag, owner, clock, mvme122_board) { } @@ -139,10 +139,10 @@ protected: class vme_mvme123_card_device : public vme_mvme120_device { public: - vme_mvme123_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_mvme123_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_mvme123_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) + vme_mvme123_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vme_mvme120_device(mconfig, type, tag, owner, clock, mvme123_board) { } diff --git a/src/devices/bus/vme/vme_mvme350.cpp b/src/devices/bus/vme/vme_mvme350.cpp index 2ca5c966b7b..a2ec60ddefd 100644 --- a/src/devices/bus/vme/vme_mvme350.cpp +++ b/src/devices/bus/vme/vme_mvme350.cpp @@ -208,14 +208,14 @@ const tiny_rom_entry *vme_mvme350_card_device::device_rom_region() const // LIVE DEVICE //************************************************************************** -vme_mvme350_card_device::vme_mvme350_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +vme_mvme350_card_device::vme_mvme350_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_vme_card_interface(mconfig, *this) { LOG("%s %s\n", tag, FUNCNAME); } -vme_mvme350_card_device::vme_mvme350_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vme_mvme350_card_device::vme_mvme350_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_mvme350_card_device(mconfig, VME_MVME350, tag, owner, clock) { LOG("%s %s\n", tag, FUNCNAME); diff --git a/src/devices/bus/vme/vme_mvme350.h b/src/devices/bus/vme/vme_mvme350.h index a328f3e7c53..4e6735de267 100644 --- a/src/devices/bus/vme/vme_mvme350.h +++ b/src/devices/bus/vme/vme_mvme350.h @@ -12,14 +12,14 @@ DECLARE_DEVICE_TYPE(VME_MVME350, vme_mvme350_card_device) class vme_mvme350_card_device : public device_t, public device_vme_card_interface { public: - vme_mvme350_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_mvme350_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Shared memory methods to be exported to the VME bus // virtual uint16_t read16() override; // virtual void write16(uint16_t data) override; protected: - vme_mvme350_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vme_mvme350_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/vme/vme_mzr8105.cpp b/src/devices/bus/vme/vme_mzr8105.cpp index fe63e92ee28..5f18f02c4b1 100644 --- a/src/devices/bus/vme/vme_mzr8105.cpp +++ b/src/devices/bus/vme/vme_mzr8105.cpp @@ -41,18 +41,18 @@ void vme_mzr8105_card_device::device_add_mconfig(machine_config &config) M68000(config, m_maincpu, XTAL(10'000'000)) m_maincpu->set_addrmap(AS_PROGRAM, &vme_mzr8105_card_device::mzr8105_mem); - VME(config, "vme", 0).use_owner_spaces(); + VME(config, "vme").use_owner_spaces(); VME_SLOT(config, "slot1", mzr8105_vme_cards, "mzr8300", 1, "vme"); } -vme_mzr8105_card_device::vme_mzr8105_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vme_mzr8105_card_device::vme_mzr8105_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_mzr8105_card_device(mconfig, VME_MZR8105, tag, owner, clock) { m_slot = 1; LOG("%s %s\n", tag, FUNCNAME); } -vme_mzr8105_card_device::vme_mzr8105_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +vme_mzr8105_card_device::vme_mzr8105_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_vme_card_interface(mconfig, *this) { diff --git a/src/devices/bus/vme/vme_mzr8105.h b/src/devices/bus/vme/vme_mzr8105.h index 9d5e371b47f..67a13c1061a 100644 --- a/src/devices/bus/vme/vme_mzr8105.h +++ b/src/devices/bus/vme/vme_mzr8105.h @@ -12,10 +12,10 @@ DECLARE_DEVICE_TYPE(VME_MZR8105, vme_mzr8105_card_device) class vme_mzr8105_card_device : public device_t, public device_vme_card_interface { public: - vme_mzr8105_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_mzr8105_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - vme_mzr8105_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vme_mzr8105_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/vme/vme_mzr8300.cpp b/src/devices/bus/vme/vme_mzr8300.cpp index 99e2e8c0889..58c5e476902 100644 --- a/src/devices/bus/vme/vme_mzr8300.cpp +++ b/src/devices/bus/vme/vme_mzr8300.cpp @@ -153,14 +153,14 @@ void vme_mzr8300_card_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -vme_mzr8300_card_device::vme_mzr8300_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +vme_mzr8300_card_device::vme_mzr8300_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_vme_card_interface(mconfig, *this) { LOG("%s %s\n", tag, FUNCNAME); } -vme_mzr8300_card_device::vme_mzr8300_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vme_mzr8300_card_device::vme_mzr8300_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vme_mzr8300_card_device(mconfig, VME_MZR8300, tag, owner, clock) { } diff --git a/src/devices/bus/vme/vme_mzr8300.h b/src/devices/bus/vme/vme_mzr8300.h index d551bb2f077..e5ae2d22913 100644 --- a/src/devices/bus/vme/vme_mzr8300.h +++ b/src/devices/bus/vme/vme_mzr8300.h @@ -12,13 +12,13 @@ DECLARE_DEVICE_TYPE(VME_MZR8300, vme_mzr8300_card_device) class vme_mzr8300_card_device : public device_t, public device_vme_card_interface { public: - vme_mzr8300_card_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vme_mzr8300_card_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // virtual uint8_t read8(offs_t offset) override; // virtual void write8(offs_t offset, uint8_t data) override; protected: - vme_mzr8300_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vme_mzr8300_card_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/bus/vme/vme_smvme2000.cpp b/src/devices/bus/vme/vme_smvme2000.cpp index ddce242739a..114be0f5f7f 100644 --- a/src/devices/bus/vme/vme_smvme2000.cpp +++ b/src/devices/bus/vme/vme_smvme2000.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(VME_SMVME2000, vme_smvme2000_device, "smvme2000", "Signetics SMVME2000") -vme_smvme2000_device::vme_smvme2000_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +vme_smvme2000_device::vme_smvme2000_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VME_SMVME2000, tag, owner, clock) , device_vme_card_interface(mconfig, *this) , m_cpu(*this, "cpu") @@ -96,7 +96,7 @@ void vme_smvme2000_device::device_add_mconfig(machine_config &config) SCN2681(config, m_duart, 3.6864_MHz_XTAL); m_duart->irq_cb().set(m_pit, FUNC(pit68230_device::h3_w)); // TODO: verify destination - PIT68230(config, m_pit, 0); + PIT68230(config, m_pit); m_pit->pc_out_callback().set( [this](u8 data) { diff --git a/src/devices/bus/vme/vme_smvme2000.h b/src/devices/bus/vme/vme_smvme2000.h index cffea3cb469..df41c9ebe1a 100644 --- a/src/devices/bus/vme/vme_smvme2000.h +++ b/src/devices/bus/vme/vme_smvme2000.h @@ -20,7 +20,7 @@ class vme_smvme2000_device , public device_vme_card_interface { public: - vme_smvme2000_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + vme_smvme2000_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/bus/vsmile/keyboard.cpp b/src/devices/bus/vsmile/keyboard.cpp index 2c2501ecd8e..6b08f59f84b 100644 --- a/src/devices/bus/vsmile/keyboard.cpp +++ b/src/devices/bus/vsmile/keyboard.cpp @@ -25,22 +25,22 @@ DEFINE_DEVICE_TYPE(VSMILE_KEYBOARD_GE, vsmile_keyboard_ge_device, "vsmile_keyboa // V.Smile Keyboard //************************************************************************** -vsmile_keyboard_us_device::vsmile_keyboard_us_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +vsmile_keyboard_us_device::vsmile_keyboard_us_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : vsmile_keyboard_device(mconfig, VSMILE_KEYBOARD_US, tag, owner, clock, 0x40) { } -vsmile_keyboard_fr_device::vsmile_keyboard_fr_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +vsmile_keyboard_fr_device::vsmile_keyboard_fr_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : vsmile_keyboard_device(mconfig, VSMILE_KEYBOARD_FR, tag, owner, clock, 0x42) { } -vsmile_keyboard_ge_device::vsmile_keyboard_ge_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +vsmile_keyboard_ge_device::vsmile_keyboard_ge_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : vsmile_keyboard_device(mconfig, VSMILE_KEYBOARD_GE, tag, owner, clock, 0x44) { } -vsmile_keyboard_device::vsmile_keyboard_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock, uint8_t layout_type) +vsmile_keyboard_device::vsmile_keyboard_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, uint8_t layout_type) : vsmile_ctrl_device_base(mconfig, type, tag, owner, clock) , device_matrix_keyboard_interface(mconfig, *this, "ROW0", "ROW1", "ROW2", "ROW3", "ROW4") , m_io_joy(*this, "JOY") diff --git a/src/devices/bus/vsmile/keyboard.h b/src/devices/bus/vsmile/keyboard.h index 2d01776ee39..2e01f3bb460 100644 --- a/src/devices/bus/vsmile/keyboard.h +++ b/src/devices/bus/vsmile/keyboard.h @@ -53,7 +53,7 @@ public: }; protected: - vsmile_keyboard_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock, uint8_t layout_type); + vsmile_keyboard_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, uint8_t layout_type); // device_t implementation virtual void device_start() override; @@ -103,7 +103,7 @@ class vsmile_keyboard_us_device : public vsmile_keyboard_device { public: // construction/destruction - vsmile_keyboard_us_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + vsmile_keyboard_us_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device_t implementation @@ -114,7 +114,7 @@ class vsmile_keyboard_fr_device : public vsmile_keyboard_device { public: // construction/destruction - vsmile_keyboard_fr_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + vsmile_keyboard_fr_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device_t implementation @@ -125,7 +125,7 @@ class vsmile_keyboard_ge_device : public vsmile_keyboard_device { public: // construction/destruction - vsmile_keyboard_ge_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + vsmile_keyboard_ge_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device_t implementation diff --git a/src/devices/bus/vsmile/mat.cpp b/src/devices/bus/vsmile/mat.cpp index 6dfeac5be98..53df8a925a1 100644 --- a/src/devices/bus/vsmile/mat.cpp +++ b/src/devices/bus/vsmile/mat.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(VSMILE_MAT, vsmile_mat_device, "vsmile_mat", "V.Smile Gym Mat // V.Smile gym mat //************************************************************************** -vsmile_mat_device::vsmile_mat_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +vsmile_mat_device::vsmile_mat_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : vsmile_pad_device(mconfig, VSMILE_MAT, tag, owner, clock) , m_io_joy(*this, "JOY") , m_io_colors(*this, "COLORS") diff --git a/src/devices/bus/vsmile/mat.h b/src/devices/bus/vsmile/mat.h index 253930ff085..06eb1facd45 100644 --- a/src/devices/bus/vsmile/mat.h +++ b/src/devices/bus/vsmile/mat.h @@ -17,7 +17,7 @@ class vsmile_mat_device : public vsmile_pad_device { public: // construction/destruction - vsmile_mat_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + vsmile_mat_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~vsmile_mat_device(); // input handlers diff --git a/src/devices/bus/vsmile/pad.cpp b/src/devices/bus/vsmile/pad.cpp index 7383de09475..39a65084c3b 100644 --- a/src/devices/bus/vsmile/pad.cpp +++ b/src/devices/bus/vsmile/pad.cpp @@ -21,12 +21,12 @@ DEFINE_DEVICE_TYPE(VSMILE_PAD, vsmile_pad_device, "vsmile_pad", "V.Smile Joystic // V.Smile control pad //************************************************************************** -vsmile_pad_device::vsmile_pad_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +vsmile_pad_device::vsmile_pad_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : vsmile_pad_device(mconfig, VSMILE_PAD, tag, owner, clock) { } -vsmile_pad_device::vsmile_pad_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock) +vsmile_pad_device::vsmile_pad_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : vsmile_ctrl_device_base(mconfig, type, tag, owner, clock) , m_io_joy(*this, "JOY") , m_io_colors(*this, "COLORS") diff --git a/src/devices/bus/vsmile/pad.h b/src/devices/bus/vsmile/pad.h index e5e08ce410c..e218d3984ba 100644 --- a/src/devices/bus/vsmile/pad.h +++ b/src/devices/bus/vsmile/pad.h @@ -17,7 +17,7 @@ class vsmile_pad_device : public vsmile_ctrl_device_base { public: // construction/destruction - vsmile_pad_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + vsmile_pad_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~vsmile_pad_device(); // input handlers @@ -42,7 +42,7 @@ public: }; protected: - vsmile_pad_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock = 0U); + vsmile_pad_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // device_t implementation virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/bus/vsmile/rom.cpp b/src/devices/bus/vsmile/rom.cpp index bc69099d698..bfcbff986fb 100644 --- a/src/devices/bus/vsmile/rom.cpp +++ b/src/devices/bus/vsmile/rom.cpp @@ -21,23 +21,23 @@ DEFINE_DEVICE_TYPE(VSMILE_ROM_STD, vsmile_rom_device, "vsmile_rom", DEFINE_DEVICE_TYPE(VSMILE_ROM_NVRAM, vsmile_rom_nvram_device, "vsmile_rom_nvram", "V.Smile Cart + NVRAM") -vsmile_rom_device::vsmile_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vsmile_rom_device::vsmile_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_vsmile_cart_interface(mconfig, *this) { } -vsmile_rom_device::vsmile_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vsmile_rom_device::vsmile_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vsmile_rom_device(mconfig, VSMILE_ROM_STD, tag, owner, clock) { } -vsmile_rom_nvram_device::vsmile_rom_nvram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vsmile_rom_nvram_device::vsmile_rom_nvram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vsmile_rom_device(mconfig, type, tag, owner, clock) { } -vsmile_rom_nvram_device::vsmile_rom_nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vsmile_rom_nvram_device::vsmile_rom_nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vsmile_rom_nvram_device(mconfig, VSMILE_ROM_NVRAM, tag, owner, clock) { } diff --git a/src/devices/bus/vsmile/rom.h b/src/devices/bus/vsmile/rom.h index b9ac8ef0b07..29051590990 100644 --- a/src/devices/bus/vsmile/rom.h +++ b/src/devices/bus/vsmile/rom.h @@ -13,7 +13,7 @@ class vsmile_rom_device : public device_t, public device_vsmile_cart_interface { public: // construction/destruction - vsmile_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vsmile_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual uint16_t bank0_r(offs_t offset) override { return m_rom[m_bank_offset + 0x000000 + offset]; } @@ -25,7 +25,7 @@ public: virtual void set_cs2(bool cs2) override; protected: - vsmile_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vsmile_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -41,13 +41,13 @@ class vsmile_rom_nvram_device : public vsmile_rom_device { public: // construction/destruction - vsmile_rom_nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vsmile_rom_nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint16_t bank2_r(offs_t offset) override; virtual void bank2_w(offs_t offset, uint16_t data) override; protected: - vsmile_rom_nvram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vsmile_rom_nvram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/bus/vsmile/vsmile_ctrl.h b/src/devices/bus/vsmile/vsmile_ctrl.h index 99369dc6cbf..193a7016abd 100644 --- a/src/devices/bus/vsmile/vsmile_ctrl.h +++ b/src/devices/bus/vsmile/vsmile_ctrl.h @@ -58,14 +58,14 @@ public: // construction/destruction template <typename T> vsmile_ctrl_port_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : vsmile_ctrl_port_device(mconfig, tag, owner, 0U) + : vsmile_ctrl_port_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - vsmile_ctrl_port_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 0U); + vsmile_ctrl_port_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~vsmile_ctrl_port_device(); // input signals @@ -96,7 +96,7 @@ public: protected: // construction - vsmile_ctrl_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, uint32_t clock); + vsmile_ctrl_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device_t implementation virtual void device_start() override; diff --git a/src/devices/bus/vsmile/vsmile_slot.cpp b/src/devices/bus/vsmile/vsmile_slot.cpp index 5be96466c64..6f60dc7cb8e 100644 --- a/src/devices/bus/vsmile/vsmile_slot.cpp +++ b/src/devices/bus/vsmile/vsmile_slot.cpp @@ -72,7 +72,7 @@ void device_vsmile_cart_interface::nvram_alloc(uint32_t size) //------------------------------------------------- // vsmile_cart_slot_device - constructor //------------------------------------------------- -vsmile_cart_slot_device::vsmile_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vsmile_cart_slot_device::vsmile_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VSMILE_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_vsmile_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/vsmile/vsmile_slot.h b/src/devices/bus/vsmile/vsmile_slot.h index 5313abe092b..3866a58855a 100644 --- a/src/devices/bus/vsmile/vsmile_slot.h +++ b/src/devices/bus/vsmile/vsmile_slot.h @@ -69,14 +69,14 @@ public: // construction/destruction template <typename T> vsmile_cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : vsmile_cart_slot_device(mconfig, tag, owner, (uint32_t)0) + : vsmile_cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - vsmile_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vsmile_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~vsmile_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/vtech/ioexp/ioexp.cpp b/src/devices/bus/vtech/ioexp/ioexp.cpp index 475f287201e..1258438dda5 100644 --- a/src/devices/bus/vtech/ioexp/ioexp.cpp +++ b/src/devices/bus/vtech/ioexp/ioexp.cpp @@ -27,11 +27,15 @@ DEFINE_DEVICE_TYPE(VTECH_IOEXP_SLOT, vtech_ioexp_slot_device, "vtech_ioexp_slot" // vtech_ioexp_slot_device - constructor //------------------------------------------------- -vtech_ioexp_slot_device::vtech_ioexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_ioexp_slot_device::vtech_ioexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VTECH_IOEXP_SLOT, tag, owner, clock), device_single_card_slot_interface<device_vtech_ioexp_interface>(mconfig, *this), m_iospace(*this, finder_base::DUMMY_TAG, -1) { + option_reset(); + vtech_ioexp_slot_carts(*this); + set_default_option(nullptr); + set_fixed(false); } //------------------------------------------------- @@ -100,7 +104,7 @@ device_vtech_ioexp_interface::~device_vtech_ioexp_interface() // vtech_ioexp_device - constructor //------------------------------------------------- -vtech_ioexp_device::vtech_ioexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +vtech_ioexp_device::vtech_ioexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_vtech_ioexp_interface(mconfig, *this), m_io(*this, "iospace") diff --git a/src/devices/bus/vtech/ioexp/ioexp.h b/src/devices/bus/vtech/ioexp/ioexp.h index c851d0e0d48..266121ab207 100644 --- a/src/devices/bus/vtech/ioexp/ioexp.h +++ b/src/devices/bus/vtech/ioexp/ioexp.h @@ -46,15 +46,7 @@ class vtech_ioexp_slot_device : public device_t, public device_single_card_slot_ friend class device_vtech_ioexp_interface; public: // construction/destruction - vtech_ioexp_slot_device(machine_config const &mconfig, char const *tag, device_t *owner) - : vtech_ioexp_slot_device(mconfig, tag, owner, (uint32_t)0) - { - option_reset(); - vtech_ioexp_slot_carts(*this); - set_default_option(nullptr); - set_fixed(false); - } - vtech_ioexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_ioexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~vtech_ioexp_slot_device(); template <typename T> void set_iospace(T &&tag, int spacenum) { m_iospace.set_tag(std::forward<T>(tag), spacenum); } @@ -90,7 +82,7 @@ class vtech_ioexp_device : public device_t, public device_vtech_ioexp_interface { public: // construction/destruction - vtech_ioexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vtech_ioexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // from host virtual uint8_t iorq_r(offs_t offset) override; diff --git a/src/devices/bus/vtech/ioexp/joystick.cpp b/src/devices/bus/vtech/ioexp/joystick.cpp index f54125c64ae..c6b9e2ae7f9 100644 --- a/src/devices/bus/vtech/ioexp/joystick.cpp +++ b/src/devices/bus/vtech/ioexp/joystick.cpp @@ -75,7 +75,7 @@ ioport_constructor vtech_joystick_interface_device::device_input_ports() const // vtech_joystick_interface_device - constructor //------------------------------------------------- -vtech_joystick_interface_device::vtech_joystick_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_joystick_interface_device::vtech_joystick_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_ioexp_device(mconfig, VTECH_JOYSTICK_INTERFACE, tag, owner, clock), m_joy0(*this, "joystick_0"), m_joy0_arm(*this, "joystick_0_arm"), diff --git a/src/devices/bus/vtech/ioexp/joystick.h b/src/devices/bus/vtech/ioexp/joystick.h index 2d59f7d4951..57d9a5dbc45 100644 --- a/src/devices/bus/vtech/ioexp/joystick.h +++ b/src/devices/bus/vtech/ioexp/joystick.h @@ -27,7 +27,7 @@ class vtech_joystick_interface_device : public vtech_ioexp_device { public: // construction/destruction - vtech_joystick_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_joystick_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t joystick_r(offs_t offset); diff --git a/src/devices/bus/vtech/ioexp/lpen.cpp b/src/devices/bus/vtech/ioexp/lpen.cpp index 732340218e1..32accdeeeb5 100644 --- a/src/devices/bus/vtech/ioexp/lpen.cpp +++ b/src/devices/bus/vtech/ioexp/lpen.cpp @@ -37,7 +37,7 @@ void vtech_lpen_interface_device::io_map(address_map &map) // vtech_lpen_interface_device - constructor //------------------------------------------------- -vtech_lpen_interface_device::vtech_lpen_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_lpen_interface_device::vtech_lpen_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_ioexp_device(mconfig, VTECH_LPEN_INTERFACE, tag, owner, clock) { } diff --git a/src/devices/bus/vtech/ioexp/lpen.h b/src/devices/bus/vtech/ioexp/lpen.h index 95759e5fcff..285d884da44 100644 --- a/src/devices/bus/vtech/ioexp/lpen.h +++ b/src/devices/bus/vtech/ioexp/lpen.h @@ -24,7 +24,7 @@ class vtech_lpen_interface_device : public vtech_ioexp_device { public: // construction/destruction - vtech_lpen_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_lpen_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::CONTROLS; } diff --git a/src/devices/bus/vtech/ioexp/printer.cpp b/src/devices/bus/vtech/ioexp/printer.cpp index b5eaa4e8a4b..1947862a911 100644 --- a/src/devices/bus/vtech/ioexp/printer.cpp +++ b/src/devices/bus/vtech/ioexp/printer.cpp @@ -55,7 +55,7 @@ void vtech_printer_interface_device::device_add_mconfig(machine_config &config) // vtech_printer_interface_device - constructor //------------------------------------------------- -vtech_printer_interface_device::vtech_printer_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_printer_interface_device::vtech_printer_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_ioexp_device(mconfig, VTECH_PRINTER_INTERFACE, tag, owner, clock), m_centronics(*this, "centronics"), m_latch(*this, "latch"), diff --git a/src/devices/bus/vtech/ioexp/printer.h b/src/devices/bus/vtech/ioexp/printer.h index be25c7fd614..8668eb80901 100644 --- a/src/devices/bus/vtech/ioexp/printer.h +++ b/src/devices/bus/vtech/ioexp/printer.h @@ -27,7 +27,7 @@ class vtech_printer_interface_device : public vtech_ioexp_device { public: // construction/destruction - vtech_printer_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_printer_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/vtech/memexp/floppy.cpp b/src/devices/bus/vtech/memexp/floppy.cpp index 4e641947aaf..55f1c249309 100644 --- a/src/devices/bus/vtech/memexp/floppy.cpp +++ b/src/devices/bus/vtech/memexp/floppy.cpp @@ -95,7 +95,7 @@ void vtech_floppy_controller_device::device_add_mconfig(machine_config &config) // vtech_floppy_controller_device - constructor //------------------------------------------------- -vtech_floppy_controller_device::vtech_floppy_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_floppy_controller_device::vtech_floppy_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_memexp_device(mconfig, VTECH_FLOPPY_CONTROLLER, tag, owner, clock), m_memexp(*this, "mem"), m_floppy0(*this, "0"), diff --git a/src/devices/bus/vtech/memexp/floppy.h b/src/devices/bus/vtech/memexp/floppy.h index 167cbf5ba63..abe89105ed1 100644 --- a/src/devices/bus/vtech/memexp/floppy.h +++ b/src/devices/bus/vtech/memexp/floppy.h @@ -28,7 +28,7 @@ class vtech_floppy_controller_device : public vtech_memexp_device { public: // construction/destruction - vtech_floppy_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_floppy_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/vtech/memexp/memexp.cpp b/src/devices/bus/vtech/memexp/memexp.cpp index 74d2213009a..b5df1a3040d 100644 --- a/src/devices/bus/vtech/memexp/memexp.cpp +++ b/src/devices/bus/vtech/memexp/memexp.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(VTECH_MEMEXP_SLOT, vtech_memexp_slot_device, "vtech_memexp_sl // vtech_memexp_slot_device - constructor //------------------------------------------------- -vtech_memexp_slot_device::vtech_memexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_memexp_slot_device::vtech_memexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VTECH_MEMEXP_SLOT, tag, owner, clock), device_single_card_slot_interface<device_vtech_memexp_interface>(mconfig, *this), m_memspace(*this, finder_base::DUMMY_TAG, -1), @@ -36,6 +36,10 @@ vtech_memexp_slot_device::vtech_memexp_slot_device(const machine_config &mconfig m_nmi_handler(*this), m_reset_handler(*this) { + option_reset(); + vtech_memexp_carts(*this); + set_default_option(nullptr); + set_fixed(false); } //------------------------------------------------- @@ -125,7 +129,7 @@ device_vtech_memexp_interface::~device_vtech_memexp_interface() // vtech_memexp_device - constructor //------------------------------------------------- -vtech_memexp_device::vtech_memexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +vtech_memexp_device::vtech_memexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_vtech_memexp_interface(mconfig, *this), m_mem(*this, "memspace"), diff --git a/src/devices/bus/vtech/memexp/memexp.h b/src/devices/bus/vtech/memexp/memexp.h index 5fd3ee6a449..75013fe98a4 100644 --- a/src/devices/bus/vtech/memexp/memexp.h +++ b/src/devices/bus/vtech/memexp/memexp.h @@ -53,15 +53,7 @@ class vtech_memexp_slot_device : public device_t, public device_single_card_slot friend class device_vtech_memexp_interface; public: // construction/destruction - vtech_memexp_slot_device(machine_config const &mconfig, char const *tag, device_t *owner) - : vtech_memexp_slot_device(mconfig, tag, owner, (uint32_t)0) - { - option_reset(); - vtech_memexp_carts(*this); - set_default_option(nullptr); - set_fixed(false); - } - vtech_memexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_memexp_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~vtech_memexp_slot_device(); template <typename T> void set_memspace(T &&tag, int spacenum) { m_memspace.set_tag(std::forward<T>(tag), spacenum); } @@ -114,7 +106,7 @@ class vtech_memexp_device : public device_t, public device_vtech_memexp_interfac { public: // construction/destruction - vtech_memexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vtech_memexp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // from host virtual uint8_t mreq_r(offs_t offset) override; diff --git a/src/devices/bus/vtech/memexp/memory.cpp b/src/devices/bus/vtech/memexp/memory.cpp index bfac5f06b4c..b770f4a66f9 100644 --- a/src/devices/bus/vtech/memexp/memory.cpp +++ b/src/devices/bus/vtech/memexp/memory.cpp @@ -38,7 +38,7 @@ void vtech_laser110_16k_device::mem_map(address_map &map) // laser110_16k_device - constructor //------------------------------------------------- -vtech_laser110_16k_device::vtech_laser110_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_laser110_16k_device::vtech_laser110_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_memexp_device(mconfig, VTECH_LASER110_16K, tag, owner, clock) { } @@ -71,7 +71,7 @@ void vtech_laser210_16k_device::mem_map(address_map &map) // vtech_laser210_16k_device - constructor //------------------------------------------------- -vtech_laser210_16k_device::vtech_laser210_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_laser210_16k_device::vtech_laser210_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_memexp_device(mconfig, VTECH_LASER210_16K, tag, owner, clock) { } @@ -104,7 +104,7 @@ void vtech_laser310_16k_device::mem_map(address_map &map) // vtech_laser310_16k_device - constructor //------------------------------------------------- -vtech_laser310_16k_device::vtech_laser310_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_laser310_16k_device::vtech_laser310_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_memexp_device(mconfig, VTECH_LASER310_16K, tag, owner, clock) { } @@ -148,7 +148,7 @@ void vtech_laser_64k_device::io_map(address_map &map) // vtech_laser_64k_device - constructor //------------------------------------------------- -vtech_laser_64k_device::vtech_laser_64k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_laser_64k_device::vtech_laser_64k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_memexp_device(mconfig, VTECH_LASER_64K, tag, owner, clock), m_fixed_bank(*this, "fixed_bank"), m_bank(*this, "bank") diff --git a/src/devices/bus/vtech/memexp/memory.h b/src/devices/bus/vtech/memexp/memory.h index 5af19fd27f1..c61844fb447 100644 --- a/src/devices/bus/vtech/memexp/memory.h +++ b/src/devices/bus/vtech/memexp/memory.h @@ -24,7 +24,7 @@ class vtech_laser110_16k_device : public vtech_memexp_device { public: // construction/destruction - vtech_laser110_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_laser110_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -38,7 +38,7 @@ class vtech_laser210_16k_device : public vtech_memexp_device { public: // construction/destruction - vtech_laser210_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_laser210_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -52,7 +52,7 @@ class vtech_laser310_16k_device : public vtech_memexp_device { public: // construction/destruction - vtech_laser310_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_laser310_16k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -66,7 +66,7 @@ class vtech_laser_64k_device : public vtech_memexp_device { public: // construction/destruction - vtech_laser_64k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_laser_64k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/bus/vtech/memexp/rs232.cpp b/src/devices/bus/vtech/memexp/rs232.cpp index cf07b2055d6..ea2d65f14b6 100644 --- a/src/devices/bus/vtech/memexp/rs232.cpp +++ b/src/devices/bus/vtech/memexp/rs232.cpp @@ -67,7 +67,7 @@ void vtech_rs232_interface_device::device_add_mconfig(machine_config &config) // vtech_rs232_interface_device - constructor //------------------------------------------------- -vtech_rs232_interface_device::vtech_rs232_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_rs232_interface_device::vtech_rs232_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_memexp_device(mconfig, VTECH_RS232_INTERFACE, tag, owner, clock), m_rs232(*this, "rs232"), m_rx(1) diff --git a/src/devices/bus/vtech/memexp/rs232.h b/src/devices/bus/vtech/memexp/rs232.h index 30af4a2eaaf..75749c83742 100644 --- a/src/devices/bus/vtech/memexp/rs232.h +++ b/src/devices/bus/vtech/memexp/rs232.h @@ -25,7 +25,7 @@ class vtech_rs232_interface_device : public vtech_memexp_device { public: // construction/destruction - vtech_rs232_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_rs232_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/vtech/memexp/rtty.cpp b/src/devices/bus/vtech/memexp/rtty.cpp index 6a0f96c58a8..337cd5c848b 100644 --- a/src/devices/bus/vtech/memexp/rtty.cpp +++ b/src/devices/bus/vtech/memexp/rtty.cpp @@ -52,7 +52,7 @@ const tiny_rom_entry *vtech_rtty_interface_device::device_rom_region() const // vtech_rtty_interface_device - constructor //------------------------------------------------- -vtech_rtty_interface_device::vtech_rtty_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_rtty_interface_device::vtech_rtty_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_memexp_device(mconfig, VTECH_RTTY_INTERFACE, tag, owner, clock) { } diff --git a/src/devices/bus/vtech/memexp/rtty.h b/src/devices/bus/vtech/memexp/rtty.h index 62d1f5b94af..24796e6b5ea 100644 --- a/src/devices/bus/vtech/memexp/rtty.h +++ b/src/devices/bus/vtech/memexp/rtty.h @@ -24,7 +24,7 @@ class vtech_rtty_interface_device : public vtech_memexp_device { public: // construction/destruction - vtech_rtty_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_rtty_interface_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/vtech/memexp/sdloader.cpp b/src/devices/bus/vtech/memexp/sdloader.cpp index 84df085c86a..7e533c0bc7c 100644 --- a/src/devices/bus/vtech/memexp/sdloader.cpp +++ b/src/devices/bus/vtech/memexp/sdloader.cpp @@ -87,7 +87,7 @@ void vtech_sdloader_device::device_add_mconfig(machine_config &config) { vtech_memexp_device::device_add_mconfig(config); - SPI_SDCARD(config, m_sdcard, 0); + SPI_SDCARD(config, m_sdcard); m_sdcard->spi_miso_callback().set(FUNC(vtech_sdloader_device::spi_miso_w)); } @@ -100,7 +100,7 @@ void vtech_sdloader_device::device_add_mconfig(machine_config &config) // vtech_sdloader_device - constructor //------------------------------------------------- -vtech_sdloader_device::vtech_sdloader_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_sdloader_device::vtech_sdloader_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_memexp_device(mconfig, VTECH_SDLOADER, tag, owner, clock), m_sdcard(*this, "sdcard"), m_dosbank(*this, "dosbank"), diff --git a/src/devices/bus/vtech/memexp/sdloader.h b/src/devices/bus/vtech/memexp/sdloader.h index fe1fa6ea313..8ab77f287bd 100644 --- a/src/devices/bus/vtech/memexp/sdloader.h +++ b/src/devices/bus/vtech/memexp/sdloader.h @@ -25,7 +25,7 @@ class vtech_sdloader_device : public vtech_memexp_device { public: // construction/destruction - vtech_sdloader_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_sdloader_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::DISK; } diff --git a/src/devices/bus/vtech/memexp/wordpro.cpp b/src/devices/bus/vtech/memexp/wordpro.cpp index 811cb953a83..7bffe76b49a 100644 --- a/src/devices/bus/vtech/memexp/wordpro.cpp +++ b/src/devices/bus/vtech/memexp/wordpro.cpp @@ -52,7 +52,7 @@ const tiny_rom_entry *vtech_wordpro_device::device_rom_region() const // vtech_wordpro_device - constructor //------------------------------------------------- -vtech_wordpro_device::vtech_wordpro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vtech_wordpro_device::vtech_wordpro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vtech_memexp_device(mconfig, VTECH_WORDPRO, tag, owner, clock) { } diff --git a/src/devices/bus/vtech/memexp/wordpro.h b/src/devices/bus/vtech/memexp/wordpro.h index 0515a12bb36..e5484556923 100644 --- a/src/devices/bus/vtech/memexp/wordpro.h +++ b/src/devices/bus/vtech/memexp/wordpro.h @@ -24,7 +24,7 @@ class vtech_wordpro_device : public vtech_memexp_device { public: // construction/destruction - vtech_wordpro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vtech_wordpro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/bus/wangpc/emb.cpp b/src/devices/bus/wangpc/emb.cpp index 6a69c1a0fee..4aaba0da0da 100644 --- a/src/devices/bus/wangpc/emb.cpp +++ b/src/devices/bus/wangpc/emb.cpp @@ -44,7 +44,7 @@ DEFINE_DEVICE_TYPE(WANGPC_EMB, wangpc_emb_device, "wangpc_emb", "Wang PC-PM031-B // wangpc_emb_device - constructor //------------------------------------------------- -wangpc_emb_device::wangpc_emb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wangpc_emb_device::wangpc_emb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WANGPC_EMB, tag, owner, clock), device_wangpcbus_card_interface(mconfig, *this), m_ram(*this, "ram", RAM_SIZE, ENDIANNESS_LITTLE), diff --git a/src/devices/bus/wangpc/emb.h b/src/devices/bus/wangpc/emb.h index 1f23fed9f09..10ad045bf06 100644 --- a/src/devices/bus/wangpc/emb.h +++ b/src/devices/bus/wangpc/emb.h @@ -26,7 +26,7 @@ class wangpc_emb_device : public device_t, { public: // construction/destruction - wangpc_emb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wangpc_emb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/wangpc/lic.cpp b/src/devices/bus/wangpc/lic.cpp index f56c673fd26..1ae230fa8c2 100644 --- a/src/devices/bus/wangpc/lic.cpp +++ b/src/devices/bus/wangpc/lic.cpp @@ -63,7 +63,7 @@ void wangpc_lic_device::device_add_mconfig(machine_config &config) // wangpc_lic_device - constructor //------------------------------------------------- -wangpc_lic_device::wangpc_lic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wangpc_lic_device::wangpc_lic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WANGPC_LIC, tag, owner, clock), device_wangpcbus_card_interface(mconfig, *this) { diff --git a/src/devices/bus/wangpc/lic.h b/src/devices/bus/wangpc/lic.h index 8ead2c65f0a..e798f0c1de5 100644 --- a/src/devices/bus/wangpc/lic.h +++ b/src/devices/bus/wangpc/lic.h @@ -26,7 +26,7 @@ class wangpc_lic_device : public device_t, { public: // construction/destruction - wangpc_lic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wangpc_lic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/wangpc/lvc.cpp b/src/devices/bus/wangpc/lvc.cpp index 2eb45e47db0..948e8c074c0 100644 --- a/src/devices/bus/wangpc/lvc.cpp +++ b/src/devices/bus/wangpc/lvc.cpp @@ -160,7 +160,7 @@ inline void wangpc_lvc_device::set_irq(int state) // wangpc_lvc_device - constructor //------------------------------------------------- -wangpc_lvc_device::wangpc_lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wangpc_lvc_device::wangpc_lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WANGPC_LVC, tag, owner, clock), device_wangpcbus_card_interface(mconfig, *this), m_crtc(*this, MC6845_TAG), diff --git a/src/devices/bus/wangpc/lvc.h b/src/devices/bus/wangpc/lvc.h index 7f0cb5ac816..9947ec7c3e8 100644 --- a/src/devices/bus/wangpc/lvc.h +++ b/src/devices/bus/wangpc/lvc.h @@ -27,7 +27,7 @@ class wangpc_lvc_device : public device_t, { public: // construction/destruction - wangpc_lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wangpc_lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/wangpc/mcc.cpp b/src/devices/bus/wangpc/mcc.cpp index 7eb56eb479e..aaf89f9be24 100644 --- a/src/devices/bus/wangpc/mcc.cpp +++ b/src/devices/bus/wangpc/mcc.cpp @@ -57,8 +57,8 @@ DEFINE_DEVICE_TYPE(WANGPC_MCC, wangpc_mcc_device, "wangpc_mcc", "Wang PC-PM043 M void wangpc_mcc_device::device_add_mconfig(machine_config &config) { - Z80SIO(config, m_sio, 4000000); // SIO/2? - Z80DART(config, m_dart, 4000000); + Z80SIO(config, m_sio, XTAL::u(4000000)); // SIO/2? + Z80DART(config, m_dart, XTAL::u(4000000)); } @@ -93,7 +93,7 @@ inline void wangpc_mcc_device::set_irq(int state) // wangpc_mcc_device - constructor //------------------------------------------------- -wangpc_mcc_device::wangpc_mcc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wangpc_mcc_device::wangpc_mcc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WANGPC_MCC, tag, owner, clock), device_wangpcbus_card_interface(mconfig, *this), m_sio(*this, Z80SIO2_TAG), diff --git a/src/devices/bus/wangpc/mcc.h b/src/devices/bus/wangpc/mcc.h index 9aa0d4adee1..02ec34cf05b 100644 --- a/src/devices/bus/wangpc/mcc.h +++ b/src/devices/bus/wangpc/mcc.h @@ -27,7 +27,7 @@ class wangpc_mcc_device : public device_t, { public: // construction/destruction - wangpc_mcc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wangpc_mcc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/wangpc/mvc.cpp b/src/devices/bus/wangpc/mvc.cpp index 12aae997900..8d88773b9ac 100644 --- a/src/devices/bus/wangpc/mvc.cpp +++ b/src/devices/bus/wangpc/mvc.cpp @@ -182,7 +182,7 @@ inline void wangpc_mvc_device::set_irq(int state) // wangpc_mvc_device - constructor //------------------------------------------------- -wangpc_mvc_device::wangpc_mvc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wangpc_mvc_device::wangpc_mvc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WANGPC_MVC, tag, owner, clock), device_wangpcbus_card_interface(mconfig, *this), m_crtc(*this, MC6845_TAG), diff --git a/src/devices/bus/wangpc/mvc.h b/src/devices/bus/wangpc/mvc.h index 9911952f6ac..49c3f483367 100644 --- a/src/devices/bus/wangpc/mvc.h +++ b/src/devices/bus/wangpc/mvc.h @@ -27,7 +27,7 @@ class wangpc_mvc_device : public device_t, { public: // construction/destruction - wangpc_mvc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wangpc_mvc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/wangpc/rtc.cpp b/src/devices/bus/wangpc/rtc.cpp index 8cd5e055ac6..1449fbd38c3 100644 --- a/src/devices/bus/wangpc/rtc.cpp +++ b/src/devices/bus/wangpc/rtc.cpp @@ -107,20 +107,20 @@ static const z80_daisy_config wangpc_rtc_daisy_chain[] = void wangpc_rtc_device::device_add_mconfig(machine_config &config) { - Z80(config, m_maincpu, 2000000); + Z80(config, m_maincpu, XTAL::u(2000000)); m_maincpu->set_daisy_config(wangpc_rtc_daisy_chain); m_maincpu->set_addrmap(AS_PROGRAM, &wangpc_rtc_device::wangpc_rtc_mem); m_maincpu->set_addrmap(AS_IO, &wangpc_rtc_device::wangpc_rtc_io); - AM9517A(config, m_dmac, 2000000); + AM9517A(config, m_dmac, XTAL::u(2000000)); - Z80CTC(config, m_ctc0, 2000000); + Z80CTC(config, m_ctc0, XTAL::u(2000000)); m_ctc0->intr_callback().set_inputline(m_maincpu, INPUT_LINE_IRQ0); - Z80CTC(config, m_ctc1, 2000000); + Z80CTC(config, m_ctc1, XTAL::u(2000000)); m_ctc1->intr_callback().set_inputline(m_maincpu, INPUT_LINE_IRQ0); - Z80SIO(config, m_sio, 2000000); // SIO/0? + Z80SIO(config, m_sio, XTAL::u(2000000)); // SIO/0? m_sio->out_int_callback().set_inputline(m_maincpu, INPUT_LINE_IRQ0); } @@ -178,7 +178,7 @@ ioport_constructor wangpc_rtc_device::device_input_ports() const // wangpc_rtc_device - constructor //------------------------------------------------- -wangpc_rtc_device::wangpc_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wangpc_rtc_device::wangpc_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WANGPC_RTC, tag, owner, clock), device_wangpcbus_card_interface(mconfig, *this), m_maincpu(*this, Z80_TAG), diff --git a/src/devices/bus/wangpc/rtc.h b/src/devices/bus/wangpc/rtc.h index 4366536ccdf..b0cfd3953ee 100644 --- a/src/devices/bus/wangpc/rtc.h +++ b/src/devices/bus/wangpc/rtc.h @@ -30,7 +30,7 @@ class wangpc_rtc_device : public device_t, { public: // construction/destruction - wangpc_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wangpc_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/wangpc/tig.cpp b/src/devices/bus/wangpc/tig.cpp index f0c00ed3cc3..45c6f540e20 100644 --- a/src/devices/bus/wangpc/tig.cpp +++ b/src/devices/bus/wangpc/tig.cpp @@ -145,7 +145,7 @@ void wangpc_tig_device::device_add_mconfig(machine_config &config) // wangpc_tig_device - constructor //------------------------------------------------- -wangpc_tig_device::wangpc_tig_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wangpc_tig_device::wangpc_tig_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WANGPC_TIG, tag, owner, clock), device_wangpcbus_card_interface(mconfig, *this), m_hgdc0(*this, UPD7720_0_TAG), diff --git a/src/devices/bus/wangpc/tig.h b/src/devices/bus/wangpc/tig.h index 0e95eb42676..80146296d6b 100644 --- a/src/devices/bus/wangpc/tig.h +++ b/src/devices/bus/wangpc/tig.h @@ -28,7 +28,7 @@ class wangpc_tig_device : public device_t, { public: // construction/destruction - wangpc_tig_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wangpc_tig_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/wangpc/wangpc.cpp b/src/devices/bus/wangpc/wangpc.cpp index 7f209465d2d..efbe327fdb0 100644 --- a/src/devices/bus/wangpc/wangpc.cpp +++ b/src/devices/bus/wangpc/wangpc.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(WANGPC_BUS_SLOT, wangpcbus_slot_device, "wangpcbus_slot", "Wa // wangpcbus_slot_device - constructor //------------------------------------------------- -wangpcbus_slot_device::wangpcbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wangpcbus_slot_device::wangpcbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WANGPC_BUS_SLOT, tag, owner, clock), device_single_card_slot_interface<device_wangpcbus_card_interface>(mconfig, *this), m_bus(*this, finder_base::DUMMY_TAG), @@ -51,7 +51,7 @@ void wangpcbus_slot_device::device_start() // wangpcbus_device - constructor //------------------------------------------------- -wangpcbus_device::wangpcbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wangpcbus_device::wangpcbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WANGPC_BUS, tag, owner, clock), m_write_irq2(*this), m_write_irq3(*this), diff --git a/src/devices/bus/wangpc/wangpc.h b/src/devices/bus/wangpc/wangpc.h index 05ca1908f75..db1edd72564 100644 --- a/src/devices/bus/wangpc/wangpc.h +++ b/src/devices/bus/wangpc/wangpc.h @@ -33,7 +33,7 @@ public: // construction/destruction template <typename T, typename U> wangpcbus_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&bus, U &&opts, char const *dflt, int sid) - : wangpcbus_slot_device(mconfig, tag, owner, 0) + : wangpcbus_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); @@ -42,7 +42,7 @@ public: set_bus(std::forward<T>(bus)); set_bus_slot(sid); } - wangpcbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + wangpcbus_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration template <typename T> void set_bus(T &&tag) { m_bus.set_tag(std::forward<T>(tag)); } @@ -69,7 +69,7 @@ class wangpcbus_device : public device_t { public: // construction/destruction - wangpcbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wangpcbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~wangpcbus_device() { m_device_list.detach_all(); } auto irq2_wr_callback() { return m_write_irq2.bind(); } diff --git a/src/devices/bus/wangpc/wdc.cpp b/src/devices/bus/wangpc/wdc.cpp index ddb6d07163b..10dc18cbca7 100644 --- a/src/devices/bus/wangpc/wdc.cpp +++ b/src/devices/bus/wangpc/wdc.cpp @@ -94,15 +94,15 @@ void wangpc_wdc_device::wangpc_wdc_io(address_map &map) void wangpc_wdc_device::device_add_mconfig(machine_config &config) { - Z80(config, m_maincpu, 2000000); // XTAL(10'000'000) / ? + Z80(config, m_maincpu, XTAL::u(2000000)); // XTAL(10'000'000) / ? //m_maincpu->set_daisy_config(wangpc_wdc_daisy_chain); m_maincpu->set_addrmap(AS_PROGRAM, &wangpc_wdc_device::wangpc_wdc_mem); m_maincpu->set_addrmap(AS_IO, &wangpc_wdc_device::wangpc_wdc_io); - Z80CTC(config, m_ctc, 2000000); + Z80CTC(config, m_ctc, XTAL::u(2000000)); m_ctc->intr_callback().set_inputline(m_maincpu, INPUT_LINE_IRQ0); - SCSIHD(config, "harddisk0", 0); + SCSIHD(config, "harddisk0"); } @@ -134,7 +134,7 @@ inline void wangpc_wdc_device::set_irq(int state) // wangpc_wdc_device - constructor //------------------------------------------------- -wangpc_wdc_device::wangpc_wdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wangpc_wdc_device::wangpc_wdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WANGPC_WDC, tag, owner, clock), device_wangpcbus_card_interface(mconfig, *this), m_maincpu(*this, Z80_TAG), diff --git a/src/devices/bus/wangpc/wdc.h b/src/devices/bus/wangpc/wdc.h index cb09025e13e..32762fc5b85 100644 --- a/src/devices/bus/wangpc/wdc.h +++ b/src/devices/bus/wangpc/wdc.h @@ -29,7 +29,7 @@ class wangpc_wdc_device : public device_t, { public: // construction/destruction - wangpc_wdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wangpc_wdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/wswan/rom.cpp b/src/devices/bus/wswan/rom.cpp index 2d089989989..1f839c7f8e3 100644 --- a/src/devices/bus/wswan/rom.cpp +++ b/src/devices/bus/wswan/rom.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(WS_ROM_EEPROM, ws_rom_eeprom_device, "ws_eeprom", "Wonderswan DEFINE_DEVICE_TYPE(WS_ROM_WWITCH, ws_wwitch_device, "ws_wwitch", "WonderWitch") -ws_rom_device::ws_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +ws_rom_device::ws_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_ws_cart_interface(mconfig, *this), m_base20(0), @@ -46,31 +46,31 @@ ws_rom_device::ws_rom_device(const machine_config &mconfig, device_type type, co { } -ws_rom_device::ws_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +ws_rom_device::ws_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ws_rom_device(mconfig, WS_ROM_STD, tag, owner, clock) { } -ws_rom_sram_device::ws_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +ws_rom_sram_device::ws_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ws_rom_device(mconfig, WS_ROM_SRAM, tag, owner, clock), m_nvram_base(0) { } -ws_rom_sram_device::ws_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +ws_rom_sram_device::ws_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ws_rom_device(mconfig, type, tag, owner, clock), m_nvram_base(0) { } -ws_rom_eeprom_device::ws_rom_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +ws_rom_eeprom_device::ws_rom_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ws_rom_device(mconfig, WS_ROM_EEPROM, tag, owner, clock), m_eeprom_mode(0), m_eeprom_address(0), m_eeprom_command(0), m_eeprom_start(0), m_eeprom_write_enabled(0) { } -ws_wwitch_device::ws_wwitch_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +ws_wwitch_device::ws_wwitch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ws_rom_sram_device(mconfig, WS_ROM_WWITCH, tag, owner, clock) { } diff --git a/src/devices/bus/wswan/rom.h b/src/devices/bus/wswan/rom.h index 9a47ebf8023..f0c50799b2f 100644 --- a/src/devices/bus/wswan/rom.h +++ b/src/devices/bus/wswan/rom.h @@ -13,7 +13,7 @@ class ws_rom_device : public device_t, { public: // construction/destruction - ws_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ws_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual u16 read_rom20(offs_t offset, u16 mem_mask) override; @@ -23,7 +23,7 @@ public: virtual void write_io(offs_t offset, u16 data, u16 mem_mask) override; protected: - ws_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + ws_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -56,7 +56,7 @@ class ws_rom_sram_device : public ws_rom_device { public: // construction/destruction - ws_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ws_rom_sram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual u16 read_ram(offs_t offset, u16 mem_mask) override; @@ -64,7 +64,7 @@ public: virtual void write_io(offs_t offset, u16 data, u16 mem_mask) override; protected: - ws_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + ws_rom_sram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -81,7 +81,7 @@ class ws_rom_eeprom_device : public ws_rom_device { public: // construction/destruction - ws_rom_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ws_rom_eeprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual u16 read_io(offs_t offset, u16 mem_mask) override; @@ -105,7 +105,7 @@ class ws_wwitch_device : public ws_rom_sram_device { public: // construction/destruction - ws_wwitch_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ws_wwitch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // reading and writing virtual u16 read_ram(offs_t offset, u16 mem_mask) override; diff --git a/src/devices/bus/wswan/slot.cpp b/src/devices/bus/wswan/slot.cpp index 959f43f4bd0..85117073120 100644 --- a/src/devices/bus/wswan/slot.cpp +++ b/src/devices/bus/wswan/slot.cpp @@ -76,7 +76,7 @@ void device_ws_cart_interface::nvram_alloc(u32 size) //------------------------------------------------- // ws_cart_slot_device - constructor //------------------------------------------------- -ws_cart_slot_device::ws_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +ws_cart_slot_device::ws_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WS_CART_SLOT, tag, owner, clock), device_cartrom_image_interface(mconfig, *this), device_single_card_slot_interface<device_ws_cart_interface>(mconfig, *this), diff --git a/src/devices/bus/wswan/slot.h b/src/devices/bus/wswan/slot.h index fd9d1928b92..e4a1c4e4573 100644 --- a/src/devices/bus/wswan/slot.h +++ b/src/devices/bus/wswan/slot.h @@ -134,7 +134,7 @@ class ws_cart_slot_device : public device_t, public: // construction/destruction template <typename T> - ws_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&opts, const char *dflt) + ws_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&opts, const char *dflt) : ws_cart_slot_device(mconfig, tag, owner, clock) { option_reset(); @@ -142,7 +142,7 @@ public: set_default_option(dflt); set_fixed(false); } - ws_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ws_cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~ws_cart_slot_device(); // image-level overrides diff --git a/src/devices/bus/x68k/x68k_midi.cpp b/src/devices/bus/x68k/x68k_midi.cpp index 2f55ce3781f..b069404920e 100644 --- a/src/devices/bus/x68k/x68k_midi.cpp +++ b/src/devices/bus/x68k/x68k_midi.cpp @@ -29,7 +29,7 @@ void x68k_midi_device::device_add_mconfig(machine_config &config) } -x68k_midi_device::x68k_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +x68k_midi_device::x68k_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, X68K_MIDI, tag, owner, clock) , device_x68k_expansion_card_interface(mconfig, *this) , m_slot(nullptr) diff --git a/src/devices/bus/x68k/x68k_midi.h b/src/devices/bus/x68k/x68k_midi.h index b43968d468b..4213bf42a3c 100644 --- a/src/devices/bus/x68k/x68k_midi.h +++ b/src/devices/bus/x68k/x68k_midi.h @@ -22,7 +22,7 @@ class x68k_midi_device : public device_t, { public: // construction/destruction - x68k_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + x68k_midi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/bus/x68k/x68k_neptunex.cpp b/src/devices/bus/x68k/x68k_neptunex.cpp index b5c10545cd9..5aadfead162 100644 --- a/src/devices/bus/x68k/x68k_neptunex.cpp +++ b/src/devices/bus/x68k/x68k_neptunex.cpp @@ -19,13 +19,13 @@ DEFINE_DEVICE_TYPE(X68K_NEPTUNEX, x68k_neptune_device, "x68k_neptunex", "Neptune // device machine config void x68k_neptune_device::device_add_mconfig(machine_config &config) { - DP8390D(config, m_dp8390, 0); + DP8390D(config, m_dp8390); m_dp8390->irq_callback().set(FUNC(x68k_neptune_device::x68k_neptune_irq_w)); m_dp8390->mem_read_callback().set(FUNC(x68k_neptune_device::x68k_neptune_mem_read)); m_dp8390->mem_write_callback().set(FUNC(x68k_neptune_device::x68k_neptune_mem_write)); } -x68k_neptune_device::x68k_neptune_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +x68k_neptune_device::x68k_neptune_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, X68K_NEPTUNEX, tag, owner, clock) , device_x68k_expansion_card_interface(mconfig, *this) , m_slot(nullptr) diff --git a/src/devices/bus/x68k/x68k_neptunex.h b/src/devices/bus/x68k/x68k_neptunex.h index b60a58d46e1..aa26ddf4bd4 100644 --- a/src/devices/bus/x68k/x68k_neptunex.h +++ b/src/devices/bus/x68k/x68k_neptunex.h @@ -25,7 +25,7 @@ class x68k_neptune_device : public device_t, { public: // construction/destruction - x68k_neptune_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + x68k_neptune_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t x68k_neptune_port_r(offs_t offset, uint16_t mem_mask = ~0); void x68k_neptune_port_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/bus/x68k/x68k_scsiext.cpp b/src/devices/bus/x68k/x68k_scsiext.cpp index bec669ef1f5..91777b3df57 100644 --- a/src/devices/bus/x68k/x68k_scsiext.cpp +++ b/src/devices/bus/x68k/x68k_scsiext.cpp @@ -54,7 +54,7 @@ void x68k_scsiext_device::device_add_mconfig(machine_config &config) m_spc->drq_cb().set(FUNC(x68k_scsiext_device::drq_w)); } -x68k_scsiext_device::x68k_scsiext_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +x68k_scsiext_device::x68k_scsiext_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, X68K_SCSIEXT, tag, owner, clock) , device_x68k_expansion_card_interface(mconfig, *this) , m_slot(nullptr), diff --git a/src/devices/bus/x68k/x68k_scsiext.h b/src/devices/bus/x68k/x68k_scsiext.h index c3be3ab84b5..680eda03d2a 100644 --- a/src/devices/bus/x68k/x68k_scsiext.h +++ b/src/devices/bus/x68k/x68k_scsiext.h @@ -19,7 +19,7 @@ class x68k_scsiext_device : public device_t, { public: // construction/destruction - x68k_scsiext_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + x68k_scsiext_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t register_r(offs_t offset); void register_w(offs_t offset, uint8_t data); diff --git a/src/devices/bus/x68k/x68kexp.cpp b/src/devices/bus/x68k/x68kexp.cpp index 398c507802c..8159b25640f 100644 --- a/src/devices/bus/x68k/x68kexp.cpp +++ b/src/devices/bus/x68k/x68kexp.cpp @@ -45,7 +45,7 @@ uint8_t device_x68k_expansion_card_interface::iack4() // LIVE DEVICE //************************************************************************** -x68k_expansion_slot_device::x68k_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +x68k_expansion_slot_device::x68k_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, X68K_EXPANSION_SLOT, tag, owner, clock), device_single_card_slot_interface<device_x68k_expansion_card_interface>(mconfig, *this), m_space(*this, finder_base::DUMMY_TAG, -1), diff --git a/src/devices/bus/x68k/x68kexp.h b/src/devices/bus/x68k/x68kexp.h index 8b46c8e9cf5..9633ec4ff0a 100644 --- a/src/devices/bus/x68k/x68kexp.h +++ b/src/devices/bus/x68k/x68kexp.h @@ -99,14 +99,14 @@ public: // construction/destruction template <typename T> x68k_expansion_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : x68k_expansion_slot_device(mconfig, tag, owner, 0) + : x68k_expansion_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - x68k_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + x68k_expansion_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~x68k_expansion_slot_device(); template <typename T> void set_space(T &&tag, int spacenum) { m_space.set_tag(std::forward<T>(tag), spacenum); } diff --git a/src/devices/bus/z29_kbd/he191_3425.cpp b/src/devices/bus/z29_kbd/he191_3425.cpp index 5a52f363590..f1317d2be69 100644 --- a/src/devices/bus/z29_kbd/he191_3425.cpp +++ b/src/devices/bus/z29_kbd/he191_3425.cpp @@ -20,7 +20,7 @@ DEFINE_DEVICE_TYPE(HE191_3425, he191_3425_device, "he191_3425", "Heath HE 191-3425 Keyboard") -he191_3425_device::he191_3425_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +he191_3425_device::he191_3425_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HE191_3425, tag, owner, clock) , device_z29_keyboard_interface(mconfig, *this) , m_mcu(*this, "mcu") @@ -224,7 +224,7 @@ void he191_3425_device::device_add_mconfig(machine_config &config) mcu.t1_in_cb().set(FUNC(he191_3425_device::mcu_t1_r)); SPEAKER(config, "speaker").front_center(); - BEEP(config, m_buzzer, 1'000'000'000 / PERIOD_OF_555_ASTABLE_NSEC(RES_R(510), RES_R(510), CAP_U(1))); + BEEP(config, m_buzzer, XTAL::u(1'000'000'000) / PERIOD_OF_555_ASTABLE_NSEC(RES_R(510), RES_R(510), CAP_U(1))); m_buzzer->add_route(ALL_OUTPUTS, "speaker", 1.0); } diff --git a/src/devices/bus/z29_kbd/he191_3425.h b/src/devices/bus/z29_kbd/he191_3425.h index cf0129936fb..3bd343b9711 100644 --- a/src/devices/bus/z29_kbd/he191_3425.h +++ b/src/devices/bus/z29_kbd/he191_3425.h @@ -14,7 +14,7 @@ class he191_3425_device : public device_t, public device_z29_keyboard_interface { public: // device type constructor - he191_3425_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + he191_3425_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // miscellanous handlers DECLARE_WRITE_LINE_MEMBER(shift_reset); diff --git a/src/devices/bus/z29_kbd/keyboard.cpp b/src/devices/bus/z29_kbd/keyboard.cpp index 637bc8d4389..e88112360aa 100644 --- a/src/devices/bus/z29_kbd/keyboard.cpp +++ b/src/devices/bus/z29_kbd/keyboard.cpp @@ -68,7 +68,7 @@ DEFINE_DEVICE_TYPE(Z29_KEYBOARD, z29_keyboard_port_device, "z29_kbd", "Z-29 Keyboard Port") -z29_keyboard_port_device::z29_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +z29_keyboard_port_device::z29_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z29_KEYBOARD, tag, owner, clock) , device_single_card_slot_interface<device_z29_keyboard_interface>(mconfig, *this) , m_keyin_callback(*this) diff --git a/src/devices/bus/z29_kbd/keyboard.h b/src/devices/bus/z29_kbd/keyboard.h index 501d8bbe569..3aeb275a943 100644 --- a/src/devices/bus/z29_kbd/keyboard.h +++ b/src/devices/bus/z29_kbd/keyboard.h @@ -27,10 +27,10 @@ class z29_keyboard_port_device : public device_t, public device_single_card_slot public: // construction/destruction - z29_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + z29_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> z29_keyboard_port_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt) - : z29_keyboard_port_device(mconfig, tag, owner, 0U) + : z29_keyboard_port_device(mconfig, tag, owner) { option_reset(); opts(*this); diff --git a/src/devices/bus/z29_kbd/md_kbd.cpp b/src/devices/bus/z29_kbd/md_kbd.cpp index 1a313af10ce..2bb996f37d3 100644 --- a/src/devices/bus/z29_kbd/md_kbd.cpp +++ b/src/devices/bus/z29_kbd/md_kbd.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(MD_KEYBOARD, md_keyboard_device, "md_kbd", "Micro-Decision Keyboard") -md_keyboard_device::md_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +md_keyboard_device::md_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MD_KEYBOARD, tag, owner, clock) , device_z29_keyboard_interface(mconfig, *this) , m_mcu(*this, "mcu") @@ -262,7 +262,7 @@ void md_keyboard_device::device_add_mconfig(machine_config &config) m_mcu->t1_in_cb().set(FUNC(md_keyboard_device::mcu_t1_r)); SPEAKER(config, "speaker").front_center(); - BEEP(config, m_buzzer, 1'000'000'000 / PERIOD_OF_555_ASTABLE_NSEC(RES_R(510), RES_R(510), CAP_U(1))); + BEEP(config, m_buzzer, XTAL::u(1'000'000'000) / PERIOD_OF_555_ASTABLE_NSEC(RES_R(510), RES_R(510), CAP_U(1))); m_buzzer->add_route(ALL_OUTPUTS, "speaker", 1.0); } diff --git a/src/devices/bus/z29_kbd/md_kbd.h b/src/devices/bus/z29_kbd/md_kbd.h index 8a81b9a461d..85468bba15b 100644 --- a/src/devices/bus/z29_kbd/md_kbd.h +++ b/src/devices/bus/z29_kbd/md_kbd.h @@ -14,7 +14,7 @@ class md_keyboard_device : public device_t, public device_z29_keyboard_interface { public: // device type constructor - md_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + md_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/z88/flash.cpp b/src/devices/bus/z88/flash.cpp index bda80f4cff6..74363f5b27b 100644 --- a/src/devices/bus/z88/flash.cpp +++ b/src/devices/bus/z88/flash.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(Z88_1024K_FLASH, z88_1024k_flash_device, "z88_1024k_flash", " // z88_1024k_flash_device - constructor //------------------------------------------------- -z88_1024k_flash_device::z88_1024k_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z88_1024k_flash_device::z88_1024k_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z88_1024K_FLASH, tag, owner, clock) , device_z88cart_interface(mconfig, *this) , m_flash(*this, FLASH_TAG) diff --git a/src/devices/bus/z88/flash.h b/src/devices/bus/z88/flash.h index 12d3bf7b825..2c36b762570 100644 --- a/src/devices/bus/z88/flash.h +++ b/src/devices/bus/z88/flash.h @@ -19,7 +19,7 @@ class z88_1024k_flash_device : public device_t, { public: // construction/destruction - z88_1024k_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z88_1024k_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/bus/z88/ram.cpp b/src/devices/bus/z88/ram.cpp index 6ba311908f9..9223d22b1b1 100644 --- a/src/devices/bus/z88/ram.cpp +++ b/src/devices/bus/z88/ram.cpp @@ -32,12 +32,12 @@ DEFINE_DEVICE_TYPE(Z88_1024K_RAM, z88_1024k_ram_device, "z88_1024k_ram", "Z88 10 // z88_32k_ram_device - constructor //------------------------------------------------- -z88_32k_ram_device::z88_32k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z88_32k_ram_device::z88_32k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z88_32k_ram_device(mconfig, Z88_32K_RAM, tag, owner, clock) { } -z88_32k_ram_device::z88_32k_ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +z88_32k_ram_device::z88_32k_ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_nvram_interface(mconfig, *this) , device_z88cart_interface(mconfig, *this) @@ -49,7 +49,7 @@ z88_32k_ram_device::z88_32k_ram_device(const machine_config &mconfig, device_typ // z88_128k_ram_device - constructor //------------------------------------------------- -z88_128k_ram_device::z88_128k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z88_128k_ram_device::z88_128k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z88_32k_ram_device(mconfig, Z88_128K_RAM, tag, owner, clock) { } @@ -58,7 +58,7 @@ z88_128k_ram_device::z88_128k_ram_device(const machine_config &mconfig, const ch // z88_512k_ram_device - constructor //------------------------------------------------- -z88_512k_ram_device::z88_512k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z88_512k_ram_device::z88_512k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z88_32k_ram_device(mconfig, Z88_512K_RAM, tag, owner, clock) { } @@ -67,7 +67,7 @@ z88_512k_ram_device::z88_512k_ram_device(const machine_config &mconfig, const ch // z88_1024k_ram_device - constructor //------------------------------------------------- -z88_1024k_ram_device::z88_1024k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z88_1024k_ram_device::z88_1024k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z88_32k_ram_device(mconfig, Z88_1024K_RAM, tag, owner, clock) { } diff --git a/src/devices/bus/z88/ram.h b/src/devices/bus/z88/ram.h index 96aafd82e24..4ea81667e39 100644 --- a/src/devices/bus/z88/ram.h +++ b/src/devices/bus/z88/ram.h @@ -19,10 +19,10 @@ class z88_32k_ram_device : public device_t, { public: // construction/destruction - z88_32k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z88_32k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - z88_32k_ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + z88_32k_ram_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -49,7 +49,7 @@ class z88_128k_ram_device : public z88_32k_ram_device { public: // construction/destruction - z88_128k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z88_128k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // z88cart_interface overrides @@ -62,7 +62,7 @@ class z88_512k_ram_device : public z88_32k_ram_device { public: // construction/destruction - z88_512k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z88_512k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // z88cart_interface overrides @@ -75,7 +75,7 @@ class z88_1024k_ram_device : public z88_32k_ram_device { public: // construction/destruction - z88_1024k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z88_1024k_ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // z88cart_interface overrides diff --git a/src/devices/bus/z88/rom.cpp b/src/devices/bus/z88/rom.cpp index 3d28a0a38b8..e207ca57d8b 100644 --- a/src/devices/bus/z88/rom.cpp +++ b/src/devices/bus/z88/rom.cpp @@ -31,12 +31,12 @@ DEFINE_DEVICE_TYPE(Z88_256K_ROM, z88_256k_rom_device, "z88_256k_rom", "Z88 256KB // z88_32k_rom_device - constructor //------------------------------------------------- -z88_32k_rom_device::z88_32k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z88_32k_rom_device::z88_32k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z88_32k_rom_device(mconfig, Z88_32K_ROM, tag, owner, clock) { } -z88_32k_rom_device::z88_32k_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +z88_32k_rom_device::z88_32k_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_nvram_interface(mconfig, *this) , device_z88cart_interface(mconfig, *this) @@ -50,7 +50,7 @@ z88_32k_rom_device::z88_32k_rom_device(const machine_config &mconfig, device_typ // z88_128k_rom_device - constructor //------------------------------------------------- -z88_128k_rom_device::z88_128k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z88_128k_rom_device::z88_128k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z88_32k_rom_device(mconfig, Z88_128K_ROM, tag, owner, clock) { } @@ -59,7 +59,7 @@ z88_128k_rom_device::z88_128k_rom_device(const machine_config &mconfig, const ch // z88_256k_rom_device - constructor //------------------------------------------------- -z88_256k_rom_device::z88_256k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z88_256k_rom_device::z88_256k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z88_32k_rom_device(mconfig, Z88_256K_ROM, tag, owner, clock) { } diff --git a/src/devices/bus/z88/rom.h b/src/devices/bus/z88/rom.h index 8bdd1a5ef92..a4ebf05ac33 100644 --- a/src/devices/bus/z88/rom.h +++ b/src/devices/bus/z88/rom.h @@ -19,10 +19,10 @@ class z88_32k_rom_device : public device_t, { public: // construction/destruction - z88_32k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z88_32k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - z88_32k_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + z88_32k_rom_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -53,7 +53,7 @@ class z88_128k_rom_device : public z88_32k_rom_device { public: // construction/destruction - z88_128k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z88_128k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // z88cart_interface overrides @@ -66,7 +66,7 @@ class z88_256k_rom_device : public z88_32k_rom_device { public: // construction/destruction - z88_256k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z88_256k_rom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // z88cart_interface overrides diff --git a/src/devices/bus/z88/z88.cpp b/src/devices/bus/z88/z88.cpp index 8a12bb47b82..5373972edee 100644 --- a/src/devices/bus/z88/z88.cpp +++ b/src/devices/bus/z88/z88.cpp @@ -55,7 +55,7 @@ device_z88cart_interface::~device_z88cart_interface() //------------------------------------------------- // z88cart_slot_device - constructor //------------------------------------------------- -z88cart_slot_device::z88cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z88cart_slot_device::z88cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z88CART_SLOT, tag, owner, clock) , device_cartrom_image_interface(mconfig, *this) , device_single_card_slot_interface<device_z88cart_interface>(mconfig, *this) diff --git a/src/devices/bus/z88/z88.h b/src/devices/bus/z88/z88.h index bece08cbf72..a8bc2a59553 100644 --- a/src/devices/bus/z88/z88.h +++ b/src/devices/bus/z88/z88.h @@ -93,14 +93,14 @@ public: // construction/destruction template <typename T> z88cart_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : z88cart_slot_device(mconfig, tag, owner, 0) + : z88cart_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - z88cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + z88cart_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto out_flp_callback() { return m_out_flp_cb.bind(); } diff --git a/src/devices/cpu/8x300/8x300.cpp b/src/devices/cpu/8x300/8x300.cpp index cd6efcb1b3c..bbe6ffd615c 100644 --- a/src/devices/cpu/8x300/8x300.cpp +++ b/src/devices/cpu/8x300/8x300.cpp @@ -41,7 +41,7 @@ DEFINE_DEVICE_TYPE(N8X300, n8x300_cpu_device, "8x300", "Signetics 8X300") DEFINE_DEVICE_TYPE(N8X305, n8x305_cpu_device, "8x305", "Signetics 8X305") -n8x300_cpu_device::n8x300_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +n8x300_cpu_device::n8x300_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, 13, -1) , m_io_config("io", ENDIANNESS_BIG, 8, 9, 0) @@ -54,12 +54,12 @@ n8x300_cpu_device::n8x300_cpu_device(const machine_config &mconfig, device_type { } -n8x300_cpu_device::n8x300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +n8x300_cpu_device::n8x300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : n8x300_cpu_device(mconfig, N8X300, tag, owner, clock) { } -n8x305_cpu_device::n8x305_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +n8x305_cpu_device::n8x305_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : n8x300_cpu_device(mconfig, N8X305, tag, owner, clock) { } diff --git a/src/devices/cpu/8x300/8x300.h b/src/devices/cpu/8x300/8x300.h index e4f2a2a3dda..f3e17d0df0c 100644 --- a/src/devices/cpu/8x300/8x300.h +++ b/src/devices/cpu/8x300/8x300.h @@ -43,7 +43,7 @@ class n8x300_cpu_device : public cpu_device { public: // construction/destruction - n8x300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + n8x300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto sc_callback() { return m_sc_callback.bind(); } auto wc_callback() { return m_wc_callback.bind(); } @@ -52,7 +52,7 @@ public: auto rb_callback() { return m_rb_callback.bind(); } auto iv_callback() { return m_iv_callback.bind(); } protected: - n8x300_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + n8x300_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -152,7 +152,7 @@ class n8x305_cpu_device : public n8x300_cpu_device { public: // construction/destruction - n8x305_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + n8x305_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void set_reg(uint8_t reg, uint8_t val, bool xmit) override; diff --git a/src/devices/cpu/adsp2100/adsp2100.cpp b/src/devices/cpu/adsp2100/adsp2100.cpp index 86b0158caa7..23aa525b79a 100644 --- a/src/devices/cpu/adsp2100/adsp2100.cpp +++ b/src/devices/cpu/adsp2100/adsp2100.cpp @@ -127,7 +127,7 @@ DEFINE_DEVICE_TYPE(ADSP2181, adsp2181_device, "adsp2181", "Analog Devices ADSP-2 // adsp21xx_device - constructor //------------------------------------------------- -adsp21xx_device::adsp21xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t chiptype) +adsp21xx_device::adsp21xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t chiptype) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 32, 14, -2), m_data_config("data", ENDIANNESS_LITTLE, 16, 14, -1), @@ -258,31 +258,31 @@ adsp21xx_device::adsp21xx_device(const machine_config &mconfig, device_type type m_shift_xregs[7] = &m_core.sr.srx.sr1; } -adsp2100_device::adsp2100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adsp2100_device::adsp2100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adsp21xx_device(mconfig, ADSP2100, tag, owner, clock, CHIP_TYPE_ADSP2100) { } -adsp2101_device::adsp2101_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adsp2101_device::adsp2101_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adsp2101_device(mconfig, ADSP2101, tag, owner, clock, CHIP_TYPE_ADSP2101) { } -adsp2101_device::adsp2101_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t chiptype) +adsp2101_device::adsp2101_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t chiptype) : adsp21xx_device(mconfig, type, tag, owner, clock, chiptype) { } -adsp2104_device::adsp2104_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adsp2104_device::adsp2104_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adsp2101_device(mconfig, ADSP2104, tag, owner, clock, CHIP_TYPE_ADSP2104) { } -adsp2105_device::adsp2105_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adsp2105_device::adsp2105_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adsp2101_device(mconfig, ADSP2105, tag, owner, clock, CHIP_TYPE_ADSP2105) { } -adsp2115_device::adsp2115_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adsp2115_device::adsp2115_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adsp2101_device(mconfig, ADSP2115, tag, owner, clock, CHIP_TYPE_ADSP2115) { } -adsp2181_device::adsp2181_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adsp2181_device::adsp2181_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adsp21xx_device(mconfig, ADSP2181, tag, owner, clock, CHIP_TYPE_ADSP2181) , m_io_config("io", ENDIANNESS_LITTLE, 16, 11, -1) { } diff --git a/src/devices/cpu/adsp2100/adsp2100.h b/src/devices/cpu/adsp2100/adsp2100.h index 046e10fa6ba..2638d56c04d 100644 --- a/src/devices/cpu/adsp2100/adsp2100.h +++ b/src/devices/cpu/adsp2100/adsp2100.h @@ -210,7 +210,7 @@ protected: }; // construction/destruction - adsp21xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t chiptype); + adsp21xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t chiptype); // device-level overrides virtual void device_start() override; @@ -473,7 +473,7 @@ class adsp2100_device : public adsp21xx_device { public: // construction/destruction - adsp2100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adsp2100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides @@ -494,10 +494,10 @@ class adsp2101_device : public adsp21xx_device { public: // construction/destruction - adsp2101_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adsp2101_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - adsp2101_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t chiptype); + adsp2101_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t chiptype); // device_execute_interface overrides virtual uint32_t execute_input_lines() const noexcept override; @@ -517,7 +517,7 @@ class adsp2181_device : public adsp21xx_device { public: // construction/destruction - adsp2181_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adsp2181_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides @@ -547,19 +547,19 @@ public: class adsp2104_device : public adsp2101_device { public: - adsp2104_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adsp2104_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class adsp2105_device : public adsp2101_device { public: - adsp2105_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adsp2105_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class adsp2115_device : public adsp2101_device { public: - adsp2115_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adsp2115_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/alpha/alpha.cpp b/src/devices/cpu/alpha/alpha.cpp index 54fd995b092..f752b566eb2 100644 --- a/src/devices/cpu/alpha/alpha.cpp +++ b/src/devices/cpu/alpha/alpha.cpp @@ -38,17 +38,17 @@ DEFINE_DEVICE_TYPE(DEC_21064, dec_21064_device, "21064", "DEC Alpha 21064") -dec_21064_device::dec_21064_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dec_21064_device::dec_21064_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : alpha_ev4_device(mconfig, DEC_21064, tag, owner, clock) { } -alpha_ev4_device::alpha_ev4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +alpha_ev4_device::alpha_ev4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : alpha_device(mconfig, type, tag, owner, clock) { } -alpha_device::alpha_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +alpha_device::alpha_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_dasm_type(alpha_disassembler::dasm_type::TYPE_UNKNOWN) , m_as_config diff --git a/src/devices/cpu/alpha/alpha.h b/src/devices/cpu/alpha/alpha.h index bf374d227b0..2aa72783324 100644 --- a/src/devices/cpu/alpha/alpha.h +++ b/src/devices/cpu/alpha/alpha.h @@ -18,7 +18,7 @@ public: auto srom_data_r() { return m_srom_data_cb.bind(); } protected: - alpha_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + alpha_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device_t overrides virtual void device_start() override; @@ -76,7 +76,7 @@ protected: class alpha_ev4_device : public alpha_device { public: - alpha_ev4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + alpha_ev4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -253,7 +253,7 @@ protected: class dec_21064_device : public alpha_ev4_device { public: - dec_21064_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dec_21064_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; diff --git a/src/devices/cpu/alto2/alto2cpu.cpp b/src/devices/cpu/alto2/alto2cpu.cpp index 5d093a96966..07ab991d042 100644 --- a/src/devices/cpu/alto2/alto2cpu.cpp +++ b/src/devices/cpu/alto2/alto2cpu.cpp @@ -125,7 +125,7 @@ void alto2_cpu_device::iomem_map(address_map &map) // alto2_cpu_device - constructor //------------------------------------------------- -alto2_cpu_device::alto2_cpu_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +alto2_cpu_device::alto2_cpu_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : cpu_device(mconfig, ALTO2, tag, owner, clock), m_kb_read_callback(*this), m_utilout_callback(*this), diff --git a/src/devices/cpu/alto2/alto2cpu.h b/src/devices/cpu/alto2/alto2cpu.h index c269737d2e6..4fa396e7b3a 100644 --- a/src/devices/cpu/alto2/alto2cpu.h +++ b/src/devices/cpu/alto2/alto2cpu.h @@ -179,7 +179,7 @@ class alto2_cpu_device : public cpu_device { public: // construction/destruction - alto2_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + alto2_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~alto2_cpu_device(); auto kb_read_callback() { return m_kb_read_callback.bind(); } diff --git a/src/devices/cpu/am29000/am29000.cpp b/src/devices/cpu/am29000/am29000.cpp index b66c5163e1e..0f8a91d4a13 100644 --- a/src/devices/cpu/am29000/am29000.cpp +++ b/src/devices/cpu/am29000/am29000.cpp @@ -78,7 +78,7 @@ DEFINE_DEVICE_TYPE(AM29000, am29000_cpu_device, "am29000", "AMC Am29000") STATE ACCESSORS ***************************************************************************/ -am29000_cpu_device::am29000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am29000_cpu_device::am29000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, AM29000, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 32, 32, 0) , m_io_config("io", ENDIANNESS_BIG, 32, 32, 0) diff --git a/src/devices/cpu/am29000/am29000.h b/src/devices/cpu/am29000/am29000.h index c19eeb8b9f2..203c9191f77 100644 --- a/src/devices/cpu/am29000/am29000.h +++ b/src/devices/cpu/am29000/am29000.h @@ -436,7 +436,7 @@ class am29000_cpu_device : public cpu_device { public: // construction/destruction - am29000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + am29000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/amis2000/amis2000.cpp b/src/devices/cpu/amis2000/amis2000.cpp index 468b29acd98..9dedbf962ac 100644 --- a/src/devices/cpu/amis2000/amis2000.cpp +++ b/src/devices/cpu/amis2000/amis2000.cpp @@ -59,15 +59,15 @@ void amis2000_base_device::data_80x4(address_map &map) // device definitions -amis2000_cpu_device::amis2000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +amis2000_cpu_device::amis2000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : amis2000_base_device(mconfig, AMI_S2000, tag, owner, clock, 2, 10, 3, 13, address_map_constructor(FUNC(amis2000_cpu_device::program_1k), this), 6, address_map_constructor(FUNC(amis2000_cpu_device::data_64x4), this)) { } -amis2150_cpu_device::amis2150_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +amis2150_cpu_device::amis2150_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : amis2000_base_device(mconfig, AMI_S2150, tag, owner, clock, 3, 11, 3, 13, address_map_constructor(FUNC(amis2150_cpu_device::program_1_5k), this), 7, address_map_constructor(FUNC(amis2150_cpu_device::data_80x4), this)) { } -amis2152_cpu_device::amis2152_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +amis2152_cpu_device::amis2152_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : amis2000_base_device(mconfig, AMI_S2152, tag, owner, clock, 3, 11, 3, 13, address_map_constructor(FUNC(amis2152_cpu_device::program_1_5k), this), 7, address_map_constructor(FUNC(amis2152_cpu_device::data_80x4), this)) { } diff --git a/src/devices/cpu/amis2000/amis2000.h b/src/devices/cpu/amis2000/amis2000.h index f284149dd15..5cdeadfe5fb 100644 --- a/src/devices/cpu/amis2000/amis2000.h +++ b/src/devices/cpu/amis2000/amis2000.h @@ -39,7 +39,7 @@ public: protected: // construction/destruction - amis2000_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 bu_bits, u8 callstack_bits, u8 callstack_depth, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) + amis2000_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 bu_bits, u8 callstack_bits, u8 callstack_depth, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, prgwidth, 0, program) , m_data_config("data", ENDIANNESS_BIG, 8, datawidth, 0, data) @@ -189,21 +189,21 @@ protected: class amis2000_cpu_device : public amis2000_base_device { public: - amis2000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + amis2000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class amis2150_cpu_device : public amis2000_base_device { public: - amis2150_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + amis2150_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class amis2152_cpu_device : public amis2000_base_device { public: - amis2152_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + amis2152_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/apexc/apexc.cpp b/src/devices/cpu/apexc/apexc.cpp index 68c1547823c..c982a442c7a 100644 --- a/src/devices/cpu/apexc/apexc.cpp +++ b/src/devices/cpu/apexc/apexc.cpp @@ -337,7 +337,7 @@ DEFINE_DEVICE_TYPE(APEXC, apexc_cpu_device, "apexc_cpu", "APE(X)C") #define DELAY(n) {m_icount -= (n); m_current_word = (m_current_word + (n)) & 0x1f;} -apexc_cpu_device::apexc_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +apexc_cpu_device::apexc_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, APEXC, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 32, 15, 0) , m_tape_read_cb(*this) diff --git a/src/devices/cpu/apexc/apexc.h b/src/devices/cpu/apexc/apexc.h index 84b44add940..7339f7ec7a5 100644 --- a/src/devices/cpu/apexc/apexc.h +++ b/src/devices/cpu/apexc/apexc.h @@ -20,7 +20,7 @@ class apexc_cpu_device : public cpu_device { public: // construction/destruction - apexc_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apexc_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration auto tape_read() { return m_tape_read_cb.bind(); } diff --git a/src/devices/cpu/arc/arc.cpp b/src/devices/cpu/arc/arc.cpp index 5b1b61bf6e1..0bba6735819 100644 --- a/src/devices/cpu/arc/arc.cpp +++ b/src/devices/cpu/arc/arc.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(ARC, arc_cpu_device, "arc_a4", "Argonaut ARCtangent A4") -arc_cpu_device::arc_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arc_cpu_device::arc_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, ARC, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 32, 24, 0) , m_pc(0), m_program(nullptr), m_icount(0), m_debugger_temp(0) diff --git a/src/devices/cpu/arc/arc.h b/src/devices/cpu/arc/arc.h index fd4fa0582e1..bf1096ad09c 100644 --- a/src/devices/cpu/arc/arc.h +++ b/src/devices/cpu/arc/arc.h @@ -21,7 +21,7 @@ class arc_cpu_device : public cpu_device { public: // construction/destruction - arc_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arc_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/arcompact/arcompact.cpp b/src/devices/cpu/arcompact/arcompact.cpp index f1055895d87..d64885911ae 100644 --- a/src/devices/cpu/arcompact/arcompact.cpp +++ b/src/devices/cpu/arcompact/arcompact.cpp @@ -49,7 +49,7 @@ void arcompact_device::arcompact_auxreg_map(address_map &map) #define AUX_SPACE_ADDRESS_WIDTH 32 // IO space is 32 bits of dwords -arcompact_device::arcompact_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arcompact_device::arcompact_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, ARCA5, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 32, 32, 0) // some docs describe these as 'middle endian'?! , m_io_config( "io", ENDIANNESS_LITTLE, 32, AUX_SPACE_ADDRESS_WIDTH, -2, address_map_constructor(FUNC(arcompact_device::arcompact_auxreg_map), this)) diff --git a/src/devices/cpu/arcompact/arcompact.h b/src/devices/cpu/arcompact/arcompact.h index d87499bc969..6b6ffa5d0af 100644 --- a/src/devices/cpu/arcompact/arcompact.h +++ b/src/devices/cpu/arcompact/arcompact.h @@ -70,7 +70,7 @@ class arcompact_device : public cpu_device { public: // construction/destruction - arcompact_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arcompact_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t arcompact_auxreg002_LPSTART_r(); void arcompact_auxreg002_LPSTART_w(uint32_t data); diff --git a/src/devices/cpu/arm/arm.cpp b/src/devices/cpu/arm/arm.cpp index 6a99468da75..980f5fe261d 100644 --- a/src/devices/cpu/arm/arm.cpp +++ b/src/devices/cpu/arm/arm.cpp @@ -225,13 +225,13 @@ device_memory_interface::space_config_vector arm_cpu_device::memory_space_config }; } -arm_cpu_device::arm_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm_cpu_device::arm_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm_cpu_device(mconfig, ARM, tag, owner, clock) { } -arm_cpu_device::arm_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +arm_cpu_device::arm_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 32, 26, 0) , m_copro_type(copro_type::UNKNOWN_CP15) diff --git a/src/devices/cpu/arm/arm.h b/src/devices/cpu/arm/arm.h index aeafa3c0d7b..d52de002db2 100644 --- a/src/devices/cpu/arm/arm.h +++ b/src/devices/cpu/arm/arm.h @@ -27,7 +27,7 @@ public: }; // construction/destruction - arm_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_copro_type(copro_type type) { m_copro_type = type; } @@ -41,7 +41,7 @@ protected: ARM32_IR13, ARM32_IR14, ARM32_SR13, ARM32_SR14 }; - arm_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + arm_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/arm7/arm7.cpp b/src/devices/cpu/arm7/arm7.cpp index d2c40209dd1..e8e5c1005f4 100644 --- a/src/devices/cpu/arm7/arm7.cpp +++ b/src/devices/cpu/arm7/arm7.cpp @@ -78,12 +78,12 @@ DEFINE_DEVICE_TYPE(PXA270, pxa270_cpu_device, "pxa270", "Intel DEFINE_DEVICE_TYPE(SA1110, sa1110_cpu_device, "sa1110", "Intel StrongARM SA-1110") DEFINE_DEVICE_TYPE(IGS036, igs036_cpu_device, "igs036", "IGS036") -arm7_cpu_device::arm7_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm7_cpu_device::arm7_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, ARM7, tag, owner, clock, 4, ARCHFLAG_T, ENDIANNESS_LITTLE) { } -arm7_cpu_device::arm7_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness) +arm7_cpu_device::arm7_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", endianness, 32, 32, 0) , m_prefetch_word0_shift(endianness == ENDIANNESS_LITTLE ? 0 : 16) @@ -114,13 +114,13 @@ arm7_cpu_device::arm7_cpu_device(const machine_config &mconfig, device_type type } -arm7_be_cpu_device::arm7_be_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm7_be_cpu_device::arm7_be_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, ARM7_BE, tag, owner, clock, 4, ARCHFLAG_T, ENDIANNESS_BIG) { } -arm710a_cpu_device::arm710a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm710a_cpu_device::arm710a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, ARM710A, tag, owner, clock, 4, ARCHFLAG_MODE26, ENDIANNESS_LITTLE) { m_copro_id = ARM9_COPRO_ID_MFR_ARM @@ -129,7 +129,7 @@ arm710a_cpu_device::arm710a_cpu_device(const machine_config &mconfig, const char } -arm710t_cpu_device::arm710t_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm710t_cpu_device::arm710t_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, ARM710T, tag, owner, clock, 4, ARCHFLAG_MODE26, ENDIANNESS_LITTLE) { m_copro_id = ARM9_COPRO_ID_MFR_ARM @@ -138,7 +138,7 @@ arm710t_cpu_device::arm710t_cpu_device(const machine_config &mconfig, const char } -arm7500_cpu_device::arm7500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm7500_cpu_device::arm7500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, ARM7500, tag, owner, clock, 4, ARCHFLAG_MODE26, ENDIANNESS_LITTLE) { m_copro_id = ARM9_COPRO_ID_MFR_ARM @@ -147,13 +147,13 @@ arm7500_cpu_device::arm7500_cpu_device(const machine_config &mconfig, const char } -arm9_cpu_device::arm9_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm9_cpu_device::arm9_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm9_cpu_device(mconfig, ARM9, tag, owner, clock, 5, ARCHFLAG_T | ARCHFLAG_E, ENDIANNESS_LITTLE) { } -arm9_cpu_device::arm9_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness) +arm9_cpu_device::arm9_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness) : arm7_cpu_device(mconfig, type, tag, owner, clock, archRev, archFlags, endianness) { uint32_t arch = ARM9_COPRO_ID_ARCH_V4; @@ -181,7 +181,7 @@ arm9_cpu_device::arm9_cpu_device(const machine_config &mconfig, device_type type } -arm920t_cpu_device::arm920t_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm920t_cpu_device::arm920t_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm9_cpu_device(mconfig, ARM920T, tag, owner, clock, 4, ARCHFLAG_T, ENDIANNESS_LITTLE) { m_copro_id = ARM9_COPRO_ID_MFR_ARM @@ -191,7 +191,7 @@ arm920t_cpu_device::arm920t_cpu_device(const machine_config &mconfig, const char | 0; // Stepping } -arm946es_cpu_device::arm946es_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +arm946es_cpu_device::arm946es_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : arm9_cpu_device(mconfig, type, tag, owner, clock, 5, ARCHFLAG_T | ARCHFLAG_E, ENDIANNESS_LITTLE), cp15_control(0x78) { @@ -212,18 +212,18 @@ arm946es_cpu_device::arm946es_cpu_device(const machine_config &mconfig, device_t cp15_itcm_reg = cp15_dtcm_reg = 0; } -arm946es_cpu_device::arm946es_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm946es_cpu_device::arm946es_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm946es_cpu_device(mconfig, ARM946ES, tag, owner, clock) { } -arm11_cpu_device::arm11_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm11_cpu_device::arm11_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm11_cpu_device(mconfig, ARM11, tag, owner, clock, 6, ARCHFLAG_T | ARCHFLAG_E | ARCHFLAG_K, ENDIANNESS_LITTLE) { } -arm11_cpu_device::arm11_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness) +arm11_cpu_device::arm11_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness) : arm9_cpu_device(mconfig, type, tag, owner, clock, archRev, archFlags, endianness) { uint32_t arch = ARM9_COPRO_ID_ARCH_V6; @@ -231,7 +231,7 @@ arm11_cpu_device::arm11_cpu_device(const machine_config &mconfig, device_type ty m_copro_id = ARM9_COPRO_ID_MFR_ARM | arch | (0xB00 << 4); } -arm1176jzf_s_cpu_device::arm1176jzf_s_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm1176jzf_s_cpu_device::arm1176jzf_s_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm11_cpu_device(mconfig, ARM1176JZF_S, tag, owner, clock, 6, ARCHFLAG_T | ARCHFLAG_E | ARCHFLAG_K, ENDIANNESS_LITTLE) { m_copro_id = ARM9_COPRO_ID_MFR_ARM @@ -242,12 +242,12 @@ arm1176jzf_s_cpu_device::arm1176jzf_s_cpu_device(const machine_config &mconfig, } // unknown configuration, but uses MPU not MMU, so closer to ARM946ES -igs036_cpu_device::igs036_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +igs036_cpu_device::igs036_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm946es_cpu_device(mconfig, IGS036, tag, owner, clock) { } -pxa250_cpu_device::pxa250_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pxa250_cpu_device::pxa250_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, PXA250, tag, owner, clock, 5, ARCHFLAG_T | ARCHFLAG_E | ARCHFLAG_XSCALE, ENDIANNESS_LITTLE) { m_copro_id = ARM9_COPRO_ID_MFR_INTEL @@ -256,7 +256,7 @@ pxa250_cpu_device::pxa250_cpu_device(const machine_config &mconfig, const char * | ARM9_COPRO_ID_STEP_PXA255_A0; } -pxa255_cpu_device::pxa255_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pxa255_cpu_device::pxa255_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, PXA255, tag, owner, clock, 5, ARCHFLAG_T | ARCHFLAG_E | ARCHFLAG_XSCALE, ENDIANNESS_LITTLE) { m_copro_id = ARM9_COPRO_ID_MFR_INTEL @@ -265,7 +265,7 @@ pxa255_cpu_device::pxa255_cpu_device(const machine_config &mconfig, const char * | ARM9_COPRO_ID_STEP_PXA255_A0; } -pxa270_cpu_device::pxa270_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pxa270_cpu_device::pxa270_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, PXA270, tag, owner, clock, 5, ARCHFLAG_T | ARCHFLAG_E | ARCHFLAG_XSCALE, ENDIANNESS_LITTLE) { m_copro_id = ARM9_COPRO_ID_MFR_INTEL @@ -274,7 +274,7 @@ pxa270_cpu_device::pxa270_cpu_device(const machine_config &mconfig, const char * | ARM9_COPRO_ID_STEP_PXA255_A0; } -sa1110_cpu_device::sa1110_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sa1110_cpu_device::sa1110_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, SA1110, tag, owner, clock, 4, ARCHFLAG_SA, ENDIANNESS_LITTLE) // has StrongARM, no Thumb, no Enhanced DSP { diff --git a/src/devices/cpu/arm7/arm7.h b/src/devices/cpu/arm7/arm7.h index c46516508db..03e0918a538 100644 --- a/src/devices/cpu/arm7/arm7.h +++ b/src/devices/cpu/arm7/arm7.h @@ -51,7 +51,7 @@ class arm7_cpu_device : public cpu_device, public arm7_disassembler::config { public: // construction/destruction - arm7_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm7_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_high_vectors() { m_vectorbase = 0xffff0000; } @@ -113,7 +113,7 @@ protected: ARM9_COPRO_ID_MFR_INTEL = 0x69 << 24 }; - arm7_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness); + arm7_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness); void postload(); @@ -622,7 +622,7 @@ class arm7_be_cpu_device : public arm7_cpu_device { public: // construction/destruction - arm7_be_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm7_be_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -630,31 +630,31 @@ class arm7500_cpu_device : public arm7_cpu_device { public: // construction/destruction - arm7500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm7500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class arm710a_cpu_device : public arm7_cpu_device { public: // construction/destruction - arm710a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm710a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class arm710t_cpu_device : public arm7_cpu_device { public: // construction/destruction - arm710t_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm710t_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class arm9_cpu_device : public arm7_cpu_device { public: // construction/destruction - arm9_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm9_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - arm9_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness); + arm9_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness); }; @@ -662,7 +662,7 @@ class arm920t_cpu_device : public arm9_cpu_device { public: // construction/destruction - arm920t_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm920t_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -670,7 +670,7 @@ class arm946es_cpu_device : public arm9_cpu_device { public: // construction/destruction - arm946es_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm946es_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // 946E-S has Protection Unit instead of ARM MMU so CP15 is quite different virtual uint32_t arm7_rt_r_callback(offs_t offset) override; @@ -684,7 +684,7 @@ public: virtual uint8_t arm7_cpu_read8(uint32_t addr) override; protected: - arm946es_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + arm946es_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -701,17 +701,17 @@ class arm11_cpu_device : public arm9_cpu_device { public: // construction/destruction - arm11_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm11_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - arm11_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness); + arm11_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t archRev, uint32_t archFlags, endianness_t endianness); }; class arm1176jzf_s_cpu_device : public arm11_cpu_device { public: // construction/destruction - arm1176jzf_s_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm1176jzf_s_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint32_t arm7_rt_r_callback(offs_t offset) override; virtual void arm7_rt_w_callback(offs_t offset, uint32_t data) override; @@ -724,35 +724,35 @@ class igs036_cpu_device : public arm946es_cpu_device { public: // construction/destruction - igs036_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + igs036_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class pxa250_cpu_device : public arm7_cpu_device { public: // construction/destruction - pxa250_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pxa250_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class pxa255_cpu_device : public arm7_cpu_device { public: // construction/destruction - pxa255_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pxa255_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class pxa270_cpu_device : public arm7_cpu_device { public: // construction/destruction - pxa270_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pxa270_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class sa1110_cpu_device : public arm7_cpu_device { public: // construction/destruction - sa1110_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sa1110_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(ARM7, arm7_cpu_device) diff --git a/src/devices/cpu/arm7/lpc210x.cpp b/src/devices/cpu/arm7/lpc210x.cpp index 75a322f01a2..99ecfb478f4 100644 --- a/src/devices/cpu/arm7/lpc210x.cpp +++ b/src/devices/cpu/arm7/lpc210x.cpp @@ -41,7 +41,7 @@ void lpc210x_device::lpc2103_map(address_map &map) } -lpc210x_device::lpc210x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lpc210x_device::lpc210x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, LPC2103, tag, owner, clock, 4, ARCHFLAG_T, ENDIANNESS_LITTLE) , m_program_config("program", ENDIANNESS_LITTLE, 32, 32, 0, address_map_constructor(FUNC(lpc210x_device::lpc2103_map), this)) , m_vic(*this, "vic") @@ -256,7 +256,7 @@ void lpc210x_device::write_timer(int timer, int offset, uint32_t data, uint32_t void lpc210x_device::device_add_mconfig(machine_config &config) { - PL190_VIC(config, m_vic, 0); + PL190_VIC(config, m_vic); m_vic->out_irq_cb().set_inputline(*this, ARM7_IRQ_LINE); m_vic->out_fiq_cb().set_inputline(*this, ARM7_FIRQ_LINE); } diff --git a/src/devices/cpu/arm7/lpc210x.h b/src/devices/cpu/arm7/lpc210x.h index 47a801a6058..c36f6fbd109 100644 --- a/src/devices/cpu/arm7/lpc210x.h +++ b/src/devices/cpu/arm7/lpc210x.h @@ -22,7 +22,7 @@ class lpc210x_device : public arm7_cpu_device { public: - lpc210x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + lpc210x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t arm_E01FC088_r(); uint32_t flash_r(offs_t offset); diff --git a/src/devices/cpu/arm7/upd800468.cpp b/src/devices/cpu/arm7/upd800468.cpp index 16b6928bf7c..1248b5ea2b3 100644 --- a/src/devices/cpu/arm7/upd800468.cpp +++ b/src/devices/cpu/arm7/upd800468.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(UPD800468_TIMER, upd800468_timer_device, "upd800468_timer", "NEC uPD800468 timer") -upd800468_timer_device::upd800468_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd800468_timer_device::upd800468_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD800468_TIMER, tag, owner, clock) , m_irq_cb(*this) { @@ -122,7 +122,7 @@ void upd800468_device::upd800468_map(address_map &map) map(0xfffff000, 0xffffffff).m(m_vic, FUNC(vic_upd800468_device::map)); } -upd800468_device::upd800468_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd800468_device::upd800468_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm7_cpu_device(mconfig, UPD800468, tag, owner, clock, 4, ARCHFLAG_T, ENDIANNESS_LITTLE) , m_program_config("program", ENDIANNESS_LITTLE, 32, 32, 0, address_map_constructor(FUNC(upd800468_device::upd800468_map), this)) , m_vic(*this, "vic") @@ -142,7 +142,7 @@ device_memory_interface::space_config_vector upd800468_device::memory_space_conf void upd800468_device::device_add_mconfig(machine_config &config) { - UPD800468_VIC(config, m_vic, 0); + UPD800468_VIC(config, m_vic); m_vic->out_irq_cb().set_inputline(*this, ARM7_IRQ_LINE); m_vic->out_fiq_cb().set_inputline(*this, ARM7_FIRQ_LINE); @@ -157,7 +157,7 @@ void upd800468_device::device_add_mconfig(machine_config &config) m_timer[2]->irq_cb().set(m_vic, FUNC(vic_upd800468_device::irq_w<23>)); // key/button controller is compatible with the one from earlier keyboards - GT913_KBD_HLE(config, m_kbd, 0); + GT913_KBD_HLE(config, m_kbd); m_kbd->irq_cb().set(m_vic, FUNC(vic_upd800468_device::irq_w<31>)); } diff --git a/src/devices/cpu/arm7/upd800468.h b/src/devices/cpu/arm7/upd800468.h index 7f662581c7f..a90fdcf9827 100644 --- a/src/devices/cpu/arm7/upd800468.h +++ b/src/devices/cpu/arm7/upd800468.h @@ -18,7 +18,7 @@ class upd800468_timer_device : public device_t { public: - upd800468_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd800468_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_cb() { return m_irq_cb.bind(); } @@ -45,7 +45,7 @@ private: class upd800468_device : public arm7_cpu_device { public: - upd800468_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + upd800468_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void upd800468_map(address_map &map); diff --git a/src/devices/cpu/asap/asap.cpp b/src/devices/cpu/asap/asap.cpp index 045819aa4ae..554a83dd2ee 100644 --- a/src/devices/cpu/asap/asap.cpp +++ b/src/devices/cpu/asap/asap.cpp @@ -136,7 +136,7 @@ DEFINE_DEVICE_TYPE(ASAP, asap_device, "asap", "Atari ASAP") // asap_device - constructor //------------------------------------------------- -asap_device::asap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +asap_device::asap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, ASAP, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 32, 32), m_pc(0), diff --git a/src/devices/cpu/asap/asap.h b/src/devices/cpu/asap/asap.h index 3adb9ef37f4..1e62fd76202 100644 --- a/src/devices/cpu/asap/asap.h +++ b/src/devices/cpu/asap/asap.h @@ -26,7 +26,7 @@ class asap_device : public cpu_device { public: // construction/destruction - asap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + asap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // public interfaces diff --git a/src/devices/cpu/avr8/avr8.cpp b/src/devices/cpu/avr8/avr8.cpp index f650a53bbb3..85afb1482bd 100644 --- a/src/devices/cpu/avr8/avr8.cpp +++ b/src/devices/cpu/avr8/avr8.cpp @@ -642,7 +642,7 @@ void attiny15_device::attiny15_internal_map(address_map &map) // atmega88_device - constructor //------------------------------------------------- -atmega88_device::atmega88_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atmega88_device::atmega88_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avr8_device(mconfig, tag, owner, clock, ATMEGA88, 0x0fff, address_map_constructor(FUNC(atmega88_device::atmega88_internal_map), this), 3) { } @@ -651,7 +651,7 @@ atmega88_device::atmega88_device(const machine_config &mconfig, const char *tag, // atmega168_device - constructor //------------------------------------------------- -atmega168_device::atmega168_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atmega168_device::atmega168_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avr8_device(mconfig, tag, owner, clock, ATMEGA168, 0x1fff, address_map_constructor(FUNC(atmega168_device::atmega168_internal_map), this), 3) { } @@ -660,7 +660,7 @@ atmega168_device::atmega168_device(const machine_config &mconfig, const char *ta // atmega328_device - constructor //------------------------------------------------- -atmega328_device::atmega328_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atmega328_device::atmega328_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avr8_device(mconfig, tag, owner, clock, ATMEGA328, 0x7fff, address_map_constructor(FUNC(atmega328_device::atmega328_internal_map), this), 3) { } @@ -669,7 +669,7 @@ atmega328_device::atmega328_device(const machine_config &mconfig, const char *ta // atmega644_device - constructor //------------------------------------------------- -atmega644_device::atmega644_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atmega644_device::atmega644_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avr8_device(mconfig, tag, owner, clock, ATMEGA644, 0xffff, address_map_constructor(FUNC(atmega644_device::atmega644_internal_map), this), 3) { } @@ -678,7 +678,7 @@ atmega644_device::atmega644_device(const machine_config &mconfig, const char *ta // atmega1280_device - constructor //------------------------------------------------- -atmega1280_device::atmega1280_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atmega1280_device::atmega1280_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avr8_device(mconfig, tag, owner, clock, ATMEGA1280, 0x1ffff, address_map_constructor(FUNC(atmega1280_device::atmega1280_internal_map), this), 6) { } @@ -687,7 +687,7 @@ atmega1280_device::atmega1280_device(const machine_config &mconfig, const char * // atmega2560_device - constructor //------------------------------------------------- -atmega2560_device::atmega2560_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atmega2560_device::atmega2560_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avr8_device(mconfig, tag, owner, clock, ATMEGA2560, 0x1ffff, address_map_constructor(FUNC(atmega2560_device::atmega2560_internal_map), this), 6) { } @@ -696,7 +696,7 @@ atmega2560_device::atmega2560_device(const machine_config &mconfig, const char * // attiny15_device - constructor //------------------------------------------------- -attiny15_device::attiny15_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +attiny15_device::attiny15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avr8_device(mconfig, tag, owner, clock, ATTINY15, 0x03ff, address_map_constructor(FUNC(attiny15_device::attiny15_internal_map), this), 2) { } @@ -705,7 +705,7 @@ attiny15_device::attiny15_device(const machine_config &mconfig, const char *tag, // avr8_device - constructor //------------------------------------------------- -avr8_device::avr8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, const device_type type, uint32_t addr_mask, address_map_constructor internal_map, int32_t num_timers) +avr8_device::avr8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, uint32_t addr_mask, address_map_constructor internal_map, int32_t num_timers) : cpu_device(mconfig, type, tag, owner, clock) , m_shifted_pc(0) , m_program_config("program", ENDIANNESS_LITTLE, 8, 22) diff --git a/src/devices/cpu/avr8/avr8.h b/src/devices/cpu/avr8/avr8.h index 85f05e8cea6..758cd1cf945 100644 --- a/src/devices/cpu/avr8/avr8.h +++ b/src/devices/cpu/avr8/avr8.h @@ -45,7 +45,7 @@ public: template<uint8_t Port> auto gpio_in() { return m_gpio_in_cb[Port].bind(); } protected: - avr8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, const device_type type, uint32_t address_mask, address_map_constructor internal_map, int32_t num_timers); + avr8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, uint32_t address_mask, address_map_constructor internal_map, int32_t num_timers); typedef void (avr8_device::*op_func) (uint16_t op); @@ -319,7 +319,7 @@ class atmega88_device : public avr8_device { public: // construction/destruction - atmega88_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atmega88_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void atmega88_internal_map(address_map &map); }; @@ -329,7 +329,7 @@ class atmega168_device : public avr8_device { public: // construction/destruction - atmega168_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atmega168_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void update_interrupt(int source) override; void atmega168_internal_map(address_map &map); @@ -341,7 +341,7 @@ class atmega328_device : public avr8_device { public: // construction/destruction - atmega328_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atmega328_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void update_interrupt(int source) override; void atmega328_internal_map(address_map &map); @@ -353,7 +353,7 @@ class atmega644_device : public avr8_device { public: // construction/destruction - atmega644_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atmega644_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void update_interrupt(int source) override; void atmega644_internal_map(address_map &map); @@ -365,7 +365,7 @@ class atmega1280_device : public avr8_device { public: // construction/destruction - atmega1280_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atmega1280_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void update_interrupt(int source) override; void atmega1280_internal_map(address_map &map); @@ -377,7 +377,7 @@ class atmega2560_device : public avr8_device { public: // construction/destruction - atmega2560_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + atmega2560_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void update_interrupt(int source) override; void atmega2560_internal_map(address_map &map); @@ -389,7 +389,7 @@ class attiny15_device : public avr8_device { public: // construction/destruction - attiny15_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + attiny15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void attiny15_internal_map(address_map &map); }; diff --git a/src/devices/cpu/axc51/axc51.cpp b/src/devices/cpu/axc51/axc51.cpp index 602e14b75b0..068c298672b 100644 --- a/src/devices/cpu/axc51/axc51.cpp +++ b/src/devices/cpu/axc51/axc51.cpp @@ -72,7 +72,7 @@ void axc51base_cpu_device::io_internal(address_map& map) } -axc51base_cpu_device::axc51base_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor program_map, address_map_constructor data_map, address_map_constructor io_map, int program_width, int data_width, uint8_t features) +axc51base_cpu_device::axc51base_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program_map, address_map_constructor data_map, address_map_constructor io_map, int program_width, int data_width, uint8_t features) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0, program_map) , m_data_config("data", ENDIANNESS_LITTLE, 8, 11, 0, data_map) @@ -104,7 +104,7 @@ axc51base_cpu_device::axc51base_cpu_device(const machine_config &mconfig, device } -axc51base_cpu_device::axc51base_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features) +axc51base_cpu_device::axc51base_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features) : axc51base_cpu_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(axc51base_cpu_device::program_internal), this), address_map_constructor(FUNC(axc51base_cpu_device::data_internal), this), address_map_constructor(FUNC(axc51base_cpu_device::io_internal), this), program_width, data_width, features) { } @@ -1546,12 +1546,12 @@ void ax208_cpu_device::device_reset() // AX208 (specific CPU) -ax208_cpu_device::ax208_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ax208_cpu_device::ax208_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : axc51base_cpu_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(ax208_cpu_device::ax208_internal_program_mem), this), address_map_constructor(FUNC(ax208_cpu_device::data_internal), this), address_map_constructor(FUNC(axc51base_cpu_device::io_internal), this), 0, 8) { } -ax208_cpu_device::ax208_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ax208_cpu_device::ax208_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ax208_cpu_device(mconfig, AX208, tag, owner, clock) { } @@ -1565,7 +1565,7 @@ std::unique_ptr<util::disasm_interface> ax208_cpu_device::create_disassembler() -ax208p_cpu_device::ax208p_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ax208p_cpu_device::ax208p_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ax208_cpu_device(mconfig, AX208P, tag, owner, clock) { } diff --git a/src/devices/cpu/axc51/axc51.h b/src/devices/cpu/axc51/axc51.h index 291c4231414..03a5bcc624f 100644 --- a/src/devices/cpu/axc51/axc51.h +++ b/src/devices/cpu/axc51/axc51.h @@ -36,8 +36,8 @@ public: protected: // construction/destruction - axc51base_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features = 0); - axc51base_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor program_map, address_map_constructor data_map, address_map_constructor io_map, int program_width, int data_width, uint8_t features = 0); + axc51base_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features = 0); + axc51base_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program_map, address_map_constructor data_map, address_map_constructor io_map, int program_width, int data_width, uint8_t features = 0); // device-level overrides virtual void device_start() override; @@ -519,10 +519,10 @@ class ax208_cpu_device : public axc51base_cpu_device { public: // construction/destruction - ax208_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ax208_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - ax208_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ax208_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_reset() override; @@ -536,7 +536,7 @@ class ax208p_cpu_device : public ax208_cpu_device { public: // construction/destruction - ax208p_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ax208p_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/cpu/bcp/dp8344.cpp b/src/devices/cpu/bcp/dp8344.cpp index 3e78cb0d0dd..4a28cd76040 100644 --- a/src/devices/cpu/bcp/dp8344.cpp +++ b/src/devices/cpu/bcp/dp8344.cpp @@ -62,7 +62,7 @@ ALLOW_SAVE_TYPE(dp8344_device::inst_state); // dp8344_device - constructor //------------------------------------------------- -dp8344_device::dp8344_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +dp8344_device::dp8344_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_inst_config("instruction", ENDIANNESS_LITTLE, 16, 16, -1) , m_data_config("data", ENDIANNESS_LITTLE, 8, 16, 0) @@ -118,7 +118,7 @@ dp8344_device::dp8344_device(const machine_config &mconfig, device_type type, co // dp8344a_device - constructor //------------------------------------------------- -dp8344a_device::dp8344a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dp8344a_device::dp8344a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dp8344_device(mconfig, DP8344A, tag, owner, clock) { } @@ -128,7 +128,7 @@ dp8344a_device::dp8344a_device(const machine_config &mconfig, const char *tag, d // dp8344b_device - constructor //------------------------------------------------- -dp8344b_device::dp8344b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dp8344b_device::dp8344b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dp8344_device(mconfig, DP8344B, tag, owner, clock) { // TODO: emulate differences between DP8344A and DP8344B diff --git a/src/devices/cpu/bcp/dp8344.h b/src/devices/cpu/bcp/dp8344.h index f4e1e674da9..f035157f6a8 100644 --- a/src/devices/cpu/bcp/dp8344.h +++ b/src/devices/cpu/bcp/dp8344.h @@ -62,7 +62,7 @@ public: protected: // construction/destruction - dp8344_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + dp8344_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-specific overrides virtual void device_resolve_objects() override; @@ -227,7 +227,7 @@ class dp8344a_device : public dp8344_device { public: // device type constructor - dp8344a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dp8344a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> dp8344b_device @@ -236,7 +236,7 @@ class dp8344b_device : public dp8344_device { public: // device type constructor - dp8344b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dp8344b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type declarations diff --git a/src/devices/cpu/capricorn/capricorn.cpp b/src/devices/cpu/capricorn/capricorn.cpp index ee398f5296a..a5d00f16ec3 100644 --- a/src/devices/cpu/capricorn/capricorn.cpp +++ b/src/devices/cpu/capricorn/capricorn.cpp @@ -138,7 +138,7 @@ static constexpr uint8_t E_MASK = 0xf; DEFINE_DEVICE_TYPE(HP_CAPRICORN , capricorn_cpu_device , "capricorn" , "HP-Capricorn") -capricorn_cpu_device::capricorn_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +capricorn_cpu_device::capricorn_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, HP_CAPRICORN, tag, owner, clock), m_program_config("program" , ENDIANNESS_LITTLE , 8 , 16), m_opcode_func(*this), diff --git a/src/devices/cpu/capricorn/capricorn.h b/src/devices/cpu/capricorn/capricorn.h index 40bbb2cc3ab..c9aec4f56eb 100644 --- a/src/devices/cpu/capricorn/capricorn.h +++ b/src/devices/cpu/capricorn/capricorn.h @@ -17,7 +17,7 @@ class capricorn_cpu_device : public cpu_device { public: - capricorn_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + capricorn_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t flatten_burst(); diff --git a/src/devices/cpu/ccpu/ccpu.cpp b/src/devices/cpu/ccpu/ccpu.cpp index d13c272b21a..2c1f85c4418 100644 --- a/src/devices/cpu/ccpu/ccpu.cpp +++ b/src/devices/cpu/ccpu/ccpu.cpp @@ -62,7 +62,7 @@ do { \ INITIALIZATION AND SHUTDOWN ***************************************************************************/ -ccpu_cpu_device::ccpu_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ccpu_cpu_device::ccpu_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, CCPU, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, 15, 0) , m_data_config("data", ENDIANNESS_BIG, 16, 32, -1) diff --git a/src/devices/cpu/ccpu/ccpu.h b/src/devices/cpu/ccpu/ccpu.h index c4377f251e3..2c17b2e623f 100644 --- a/src/devices/cpu/ccpu/ccpu.h +++ b/src/devices/cpu/ccpu/ccpu.h @@ -42,7 +42,7 @@ public: typedef device_delegate<void (int16_t, int16_t, int16_t, int16_t, uint8_t)> vector_delegate; // construction/destruction - ccpu_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ccpu_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto external_func() { return m_external_input.bind(); } diff --git a/src/devices/cpu/clipper/clipper.cpp b/src/devices/cpu/clipper/clipper.cpp index e310b66ea62..d48ef9ae9b0 100644 --- a/src/devices/cpu/clipper/clipper.cpp +++ b/src/devices/cpu/clipper/clipper.cpp @@ -51,28 +51,28 @@ DEFINE_DEVICE_TYPE(CLIPPER_C100, clipper_c100_device, "clipper_c100", "C100 CLIP DEFINE_DEVICE_TYPE(CLIPPER_C300, clipper_c300_device, "clipper_c300", "C300 CLIPPER") DEFINE_DEVICE_TYPE(CLIPPER_C400, clipper_c400_device, "clipper_c400", "C400 CLIPPER") -clipper_c100_device::clipper_c100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +clipper_c100_device::clipper_c100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : clipper_device(mconfig, CLIPPER_C100, tag, owner, clock, ENDIANNESS_LITTLE, SSW_ID_C1R1) , m_icammu(*this, "^cammu_i") , m_dcammu(*this, "^cammu_d") { } -clipper_c300_device::clipper_c300_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +clipper_c300_device::clipper_c300_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : clipper_device(mconfig, CLIPPER_C300, tag, owner, clock, ENDIANNESS_LITTLE, SSW_ID_C3R1) , m_icammu(*this, "^cammu_i") , m_dcammu(*this, "^cammu_d") { } -clipper_c400_device::clipper_c400_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +clipper_c400_device::clipper_c400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : clipper_device(mconfig, CLIPPER_C400, tag, owner, clock, ENDIANNESS_LITTLE, SSW_ID_C4R4) , m_db_pc(0) , m_cammu(*this, "^cammu") { } -clipper_device::clipper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, const endianness_t endianness, const u32 cpuid) +clipper_device::clipper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const endianness_t endianness, const u32 cpuid) : cpu_device(mconfig, type, tag, owner, clock) , m_main_config("main", endianness, 32, 32, 0) , m_io_config("io", endianness, 32, 32, 0) diff --git a/src/devices/cpu/clipper/clipper.h b/src/devices/cpu/clipper/clipper.h index 3e78a5fdfff..f6e492f5496 100644 --- a/src/devices/cpu/clipper/clipper.h +++ b/src/devices/cpu/clipper/clipper.h @@ -148,7 +148,7 @@ public: }; protected: - clipper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, const endianness_t endianness, const u32 cpuid); + clipper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const endianness_t endianness, const u32 cpuid); // device-level overrides virtual void device_start() override; @@ -325,7 +325,7 @@ protected: class clipper_c100_device : public clipper_device { public: - clipper_c100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + clipper_c100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual cammu_device &get_icammu() const override { return *m_icammu; } @@ -339,7 +339,7 @@ private: class clipper_c300_device : public clipper_device { public: - clipper_c300_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + clipper_c300_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual cammu_device &get_icammu() const override { return *m_icammu; } @@ -353,7 +353,7 @@ private: class clipper_c400_device : public clipper_device { public: - clipper_c400_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + clipper_c400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/cop400/cop400.cpp b/src/devices/cpu/cop400/cop400.cpp index dcd9a6edc0f..e9669d9ea2a 100644 --- a/src/devices/cpu/cop400/cop400.cpp +++ b/src/devices/cpu/cop400/cop400.cpp @@ -170,7 +170,7 @@ void cop400_cpu_device::data_128b(address_map &map) } -cop400_cpu_device::cop400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t program_addr_bits, uint8_t data_addr_bits, uint8_t featuremask, uint8_t g_mask, uint8_t d_mask, uint8_t in_mask, bool has_counter, bool has_inil, address_map_constructor internal_map_program, address_map_constructor internal_map_data) +cop400_cpu_device::cop400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t program_addr_bits, uint8_t data_addr_bits, uint8_t featuremask, uint8_t g_mask, uint8_t d_mask, uint8_t in_mask, bool has_counter, bool has_inil, address_map_constructor internal_map_program, address_map_constructor internal_map_data) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, program_addr_bits, 0, internal_map_program) , m_data_config("data", ENDIANNESS_LITTLE, 8, data_addr_bits, 0, internal_map_data) // data width is really 4 @@ -247,87 +247,87 @@ cop400_cpu_device::cop400_cpu_device(const machine_config &mconfig, device_type } } -cop401_cpu_device::cop401_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop401_cpu_device::cop401_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP401, tag, owner, clock, 9, 6, COP410_FEATURE, 0xf, 0xf, 0, false, false, address_map_constructor(), address_map_constructor(FUNC(cop401_cpu_device::data_32b), this)) { } -cop410_cpu_device::cop410_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop410_cpu_device::cop410_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP410, tag, owner, clock, 9, 6, COP410_FEATURE, 0xf, 0xf, 0, false, false, address_map_constructor(FUNC(cop410_cpu_device::program_512b), this), address_map_constructor(FUNC(cop410_cpu_device::data_32b), this)) { } -cop411_cpu_device::cop411_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop411_cpu_device::cop411_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP411, tag, owner, clock, 9, 6, COP410_FEATURE, 0x7, 0x3, 0, false, false, address_map_constructor(FUNC(cop411_cpu_device::program_512b), this), address_map_constructor(FUNC(cop411_cpu_device::data_32b), this)) { } -cop402_cpu_device::cop402_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop402_cpu_device::cop402_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP402, tag, owner, clock, 10, 6, COP420_FEATURE, 0xf, 0xf, 0xf, true, true, address_map_constructor(), address_map_constructor(FUNC(cop402_cpu_device::data_64b), this)) { } -cop420_cpu_device::cop420_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop420_cpu_device::cop420_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP420, tag, owner, clock, 10, 6, COP420_FEATURE, 0xf, 0xf, 0xf, true, true, address_map_constructor(FUNC(cop420_cpu_device::program_1kb), this), address_map_constructor(FUNC(cop420_cpu_device::data_64b), this)) { } -cop421_cpu_device::cop421_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop421_cpu_device::cop421_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP421, tag, owner, clock, 10, 6, COP420_FEATURE, 0xf, 0xf, 0, true, false, address_map_constructor(FUNC(cop421_cpu_device::program_1kb), this), address_map_constructor(FUNC(cop421_cpu_device::data_64b), this)) { } -cop422_cpu_device::cop422_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop422_cpu_device::cop422_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP422, tag, owner, clock, 10, 6, COP420_FEATURE, 0xe, 0xe, 0, true, false, address_map_constructor(FUNC(cop422_cpu_device::program_1kb), this), address_map_constructor(FUNC(cop422_cpu_device::data_64b), this)) { } -cop404l_cpu_device::cop404l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop404l_cpu_device::cop404l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP404L, tag, owner, clock, 11, 7, COP444L_FEATURE, 0xf, 0xf, 0xf, true, true, address_map_constructor(), address_map_constructor(FUNC(cop404l_cpu_device::data_128b), this)) { } -cop444l_cpu_device::cop444l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop444l_cpu_device::cop444l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP444L, tag, owner, clock, 11, 7, COP444L_FEATURE, 0xf, 0xf, 0xf, true, true, address_map_constructor(FUNC(cop444l_cpu_device::program_2kb), this), address_map_constructor(FUNC(cop444l_cpu_device::data_128b), this)) { } -cop445l_cpu_device::cop445l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop445l_cpu_device::cop445l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP445L, tag, owner, clock, 11, 7, COP444L_FEATURE, 0x7, 0x3, 0, true, false, address_map_constructor(FUNC(cop445l_cpu_device::program_2kb), this), address_map_constructor(FUNC(cop445l_cpu_device::data_128b), this)) { } -cop404c_cpu_device::cop404c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop404c_cpu_device::cop404c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP404C, tag, owner, clock, 11, 7, COP424C_FEATURE, 0xf, 0xf, 0xf, true, true, address_map_constructor(), address_map_constructor(FUNC(cop404c_cpu_device::data_128b), this)) { } -cop424c_cpu_device::cop424c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop424c_cpu_device::cop424c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP424C, tag, owner, clock, 10, 6, COP424C_FEATURE, 0xf, 0xf, 0xf, true, true, address_map_constructor(FUNC(cop424c_cpu_device::program_1kb), this), address_map_constructor(FUNC(cop424c_cpu_device::data_64b), this)) { } -cop425c_cpu_device::cop425c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop425c_cpu_device::cop425c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP425C, tag, owner, clock, 10, 6, COP424C_FEATURE, 0xf, 0xf, 0, true, false, address_map_constructor(FUNC(cop425c_cpu_device::program_1kb), this), address_map_constructor(FUNC(cop425c_cpu_device::data_64b), this)) { } -cop426c_cpu_device::cop426c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop426c_cpu_device::cop426c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP426C, tag, owner, clock, 10, 6, COP424C_FEATURE, 0xe, 0xe, 0xf, true, true, address_map_constructor(FUNC(cop426c_cpu_device::program_1kb), this), address_map_constructor(FUNC(cop426c_cpu_device::data_64b), this)) { } -cop444c_cpu_device::cop444c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop444c_cpu_device::cop444c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP444C, tag, owner, clock, 11, 7, COP424C_FEATURE, 0xf, 0xf, 0xf, true, true, address_map_constructor(FUNC(cop444c_cpu_device::program_2kb), this), address_map_constructor(FUNC(cop444c_cpu_device::data_128b), this)) { } -cop445c_cpu_device::cop445c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop445c_cpu_device::cop445c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP445C, tag, owner, clock, 11, 7, COP424C_FEATURE, 0xf, 0xf, 0, true, false, address_map_constructor(FUNC(cop445c_cpu_device::program_2kb), this), address_map_constructor(FUNC(cop445c_cpu_device::data_128b), this)) { } -cop446c_cpu_device::cop446c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cop446c_cpu_device::cop446c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cop400_cpu_device(mconfig, COP446C, tag, owner, clock, 11, 7, COP424C_FEATURE, 0xe, 0xe, 0xf, true, true, address_map_constructor(FUNC(cop446c_cpu_device::program_2kb),this), address_map_constructor(FUNC(cop446c_cpu_device::data_128b), this)) { } diff --git a/src/devices/cpu/cop400/cop400.h b/src/devices/cpu/cop400/cop400.h index 45b2b4d0f25..4653dee10d3 100644 --- a/src/devices/cpu/cop400/cop400.h +++ b/src/devices/cpu/cop400/cop400.h @@ -129,7 +129,7 @@ public: protected: // construction/destruction - cop400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t program_addr_bits, uint8_t data_addr_bits, uint8_t featuremask, uint8_t g_mask, uint8_t d_mask, uint8_t in_mask, bool has_counter, bool has_inil, address_map_constructor internal_map_program, address_map_constructor internal_map_data); + cop400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t program_addr_bits, uint8_t data_addr_bits, uint8_t featuremask, uint8_t g_mask, uint8_t d_mask, uint8_t in_mask, bool has_counter, bool has_inil, address_map_constructor internal_map_program, address_map_constructor internal_map_data); // device-level overrides virtual void device_start() override; @@ -364,7 +364,7 @@ class cop401_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop401_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop401_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -372,7 +372,7 @@ class cop410_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop410_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop410_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -381,7 +381,7 @@ class cop411_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop411_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop411_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -391,7 +391,7 @@ class cop402_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop402_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop402_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -399,7 +399,7 @@ class cop420_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop420_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop420_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -408,7 +408,7 @@ class cop421_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop421_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop421_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -417,7 +417,7 @@ class cop422_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop422_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop422_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -427,7 +427,7 @@ class cop404l_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop404l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop404l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -435,7 +435,7 @@ class cop444l_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop444l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop444l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -444,7 +444,7 @@ class cop445l_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop445l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop445l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -453,7 +453,7 @@ class cop404c_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop404c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop404c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -462,7 +462,7 @@ class cop424c_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop424c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop424c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -471,7 +471,7 @@ class cop425c_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop425c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop425c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -480,7 +480,7 @@ class cop426c_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop426c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop426c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -489,7 +489,7 @@ class cop444c_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop444c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop444c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -498,7 +498,7 @@ class cop445c_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop445c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop445c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -507,7 +507,7 @@ class cop446c_cpu_device : public cop400_cpu_device { public: // construction/destruction - cop446c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cop446c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/cops1/cops1base.cpp b/src/devices/cpu/cops1/cops1base.cpp index 3bba883377b..b69700d6b91 100644 --- a/src/devices/cpu/cops1/cops1base.cpp +++ b/src/devices/cpu/cops1/cops1base.cpp @@ -34,7 +34,7 @@ TODO: #include "cops1base.h" -cops1_base_device::cops1_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +cops1_base_device::cops1_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 8, prgwidth, 0, program), m_data_config("data", ENDIANNESS_LITTLE, 8, datawidth, 0, data), diff --git a/src/devices/cpu/cops1/cops1base.h b/src/devices/cpu/cops1/cops1base.h index 75009fe7b49..8e8934009b6 100644 --- a/src/devices/cpu/cops1/cops1base.h +++ b/src/devices/cpu/cops1/cops1base.h @@ -67,7 +67,7 @@ public: protected: // construction/destruction - cops1_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + cops1_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/cops1/mm5799.cpp b/src/devices/cpu/cops1/mm5799.cpp index 7f6515760a4..3a6c427d146 100644 --- a/src/devices/cpu/cops1/mm5799.cpp +++ b/src/devices/cpu/cops1/mm5799.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(MM5799, mm5799_device, "mm5799", "National Semiconductor MM57 // constructor -mm5799_device::mm5799_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm5799_device::mm5799_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cops1_base_device(mconfig, MM5799, tag, owner, clock, 11, address_map_constructor(FUNC(mm5799_device::program_map), this), 7, address_map_constructor(FUNC(mm5799_device::data_map), this)) { } diff --git a/src/devices/cpu/cops1/mm5799.h b/src/devices/cpu/cops1/mm5799.h index a07aecd97fa..03e6d71e41b 100644 --- a/src/devices/cpu/cops1/mm5799.h +++ b/src/devices/cpu/cops1/mm5799.h @@ -37,7 +37,7 @@ class mm5799_device : public cops1_base_device { public: - mm5799_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm5799_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/cosmac/cosmac.cpp b/src/devices/cpu/cosmac/cosmac.cpp index bc38bf034c2..60f40fedbee 100644 --- a/src/devices/cpu/cosmac/cosmac.cpp +++ b/src/devices/cpu/cosmac/cosmac.cpp @@ -358,7 +358,7 @@ DEFINE_DEVICE_TYPE(CDP1806, cdp1806_device, "cdp1806", "RCA CDP1806") // cosmac_device - constructor //------------------------------------------------- -cosmac_device::cosmac_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +cosmac_device::cosmac_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock), cosmac_disassembler::config(), m_program_config("program", ENDIANNESS_LITTLE, 8, 16), @@ -391,7 +391,7 @@ cosmac_device::cosmac_device(const machine_config &mconfig, device_type type, co // cdp1801_device - constructor //------------------------------------------------- -cdp1801_device::cdp1801_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cdp1801_device::cdp1801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cosmac_device(mconfig, CDP1801, tag, owner, clock) { } @@ -400,11 +400,11 @@ cdp1801_device::cdp1801_device(const machine_config &mconfig, const char *tag, d // cdp1802_device - constructor //------------------------------------------------- -cdp1802_device::cdp1802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cdp1802_device::cdp1802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cdp1802_device(mconfig, CDP1802, tag, owner, clock) { } -cdp1802_device::cdp1802_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +cdp1802_device::cdp1802_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cosmac_device(mconfig, type, tag, owner, clock) { } @@ -413,11 +413,11 @@ cdp1802_device::cdp1802_device(const machine_config &mconfig, device_type type, // cdp1804_device - constructor //------------------------------------------------- -cdp1804_device::cdp1804_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cdp1804_device::cdp1804_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cdp1804_device(mconfig, CDP1804, tag, owner, clock) { } -cdp1804_device::cdp1804_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +cdp1804_device::cdp1804_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cdp1802_device(mconfig, type, tag, owner, clock) { } @@ -426,11 +426,11 @@ cdp1804_device::cdp1804_device(const machine_config &mconfig, device_type type, // cdp1805_device - constructor //------------------------------------------------- -cdp1805_device::cdp1805_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cdp1805_device::cdp1805_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cdp1805_device(mconfig, CDP1805, tag, owner, clock) { } -cdp1805_device::cdp1805_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +cdp1805_device::cdp1805_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cdp1804_device(mconfig, type, tag, owner, clock) { } @@ -439,7 +439,7 @@ cdp1805_device::cdp1805_device(const machine_config &mconfig, device_type type, // cdp1806_device - constructor //------------------------------------------------- -cdp1806_device::cdp1806_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cdp1806_device::cdp1806_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cdp1805_device(mconfig, CDP1806, tag, owner, clock) { } diff --git a/src/devices/cpu/cosmac/cosmac.h b/src/devices/cpu/cosmac/cosmac.h index 2d29a10ce44..1d8e9c55612 100644 --- a/src/devices/cpu/cosmac/cosmac.h +++ b/src/devices/cpu/cosmac/cosmac.h @@ -183,7 +183,7 @@ public: protected: // construction/destruction - cosmac_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cosmac_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -457,7 +457,7 @@ class cdp1801_device : public cosmac_device { public: // construction/destruction - cdp1801_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides @@ -478,10 +478,10 @@ class cdp1802_device : public cosmac_device { public: // construction/destruction - cdp1802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - cdp1802_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cdp1802_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device_disasm_interface overrides virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -499,10 +499,10 @@ class cdp1804_device : public cdp1802_device { public: // construction/destruction - cdp1804_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1804_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - cdp1804_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cdp1804_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual cosmac_device::ophandler get_ophandler(uint16_t opcode) const override; virtual bool has_extended_opcodes() override { return true; } @@ -520,10 +520,10 @@ class cdp1805_device : public cdp1804_device { public: // construction/destruction - cdp1805_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1805_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - cdp1805_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cdp1805_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device_disasm_interface overrides virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -536,7 +536,7 @@ class cdp1806_device : public cdp1805_device { public: // construction/destruction - cdp1806_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1806_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/cp1610/cp1610.cpp b/src/devices/cpu/cp1610/cp1610.cpp index 71d41844be8..c73bd969ebb 100644 --- a/src/devices/cpu/cp1610/cp1610.cpp +++ b/src/devices/cpu/cp1610/cp1610.cpp @@ -3390,7 +3390,7 @@ void cp1610_cpu_device::execute_set_input(int irqline, int state) } -cp1610_cpu_device::cp1610_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cp1610_cpu_device::cp1610_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, CP1610, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, 16, -1) , m_intr_state(0) diff --git a/src/devices/cpu/cr16b/cr16b.cpp b/src/devices/cpu/cr16b/cr16b.cpp index c9c6d414caf..89a8cbd15dc 100644 --- a/src/devices/cpu/cr16b/cr16b.cpp +++ b/src/devices/cpu/cr16b/cr16b.cpp @@ -15,7 +15,7 @@ // device type definitions DEFINE_DEVICE_TYPE(CR16B, cr16b_device, "cr16b", "CompactRISC CR16B") -cr16b_device::cr16b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map) +cr16b_device::cr16b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map) : cpu_device(mconfig, type, tag, owner, clock) , m_space_config("program", ENDIANNESS_LITTLE, 16, 21, 0, map) , m_regs{0} @@ -32,7 +32,7 @@ cr16b_device::cr16b_device(const machine_config &mconfig, device_type type, cons } // TODO: figure out some actual device types instead -cr16b_device::cr16b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cr16b_device::cr16b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cr16b_device(mconfig, CR16B, tag, owner, clock, address_map_constructor()) { } diff --git a/src/devices/cpu/cr16b/cr16b.h b/src/devices/cpu/cr16b/cr16b.h index a8028b03108..73d5c59787e 100644 --- a/src/devices/cpu/cr16b/cr16b.h +++ b/src/devices/cpu/cr16b/cr16b.h @@ -10,7 +10,7 @@ class cr16b_device : public cpu_device { public: - cr16b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cr16b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); enum { CR16_PC, CR16_ISP, CR16_INTBASE, @@ -23,7 +23,7 @@ public: protected: // construction/destruction - cr16b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map); + cr16b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/cubeqcpu/cubeqcpu.cpp b/src/devices/cpu/cubeqcpu/cubeqcpu.cpp index da608c33d65..72ad7fac169 100644 --- a/src/devices/cpu/cubeqcpu/cubeqcpu.cpp +++ b/src/devices/cpu/cubeqcpu/cubeqcpu.cpp @@ -75,7 +75,7 @@ DEFINE_DEVICE_TYPE(CQUESTROT, cquestrot_cpu_device, "cquestrot", "Cube Quest Rot DEFINE_DEVICE_TYPE(CQUESTLIN, cquestlin_cpu_device, "cquestlin", "Cube Quest Line CPU") -cquestsnd_cpu_device::cquestsnd_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cquestsnd_cpu_device::cquestsnd_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, CQUESTSND, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 64, 8, -3) , m_dac_w(*this) @@ -97,7 +97,7 @@ std::unique_ptr<util::disasm_interface> cquestsnd_cpu_device::create_disassemble } -cquestrot_cpu_device::cquestrot_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cquestrot_cpu_device::cquestrot_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, CQUESTROT, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 64, 9, -3) , m_linedata_w(*this) @@ -117,7 +117,7 @@ std::unique_ptr<util::disasm_interface> cquestrot_cpu_device::create_disassemble } -cquestlin_cpu_device::cquestlin_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cquestlin_cpu_device::cquestlin_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, CQUESTLIN, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 64, 8, -3) , m_linedata_r(*this) diff --git a/src/devices/cpu/cubeqcpu/cubeqcpu.h b/src/devices/cpu/cubeqcpu/cubeqcpu.h index 54070a1bd48..5ab672d6c79 100644 --- a/src/devices/cpu/cubeqcpu/cubeqcpu.h +++ b/src/devices/cpu/cubeqcpu/cubeqcpu.h @@ -20,7 +20,7 @@ class cquestsnd_cpu_device : public cpu_device { public: // construction/destruction - cquestsnd_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cquestsnd_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto dac_w() { return m_dac_w.bind(); } @@ -112,7 +112,7 @@ class cquestrot_cpu_device : public cpu_device { public: // construction/destruction - cquestrot_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cquestrot_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto linedata_w() { return m_linedata_w.bind(); } @@ -224,7 +224,7 @@ class cquestlin_cpu_device : public cpu_device { public: // construction/destruction - cquestlin_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cquestlin_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto linedata_r() { return m_linedata_r.bind(); } diff --git a/src/devices/cpu/diablo/diablo1300.cpp b/src/devices/cpu/diablo/diablo1300.cpp index baaf6f8bc47..361016a43a2 100644 --- a/src/devices/cpu/diablo/diablo1300.cpp +++ b/src/devices/cpu/diablo/diablo1300.cpp @@ -86,7 +86,7 @@ DEFINE_DEVICE_TYPE(DIABLO1300, diablo1300_cpu_device, "diablo1300", "DIABLO 1300 // diablo1300_cpu_device - constructor //------------------------------------------------- -diablo1300_cpu_device::diablo1300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +diablo1300_cpu_device::diablo1300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, DIABLO1300, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 9, -1) , m_data_config("data", ENDIANNESS_LITTLE, 8, 5) diff --git a/src/devices/cpu/diablo/diablo1300.h b/src/devices/cpu/diablo/diablo1300.h index 753d2f7b2b1..fa510664b74 100644 --- a/src/devices/cpu/diablo/diablo1300.h +++ b/src/devices/cpu/diablo/diablo1300.h @@ -20,7 +20,7 @@ class diablo1300_cpu_device : public cpu_device { public: // construction/destruction - diablo1300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + diablo1300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/dsp16/dsp16.cpp b/src/devices/cpu/dsp16/dsp16.cpp index 4078389e2bc..75bb5f39ac8 100644 --- a/src/devices/cpu/dsp16/dsp16.cpp +++ b/src/devices/cpu/dsp16/dsp16.cpp @@ -171,7 +171,7 @@ dsp16_device_base::dsp16_device_base( device_type type, char const *tag, device_t *owner, - u32 clock, + const XTAL &clock, u8 yaau_bits, address_map_constructor &&data_map) : cpu_device(mconfig, type, tag, owner, clock) @@ -2075,7 +2075,7 @@ void dsp16_device_base::pio_pdx_write(u16 sel, u16 value) DSP16 SPECIALISATION ***************************************************************************/ -dsp16_device::dsp16_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +dsp16_device::dsp16_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : dsp16_device_base( mconfig, DSP16, tag, owner, clock, 9, @@ -2107,7 +2107,7 @@ void dsp16_device::data_map(address_map &map) DSP16A SPECIALISATION ***************************************************************************/ -dsp16a_device::dsp16a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +dsp16a_device::dsp16a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : dsp16_device_base( mconfig, DSP16A, tag, owner, clock, 16, diff --git a/src/devices/cpu/dsp16/dsp16.h b/src/devices/cpu/dsp16/dsp16.h index 3f7ae66dd53..c8c2e4b631a 100644 --- a/src/devices/cpu/dsp16/dsp16.h +++ b/src/devices/cpu/dsp16/dsp16.h @@ -70,7 +70,7 @@ protected: device_type type, char const *tag, device_t *owner, - u32 clock, + const XTAL &clock, u8 yaau_bits, address_map_constructor &&data_map); @@ -342,7 +342,7 @@ class dsp16_device : public dsp16_device_base { public: // construction/destruction - dsp16_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + dsp16_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // dsp16_device_base implementation @@ -360,7 +360,7 @@ class dsp16a_device : public dsp16_device_base { public: // construction/destruction - dsp16a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + dsp16a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // dsp16_device_base implementation diff --git a/src/devices/cpu/dsp32/dsp32.cpp b/src/devices/cpu/dsp32/dsp32.cpp index 9ef3aef63c9..e4a4316fdb0 100644 --- a/src/devices/cpu/dsp32/dsp32.cpp +++ b/src/devices/cpu/dsp32/dsp32.cpp @@ -142,7 +142,7 @@ DEFINE_DEVICE_TYPE(DSP32C, dsp32c_device, "dsp32c", "AT&T DSP32C") // dsp32c_device - constructor //------------------------------------------------- -dsp32c_device::dsp32c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dsp32c_device::dsp32c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, DSP32C, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 32, 24), m_pin(0), diff --git a/src/devices/cpu/dsp32/dsp32.h b/src/devices/cpu/dsp32/dsp32.h index 90ede0181fa..babec516eef 100644 --- a/src/devices/cpu/dsp32/dsp32.h +++ b/src/devices/cpu/dsp32/dsp32.h @@ -36,7 +36,7 @@ class dsp32c_device : public cpu_device { public: // construction/destruction - dsp32c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dsp32c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_cb() { return m_output_pins_changed.bind(); } diff --git a/src/devices/cpu/dsp56000/dsp56000.cpp b/src/devices/cpu/dsp56000/dsp56000.cpp index eed944bdc0a..0bb28ef0b40 100644 --- a/src/devices/cpu/dsp56000/dsp56000.cpp +++ b/src/devices/cpu/dsp56000/dsp56000.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(DSP56000, dsp56000_device, "dsp56000", "Motorola DSP56000") DEFINE_DEVICE_TYPE(DSP56001, dsp56001_device, "dsp56001", "Motorola DSP56001") -dsp56000_device_base::dsp56000_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) +dsp56000_device_base::dsp56000_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_p_config("p", ENDIANNESS_BIG, 32, 16, -2) , m_x_config("x", ENDIANNESS_BIG, 32, 16, -2) @@ -33,12 +33,12 @@ dsp56000_device_base::dsp56000_device_base(machine_config const &mconfig, device { } -dsp56000_device::dsp56000_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +dsp56000_device::dsp56000_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : dsp56000_device_base(mconfig, DSP56000, tag, owner, clock) { } -dsp56001_device::dsp56001_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +dsp56001_device::dsp56001_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : dsp56000_device_base(mconfig, DSP56001, tag, owner, clock) { } diff --git a/src/devices/cpu/dsp56000/dsp56000.h b/src/devices/cpu/dsp56000/dsp56000.h index 0a47b2fe078..bd813e2021f 100644 --- a/src/devices/cpu/dsp56000/dsp56000.h +++ b/src/devices/cpu/dsp56000/dsp56000.h @@ -9,7 +9,7 @@ class dsp56000_device_base : public cpu_device { protected: - dsp56000_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + dsp56000_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device_t overrides virtual void device_start() override; @@ -44,13 +44,13 @@ protected: class dsp56000_device : public dsp56000_device_base { public: - dsp56000_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + dsp56000_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class dsp56001_device : public dsp56000_device_base { public: - dsp56001_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + dsp56001_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(DSP56000, dsp56000_device) diff --git a/src/devices/cpu/dsp56156/dsp56156.cpp b/src/devices/cpu/dsp56156/dsp56156.cpp index f8685d080ae..4a6e724ea2b 100644 --- a/src/devices/cpu/dsp56156/dsp56156.cpp +++ b/src/devices/cpu/dsp56156/dsp56156.cpp @@ -122,7 +122,7 @@ void dsp56156_device::dsp56156_x_data_map(address_map &map) } -dsp56156_device::dsp56156_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dsp56156_device::dsp56156_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, DSP56156, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 16, -1, address_map_constructor(FUNC(dsp56156_device::dsp56156_program_map), this)) , m_data_config("data", ENDIANNESS_LITTLE, 16, 16, -1, address_map_constructor(FUNC(dsp56156_device::dsp56156_x_data_map), this)) diff --git a/src/devices/cpu/dsp56156/dsp56156.h b/src/devices/cpu/dsp56156/dsp56156.h index 4317fa249f5..7326b809e97 100644 --- a/src/devices/cpu/dsp56156/dsp56156.h +++ b/src/devices/cpu/dsp56156/dsp56156.h @@ -203,7 +203,7 @@ struct dsp56156_core class dsp56156_device : public cpu_device { public: - dsp56156_device(const machine_config &mconfig, const char *_tag, device_t *_owner, uint32_t _clock); + dsp56156_device(const machine_config &mconfig, const char *_tag, device_t *_owner, const XTAL &_clock); uint16_t peripheral_register_r(offs_t offset); void peripheral_register_w(offs_t offset, uint16_t data); diff --git a/src/devices/cpu/dspp/dspp.cpp b/src/devices/cpu/dspp/dspp.cpp index 70bc923a67e..995bdd27cf2 100644 --- a/src/devices/cpu/dspp/dspp.cpp +++ b/src/devices/cpu/dspp/dspp.cpp @@ -85,13 +85,13 @@ DEFINE_DEVICE_TYPE(DSPP, dspp_device, "dspp", "3DO DSPP") // dspp_device - constructor //------------------------------------------------- -dspp_device::dspp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dspp_device::dspp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dspp_device(mconfig, DSPP, tag, owner, clock, address_map_constructor(FUNC(dspp_device::code_map), this), address_map_constructor(FUNC(dspp_device::data_map), this)) { } -dspp_device::dspp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor code_map_ctor, address_map_constructor data_map_ctor) +dspp_device::dspp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor code_map_ctor, address_map_constructor data_map_ctor) : cpu_device(mconfig, type, tag, owner, clock), m_int_handler(*this), m_dma_read_handler(*this), diff --git a/src/devices/cpu/dspp/dspp.h b/src/devices/cpu/dspp/dspp.h index 68492fb7f40..75a502501c9 100644 --- a/src/devices/cpu/dspp/dspp.h +++ b/src/devices/cpu/dspp/dspp.h @@ -31,9 +31,9 @@ class dspp_device : public cpu_device friend class dspp_frontend; public: // Construction/destruction - dspp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor code_map_ctor, + dspp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor code_map_ctor, address_map_constructor data_map_ctor); - dspp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dspp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Static configuration helpers auto int_handler() { return m_int_handler.bind(); } @@ -389,5 +389,6 @@ public: // TODO // device type definition DECLARE_DEVICE_TYPE(DSPP, dspp_device); +#include "dsppfe.h" #endif // MAME_CPU_DSPP_DSPP_H diff --git a/src/devices/cpu/e0c6200/e0c6200.cpp b/src/devices/cpu/e0c6200/e0c6200.cpp index 303ad5d5754..fb56dd3babb 100644 --- a/src/devices/cpu/e0c6200/e0c6200.cpp +++ b/src/devices/cpu/e0c6200/e0c6200.cpp @@ -24,7 +24,7 @@ // construction/destruction -e0c6200_cpu_device::e0c6200_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor program, address_map_constructor data) +e0c6200_cpu_device::e0c6200_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program, address_map_constructor data) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, 13, -1, program) , m_data_config("data", ENDIANNESS_BIG, 8, 12, 0, data), m_program(nullptr), m_data(nullptr), m_op(0), m_prev_op(0), m_irq_vector(0), m_irq_id(0), m_possible_irq(false), m_halt(false), diff --git a/src/devices/cpu/e0c6200/e0c6200.h b/src/devices/cpu/e0c6200/e0c6200.h index 5222983e09b..62da9ec213c 100644 --- a/src/devices/cpu/e0c6200/e0c6200.h +++ b/src/devices/cpu/e0c6200/e0c6200.h @@ -14,7 +14,7 @@ class e0c6200_cpu_device : public cpu_device { public: // construction/destruction - e0c6200_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor program, address_map_constructor data); + e0c6200_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program, address_map_constructor data); protected: // device-level overrides diff --git a/src/devices/cpu/e0c6200/e0c6s46.cpp b/src/devices/cpu/e0c6200/e0c6s46.cpp index 5e30570ae76..578edfa481b 100644 --- a/src/devices/cpu/e0c6200/e0c6s46.cpp +++ b/src/devices/cpu/e0c6200/e0c6s46.cpp @@ -48,7 +48,7 @@ void e0c6s46_device::e0c6s46_data(address_map &map) // device definitions -e0c6s46_device::e0c6s46_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +e0c6s46_device::e0c6s46_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : e0c6200_cpu_device(mconfig, E0C6S46, tag, owner, clock, address_map_constructor(FUNC(e0c6s46_device::e0c6s46_program), this), address_map_constructor(FUNC(e0c6s46_device::e0c6s46_data), this)) , m_vram1(*this, "vram1") , m_vram2(*this, "vram2") diff --git a/src/devices/cpu/e0c6200/e0c6s46.h b/src/devices/cpu/e0c6200/e0c6s46.h index 0fb7a67e44c..658b69208f8 100644 --- a/src/devices/cpu/e0c6200/e0c6s46.h +++ b/src/devices/cpu/e0c6200/e0c6s46.h @@ -51,7 +51,7 @@ class e0c6s46_device : public e0c6200_cpu_device public: typedef device_delegate<void (bitmap_ind16 &bitmap, const rectangle &cliprect, int contrast, int seg, int com, int state)> pixel_update_delegate; - e0c6s46_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + e0c6s46_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // 5 4-bit R output ports template <std::size_t Port> auto write_r() { return m_write_r[Port].bind(); } diff --git a/src/devices/cpu/e132xs/e132xs.cpp b/src/devices/cpu/e132xs/e132xs.cpp index 1331bb1a890..8b3819be1cc 100644 --- a/src/devices/cpu/e132xs/e132xs.cpp +++ b/src/devices/cpu/e132xs/e132xs.cpp @@ -201,7 +201,7 @@ void hyperstone_device::e132_16k_iram_map(address_map &map) // hyperstone_device - constructor //------------------------------------------------- -hyperstone_device::hyperstone_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, +hyperstone_device::hyperstone_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, uint32_t prg_data_width, uint32_t io_data_width, address_map_constructor internal_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, prg_data_width, 32, 0, internal_map) @@ -237,7 +237,7 @@ hyperstone_device::~hyperstone_device() // e116t_device - constructor //------------------------------------------------- -e116t_device::e116t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e116t_device::e116t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, E116T, 16, 16, address_map_constructor(FUNC(e116t_device::e116_4k_iram_map), this)) { } @@ -247,7 +247,7 @@ e116t_device::e116t_device(const machine_config &mconfig, const char *tag, devic // e116xt_device - constructor //------------------------------------------------- -e116xt_device::e116xt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e116xt_device::e116xt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, E116XT, 16, 16, address_map_constructor(FUNC(e116t_device::e116_8k_iram_map), this)) { } @@ -257,7 +257,7 @@ e116xt_device::e116xt_device(const machine_config &mconfig, const char *tag, dev // e116xs_device - constructor //------------------------------------------------- -e116xs_device::e116xs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e116xs_device::e116xs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, E116XS, 16, 16, address_map_constructor(FUNC(e116xs_device::e116_16k_iram_map), this)) { } @@ -267,7 +267,7 @@ e116xs_device::e116xs_device(const machine_config &mconfig, const char *tag, dev // e116xsr_device - constructor //------------------------------------------------- -e116xsr_device::e116xsr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e116xsr_device::e116xsr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, E116XSR, 16, 16, address_map_constructor(FUNC(e116xsr_device::e116_16k_iram_map), this)) { } @@ -277,7 +277,7 @@ e116xsr_device::e116xsr_device(const machine_config &mconfig, const char *tag, d // e132n_device - constructor //------------------------------------------------- -e132n_device::e132n_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e132n_device::e132n_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, E132N, 32, 32, address_map_constructor(FUNC(e132n_device::e132_4k_iram_map), this)) { } @@ -287,7 +287,7 @@ e132n_device::e132n_device(const machine_config &mconfig, const char *tag, devic // e132t_device - constructor //------------------------------------------------- -e132t_device::e132t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e132t_device::e132t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, E132T, 32, 32, address_map_constructor(FUNC(e132t_device::e132_4k_iram_map), this)) { } @@ -297,7 +297,7 @@ e132t_device::e132t_device(const machine_config &mconfig, const char *tag, devic // e132xn_device - constructor //------------------------------------------------- -e132xn_device::e132xn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e132xn_device::e132xn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, E132XN, 32, 32, address_map_constructor(FUNC(e132xn_device::e132_8k_iram_map), this)) { } @@ -307,7 +307,7 @@ e132xn_device::e132xn_device(const machine_config &mconfig, const char *tag, dev // e132xt_device - constructor //------------------------------------------------- -e132xt_device::e132xt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e132xt_device::e132xt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, E132XT, 32, 32, address_map_constructor(FUNC(e132xt_device::e132_8k_iram_map), this)) { } @@ -317,7 +317,7 @@ e132xt_device::e132xt_device(const machine_config &mconfig, const char *tag, dev // e132xs_device - constructor //------------------------------------------------- -e132xs_device::e132xs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e132xs_device::e132xs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, E132XS, 32, 32, address_map_constructor(FUNC(e132xs_device::e132_16k_iram_map), this)) { } @@ -327,7 +327,7 @@ e132xs_device::e132xs_device(const machine_config &mconfig, const char *tag, dev // e132xsr_device - constructor //------------------------------------------------- -e132xsr_device::e132xsr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e132xsr_device::e132xsr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, E132XSR, 32, 32, address_map_constructor(FUNC(e132xsr_device::e132_16k_iram_map), this)) { } @@ -337,7 +337,7 @@ e132xsr_device::e132xsr_device(const machine_config &mconfig, const char *tag, d // gms30c2116_device - constructor //------------------------------------------------- -gms30c2116_device::gms30c2116_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gms30c2116_device::gms30c2116_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, GMS30C2116, 16, 16, address_map_constructor(FUNC(gms30c2116_device::e116_4k_iram_map), this)) { } @@ -347,7 +347,7 @@ gms30c2116_device::gms30c2116_device(const machine_config &mconfig, const char * // gms30c2132_device - constructor //------------------------------------------------- -gms30c2132_device::gms30c2132_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gms30c2132_device::gms30c2132_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, GMS30C2132, 32, 32, address_map_constructor(FUNC(gms30c2132_device::e132_4k_iram_map), this)) { } @@ -357,7 +357,7 @@ gms30c2132_device::gms30c2132_device(const machine_config &mconfig, const char * // gms30c2216_device - constructor //------------------------------------------------- -gms30c2216_device::gms30c2216_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gms30c2216_device::gms30c2216_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, GMS30C2216, 16, 16, address_map_constructor(FUNC(gms30c2216_device::e116_8k_iram_map), this)) { } @@ -367,7 +367,7 @@ gms30c2216_device::gms30c2216_device(const machine_config &mconfig, const char * // gms30c2232_device - constructor //------------------------------------------------- -gms30c2232_device::gms30c2232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gms30c2232_device::gms30c2232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hyperstone_device(mconfig, tag, owner, clock, GMS30C2232, 32, 32, address_map_constructor(FUNC(gms30c2232_device::e132_8k_iram_map), this)) { } diff --git a/src/devices/cpu/e132xs/e132xs.h b/src/devices/cpu/e132xs/e132xs.h index 51f9c5cc3c1..bb8d6b066b9 100644 --- a/src/devices/cpu/e132xs/e132xs.h +++ b/src/devices/cpu/e132xs/e132xs.h @@ -273,7 +273,7 @@ protected: }; // construction/destruction - hyperstone_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, + hyperstone_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, uint32_t prg_data_width, uint32_t io_data_width, address_map_constructor internal_map); void init(int scale_mask); @@ -617,7 +617,7 @@ class e116t_device : public hyperstone_device { public: // construction/destruction - e116t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e116t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -630,7 +630,7 @@ class e116xt_device : public hyperstone_device { public: // construction/destruction - e116xt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e116xt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -643,7 +643,7 @@ class e116xs_device : public hyperstone_device { public: // construction/destruction - e116xs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e116xs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -656,7 +656,7 @@ class e116xsr_device : public hyperstone_device { public: // construction/destruction - e116xsr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e116xsr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -669,7 +669,7 @@ class e132n_device : public hyperstone_device { public: // construction/destruction - e132n_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e132n_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -682,7 +682,7 @@ class e132t_device : public hyperstone_device { public: // construction/destruction - e132t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e132t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -695,7 +695,7 @@ class e132xn_device : public hyperstone_device { public: // construction/destruction - e132xn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e132xn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -708,7 +708,7 @@ class e132xt_device : public hyperstone_device { public: // construction/destruction - e132xt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e132xt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -721,7 +721,7 @@ class e132xs_device : public hyperstone_device { public: // construction/destruction - e132xs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e132xs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -734,7 +734,7 @@ class e132xsr_device : public hyperstone_device { public: // construction/destruction - e132xsr_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e132xsr_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -747,7 +747,7 @@ class gms30c2116_device : public hyperstone_device { public: // construction/destruction - gms30c2116_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gms30c2116_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -760,7 +760,7 @@ class gms30c2132_device : public hyperstone_device { public: // construction/destruction - gms30c2132_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gms30c2132_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -773,7 +773,7 @@ class gms30c2216_device : public hyperstone_device { public: // construction/destruction - gms30c2216_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gms30c2216_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -786,7 +786,7 @@ class gms30c2232_device : public hyperstone_device { public: // construction/destruction - gms30c2232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gms30c2232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/cpu/es5510/es5510.cpp b/src/devices/cpu/es5510/es5510.cpp index 6614c03ab52..2520fcf729d 100644 --- a/src/devices/cpu/es5510/es5510.cpp +++ b/src/devices/cpu/es5510/es5510.cpp @@ -134,7 +134,7 @@ inline static int32_t asl(int32_t value, int shift, uint8_t &flags) { } // Initialize ESP to mostly zeroed, configured for 64k samples of delay line memory, running (not halted) -es5510_device::es5510_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +es5510_device::es5510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, ES5510, tag, owner, clock) , icount(0) , halt_asserted(false) diff --git a/src/devices/cpu/es5510/es5510.h b/src/devices/cpu/es5510/es5510.h index 9f8d10035ca..7f046416205 100644 --- a/src/devices/cpu/es5510/es5510.h +++ b/src/devices/cpu/es5510/es5510.h @@ -19,7 +19,7 @@ public: static constexpr uint32_t DRAM_MASK = (DRAM_SIZE-1); static constexpr feature_type imperfect_features() { return feature::SOUND; } - es5510_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + es5510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t host_r(address_space &space, offs_t offset); void host_w(offs_t offset, uint8_t data); diff --git a/src/devices/cpu/esrip/esrip.cpp b/src/devices/cpu/esrip/esrip.cpp index 40457212abb..8372be41eda 100644 --- a/src/devices/cpu/esrip/esrip.cpp +++ b/src/devices/cpu/esrip/esrip.cpp @@ -1667,7 +1667,7 @@ DEFINE_DEVICE_TYPE(ESRIP, esrip_device, "esrip", "Entertainment Sciences RIP") // esrip_device - constructor //------------------------------------------------- -esrip_device::esrip_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +esrip_device::esrip_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, ESRIP, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 64, 9, -3) , m_fdt_r(*this) diff --git a/src/devices/cpu/esrip/esrip.h b/src/devices/cpu/esrip/esrip.h index f58b2d41a97..64b041549bd 100644 --- a/src/devices/cpu/esrip/esrip.h +++ b/src/devices/cpu/esrip/esrip.h @@ -32,7 +32,7 @@ public: typedef device_delegate<int (int l, int r, int fig, int attr, int addr, int col, int x_scale, int bank)> draw_delegate; // construction/destruction - esrip_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + esrip_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration helpers void set_lbrm_prom_region(const char *name) { m_lbrm_prom = name; } diff --git a/src/devices/cpu/f2mc16/f2mc16.cpp b/src/devices/cpu/f2mc16/f2mc16.cpp index de4098685c7..804c7a4482a 100644 --- a/src/devices/cpu/f2mc16/f2mc16.cpp +++ b/src/devices/cpu/f2mc16/f2mc16.cpp @@ -31,7 +31,7 @@ std::unique_ptr<util::disasm_interface> f2mc16_device::create_disassembler() return std::make_unique<f2mc16_disassembler>(); } -f2mc16_device::f2mc16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +f2mc16_device::f2mc16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 24, 0) , m_program(nullptr) @@ -43,7 +43,7 @@ f2mc16_device::f2mc16_device(const machine_config &mconfig, device_type type, co m_prefix_valid = false; } -f2mc16_device::f2mc16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +f2mc16_device::f2mc16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : f2mc16_device(mconfig, F2MC16, tag, owner, clock) { } diff --git a/src/devices/cpu/f2mc16/f2mc16.h b/src/devices/cpu/f2mc16/f2mc16.h index fc1ffc3aa55..766af666301 100644 --- a/src/devices/cpu/f2mc16/f2mc16.h +++ b/src/devices/cpu/f2mc16/f2mc16.h @@ -38,10 +38,10 @@ public: }; // construction/destruction - f2mc16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + f2mc16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - f2mc16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + f2mc16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/f2mc16/mb9061x.cpp b/src/devices/cpu/f2mc16/mb9061x.cpp index e8940162329..11b41da4e05 100644 --- a/src/devices/cpu/f2mc16/mb9061x.cpp +++ b/src/devices/cpu/f2mc16/mb9061x.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(MB90641A, mb90641_device, "mb90641a", "Fujitsu MB90641A") //------------------------------------------------- // mb9061x_device - constructor //------------------------------------------------- -mb9061x_device::mb9061x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map) : +mb9061x_device::mb9061x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map) : f2mc16_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 8, 24, 0, internal_map) { @@ -82,12 +82,12 @@ void mb90610_device::mb90610_map(address_map &map) map(0x0100, 0x10ff).ram(); // 4K of internal RAM from 0x100 to 0x1100 } -mb90610_device::mb90610_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mb90610_device::mb90610_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb90610_device(mconfig, MB90610A, tag, owner, clock) { } -mb90610_device::mb90610_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +mb90610_device::mb90610_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : mb9061x_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(mb90610_device::mb90610_map), this)) { } @@ -412,12 +412,12 @@ void mb90611_device::mb90611_map(address_map &map) map(0x0100, 0x04ff).ram(); // 1K of internal RAM from 0x100 to 0x500 } -mb90611_device::mb90611_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mb90611_device::mb90611_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb90611_device(mconfig, MB90611A, tag, owner, clock) { } -mb90611_device::mb90611_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +mb90611_device::mb90611_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : mb9061x_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(mb90611_device::mb90611_map), this)) { } @@ -431,12 +431,12 @@ void mb90641_device::mb90641_map(address_map &map) map(0x0100, 0x08ff).ram(); // 2K of internal RAM } -mb90641_device::mb90641_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mb90641_device::mb90641_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb90641_device(mconfig, MB90641A, tag, owner, clock) { } -mb90641_device::mb90641_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +mb90641_device::mb90641_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : mb9061x_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(mb90641_device::mb90641_map), this)) { } diff --git a/src/devices/cpu/f2mc16/mb9061x.h b/src/devices/cpu/f2mc16/mb9061x.h index c09bdef1b96..29257e46a53 100644 --- a/src/devices/cpu/f2mc16/mb9061x.h +++ b/src/devices/cpu/f2mc16/mb9061x.h @@ -38,7 +38,7 @@ public: protected: // construction/destruction - mb9061x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map); + mb9061x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map); // device-level overrides virtual void device_start() override; @@ -81,31 +81,31 @@ private: class mb90610_device : public mb9061x_device { public: - mb90610_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb90610_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void mb90610_map(address_map &map); protected: - mb90610_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mb90610_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; class mb90611_device : public mb9061x_device { public: - mb90611_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb90611_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void mb90611_map(address_map &map); protected: - mb90611_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mb90611_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; class mb90641_device : public mb9061x_device { public: - mb90641_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb90641_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void mb90641_map(address_map &map); protected: - mb90641_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mb90641_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(MB90610A, mb90610_device) diff --git a/src/devices/cpu/f8/f8.cpp b/src/devices/cpu/f8/f8.cpp index b7168380dad..d403dec600e 100644 --- a/src/devices/cpu/f8/f8.cpp +++ b/src/devices/cpu/f8/f8.cpp @@ -63,7 +63,7 @@ static constexpr int cL = 6; DEFINE_DEVICE_TYPE(F8, f8_cpu_device, "f8", "Fairchild F8") -f8_cpu_device::f8_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +f8_cpu_device::f8_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, F8, tag, owner, clock), m_program_config("program", ENDIANNESS_BIG, 8, 16, 0), m_regs_config("register", ENDIANNESS_BIG, 8, 6, 0, address_map_constructor(FUNC(f8_cpu_device::regs_map), this)), diff --git a/src/devices/cpu/f8/f8.h b/src/devices/cpu/f8/f8.h index fd823acb705..3c14f0fb5bd 100644 --- a/src/devices/cpu/f8/f8.h +++ b/src/devices/cpu/f8/f8.h @@ -18,7 +18,7 @@ class f8_cpu_device : public cpu_device { public: // construction/destruction - f8_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + f8_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // used by F3850 systems that override the normal zero reset address auto romc08_callback() { return m_romc08_callback.bind(); } diff --git a/src/devices/cpu/fr/fr.cpp b/src/devices/cpu/fr/fr.cpp index 51ae7313780..964a7689bda 100644 --- a/src/devices/cpu/fr/fr.cpp +++ b/src/devices/cpu/fr/fr.cpp @@ -15,7 +15,7 @@ // device type definition DEFINE_DEVICE_TYPE(MB91F155A, mb91f155a_device, "mb91f155a", "Fujitsu MB91F155A") -fr_cpu_device::fr_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int addrbits, address_map_constructor map) +fr_cpu_device::fr_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addrbits, address_map_constructor map) : cpu_device(mconfig, type, tag, owner, clock) , m_space_config("program", ENDIANNESS_BIG, 32, addrbits, 0, map) , m_regs{0} @@ -28,7 +28,7 @@ fr_cpu_device::fr_cpu_device(const machine_config &mconfig, device_type type, co { } -mb91f155a_device::mb91f155a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mb91f155a_device::mb91f155a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : fr_cpu_device(mconfig, MB91F155A, tag, owner, clock, 24, address_map_constructor(FUNC(mb91f155a_device::internal_map), this)) { } diff --git a/src/devices/cpu/fr/fr.h b/src/devices/cpu/fr/fr.h index 60e6eb8469f..e148109758b 100644 --- a/src/devices/cpu/fr/fr.h +++ b/src/devices/cpu/fr/fr.h @@ -21,7 +21,7 @@ public: protected: // construction/destruction - fr_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int addrbits, address_map_constructor map); + fr_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addrbits, address_map_constructor map); // device-level overrides virtual void device_start() override; @@ -60,7 +60,7 @@ class mb91f155a_device : public fr_cpu_device { public: // device type constructor - mb91f155a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mb91f155a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: void internal_map(address_map &map); diff --git a/src/devices/cpu/g65816/g65816.cpp b/src/devices/cpu/g65816/g65816.cpp index 7476fb8cde0..747863b8a42 100644 --- a/src/devices/cpu/g65816/g65816.cpp +++ b/src/devices/cpu/g65816/g65816.cpp @@ -113,18 +113,18 @@ enum }; -g65816_device::g65816_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +g65816_device::g65816_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : g65816_device(mconfig, G65816, tag, owner, clock, CPU_TYPE_W65C816, address_map_constructor()) { } -g65802_device::g65802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +g65802_device::g65802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : g65816_device(mconfig, G65802, tag, owner, clock, CPU_TYPE_W65C802, address_map_constructor()) { } -g65816_device::g65816_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int cpu_type, address_map_constructor internal) +g65816_device::g65816_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cpu_type, address_map_constructor internal) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, (cpu_type == CPU_TYPE_W65C802) ? 16 : 24, 0, internal) , m_data_config("data", ENDIANNESS_LITTLE, 8, (cpu_type == CPU_TYPE_W65C802) ? 16 : 24, 0, internal) @@ -168,7 +168,7 @@ void _5a22_device::_5a22_map(address_map &map) } -_5a22_device::_5a22_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +_5a22_device::_5a22_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : g65816_device(mconfig, _5A22, tag, owner, clock, CPU_TYPE_5A22, address_map_constructor(FUNC(_5a22_device::_5a22_map), this)) { } diff --git a/src/devices/cpu/g65816/g65816.h b/src/devices/cpu/g65816/g65816.h index b21845e76ec..37a750806fd 100644 --- a/src/devices/cpu/g65816/g65816.h +++ b/src/devices/cpu/g65816/g65816.h @@ -54,7 +54,7 @@ public: }; // construction/destruction - g65816_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + g65816_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto wdm_handler() { return m_wdm_w.bind(); } @@ -68,7 +68,7 @@ public: }; protected: - g65816_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int cpu_type, address_map_constructor internal); + g65816_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cpu_type, address_map_constructor internal); // device-level overrides virtual void device_start() override; @@ -1543,14 +1543,14 @@ protected: class g65802_device : public g65816_device { public: - g65802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + g65802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class _5a22_device : public g65816_device { public: - _5a22_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + _5a22_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void wrmpya_w(uint8_t data); void wrmpyb_w(uint8_t data); diff --git a/src/devices/cpu/gigatron/gigatron.cpp b/src/devices/cpu/gigatron/gigatron.cpp index 5729a33633e..b26e7da86b8 100644 --- a/src/devices/cpu/gigatron/gigatron.cpp +++ b/src/devices/cpu/gigatron/gigatron.cpp @@ -339,7 +339,7 @@ void gigatron_cpu_device::execute_set_input(int irqline, int state) #endif } -gigatron_cpu_device::gigatron_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gigatron_cpu_device::gigatron_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, GTRON, tag, owner, clock) , m_ramMask(0xffff) , m_romMask(0xffff) diff --git a/src/devices/cpu/gigatron/gigatron.h b/src/devices/cpu/gigatron/gigatron.h index b224b4ab280..1d019106fec 100644 --- a/src/devices/cpu/gigatron/gigatron.h +++ b/src/devices/cpu/gigatron/gigatron.h @@ -28,7 +28,7 @@ class gigatron_cpu_device : public cpu_device { public: // construction/destruction - gigatron_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gigatron_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto outx_cb() { return m_outx_cb.bind(); } auto out_cb() { return m_out_cb.bind(); } auto ir_cb() { return m_ir_cb.bind(); } diff --git a/src/devices/cpu/h16/hd641016.cpp b/src/devices/cpu/h16/hd641016.cpp index 9bfaa6a5cd4..c4bbe1f540a 100644 --- a/src/devices/cpu/h16/hd641016.cpp +++ b/src/devices/cpu/h16/hd641016.cpp @@ -15,7 +15,7 @@ // device type definition DEFINE_DEVICE_TYPE(HD641016, hd641016_device, "hd641016", "Hitachi HD641016") -hd641016_device::hd641016_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd641016_device::hd641016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, HD641016, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, 24, 0) , m_data_config("data", ENDIANNESS_BIG, 32, 10, 0, address_map_constructor(FUNC(hd641016_device::ram_map), this)) diff --git a/src/devices/cpu/h16/hd641016.h b/src/devices/cpu/h16/hd641016.h index 1c93f5a2ff3..24d29165730 100644 --- a/src/devices/cpu/h16/hd641016.h +++ b/src/devices/cpu/h16/hd641016.h @@ -85,7 +85,7 @@ public: }; // device type constructor - hd641016_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd641016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/h6280/h6280.cpp b/src/devices/cpu/h6280/h6280.cpp index 27c042ab299..766d0ed12ce 100644 --- a/src/devices/cpu/h6280/h6280.cpp +++ b/src/devices/cpu/h6280/h6280.cpp @@ -167,7 +167,7 @@ DEFINE_DEVICE_TYPE(H6280, h6280_device, "h6280", "Hudson Soft HuC6280") // h6280_device - constructor //------------------------------------------------- -h6280_device::h6280_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +h6280_device::h6280_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, H6280, tag, owner, clock) , device_mixer_interface(mconfig, *this, 2) , m_program_config("program", ENDIANNESS_LITTLE, 8, 21, 0, 16, 0, address_map_constructor(FUNC(h6280_device::internal_map), this)) diff --git a/src/devices/cpu/h6280/h6280.h b/src/devices/cpu/h6280/h6280.h index 22d3ac06ce6..1b5f386ea12 100644 --- a/src/devices/cpu/h6280/h6280.h +++ b/src/devices/cpu/h6280/h6280.h @@ -32,7 +32,7 @@ class h6280_device : public cpu_device, public device_mixer_interface { public: // construction/destruction - h6280_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h6280_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // public interfaces void set_irq_line(int irqline, int state); diff --git a/src/devices/cpu/h8/gt913.cpp b/src/devices/cpu/h8/gt913.cpp index c56c8ed94f3..ef9edb1bb8b 100644 --- a/src/devices/cpu/h8/gt913.cpp +++ b/src/devices/cpu/h8/gt913.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(GT913, gt913_device, "gt913", "Casio GT913F") -gt913_device::gt913_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gt913_device::gt913_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_device(mconfig, GT913, tag, owner, clock, address_map_constructor(FUNC(gt913_device::map), this)), device_mixer_interface(mconfig, *this, 2), m_rom(*this, DEVICE_SELF), @@ -104,7 +104,7 @@ void gt913_device::device_add_mconfig(machine_config &config) m_sound->add_route(0, *this, 1.0, AUTO_ALLOC_INPUT, 0); m_sound->add_route(1, *this, 1.0, AUTO_ALLOC_INPUT, 1); - GT913_KBD_HLE(config, m_kbd, 0); + GT913_KBD_HLE(config, m_kbd); m_kbd->irq_cb().set([this] (int val) { if (val) diff --git a/src/devices/cpu/h8/gt913.h b/src/devices/cpu/h8/gt913.h index 4ba89661abb..07ea286a5aa 100644 --- a/src/devices/cpu/h8/gt913.h +++ b/src/devices/cpu/h8/gt913.h @@ -23,7 +23,7 @@ class gt913_device : public h8_device, public device_mixer_interface { public: - gt913_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gt913_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/h8/h8.cpp b/src/devices/cpu/h8/h8.cpp index cd40624586c..dc5e394bcc1 100644 --- a/src/devices/cpu/h8/h8.cpp +++ b/src/devices/cpu/h8/h8.cpp @@ -15,7 +15,7 @@ #include "h8_dtc.h" #include "h8d.h" -h8_device::h8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor map_delegate) : +h8_device::h8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map_delegate) : cpu_device(mconfig, type, tag, owner, clock), program_config("program", ENDIANNESS_BIG, 16, 16, 0, map_delegate), io_config("io", ENDIANNESS_BIG, 16, 16, -1), PPC(0), NPC(0), PC(0), PIR(0), EXR(0), CCR(0), MAC(0), MACF(0), diff --git a/src/devices/cpu/h8/h8.h b/src/devices/cpu/h8/h8.h index 78ee9425142..7f744ad3709 100644 --- a/src/devices/cpu/h8/h8.h +++ b/src/devices/cpu/h8/h8.h @@ -87,7 +87,7 @@ protected: EXR_I = 0x07 }; - h8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor map_delegate); + h8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map_delegate); // device-level overrides virtual void device_config_complete() override; diff --git a/src/devices/cpu/h8/h83002.cpp b/src/devices/cpu/h8/h83002.cpp index 664134669c9..beeb917f05b 100644 --- a/src/devices/cpu/h8/h83002.cpp +++ b/src/devices/cpu/h8/h83002.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(H83002, h83002_device, "h83002", "Hitachi H8/3002") -h83002_device::h83002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83002_device::h83002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8h_device(mconfig, H83002, tag, owner, clock, address_map_constructor(FUNC(h83002_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), diff --git a/src/devices/cpu/h8/h83002.h b/src/devices/cpu/h8/h83002.h index 94c1d603230..dce30bd0b3d 100644 --- a/src/devices/cpu/h8/h83002.h +++ b/src/devices/cpu/h8/h83002.h @@ -27,7 +27,7 @@ class h83002_device : public h8h_device { public: - h83002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto tend0() { return tend0_cb.bind(); } auto tend1() { return tend1_cb.bind(); } diff --git a/src/devices/cpu/h8/h83003.cpp b/src/devices/cpu/h8/h83003.cpp index 39829d5de12..31e60831bce 100644 --- a/src/devices/cpu/h8/h83003.cpp +++ b/src/devices/cpu/h8/h83003.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(H83003, h83003_device, "h83003", "Hitachi H8/3003") -h83003_device::h83003_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83003_device::h83003_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8h_device(mconfig, H83003, tag, owner, clock, address_map_constructor(FUNC(h83003_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), diff --git a/src/devices/cpu/h8/h83003.h b/src/devices/cpu/h8/h83003.h index 6c4f7cfaced..b2fc17a7eb6 100644 --- a/src/devices/cpu/h8/h83003.h +++ b/src/devices/cpu/h8/h83003.h @@ -27,7 +27,7 @@ class h83003_device : public h8h_device { public: - h83003_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83003_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto tend0() { return tend0_cb.bind(); } auto tend1() { return tend1_cb.bind(); } diff --git a/src/devices/cpu/h8/h83006.cpp b/src/devices/cpu/h8/h83006.cpp index d19937e93dc..cb562bfbb87 100644 --- a/src/devices/cpu/h8/h83006.cpp +++ b/src/devices/cpu/h8/h83006.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(H83006, h83006_device, "h83006", "Hitachi H8/3006") DEFINE_DEVICE_TYPE(H83007, h83007_device, "h83007", "Hitachi H8/3007") -h83006_device::h83006_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start) : +h83006_device::h83006_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start) : h8h_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h83006_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), @@ -35,13 +35,13 @@ h83006_device::h83006_device(const machine_config &mconfig, device_type type, co { } -h83006_device::h83006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83006_device::h83006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83006_device(mconfig, H83006, tag, owner, clock, 0xff720) { } -h83007_device::h83007_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83007_device::h83007_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83006_device(mconfig, H83007, tag, owner, clock, 0xfef20) { } diff --git a/src/devices/cpu/h8/h83006.h b/src/devices/cpu/h8/h83006.h index 083b91ea664..65fdc9fe211 100644 --- a/src/devices/cpu/h8/h83006.h +++ b/src/devices/cpu/h8/h83006.h @@ -27,7 +27,7 @@ class h83006_device : public h8h_device { public: - h83006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_mode_a20() { mode_a20 = true; } void set_mode_a24() { mode_a20 = false; } @@ -36,7 +36,7 @@ public: void syscr_w(uint8_t data); protected: - h83006_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start); + h83006_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start); required_device<h8h_intc_device> intc; required_device<h8_adc_device> adc; @@ -79,7 +79,7 @@ protected: class h83007_device : public h83006_device { public: - h83007_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83007_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(H83006, h83006_device) diff --git a/src/devices/cpu/h8/h83008.cpp b/src/devices/cpu/h8/h83008.cpp index 3db7c5a71aa..2f515c22192 100644 --- a/src/devices/cpu/h8/h83008.cpp +++ b/src/devices/cpu/h8/h83008.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(H83008, h83008_device, "h83008", "Hitachi H8/3008") -h83008_device::h83008_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83008_device::h83008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8h_device(mconfig, H83008, tag, owner, clock, address_map_constructor(FUNC(h83008_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), diff --git a/src/devices/cpu/h8/h83008.h b/src/devices/cpu/h8/h83008.h index bb65adfcc9d..62858dfd537 100644 --- a/src/devices/cpu/h8/h83008.h +++ b/src/devices/cpu/h8/h83008.h @@ -27,7 +27,7 @@ class h83008_device : public h8h_device { public: - h83008_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_mode_a20() { mode_a20 = true; } void set_mode_a24() { mode_a20 = false; } diff --git a/src/devices/cpu/h8/h83032.cpp b/src/devices/cpu/h8/h83032.cpp index f1abc18b912..613606440b7 100644 --- a/src/devices/cpu/h8/h83032.cpp +++ b/src/devices/cpu/h8/h83032.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(H83032, h83032_device, "h83032", "Hitachi H8/3032") DEFINE_DEVICE_TYPE(H83031, h83031_device, "h83031", "Hitachi H8/3031") DEFINE_DEVICE_TYPE(H83030, h83030_device, "h83030", "Hitachi H8/3030") -h83032_device::h83032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start) : +h83032_device::h83032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start) : h8h_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h83032_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), @@ -36,17 +36,17 @@ h83032_device::h83032_device(const machine_config &mconfig, device_type type, co mode_a20 = true; } -h83032_device::h83032_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83032_device::h83032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83032_device(mconfig, H83032, tag, owner, clock, 0xf710) { } -h83031_device::h83031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83031_device::h83031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83032_device(mconfig, H83031, tag, owner, clock, 0xfb10) { } -h83030_device::h83030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83030_device::h83030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83032_device(mconfig, H83030, tag, owner, clock, 0xfd10) { } diff --git a/src/devices/cpu/h8/h83032.h b/src/devices/cpu/h8/h83032.h index fd2d99593da..58d0a2170b1 100644 --- a/src/devices/cpu/h8/h83032.h +++ b/src/devices/cpu/h8/h83032.h @@ -29,13 +29,13 @@ class h83032_device : public h8h_device { public: - h83032_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t syscr_r(); void syscr_w(uint8_t data); protected: - h83032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start); + h83032_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start); required_device<h8h_intc_device> intc; required_device<h8_adc_device> adc; @@ -77,12 +77,12 @@ protected: class h83031_device : public h83032_device { public: - h83031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h83030_device : public h83032_device { public: - h83030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(H83032, h83032_device) diff --git a/src/devices/cpu/h8/h83042.cpp b/src/devices/cpu/h8/h83042.cpp index 2b0631d201e..a0896f68ad5 100644 --- a/src/devices/cpu/h8/h83042.cpp +++ b/src/devices/cpu/h8/h83042.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(H83040, h83040_device, "h83040", "Hitachi H8/3040") DEFINE_DEVICE_TYPE(H83041, h83041_device, "h83041", "Hitachi H8/3041") DEFINE_DEVICE_TYPE(H83042, h83042_device, "h83042", "Hitachi H8/3042") -h83042_device::h83042_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +h83042_device::h83042_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : h8h_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h83042_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), @@ -36,17 +36,17 @@ h83042_device::h83042_device(const machine_config &mconfig, device_type type, co mode_a20 = true; } -h83040_device::h83040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83040_device::h83040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83042_device(mconfig, H83040, tag, owner, clock) { } -h83041_device::h83041_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83041_device::h83041_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83042_device(mconfig, H83041, tag, owner, clock) { } -h83042_device::h83042_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83042_device::h83042_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83042_device(mconfig, H83042, tag, owner, clock) { } diff --git a/src/devices/cpu/h8/h83042.h b/src/devices/cpu/h8/h83042.h index 8caa5a4e690..5037d05e165 100644 --- a/src/devices/cpu/h8/h83042.h +++ b/src/devices/cpu/h8/h83042.h @@ -32,13 +32,13 @@ class h83042_device : public h8h_device { public: - h83042_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83042_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t syscr_r(); void syscr_w(uint8_t data); protected: - h83042_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + h83042_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); required_device<h8h_intc_device> intc; required_device<h8_adc_device> adc; @@ -80,12 +80,12 @@ protected: class h83040_device : public h83042_device { public: - h83040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h83041_device : public h83042_device { public: - h83041_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83041_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(H83040, h83040_device) diff --git a/src/devices/cpu/h8/h83048.cpp b/src/devices/cpu/h8/h83048.cpp index 2358914e6cf..3e4372bb221 100644 --- a/src/devices/cpu/h8/h83048.cpp +++ b/src/devices/cpu/h8/h83048.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(H83045, h83045_device, "h83045", "Hitachi H8/3045") DEFINE_DEVICE_TYPE(H83047, h83047_device, "h83047", "Hitachi H8/3047") DEFINE_DEVICE_TYPE(H83048, h83048_device, "h83048", "Hitachi H8/3048") -h83048_device::h83048_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start) : +h83048_device::h83048_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start) : h8h_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h83048_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), @@ -37,22 +37,22 @@ h83048_device::h83048_device(const machine_config &mconfig, device_type type, co { } -h83048_device::h83048_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83048_device::h83048_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83048_device(mconfig, H83048, tag, owner, clock, 0xef10) { } -h83044_device::h83044_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83044_device::h83044_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83048_device(mconfig, H83044, tag, owner, clock, 0xf710) { } -h83045_device::h83045_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83045_device::h83045_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83048_device(mconfig, H83045, tag, owner, clock, 0xf710) { } -h83047_device::h83047_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83047_device::h83047_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83048_device(mconfig, H83047, tag, owner, clock, 0xef10) { } diff --git a/src/devices/cpu/h8/h83048.h b/src/devices/cpu/h8/h83048.h index d5afb5e67c8..3df24384c6e 100644 --- a/src/devices/cpu/h8/h83048.h +++ b/src/devices/cpu/h8/h83048.h @@ -32,7 +32,7 @@ class h83048_device : public h8h_device { public: - h83048_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83048_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_mode_a20() { mode_a20 = true; } void set_mode_a24() { mode_a20 = false; } @@ -41,7 +41,7 @@ public: void syscr_w(uint8_t data); protected: - h83048_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start); + h83048_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start); required_device<h8h_intc_device> intc; required_device<h8_adc_device> adc; @@ -84,17 +84,17 @@ protected: class h83044_device : public h83048_device { public: - h83044_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83044_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h83045_device : public h83048_device { public: - h83045_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83045_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h83047_device : public h83048_device { public: - h83047_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83047_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(H83044, h83044_device) diff --git a/src/devices/cpu/h8/h83337.cpp b/src/devices/cpu/h8/h83337.cpp index 7f9e835513c..3ed10f5ae97 100644 --- a/src/devices/cpu/h8/h83337.cpp +++ b/src/devices/cpu/h8/h83337.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(H83336, h83336_device, "h83336", "Hitachi H8/3336") DEFINE_DEVICE_TYPE(H83337, h83337_device, "h83337", "Hitachi H8/3337") -h83337_device::h83337_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start) : +h83337_device::h83337_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start) : h8_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h83337_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), @@ -33,17 +33,17 @@ h83337_device::h83337_device(const machine_config &mconfig, device_type type, co { } -h83337_device::h83337_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83337_device::h83337_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83337_device(mconfig, H83337, tag, owner, clock, 0xf780) { } -h83334_device::h83334_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83334_device::h83334_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83337_device(mconfig, H83334, tag, owner, clock, 0xfb80) { } -h83336_device::h83336_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h83336_device::h83336_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h83337_device(mconfig, H83336, tag, owner, clock, 0xf780) { } diff --git a/src/devices/cpu/h8/h83337.h b/src/devices/cpu/h8/h83337.h index cc0d9735a34..9ed5958b47a 100644 --- a/src/devices/cpu/h8/h83337.h +++ b/src/devices/cpu/h8/h83337.h @@ -34,7 +34,7 @@ class h83337_device : public h8_device { public: - h83337_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83337_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t wscr_r(); void wscr_w(uint8_t data); @@ -46,7 +46,7 @@ public: void mdcr_w(uint8_t data); protected: - h83337_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start); + h83337_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start); required_device<h8_intc_device> intc; required_device<h8_adc_device> adc; @@ -84,12 +84,12 @@ protected: class h83334_device : public h83337_device { public: - h83334_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83334_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h83336_device : public h83337_device { public: - h83336_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h83336_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(H83334, h83334_device) diff --git a/src/devices/cpu/h8/h8_adc.cpp b/src/devices/cpu/h8/h8_adc.cpp index 3235ac8c6c8..73176384a31 100644 --- a/src/devices/cpu/h8/h8_adc.cpp +++ b/src/devices/cpu/h8/h8_adc.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(H8_ADC_2320, h8_adc_2320_device, "h8_adc_2320", "H8/2320 ADC" DEFINE_DEVICE_TYPE(H8_ADC_2357, h8_adc_2357_device, "h8_adc_2357", "H8/2357 ADC") DEFINE_DEVICE_TYPE(H8_ADC_2655, h8_adc_2655_device, "h8_adc_2655", "H8/2655 ADC") -h8_adc_device::h8_adc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +h8_adc_device::h8_adc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), cpu(*this, DEVICE_SELF_OWNER), intc(nullptr), io(nullptr), intc_tag(nullptr), intc_vector(0), adcsr(0), adcr(0), register_mask(0), trigger(0), start_mode(0), start_channel(0), @@ -272,7 +272,7 @@ int h8_adc_device::get_channel_index(int count) } -h8_adc_3337_device::h8_adc_3337_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_adc_3337_device::h8_adc_3337_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_adc_device(mconfig, H8_ADC_3337, tag, owner, clock) { register_mask = 3; @@ -303,7 +303,7 @@ void h8_adc_3337_device::mode_update() } -h8_adc_3006_device::h8_adc_3006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_adc_3006_device::h8_adc_3006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_adc_device(mconfig, H8_ADC_3006, tag, owner, clock) { register_mask = 3; @@ -334,7 +334,7 @@ void h8_adc_3006_device::mode_update() } -h8_adc_2245_device::h8_adc_2245_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_adc_2245_device::h8_adc_2245_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_adc_device(mconfig, H8_ADC_2245, tag, owner, clock) { register_mask = 3; @@ -365,7 +365,7 @@ void h8_adc_2245_device::mode_update() } -h8_adc_2320_device::h8_adc_2320_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_adc_2320_device::h8_adc_2320_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_adc_device(mconfig, H8_ADC_2320, tag, owner, clock) { register_mask = 3; @@ -402,7 +402,7 @@ void h8_adc_2320_device::mode_update() } -h8_adc_2357_device::h8_adc_2357_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_adc_2357_device::h8_adc_2357_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_adc_device(mconfig, H8_ADC_2357, tag, owner, clock) { register_mask = 3; @@ -433,7 +433,7 @@ void h8_adc_2357_device::mode_update() } -h8_adc_2655_device::h8_adc_2655_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_adc_2655_device::h8_adc_2655_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_adc_device(mconfig, H8_ADC_2655, tag, owner, clock) { suspend_on_interrupt = true; diff --git a/src/devices/cpu/h8/h8_adc.h b/src/devices/cpu/h8/h8_adc.h index e54d3b747d9..8b4008eb4eb 100644 --- a/src/devices/cpu/h8/h8_adc.h +++ b/src/devices/cpu/h8/h8_adc.h @@ -33,7 +33,7 @@ public: uint64_t internal_update(uint64_t current_time); protected: - h8_adc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + h8_adc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); required_device<h8_device> cpu; h8_intc_device *intc; @@ -93,9 +93,9 @@ protected: class h8_adc_3337_device : public h8_adc_device { public: - h8_adc_3337_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_adc_3337_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_adc_3337_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc_tag, int vect) - : h8_adc_3337_device(mconfig, tag, owner, 0) + : h8_adc_3337_device(mconfig, tag, owner) { set_info(intc_tag, vect); } @@ -107,9 +107,9 @@ protected: class h8_adc_3006_device : public h8_adc_device { public: - h8_adc_3006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_adc_3006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_adc_3006_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc_tag, int vect) - : h8_adc_3006_device(mconfig, tag, owner, 0) + : h8_adc_3006_device(mconfig, tag, owner) { set_info(intc_tag, vect); } @@ -121,9 +121,9 @@ protected: class h8_adc_2245_device : public h8_adc_device { public: - h8_adc_2245_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_adc_2245_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_adc_2245_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc_tag, int vect) - : h8_adc_2245_device(mconfig, tag, owner, 0) + : h8_adc_2245_device(mconfig, tag, owner) { set_info(intc_tag, vect); } @@ -135,9 +135,9 @@ protected: class h8_adc_2320_device : public h8_adc_device { public: - h8_adc_2320_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_adc_2320_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_adc_2320_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc_tag, int vect) - : h8_adc_2320_device(mconfig, tag, owner, 0) + : h8_adc_2320_device(mconfig, tag, owner) { set_info(intc_tag, vect); } @@ -149,9 +149,9 @@ protected: class h8_adc_2357_device : public h8_adc_device { public: - h8_adc_2357_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_adc_2357_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_adc_2357_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc_tag, int vect) - : h8_adc_2357_device(mconfig, tag, owner, 0) + : h8_adc_2357_device(mconfig, tag, owner) { set_info(intc_tag, vect); } @@ -163,9 +163,9 @@ protected: class h8_adc_2655_device : public h8_adc_device { public: - h8_adc_2655_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_adc_2655_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_adc_2655_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc_tag, int vect) - : h8_adc_2655_device(mconfig, tag, owner, 0) + : h8_adc_2655_device(mconfig, tag, owner) { set_info(intc_tag, vect); } diff --git a/src/devices/cpu/h8/h8_dma.cpp b/src/devices/cpu/h8/h8_dma.cpp index d70cced09f3..ba014974ec3 100644 --- a/src/devices/cpu/h8/h8_dma.cpp +++ b/src/devices/cpu/h8/h8_dma.cpp @@ -4,7 +4,7 @@ DEFINE_DEVICE_TYPE(H8_DMA, h8_dma_device, "h8_dma", "H8 DMA controller") DEFINE_DEVICE_TYPE(H8_DMA_CHANNEL, h8_dma_channel_device, "h8_dma_channel", "H8 DMA channel") -h8_dma_device::h8_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_dma_device::h8_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, H8_DMA, tag, owner, clock), dmach0(*this, "0"), dmach1(*this, "1") @@ -118,7 +118,7 @@ void h8_dma_device::dmabcr_w(offs_t offset, uint16_t data, uint16_t mem_mask) -h8_dma_channel_device::h8_dma_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_dma_channel_device::h8_dma_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, H8_DMA_CHANNEL, tag, owner, clock), dmac(*this, "^"), cpu(*this, "^^") diff --git a/src/devices/cpu/h8/h8_dma.h b/src/devices/cpu/h8/h8_dma.h index 4a4eeda837b..7448300f4cd 100644 --- a/src/devices/cpu/h8/h8_dma.h +++ b/src/devices/cpu/h8/h8_dma.h @@ -43,7 +43,7 @@ enum { class h8_dma_device : public device_t { public: - h8_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + h8_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint8_t dmawer_r(); void dmawer_w(uint8_t data); @@ -88,7 +88,7 @@ public: MODE16_MEM_DACK }; - h8_dma_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_dma_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_dma_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc, int irq_base, int v0, int v1, int v2, int v3, int v4, int v5, int v6, int v7, int v8, int v9 = h8_dma_channel_device::NONE, @@ -98,7 +98,7 @@ public: int vd = h8_dma_channel_device::NONE, int ve = h8_dma_channel_device::NONE, int vf = h8_dma_channel_device::NONE) - : h8_dma_channel_device(mconfig, tag, owner, 0) + : h8_dma_channel_device(mconfig, tag, owner) { set_info(intc, irq_base, v0, v1, v2, v3, v4, v5, v6, v7, v8, v9, va, vb, vc, vd, ve, vf); } diff --git a/src/devices/cpu/h8/h8_dtc.cpp b/src/devices/cpu/h8/h8_dtc.cpp index a2668456414..08aab92bfb7 100644 --- a/src/devices/cpu/h8/h8_dtc.cpp +++ b/src/devices/cpu/h8/h8_dtc.cpp @@ -24,7 +24,7 @@ const int h8_dtc_device::vector_to_enable[92] = { -1, 40, 41, -1 // ERI2, RXI2, TXI2, TEI2 }; -h8_dtc_device::h8_dtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_dtc_device::h8_dtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, H8_DTC, tag, owner, clock), cpu(*this, DEVICE_SELF_OWNER) { diff --git a/src/devices/cpu/h8/h8_dtc.h b/src/devices/cpu/h8/h8_dtc.h index 6b1a32b8a9b..22052b8a757 100644 --- a/src/devices/cpu/h8/h8_dtc.h +++ b/src/devices/cpu/h8/h8_dtc.h @@ -29,9 +29,9 @@ class h8_dtc_device : public device_t { public: enum { DTC_CHAINED = 1000 }; - h8_dtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_dtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_dtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc, int irq) - : h8_dtc_device(mconfig, tag, owner, 0) + : h8_dtc_device(mconfig, tag, owner) { set_info(intc, irq); } diff --git a/src/devices/cpu/h8/h8_intc.cpp b/src/devices/cpu/h8/h8_intc.cpp index f2a7b192164..465b346e604 100644 --- a/src/devices/cpu/h8/h8_intc.cpp +++ b/src/devices/cpu/h8/h8_intc.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(H8H_INTC, h8h_intc_device, "h8h_intc", "H8H interrupt c DEFINE_DEVICE_TYPE(H8S_INTC, h8s_intc_device, "h8s_intc", "H8S interrupt controller") DEFINE_DEVICE_TYPE(GT913_INTC, gt913_intc_device, "gt913_intc", "Casio GT913F interrupt controller") -h8_intc_device::h8_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_intc_device::h8_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_intc_device(mconfig, H8_INTC, tag, owner, clock) { irq_vector_base = 4; @@ -16,7 +16,7 @@ h8_intc_device::h8_intc_device(const machine_config &mconfig, const char *tag, d irq_vector_nmi = 3; } -h8_intc_device::h8_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +h8_intc_device::h8_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), irq_vector_base(0), irq_vector_count(0), irq_vector_nmi(0), cpu(*this, DEVICE_SELF_OWNER), nmi_input(false), irq_input(0), ier(0), isr(0), iscr(0), icr_filter(0), ipr_filter(0) { @@ -199,7 +199,7 @@ void h8_intc_device::get_priority(int vect, int &icr_pri, int &ipr_pri) const } -gt913_intc_device::gt913_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gt913_intc_device::gt913_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gt913_intc_device(mconfig, GT913_INTC, tag, owner, clock) { irq_vector_base = 4; @@ -207,7 +207,7 @@ gt913_intc_device::gt913_intc_device(const machine_config &mconfig, const char * irq_vector_nmi = 3; } -gt913_intc_device::gt913_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +gt913_intc_device::gt913_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : h8_intc_device(mconfig, type, tag, owner, clock) { } @@ -226,7 +226,7 @@ void gt913_intc_device::clear_interrupt(int vector) } -h8h_intc_device::h8h_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8h_intc_device::h8h_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8h_intc_device(mconfig, H8H_INTC, tag, owner, clock) { irq_vector_base = 12; @@ -234,7 +234,7 @@ h8h_intc_device::h8h_intc_device(const machine_config &mconfig, const char *tag, irq_vector_nmi = 7; } -h8h_intc_device::h8h_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +h8h_intc_device::h8h_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : h8_intc_device(mconfig, type, tag, owner, clock) { } @@ -353,7 +353,7 @@ void h8h_intc_device::get_priority(int vect, int &icr_pri, int &ipr_pri) const icr_pri = (icr >> (slot ^ 7)) & 1; } -h8s_intc_device::h8s_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s_intc_device::h8s_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8h_intc_device(mconfig, H8S_INTC, tag, owner, clock) { irq_vector_base = 16; diff --git a/src/devices/cpu/h8/h8_intc.h b/src/devices/cpu/h8/h8_intc.h index 43569dc3b9b..23ec3244cfa 100644 --- a/src/devices/cpu/h8/h8_intc.h +++ b/src/devices/cpu/h8/h8_intc.h @@ -19,7 +19,7 @@ class h8_intc_device : public device_t { public: - h8_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + h8_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); int interrupt_taken(int vector); void internal_interrupt(int vector); @@ -50,7 +50,7 @@ protected: uint16_t iscr; int icr_filter, ipr_filter; - h8_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + h8_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -63,18 +63,18 @@ protected: class gt913_intc_device : public h8_intc_device { public: - gt913_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + gt913_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void clear_interrupt(int vector); protected: - gt913_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gt913_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_reset() override; }; class h8h_intc_device : public h8_intc_device { public: - h8h_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + h8h_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint8_t isr_r(); void isr_w(uint8_t data); @@ -92,7 +92,7 @@ protected: uint32_t icr; - h8h_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + h8h_intc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -103,7 +103,7 @@ protected: class h8s_intc_device : public h8h_intc_device { public: - h8s_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + h8s_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint8_t ipr_r(offs_t offset); void ipr_w(offs_t offset, uint8_t data); diff --git a/src/devices/cpu/h8/h8_port.cpp b/src/devices/cpu/h8/h8_port.cpp index e366e0d49a5..86390382274 100644 --- a/src/devices/cpu/h8/h8_port.cpp +++ b/src/devices/cpu/h8/h8_port.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(H8_PORT, h8_port_device, "h8_digital_port", "H8 digital port") -h8_port_device::h8_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_port_device::h8_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, H8_PORT, tag, owner, clock), cpu(*this, DEVICE_SELF_OWNER), io(nullptr), address(0), default_ddr(0), ddr(0), pcr(0), odr(0), mask(0), dr(0), last_output(0) { diff --git a/src/devices/cpu/h8/h8_port.h b/src/devices/cpu/h8/h8_port.h index 6c60b0c7621..45e6d387599 100644 --- a/src/devices/cpu/h8/h8_port.h +++ b/src/devices/cpu/h8/h8_port.h @@ -18,9 +18,9 @@ class h8_port_device : public device_t { public: - h8_port_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_port_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_port_device(const machine_config &mconfig, const char *tag, device_t *owner, int address, uint8_t default_ddr, uint8_t mask) - : h8_port_device(mconfig, tag, owner, 0) + : h8_port_device(mconfig, tag, owner) { set_info(address, default_ddr, mask); } diff --git a/src/devices/cpu/h8/h8_sci.cpp b/src/devices/cpu/h8/h8_sci.cpp index 6bc650af5c6..c7ec19d382d 100644 --- a/src/devices/cpu/h8/h8_sci.cpp +++ b/src/devices/cpu/h8/h8_sci.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(H8_SCI, h8_sci_device, "h8_sci", "H8 Serial Communications In const char *const h8_sci_device::state_names[] = { "idle", "start", "bit", "parity", "stop", "last-tick" }; -h8_sci_device::h8_sci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_sci_device::h8_sci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, H8_SCI, tag, owner, clock), cpu(*this, DEVICE_SELF_OWNER), tx_cb(*this), diff --git a/src/devices/cpu/h8/h8_sci.h b/src/devices/cpu/h8/h8_sci.h index 8c07ffe5ec2..1c9c04b38fe 100644 --- a/src/devices/cpu/h8/h8_sci.h +++ b/src/devices/cpu/h8/h8_sci.h @@ -19,9 +19,9 @@ class h8_sci_device : public device_t { public: - h8_sci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_sci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_sci_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc, int eri, int rxi, int txi, int tei) - : h8_sci_device(mconfig, tag, owner, 0) + : h8_sci_device(mconfig, tag, owner) { set_info(intc, eri, rxi, txi, tei); } diff --git a/src/devices/cpu/h8/h8_timer16.cpp b/src/devices/cpu/h8/h8_timer16.cpp index f74acb4816f..40d0d015db4 100644 --- a/src/devices/cpu/h8/h8_timer16.cpp +++ b/src/devices/cpu/h8/h8_timer16.cpp @@ -13,13 +13,13 @@ DEFINE_DEVICE_TYPE(H8_TIMER16_CHANNEL, h8_timer16_channel_device, "h8_timer16_ DEFINE_DEVICE_TYPE(H8H_TIMER16_CHANNEL, h8h_timer16_channel_device, "h8h_timer16_channel", "H8H 16-bit timer channel") DEFINE_DEVICE_TYPE(H8S_TIMER16_CHANNEL, h8s_timer16_channel_device, "h8s_timer16_channel", "H8S 16-bit timer channel") -h8_timer16_channel_device::h8_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_timer16_channel_device::h8_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_timer16_channel_device(mconfig, H8_TIMER16_CHANNEL, tag, owner, clock) { chain_tag = nullptr; } -h8_timer16_channel_device::h8_timer16_channel_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +h8_timer16_channel_device::h8_timer16_channel_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), cpu(*this, "^^"), chained_timer(nullptr), intc(nullptr), intc_tag(nullptr), tier_mask(0), tgr_count(0), tbr_count(0), tgr_clearing(0), tcr(0), tier(0), ier(0), isr(0), clock_type(0), clock_divider(0), tcnt(0), last_clock_update(0), event_time(0), phase(0), counter_cycle(0), counter_incrementing(false), channel_active(false) @@ -313,7 +313,7 @@ void h8_timer16_channel_device::recalc_event(uint64_t cur_time) cpu->internal_update(); } -h8_timer16_device::h8_timer16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_timer16_device::h8_timer16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, H8_TIMER16, tag, owner, clock), cpu(*this, DEVICE_SELF_OWNER) { @@ -519,7 +519,7 @@ uint8_t h8_timer16_channel_device::tisr_r(int offset) const return 0x00; } -h8h_timer16_channel_device::h8h_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8h_timer16_channel_device::h8h_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_timer16_channel_device(mconfig, H8H_TIMER16_CHANNEL, tag, owner, clock) { } @@ -617,7 +617,7 @@ void h8h_timer16_channel_device::tcr_update() } } -h8s_timer16_channel_device::h8s_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s_timer16_channel_device::h8s_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_timer16_channel_device(mconfig, H8S_TIMER16_CHANNEL, tag, owner, clock) { } diff --git a/src/devices/cpu/h8/h8_timer16.h b/src/devices/cpu/h8/h8_timer16.h index 6543b9ccb7c..a22e0a3caac 100644 --- a/src/devices/cpu/h8/h8_timer16.h +++ b/src/devices/cpu/h8/h8_timer16.h @@ -56,9 +56,9 @@ public: }; - h8_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, int tgr_count, int tbr_count, const char *intc, int irq_base) - : h8_timer16_channel_device(mconfig, tag, owner, 0) + : h8_timer16_channel_device(mconfig, tag, owner) { set_info(tgr_count, tbr_count, intc, irq_base); } @@ -106,7 +106,7 @@ protected: bool counter_incrementing; bool channel_active; - h8_timer16_channel_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + h8_timer16_channel_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -121,9 +121,9 @@ protected: class h8h_timer16_channel_device : public h8_timer16_channel_device { public: - h8h_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8h_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8h_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, int tgr_count, int tbr_count, const char *intc, int irq_base) - : h8h_timer16_channel_device(mconfig, tag, owner, 0) + : h8h_timer16_channel_device(mconfig, tag, owner) { set_info(tgr_count, tbr_count, intc, irq_base); } @@ -140,10 +140,10 @@ protected: class h8s_timer16_channel_device : public h8_timer16_channel_device { public: - h8s_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8s_timer16_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, int tgr_count, int _tier_mask, const char *intc, int irq_base, int t0, int t1, int t2, int t3, int t4, int t5, int t6, int t7) - : h8s_timer16_channel_device(mconfig, tag, owner, 0) + : h8s_timer16_channel_device(mconfig, tag, owner) { set_info(tgr_count, _tier_mask, intc, irq_base, t0, t1, t2, t3, t4, t5, t6, t7); } @@ -164,9 +164,9 @@ protected: class h8_timer16_device : public device_t { public: - h8_timer16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_timer16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_timer16_device(const machine_config &mconfig, const char *tag, device_t *owner, int timer_count, uint8_t default_tstr) - : h8_timer16_device(mconfig, tag, owner, 0) + : h8_timer16_device(mconfig, tag, owner) { set_info(timer_count, default_tstr); } diff --git a/src/devices/cpu/h8/h8_timer8.cpp b/src/devices/cpu/h8/h8_timer8.cpp index 352b4a7f7d9..07550cd7954 100644 --- a/src/devices/cpu/h8/h8_timer8.cpp +++ b/src/devices/cpu/h8/h8_timer8.cpp @@ -12,12 +12,12 @@ const int V = 1; DEFINE_DEVICE_TYPE(H8_TIMER8_CHANNEL, h8_timer8_channel_device, "h8_timer8_channel", "H8 8-bit timer channel") DEFINE_DEVICE_TYPE(H8H_TIMER8_CHANNEL, h8h_timer8_channel_device, "h8h_timer8_channel", "H8H 8-bit timer channel") -h8_timer8_channel_device::h8_timer8_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_timer8_channel_device::h8_timer8_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_timer8_channel_device(mconfig, H8_TIMER8_CHANNEL, tag, owner, clock) { } -h8_timer8_channel_device::h8_timer8_channel_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +h8_timer8_channel_device::h8_timer8_channel_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), cpu(*this, "^"), chained_timer(nullptr), intc(nullptr), chain_tag(nullptr), intc_tag(nullptr), irq_ca(0), irq_cb(0), irq_v(0), chain_type(0), tcr(0), tcsr(0), tcnt(0), extra_clock_bit(false), has_adte(false), has_ice(false), clock_type(0), clock_divider(0), clear_type(0), counter_cycle(0), last_clock_update(0), event_time(0) @@ -351,7 +351,7 @@ void h8_timer8_channel_device::timer_tick() } } -h8h_timer8_channel_device::h8h_timer8_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8h_timer8_channel_device::h8h_timer8_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8_timer8_channel_device(mconfig, H8H_TIMER8_CHANNEL, tag, owner, clock) { } diff --git a/src/devices/cpu/h8/h8_timer8.h b/src/devices/cpu/h8/h8_timer8.h index 0ba06d933ba..fa4a6c1ac33 100644 --- a/src/devices/cpu/h8/h8_timer8.h +++ b/src/devices/cpu/h8/h8_timer8.h @@ -29,10 +29,10 @@ public: DIV }; - h8_timer8_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_timer8_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_timer8_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc, int irq_ca, int irq_cb, int irq_v, int div1, int div2, int div3, int div4, int div5, int div6) - : h8_timer8_channel_device(mconfig, tag, owner, 0) + : h8_timer8_channel_device(mconfig, tag, owner) { set_info(intc, irq_ca, irq_cb, irq_v, div1, div2, div3, div4, div5, div6); } @@ -88,7 +88,7 @@ protected: int clock_type, clock_divider, clear_type, counter_cycle; uint64_t last_clock_update, event_time; - h8_timer8_channel_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + h8_timer8_channel_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -102,10 +102,10 @@ protected: class h8h_timer8_channel_device : public h8_timer8_channel_device { public: - h8h_timer8_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8h_timer8_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8h_timer8_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc, int irq_ca, int irq_cb, int irq_v, const char *chain_tag, int chain_type, bool has_adte, bool has_ice) - : h8h_timer8_channel_device(mconfig, tag, owner, 0) + : h8h_timer8_channel_device(mconfig, tag, owner) { set_info(intc, irq_ca, irq_cb, irq_v, chain_tag, chain_type, has_adte, has_ice); } diff --git a/src/devices/cpu/h8/h8_watchdog.cpp b/src/devices/cpu/h8/h8_watchdog.cpp index d3386b465fe..8770eddf4e0 100644 --- a/src/devices/cpu/h8/h8_watchdog.cpp +++ b/src/devices/cpu/h8/h8_watchdog.cpp @@ -6,7 +6,7 @@ DEFINE_DEVICE_TYPE(H8_WATCHDOG, h8_watchdog_device, "h8_watchdog", "H8 watchdog" const int h8_watchdog_device::div_bh[8] = { 1, 6, 7, 9, 11, 13, 15, 17 }; const int h8_watchdog_device::div_s [8] = { 1, 5, 6, 7, 8, 9, 11, 12 }; -h8_watchdog_device::h8_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8_watchdog_device::h8_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, H8_WATCHDOG, tag, owner, clock), cpu(*this, DEVICE_SELF_OWNER) { diff --git a/src/devices/cpu/h8/h8_watchdog.h b/src/devices/cpu/h8/h8_watchdog.h index 1cb63025141..06d5f1b7bdf 100644 --- a/src/devices/cpu/h8/h8_watchdog.h +++ b/src/devices/cpu/h8/h8_watchdog.h @@ -49,9 +49,9 @@ class h8_watchdog_device : public device_t { public: enum { B, H, S }; - h8_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); h8_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc, int irq, int type) - : h8_watchdog_device(mconfig, tag, owner, 0) + : h8_watchdog_device(mconfig, tag, owner) { set_info(intc, irq, type); } diff --git a/src/devices/cpu/h8/h8h.cpp b/src/devices/cpu/h8/h8h.cpp index 21f40f77600..829c1a01244 100644 --- a/src/devices/cpu/h8/h8h.cpp +++ b/src/devices/cpu/h8/h8h.cpp @@ -4,7 +4,7 @@ #include "h8h.h" #include "h8hd.h" -h8h_device::h8h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor map_delegate) : +h8h_device::h8h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map_delegate) : h8_device(mconfig, type, tag, owner, clock, map_delegate) { supports_advanced = true; diff --git a/src/devices/cpu/h8/h8h.h b/src/devices/cpu/h8/h8h.h index 1b0c9b4b3ce..ad9a94e4400 100644 --- a/src/devices/cpu/h8/h8h.h +++ b/src/devices/cpu/h8/h8h.h @@ -20,7 +20,7 @@ class h8h_device : public h8_device { protected: - h8h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor map_delegate); + h8h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map_delegate); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/h8/h8s2000.cpp b/src/devices/cpu/h8/h8s2000.cpp index 04da92cdee3..41279505e69 100644 --- a/src/devices/cpu/h8/h8s2000.cpp +++ b/src/devices/cpu/h8/h8s2000.cpp @@ -4,7 +4,7 @@ #include "h8s2000.h" #include "h8s2000d.h" -h8s2000_device::h8s2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor map_delegate) : +h8s2000_device::h8s2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map_delegate) : h8h_device(mconfig, type, tag, owner, clock, map_delegate) { has_exr = true; diff --git a/src/devices/cpu/h8/h8s2000.h b/src/devices/cpu/h8/h8s2000.h index 8f7721928c3..a2f79b40fb4 100644 --- a/src/devices/cpu/h8/h8s2000.h +++ b/src/devices/cpu/h8/h8s2000.h @@ -22,7 +22,7 @@ class h8s2000_device : public h8h_device { protected: - h8s2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor map_delegate); + h8s2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map_delegate); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/h8/h8s2245.cpp b/src/devices/cpu/h8/h8s2245.cpp index b5101017f07..2ce4124e6cc 100644 --- a/src/devices/cpu/h8/h8s2245.cpp +++ b/src/devices/cpu/h8/h8s2245.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(H8S2245, h8s2245_device, "h8s2245", "Hitachi H8S/2245") DEFINE_DEVICE_TYPE(H8S2246, h8s2246_device, "h8s2246", "Hitachi H8S/2246") -h8s2245_device::h8s2245_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start) : +h8s2245_device::h8s2245_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start) : h8s2000_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h8s2245_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), @@ -41,22 +41,22 @@ h8s2245_device::h8s2245_device(const machine_config &mconfig, device_type type, { } -h8s2245_device::h8s2245_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2245_device::h8s2245_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2245_device(mconfig, H8S2245, tag, owner, clock, 0xffec00) { } -h8s2241_device::h8s2241_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2241_device::h8s2241_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2245_device(mconfig, H8S2241, tag, owner, clock, 0xffec00) { } -h8s2242_device::h8s2242_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2242_device::h8s2242_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2245_device(mconfig, H8S2242, tag, owner, clock, 0xffdc00) { } -h8s2246_device::h8s2246_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2246_device::h8s2246_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2245_device(mconfig, H8S2246, tag, owner, clock, 0xffdc00) { } diff --git a/src/devices/cpu/h8/h8s2245.h b/src/devices/cpu/h8/h8s2245.h index 4fca522bbc5..342d9e8e854 100644 --- a/src/devices/cpu/h8/h8s2245.h +++ b/src/devices/cpu/h8/h8s2245.h @@ -35,7 +35,7 @@ class h8s2245_device : public h8s2000_device { public: - h8s2245_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2245_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t syscr_r(); void syscr_w(uint8_t data); @@ -73,7 +73,7 @@ protected: uint16_t mstpcr; uint8_t syscr; - h8s2245_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start); + h8s2245_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start); virtual bool exr_in_stack() const override; virtual void update_irq_filter() override; @@ -91,17 +91,17 @@ protected: class h8s2241_device : public h8s2245_device { public: - h8s2241_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2241_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2242_device : public h8s2245_device { public: - h8s2242_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2242_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2246_device : public h8s2245_device { public: - h8s2246_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2246_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(H8S2241, h8s2241_device) diff --git a/src/devices/cpu/h8/h8s2320.cpp b/src/devices/cpu/h8/h8s2320.cpp index 14cd0e0a396..8b359fa74f0 100644 --- a/src/devices/cpu/h8/h8s2320.cpp +++ b/src/devices/cpu/h8/h8s2320.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(H8S2328, h8s2328_device, "h8s2328", "Hitachi H8S/2328") DEFINE_DEVICE_TYPE(H8S2329, h8s2329_device, "h8s2329", "Hitachi H8S/2329") -h8s2320_device::h8s2320_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start) : +h8s2320_device::h8s2320_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start) : h8s2000_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h8s2320_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), @@ -53,47 +53,47 @@ h8s2320_device::h8s2320_device(const machine_config &mconfig, device_type type, { } -h8s2320_device::h8s2320_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2320_device::h8s2320_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2320_device(mconfig, H8S2320, tag, owner, clock, 0xffec00) { } -h8s2321_device::h8s2321_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2321_device::h8s2321_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2320_device(mconfig, H8S2321, tag, owner, clock, 0xffec00) { } -h8s2322_device::h8s2322_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2322_device::h8s2322_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2320_device(mconfig, H8S2322, tag, owner, clock, 0xffdc00) { } -h8s2323_device::h8s2323_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2323_device::h8s2323_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2320_device(mconfig, H8S2323, tag, owner, clock, 0xffdc00) { } -h8s2324_device::h8s2324_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2324_device::h8s2324_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2320_device(mconfig, H8S2324, tag, owner, clock, 0xff7c00) { } -h8s2326_device::h8s2326_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2326_device::h8s2326_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2320_device(mconfig, H8S2326, tag, owner, clock, 0xffdc00) { } -h8s2327_device::h8s2327_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2327_device::h8s2327_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2320_device(mconfig, H8S2327, tag, owner, clock, 0xffdc00) { } -h8s2328_device::h8s2328_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2328_device::h8s2328_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2320_device(mconfig, H8S2328, tag, owner, clock, 0xffdc00) { } -h8s2329_device::h8s2329_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2329_device::h8s2329_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2320_device(mconfig, H8S2329, tag, owner, clock, 0xff7c00) { } diff --git a/src/devices/cpu/h8/h8s2320.h b/src/devices/cpu/h8/h8s2320.h index 4ea272d283f..ef8da4a9303 100644 --- a/src/devices/cpu/h8/h8s2320.h +++ b/src/devices/cpu/h8/h8s2320.h @@ -41,7 +41,7 @@ class h8s2320_device : public h8s2000_device { public: - h8s2320_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2320_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t syscr_r(); void syscr_w(uint8_t data); @@ -83,7 +83,7 @@ protected: uint32_t ram_start; uint8_t syscr; - h8s2320_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start); + h8s2320_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start); virtual bool exr_in_stack() const override; virtual void update_irq_filter() override; @@ -102,42 +102,42 @@ protected: class h8s2321_device : public h8s2320_device { public: - h8s2321_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2321_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2322_device : public h8s2320_device { public: - h8s2322_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2322_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2323_device : public h8s2320_device { public: - h8s2323_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2323_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2324_device : public h8s2320_device { public: - h8s2324_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2324_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2326_device : public h8s2320_device { public: - h8s2326_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2326_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2327_device : public h8s2320_device { public: - h8s2327_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2327_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2328_device : public h8s2320_device { public: - h8s2328_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2328_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2329_device : public h8s2320_device { public: - h8s2329_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2329_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(H8S2320, h8s2320_device) diff --git a/src/devices/cpu/h8/h8s2357.cpp b/src/devices/cpu/h8/h8s2357.cpp index eda704291c5..2bef42912f6 100644 --- a/src/devices/cpu/h8/h8s2357.cpp +++ b/src/devices/cpu/h8/h8s2357.cpp @@ -10,7 +10,7 @@ DEFINE_DEVICE_TYPE(H8S2394, h8s2394_device, "h8s2394", "Hitachi H8S/2394") DEFINE_DEVICE_TYPE(H8S2392, h8s2392_device, "h8s2392", "Hitachi H8S/2392") DEFINE_DEVICE_TYPE(H8S2390, h8s2390_device, "h8s2390", "Hitachi H8S/2390") -h8s2357_device::h8s2357_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start) : +h8s2357_device::h8s2357_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start) : h8s2000_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h8s2357_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), @@ -45,32 +45,32 @@ h8s2357_device::h8s2357_device(const machine_config &mconfig, device_type type, { } -h8s2357_device::h8s2357_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2357_device::h8s2357_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2357_device(mconfig, H8S2357, tag, owner, clock, 0xffdc00) { } -h8s2352_device::h8s2352_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2352_device::h8s2352_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2357_device(mconfig, H8S2352, tag, owner, clock, 0xffdc00) { } -h8s2398_device::h8s2398_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2398_device::h8s2398_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2357_device(mconfig, H8S2398, tag, owner, clock, 0xffdc00) { } -h8s2394_device::h8s2394_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2394_device::h8s2394_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2357_device(mconfig, H8S2394, tag, owner, clock, 0xff7c00) { } -h8s2392_device::h8s2392_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2392_device::h8s2392_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2357_device(mconfig, H8S2392, tag, owner, clock, 0xffdc00) { } -h8s2390_device::h8s2390_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2390_device::h8s2390_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2357_device(mconfig, H8S2390, tag, owner, clock, 0xffec00) { } diff --git a/src/devices/cpu/h8/h8s2357.h b/src/devices/cpu/h8/h8s2357.h index 3f20c062d01..cfd7f3bb8e7 100644 --- a/src/devices/cpu/h8/h8s2357.h +++ b/src/devices/cpu/h8/h8s2357.h @@ -36,7 +36,7 @@ class h8s2357_device : public h8s2000_device { public: - h8s2357_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2357_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t syscr_r(); void syscr_w(uint8_t data); @@ -74,7 +74,7 @@ protected: uint32_t ram_start; unsigned char syscr; - h8s2357_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t start); + h8s2357_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t start); virtual bool exr_in_stack() const override; virtual void update_irq_filter() override; @@ -93,27 +93,27 @@ protected: class h8s2352_device : public h8s2357_device { public: - h8s2352_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2352_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2398_device : public h8s2357_device { public: - h8s2398_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2398_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2394_device : public h8s2357_device { public: - h8s2394_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2394_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2392_device : public h8s2357_device { public: - h8s2392_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2392_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8s2390_device : public h8s2357_device { public: - h8s2390_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2390_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(H8S2357, h8s2357_device) diff --git a/src/devices/cpu/h8/h8s2600.cpp b/src/devices/cpu/h8/h8s2600.cpp index be04b3382df..1cc751757dd 100644 --- a/src/devices/cpu/h8/h8s2600.cpp +++ b/src/devices/cpu/h8/h8s2600.cpp @@ -4,7 +4,7 @@ #include "h8s2600.h" #include "h8s2600d.h" -h8s2600_device::h8s2600_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor map_delegate) : +h8s2600_device::h8s2600_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map_delegate) : h8s2000_device(mconfig, type, tag, owner, clock, map_delegate) { has_mac = true; diff --git a/src/devices/cpu/h8/h8s2600.h b/src/devices/cpu/h8/h8s2600.h index 84c611dd8f7..dd323c3f85f 100644 --- a/src/devices/cpu/h8/h8s2600.h +++ b/src/devices/cpu/h8/h8s2600.h @@ -20,7 +20,7 @@ class h8s2600_device : public h8s2000_device { protected: - h8s2600_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor map_delegate); + h8s2600_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map_delegate); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/h8/h8s2655.cpp b/src/devices/cpu/h8/h8s2655.cpp index eb29b29bdc3..c6dab386354 100644 --- a/src/devices/cpu/h8/h8s2655.cpp +++ b/src/devices/cpu/h8/h8s2655.cpp @@ -6,7 +6,7 @@ DEFINE_DEVICE_TYPE(H8S2655, h8s2655_device, "h8s2655", "Hitachi H8S/2655") DEFINE_DEVICE_TYPE(H8S2653, h8s2653_device, "h8s2653", "Hitachi H8S/2653") -h8s2655_device::h8s2655_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +h8s2655_device::h8s2655_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : h8s2600_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h8s2655_device::map), this)), intc(*this, "intc"), adc(*this, "adc"), @@ -41,13 +41,13 @@ h8s2655_device::h8s2655_device(const machine_config &mconfig, device_type type, has_trace = true; } -h8s2655_device::h8s2655_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2655_device::h8s2655_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2655_device(mconfig, H8S2655, tag, owner, clock) { } -h8s2653_device::h8s2653_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +h8s2653_device::h8s2653_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8s2655_device(mconfig, H8S2653, tag, owner, clock) { } diff --git a/src/devices/cpu/h8/h8s2655.h b/src/devices/cpu/h8/h8s2655.h index aa8384bce73..b8854f9d397 100644 --- a/src/devices/cpu/h8/h8s2655.h +++ b/src/devices/cpu/h8/h8s2655.h @@ -28,7 +28,7 @@ class h8s2655_device : public h8s2600_device { public: - h8s2655_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2655_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t syscr_r(); void syscr_w(uint8_t data); @@ -65,7 +65,7 @@ protected: uint8_t syscr; - h8s2655_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + h8s2655_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual bool exr_in_stack() const override; virtual void update_irq_filter() override; @@ -84,7 +84,7 @@ protected: class h8s2653_device : public h8s2655_device { public: - h8s2653_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + h8s2653_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(H8S2655, h8s2655_device) diff --git a/src/devices/cpu/h8500/h8500.cpp b/src/devices/cpu/h8500/h8500.cpp index b022749197c..563ab9ce214 100644 --- a/src/devices/cpu/h8500/h8500.cpp +++ b/src/devices/cpu/h8500/h8500.cpp @@ -12,7 +12,7 @@ #include "h8500.h" #include "h8500dasm.h" -h8500_device::h8500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int addrbits, int buswidth, int ramsize, int defmode, address_map_constructor map) +h8500_device::h8500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addrbits, int buswidth, int ramsize, int defmode, address_map_constructor map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, buswidth, addrbits, 0, map) , m_ram_config("intram", ENDIANNESS_BIG, 16, ramsize, 0, address_map_constructor(FUNC(h8500_device::ram_map), this)) diff --git a/src/devices/cpu/h8500/h8500.h b/src/devices/cpu/h8500/h8500.h index 3755ab7a4ab..7959b872639 100644 --- a/src/devices/cpu/h8500/h8500.h +++ b/src/devices/cpu/h8500/h8500.h @@ -21,7 +21,7 @@ public: void set_mode(u8 mode) { assert(!configured()); m_mode_control = mode; } protected: - h8500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int addrbits, int buswidth, int ramsize, int defmode, address_map_constructor map); + h8500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addrbits, int buswidth, int ramsize, int defmode, address_map_constructor map); // device-level overrides virtual void device_config_complete() override; diff --git a/src/devices/cpu/h8500/h8510.cpp b/src/devices/cpu/h8500/h8510.cpp index b4ade58d8d5..40aedafe93e 100644 --- a/src/devices/cpu/h8500/h8510.cpp +++ b/src/devices/cpu/h8500/h8510.cpp @@ -11,12 +11,12 @@ DEFINE_DEVICE_TYPE(HD6415108, hd6415108_device, "hd6415108", "Hitachi HD6415108 (H8/510)") -h8510_device::h8510_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +h8510_device::h8510_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : h8500_device(mconfig, type, tag, owner, clock, 24, 16, 0, 4, address_map_constructor(FUNC(h8510_device::internal_map), this)) { } -hd6415108_device::hd6415108_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd6415108_device::hd6415108_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8510_device(mconfig, HD6415108, tag, owner, clock) { } diff --git a/src/devices/cpu/h8500/h8510.h b/src/devices/cpu/h8500/h8510.h index 1cbefe87aa3..96809f0bf63 100644 --- a/src/devices/cpu/h8500/h8510.h +++ b/src/devices/cpu/h8500/h8510.h @@ -11,7 +11,7 @@ class h8510_device : public h8500_device { protected: - h8510_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + h8510_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); private: void internal_map(address_map &map); @@ -21,7 +21,7 @@ class hd6415108_device : public h8510_device { public: // device type constructor - hd6415108_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd6415108_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(HD6415108, hd6415108_device) diff --git a/src/devices/cpu/h8500/h8520.cpp b/src/devices/cpu/h8500/h8520.cpp index 459a979da98..2298459cbcc 100644 --- a/src/devices/cpu/h8500/h8520.cpp +++ b/src/devices/cpu/h8500/h8520.cpp @@ -12,17 +12,17 @@ DEFINE_DEVICE_TYPE(HD6435208, hd6435208_device, "hd6435208", "Hitachi HD6435208 (H8/520)") DEFINE_DEVICE_TYPE(HD6475208, hd6475208_device, "hd6475208", "Hitachi HD6475208 (H8/520)") -h8520_device::h8520_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +h8520_device::h8520_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : h8500_device(mconfig, type, tag, owner, clock, 20, 8, 9, 4, address_map_constructor(FUNC(h8520_device::internal_map), this)) { } -hd6435208_device::hd6435208_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd6435208_device::hd6435208_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8520_device(mconfig, HD6435208, tag, owner, clock) { } -hd6475208_device::hd6475208_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd6475208_device::hd6475208_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8520_device(mconfig, HD6475208, tag, owner, clock) { } diff --git a/src/devices/cpu/h8500/h8520.h b/src/devices/cpu/h8500/h8520.h index 7f66327c796..b43d622476f 100644 --- a/src/devices/cpu/h8500/h8520.h +++ b/src/devices/cpu/h8500/h8520.h @@ -11,7 +11,7 @@ class h8520_device : public h8500_device { protected: - h8520_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + h8520_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); private: void internal_map(address_map &map); @@ -21,14 +21,14 @@ class hd6435208_device : public h8520_device { public: // device type constructor - hd6435208_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd6435208_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd6475208_device : public h8520_device { public: // device type constructor - hd6475208_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd6475208_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(HD6435208, hd6435208_device) diff --git a/src/devices/cpu/h8500/h8532.cpp b/src/devices/cpu/h8500/h8532.cpp index 20c9869c4ee..484b09573ca 100644 --- a/src/devices/cpu/h8500/h8532.cpp +++ b/src/devices/cpu/h8500/h8532.cpp @@ -12,17 +12,17 @@ DEFINE_DEVICE_TYPE(HD6435328, hd6435328_device, "hd6435328", "Hitachi HD6435328 (H8/532)") DEFINE_DEVICE_TYPE(HD6475328, hd6475328_device, "hd6475328", "Hitachi HD6475328 (H8/532)") -h8532_device::h8532_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +h8532_device::h8532_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : h8500_device(mconfig, type, tag, owner, clock, 20, 8, 10, 4, address_map_constructor(FUNC(h8532_device::internal_map), this)) { } -hd6435328_device::hd6435328_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd6435328_device::hd6435328_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8532_device(mconfig, HD6435328, tag, owner, clock) { } -hd6475328_device::hd6475328_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd6475328_device::hd6475328_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8532_device(mconfig, HD6475328, tag, owner, clock) { } diff --git a/src/devices/cpu/h8500/h8532.h b/src/devices/cpu/h8500/h8532.h index 71ec652a465..6aa703bd63c 100644 --- a/src/devices/cpu/h8500/h8532.h +++ b/src/devices/cpu/h8500/h8532.h @@ -11,7 +11,7 @@ class h8532_device : public h8500_device { protected: - h8532_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + h8532_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); private: void internal_map(address_map &map); @@ -21,14 +21,14 @@ class hd6435328_device : public h8532_device { public: // device type constructor - hd6435328_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd6435328_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd6475328_device : public h8532_device { public: // device type constructor - hd6475328_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd6475328_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(HD6435328, hd6435328_device) diff --git a/src/devices/cpu/h8500/h8534.cpp b/src/devices/cpu/h8500/h8534.cpp index 06c9b0dc24f..78e63d11f71 100644 --- a/src/devices/cpu/h8500/h8534.cpp +++ b/src/devices/cpu/h8500/h8534.cpp @@ -14,37 +14,37 @@ DEFINE_DEVICE_TYPE(HD6475348, hd6475348_device, "hd6475348", "Hitachi HD6475348 DEFINE_DEVICE_TYPE(HD6435368, hd6435368_device, "hd6435368", "Hitachi HD6435368 (H8/536)") DEFINE_DEVICE_TYPE(HD6475368, hd6475368_device, "hd6475368", "Hitachi HD6475368 (H8/536)") -h8534_device::h8534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map) +h8534_device::h8534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map) : h8500_device(mconfig, type, tag, owner, clock, 20, 8, 11, 4, map) { } -h8534_device::h8534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +h8534_device::h8534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : h8534_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h8534_device::internal_map), this)) { } -hd6435348_device::hd6435348_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd6435348_device::hd6435348_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8534_device(mconfig, HD6435348, tag, owner, clock) { } -hd6475348_device::hd6475348_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd6475348_device::hd6475348_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8534_device(mconfig, HD6475348, tag, owner, clock) { } -h8536_device::h8536_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +h8536_device::h8536_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : h8534_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(h8536_device::internal_map), this)) { } -hd6435368_device::hd6435368_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd6435368_device::hd6435368_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8536_device(mconfig, HD6435368, tag, owner, clock) { } -hd6475368_device::hd6475368_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd6475368_device::hd6475368_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : h8536_device(mconfig, HD6475368, tag, owner, clock) { } diff --git a/src/devices/cpu/h8500/h8534.h b/src/devices/cpu/h8500/h8534.h index 2fad7985a70..c73faaf7ad9 100644 --- a/src/devices/cpu/h8500/h8534.h +++ b/src/devices/cpu/h8500/h8534.h @@ -12,8 +12,8 @@ class h8534_device : public h8500_device { protected: // delegating constructors - h8534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); - h8534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map); + h8534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + h8534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map); void register_field_map(address_map &map); @@ -25,20 +25,20 @@ class hd6435348_device : public h8534_device { public: // device type constructor - hd6435348_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd6435348_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd6475348_device : public h8534_device { public: // device type constructor - hd6475348_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd6475348_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class h8536_device : public h8534_device { protected: - h8536_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + h8536_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); private: void internal_map(address_map &map); @@ -48,14 +48,14 @@ class hd6435368_device : public h8536_device { public: // device type constructor - hd6435368_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd6435368_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd6475368_device : public h8536_device { public: // device type constructor - hd6475368_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd6475368_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(HD6435348, hd6435348_device) diff --git a/src/devices/cpu/hcd62121/hcd62121.cpp b/src/devices/cpu/hcd62121/hcd62121.cpp index e05fe883d65..20ce50af3fd 100644 --- a/src/devices/cpu/hcd62121/hcd62121.cpp +++ b/src/devices/cpu/hcd62121/hcd62121.cpp @@ -50,7 +50,7 @@ constexpr u8 FLAG_ZH = 0x01; DEFINE_DEVICE_TYPE(HCD62121, hcd62121_cpu_device, "hcd62121", "Hitachi HCD62121") -hcd62121_cpu_device::hcd62121_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hcd62121_cpu_device::hcd62121_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, HCD62121, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, 24, 0) , m_prev_pc(0) diff --git a/src/devices/cpu/hcd62121/hcd62121.h b/src/devices/cpu/hcd62121/hcd62121.h index d7d35a881dd..dad5bc53b2b 100644 --- a/src/devices/cpu/hcd62121/hcd62121.h +++ b/src/devices/cpu/hcd62121/hcd62121.h @@ -9,7 +9,7 @@ class hcd62121_cpu_device : public cpu_device { public: // construction/destruction - hcd62121_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hcd62121_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto kol_cb() { return m_kol_cb.bind(); } auto koh_cb() { return m_koh_cb.bind(); } diff --git a/src/devices/cpu/hd61700/hd61700.cpp b/src/devices/cpu/hd61700/hd61700.cpp index 2241855cf1c..095cc742406 100644 --- a/src/devices/cpu/hd61700/hd61700.cpp +++ b/src/devices/cpu/hd61700/hd61700.cpp @@ -102,7 +102,7 @@ DEFINE_DEVICE_TYPE(HD61700, hd61700_cpu_device, "hd61700", "Hitachi HD61700") // hd61700_cpu_device - constructor //------------------------------------------------- -hd61700_cpu_device::hd61700_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd61700_cpu_device::hd61700_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, HD61700, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, 18, -1) , m_ppc(0x0000) diff --git a/src/devices/cpu/hd61700/hd61700.h b/src/devices/cpu/hd61700/hd61700.h index 6f7ef9462ff..25d1a37f113 100644 --- a/src/devices/cpu/hd61700/hd61700.h +++ b/src/devices/cpu/hd61700/hd61700.h @@ -33,7 +33,7 @@ class hd61700_cpu_device : public cpu_device { public: // construction/destruction - hd61700_cpu_device(const machine_config &mconfig, const char *_tag, device_t *_owner, uint32_t _clock); + hd61700_cpu_device(const machine_config &mconfig, const char *_tag, device_t *_owner, const XTAL &_clock); auto lcd_ctrl() { return m_lcd_ctrl_cb.bind(); } auto lcd_write() { return m_lcd_write_cb.bind(); } diff --git a/src/devices/cpu/hmcs40/hmcs40.cpp b/src/devices/cpu/hmcs40/hmcs40.cpp index 841e37e1558..1c2f1a29b01 100644 --- a/src/devices/cpu/hmcs40/hmcs40.cpp +++ b/src/devices/cpu/hmcs40/hmcs40.cpp @@ -93,7 +93,7 @@ void hmcs40_cpu_device::data_160x4(address_map &map) // device definitions -hmcs40_cpu_device::hmcs40_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int family, u16 polarity, int stack_levels, int pcwidth, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) +hmcs40_cpu_device::hmcs40_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int family, u16 polarity, int stack_levels, int pcwidth, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, prgwidth, -1, program) , m_data_config("data", ENDIANNESS_LITTLE, 8, datawidth, 0, data) @@ -110,56 +110,56 @@ hmcs40_cpu_device::hmcs40_cpu_device(const machine_config &mconfig, device_type { } -hmcs43_cpu_device::hmcs43_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 polarity) +hmcs43_cpu_device::hmcs43_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 polarity) : hmcs40_cpu_device(mconfig, type, tag, owner, clock, HMCS40_FAMILY_HMCS43, polarity, 3 /* stack levels */, 10 /* pc width */, 11 /* prg width */, address_map_constructor(FUNC(hmcs43_cpu_device::program_1k), this), 7 /* data width */, address_map_constructor(FUNC(hmcs43_cpu_device::data_80x4), this)) { } -hd38750_device::hd38750_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd38750_device::hd38750_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs43_cpu_device(mconfig, HD38750, tag, owner, clock, IS_PMOS) { } -hd38755_device::hd38755_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd38755_device::hd38755_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs43_cpu_device(mconfig, HD38755, tag, owner, clock, IS_PMOS) { } -hd44750_device::hd44750_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd44750_device::hd44750_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs43_cpu_device(mconfig, HD44750, tag, owner, clock, IS_CMOS) { } -hd44758_device::hd44758_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd44758_device::hd44758_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs43_cpu_device(mconfig, HD44758, tag, owner, clock, IS_CMOS) { } -hmcs44_cpu_device::hmcs44_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 polarity) +hmcs44_cpu_device::hmcs44_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 polarity) : hmcs40_cpu_device(mconfig, type, tag, owner, clock, HMCS40_FAMILY_HMCS44, polarity, 4, 11, 12, address_map_constructor(FUNC(hmcs44_cpu_device::program_2k), this), 8, address_map_constructor(FUNC(hmcs44_cpu_device::data_160x4), this)) { } -hd38800_device::hd38800_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd38800_device::hd38800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs44_cpu_device(mconfig, HD38800, tag, owner, clock, IS_PMOS) { } -hd38805_device::hd38805_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd38805_device::hd38805_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs44_cpu_device(mconfig, HD38805, tag, owner, clock, IS_PMOS) { } -hd44801_device::hd44801_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd44801_device::hd44801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs44_cpu_device(mconfig, HD44801, tag, owner, clock, IS_CMOS) { } -hd44808_device::hd44808_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd44808_device::hd44808_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs44_cpu_device(mconfig, HD44808, tag, owner, clock, IS_CMOS) { } -hmcs45_cpu_device::hmcs45_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 polarity) +hmcs45_cpu_device::hmcs45_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 polarity) : hmcs40_cpu_device(mconfig, type, tag, owner, clock, HMCS40_FAMILY_HMCS45, polarity, 4, 11, 12, address_map_constructor(FUNC(hmcs45_cpu_device::program_2k), this), 8, address_map_constructor(FUNC(hmcs45_cpu_device::data_160x4), this)) { } -hd38820_device::hd38820_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd38820_device::hd38820_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs45_cpu_device(mconfig, HD38820, tag, owner, clock, IS_PMOS) { } -hd38825_device::hd38825_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd38825_device::hd38825_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs45_cpu_device(mconfig, HD38825, tag, owner, clock, IS_PMOS) { } -hd44820_device::hd44820_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd44820_device::hd44820_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs45_cpu_device(mconfig, HD44820, tag, owner, clock, IS_CMOS) { } -hd44828_device::hd44828_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd44828_device::hd44828_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hmcs45_cpu_device(mconfig, HD44828, tag, owner, clock, IS_CMOS) { } diff --git a/src/devices/cpu/hmcs40/hmcs40.h b/src/devices/cpu/hmcs40/hmcs40.h index 0738eab209a..ac0ae2f75c0 100644 --- a/src/devices/cpu/hmcs40/hmcs40.h +++ b/src/devices/cpu/hmcs40/hmcs40.h @@ -101,7 +101,7 @@ protected: }; // construction/destruction - hmcs40_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int family, u16 polarity, int stack_levels, int pcwidth, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + hmcs40_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int family, u16 polarity, int stack_levels, int pcwidth, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device-level overrides virtual void device_start() override; @@ -302,7 +302,7 @@ protected: class hmcs43_cpu_device : public hmcs40_cpu_device { protected: - hmcs43_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 polarity); + hmcs43_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 polarity); // overrides virtual u8 read_r(int index) override; @@ -313,32 +313,32 @@ protected: class hd38750_device : public hmcs43_cpu_device { public: - hd38750_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd38750_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd38755_device : public hmcs43_cpu_device { public: - hd38755_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd38755_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd44750_device : public hmcs43_cpu_device { public: - hd44750_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd44750_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd44758_device : public hmcs43_cpu_device { public: - hd44758_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd44758_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hmcs44_cpu_device : public hmcs40_cpu_device { protected: - hmcs44_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 polarity); + hmcs44_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 polarity); // overrides virtual u8 read_r(int index) override; @@ -348,32 +348,32 @@ protected: class hd38800_device : public hmcs44_cpu_device { public: - hd38800_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd38800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd38805_device : public hmcs44_cpu_device { public: - hd38805_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd38805_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd44801_device : public hmcs44_cpu_device { public: - hd44801_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd44801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd44808_device : public hmcs44_cpu_device { public: - hd44808_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd44808_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hmcs45_cpu_device : public hmcs40_cpu_device { protected: - hmcs45_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 polarity); + hmcs45_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 polarity); // overrides virtual u8 read_r(int index) override; @@ -383,25 +383,25 @@ protected: class hd38820_device : public hmcs45_cpu_device { public: - hd38820_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd38820_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd38825_device : public hmcs45_cpu_device { public: - hd38825_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd38825_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd44820_device : public hmcs45_cpu_device { public: - hd44820_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd44820_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd44828_device : public hmcs45_cpu_device { public: - hd44828_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd44828_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/hpc/hpc.cpp b/src/devices/cpu/hpc/hpc.cpp index 399ca9164af..60de068da6b 100644 --- a/src/devices/cpu/hpc/hpc.cpp +++ b/src/devices/cpu/hpc/hpc.cpp @@ -65,7 +65,7 @@ std::unique_ptr<util::disasm_interface> hpc46104_device::create_disassembler() } -hpc_device::hpc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map) +hpc_device::hpc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 16, 0, map) , m_program(nullptr) @@ -75,12 +75,12 @@ hpc_device::hpc_device(const machine_config &mconfig, device_type type, const ch { } -hpc46003_device::hpc46003_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hpc46003_device::hpc46003_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hpc_device(mconfig, HPC46003, tag, owner, clock, address_map_constructor(FUNC(hpc46003_device::internal_map), this)) { } -hpc46104_device::hpc46104_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hpc46104_device::hpc46104_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hpc_device(mconfig, HPC46104, tag, owner, clock, address_map_constructor(FUNC(hpc46104_device::internal_map), this)) { } diff --git a/src/devices/cpu/hpc/hpc.h b/src/devices/cpu/hpc/hpc.h index 5f73a0ee2e6..685bae90c61 100644 --- a/src/devices/cpu/hpc/hpc.h +++ b/src/devices/cpu/hpc/hpc.h @@ -22,7 +22,7 @@ public: protected: // construction/destruction - hpc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map); + hpc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map); // device-level overrides virtual void device_start() override; @@ -56,7 +56,7 @@ class hpc46003_device : public hpc_device { public: // construction/destruction - hpc46003_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hpc46003_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides @@ -70,7 +70,7 @@ class hpc46104_device : public hpc_device { public: // construction/destruction - hpc46104_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hpc46104_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides diff --git a/src/devices/cpu/hphybrid/hphybrid.cpp b/src/devices/cpu/hphybrid/hphybrid.cpp index a4eb434167a..eedfcee51bb 100644 --- a/src/devices/cpu/hphybrid/hphybrid.cpp +++ b/src/devices/cpu/hphybrid/hphybrid.cpp @@ -166,7 +166,7 @@ WRITE_LINE_MEMBER(hp_hybrid_cpu_device::flag_w) BIT_CLR(m_flags, HPHYBRID_FLG_BIT); } -hp_hybrid_cpu_device::hp_hybrid_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t addrwidth) +hp_hybrid_cpu_device::hp_hybrid_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t addrwidth) : cpu_device(mconfig, type, tag, owner, clock) , m_pa_changed_func(*this) , m_opcode_func(*this) @@ -1525,12 +1525,12 @@ void hp_hybrid_cpu_device::do_mpy() // ******************************************************************************** // hp_5061_3011_cpu_device // ******************************************************************************** -hp_5061_3011_cpu_device::hp_5061_3011_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp_5061_3011_cpu_device::hp_5061_3011_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hp_hybrid_cpu_device(mconfig, HP_5061_3011, tag, owner, clock, 16) { } -hp_5061_3011_cpu_device::hp_5061_3011_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t addrwidth) +hp_5061_3011_cpu_device::hp_5061_3011_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t addrwidth) : hp_hybrid_cpu_device(mconfig, type, tag, owner, clock, addrwidth) { } @@ -1728,7 +1728,7 @@ std::unique_ptr<util::disasm_interface> hp_5061_3011_cpu_device::create_disassem // ******************************************************************************** // hp_5061_3001_cpu_device // ******************************************************************************** -hp_5061_3001_cpu_device::hp_5061_3001_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp_5061_3001_cpu_device::hp_5061_3001_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hp_5061_3011_cpu_device(mconfig, HP_5061_3001, tag, owner, clock, 22) { } @@ -1922,7 +1922,7 @@ void hp_5061_3001_cpu_device::enter_isr() // ******************************************************************************** // hp_09825_67907_cpu_device // ******************************************************************************** -hp_09825_67907_cpu_device::hp_09825_67907_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp_09825_67907_cpu_device::hp_09825_67907_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hp_hybrid_cpu_device(mconfig , HP_09825_67907 , tag , owner , clock , 15) { } diff --git a/src/devices/cpu/hphybrid/hphybrid.h b/src/devices/cpu/hphybrid/hphybrid.h index 3864282245d..041e4b8e06f 100644 --- a/src/devices/cpu/hphybrid/hphybrid.h +++ b/src/devices/cpu/hphybrid/hphybrid.h @@ -95,7 +95,7 @@ public: template <typename... T> void set_int_cb(T &&... args) { m_int_func.set(std::forward<T>(args)...); } protected: - hp_hybrid_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t addrwidth); + hp_hybrid_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t addrwidth); // device-level overrides virtual void device_start() override; @@ -230,10 +230,10 @@ private: class hp_5061_3011_cpu_device : public hp_hybrid_cpu_device { public: - hp_5061_3011_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_5061_3011_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - hp_5061_3011_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t addrwidth); + hp_5061_3011_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t addrwidth); // TODO: fix virtual uint32_t execute_max_cycles() const noexcept override { return 25; } virtual bool execute_no_bpc(uint16_t opcode , uint16_t& next_pc) override; @@ -248,7 +248,7 @@ protected: class hp_5061_3001_cpu_device : public hp_5061_3011_cpu_device { public: - hp_5061_3001_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_5061_3001_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Set boot mode of 5061-3001: either normal (false) or as in HP9845 system (true) void set_9845_boot_mode(bool mode) { m_boot_mode = mode; } @@ -275,7 +275,7 @@ private: class hp_09825_67907_cpu_device : public hp_hybrid_cpu_device { public: - hp_09825_67907_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_09825_67907_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/i386/athlon.cpp b/src/devices/cpu/i386/athlon.cpp index dddfa80fa35..692f0e4d1d1 100644 --- a/src/devices/cpu/i386/athlon.cpp +++ b/src/devices/cpu/i386/athlon.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(ATHLONXP, athlonxp_device, "athlonxp", "Amd Athlon XP") -athlonxp_device::athlonxp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +athlonxp_device::athlonxp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pentium_device(mconfig, ATHLONXP, tag, owner, clock) , m_data_config("mmio", ENDIANNESS_LITTLE, 32, 32, 0, 32, 12) , m_opcodes_config("debugger", ENDIANNESS_LITTLE, 32, 32, 0, 32, 12) diff --git a/src/devices/cpu/i386/athlon.h b/src/devices/cpu/i386/athlon.h index 69cc6d84794..9c41b90cd2a 100644 --- a/src/devices/cpu/i386/athlon.h +++ b/src/devices/cpu/i386/athlon.h @@ -13,7 +13,7 @@ class athlonxp_device : public pentium_device { public: // construction/destruction - athlonxp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + athlonxp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void opcode_cpuid() override; diff --git a/src/devices/cpu/i386/i386.cpp b/src/devices/cpu/i386/i386.cpp index 152691db3c3..81765619596 100644 --- a/src/devices/cpu/i386/i386.cpp +++ b/src/devices/cpu/i386/i386.cpp @@ -44,13 +44,13 @@ DEFINE_DEVICE_TYPE(PENTIUM3, pentium3_device, "pentium3", "Intel Pentiu DEFINE_DEVICE_TYPE(PENTIUM4, pentium4_device, "pentium4", "Intel Pentium 4") -i386_device::i386_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i386_device::i386_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i386_device(mconfig, I386, tag, owner, clock, 32, 32, 32) { } -i386_device::i386_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_data_width, int program_addr_width, int io_data_width) +i386_device::i386_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_data_width, int program_addr_width, int io_data_width) : cpu_device(mconfig, type, tag, owner, clock) , device_vtlb_interface(mconfig, *this, AS_PROGRAM) , m_program_config("program", ENDIANNESS_LITTLE, program_data_width, program_addr_width, 0, 32, 12) @@ -62,75 +62,75 @@ i386_device::i386_device(const machine_config &mconfig, device_type type, const set_vtlb_dynamic_entries(32); } -i386sx_device::i386sx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i386sx_device::i386sx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i386_device(mconfig, I386SX, tag, owner, clock, 16, 24, 16) { } -i486_device::i486_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i486_device::i486_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i486_device(mconfig, I486, tag, owner, clock) { } -i486_device::i486_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +i486_device::i486_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : i386_device(mconfig, type, tag, owner, clock, 32, 32, 32) { } -i486dx4_device::i486dx4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i486dx4_device::i486dx4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i486_device(mconfig, I486DX4, tag, owner, clock) { } -pentium_device::pentium_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pentium_device::pentium_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pentium_device(mconfig, PENTIUM, tag, owner, clock) { } -pentium_device::pentium_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pentium_device::pentium_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : i386_device(mconfig, type, tag, owner, clock, 32, 32, 32) { // 64 dtlb small, 8 dtlb large, 32 itlb set_vtlb_dynamic_entries(96); } -mediagx_device::mediagx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mediagx_device::mediagx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i386_device(mconfig, MEDIAGX, tag, owner, clock, 32, 32, 32) { } -pentium_pro_device::pentium_pro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pentium_pro_device::pentium_pro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pentium_pro_device(mconfig, PENTIUM_PRO, tag, owner, clock) { } -pentium_pro_device::pentium_pro_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pentium_pro_device::pentium_pro_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : pentium_device(mconfig, type, tag, owner, clock) { } -pentium_mmx_device::pentium_mmx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pentium_mmx_device::pentium_mmx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pentium_device(mconfig, PENTIUM_MMX, tag, owner, clock) { // 64 dtlb small, 8 dtlb large, 32 itlb small, 2 itlb large set_vtlb_dynamic_entries(96); } -pentium2_device::pentium2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pentium2_device::pentium2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pentium_pro_device(mconfig, PENTIUM2, tag, owner, clock) { // 64 dtlb small, 8 dtlb large, 32 itlb small, 2 itlb large set_vtlb_dynamic_entries(96); } -pentium3_device::pentium3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pentium3_device::pentium3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pentium_pro_device(mconfig, PENTIUM3, tag, owner, clock) { // 64 dtlb small, 8 dtlb large, 32 itlb small, 2 itlb large set_vtlb_dynamic_entries(96); } -pentium4_device::pentium4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pentium4_device::pentium4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pentium_device(mconfig, PENTIUM4, tag, owner, clock) { // 128 dtlb, 64 itlb diff --git a/src/devices/cpu/i386/i386.h b/src/devices/cpu/i386/i386.h index 60bf5b59b8d..6bb28ee9ff1 100644 --- a/src/devices/cpu/i386/i386.h +++ b/src/devices/cpu/i386/i386.h @@ -29,7 +29,7 @@ class i386_device : public cpu_device, public device_vtlb_interface, public i386 { public: // construction/destruction - i386_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i386_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto smiact() { return m_smiact.bind(); } @@ -42,7 +42,7 @@ public: uint64_t debug_cacheflush(int params, const uint64_t *param); protected: - i386_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_data_width, int program_addr_width, int io_data_width); + i386_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_data_width, int program_addr_width, int io_data_width); // device-level overrides virtual void device_start() override; @@ -1528,7 +1528,7 @@ class i386sx_device : public i386_device { public: // construction/destruction - i386sx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i386sx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual u8 mem_pr8(offs_t address) override { return macache16.read_byte(address); } @@ -1551,10 +1551,10 @@ class i486_device : public i386_device { public: // construction/destruction - i486_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i486_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - i486_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + i486_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -1564,7 +1564,7 @@ class i486dx4_device : public i486_device { public: // construction/destruction - i486dx4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i486dx4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; @@ -1575,10 +1575,10 @@ class pentium_device : public i386_device { public: // construction/destruction - pentium_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pentium_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - pentium_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pentium_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual bool execute_input_edge_triggered(int inputnum) const noexcept override { return inputnum == INPUT_LINE_NMI || inputnum == INPUT_LINE_SMI; } virtual void execute_set_input(int inputnum, int state) override; @@ -1593,7 +1593,7 @@ class pentium_mmx_device : public pentium_device { public: // construction/destruction - pentium_mmx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pentium_mmx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -1605,7 +1605,7 @@ class mediagx_device : public i386_device { public: // construction/destruction - mediagx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mediagx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -1617,10 +1617,10 @@ class pentium_pro_device : public pentium_device { public: // construction/destruction - pentium_pro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pentium_pro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - pentium_pro_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pentium_pro_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual uint64_t opcode_rdmsr(bool &valid_msr) override; virtual void opcode_wrmsr(uint64_t data, bool &valid_msr) override; @@ -1633,7 +1633,7 @@ class pentium2_device : public pentium_pro_device { public: // construction/destruction - pentium2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pentium2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -1645,7 +1645,7 @@ class pentium3_device : public pentium_pro_device { public: // construction/destruction - pentium3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pentium3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -1659,7 +1659,7 @@ class pentium4_device : public pentium_device { public: // construction/destruction - pentium4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pentium4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual uint64_t opcode_rdmsr(bool &valid_msr) override; diff --git a/src/devices/cpu/i8008/i8008.cpp b/src/devices/cpu/i8008/i8008.cpp index c404508560b..9ada7fd875b 100644 --- a/src/devices/cpu/i8008/i8008.cpp +++ b/src/devices/cpu/i8008/i8008.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(I8008, i8008_device, "i8008", "Intel 8008") //------------------------------------------------- // i8008_device - constructor //------------------------------------------------- -i8008_device::i8008_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8008_device::i8008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, I8008, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 14) , m_io_config("io", ENDIANNESS_LITTLE, 8, 16) diff --git a/src/devices/cpu/i8008/i8008.h b/src/devices/cpu/i8008/i8008.h index 5b7882f7958..a10d9cf882d 100644 --- a/src/devices/cpu/i8008/i8008.h +++ b/src/devices/cpu/i8008/i8008.h @@ -14,7 +14,7 @@ class i8008_device : public cpu_device { public: // construction/destruction - i8008_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: enum diff --git a/src/devices/cpu/i8085/i8085.cpp b/src/devices/cpu/i8085/i8085.cpp index 9dc530c0567..646f0471032 100644 --- a/src/devices/cpu/i8085/i8085.cpp +++ b/src/devices/cpu/i8085/i8085.cpp @@ -201,12 +201,12 @@ DEFINE_DEVICE_TYPE(I8080A, i8080a_cpu_device, "i8080a", "Intel 8080A") DEFINE_DEVICE_TYPE(I8085A, i8085a_cpu_device, "i8085a", "Intel 8085A") -i8085a_cpu_device::i8085a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +i8085a_cpu_device::i8085a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8085a_cpu_device(mconfig, I8085A, tag, owner, clock, CPUTYPE_8085A) { } -i8085a_cpu_device::i8085a_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int cputype) +i8085a_cpu_device::i8085a_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cputype) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0) , m_io_config("io", ENDIANNESS_LITTLE, 8, 8, 0) @@ -221,12 +221,12 @@ i8085a_cpu_device::i8085a_cpu_device(const machine_config &mconfig, device_type { } -i8080_cpu_device::i8080_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +i8080_cpu_device::i8080_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8085a_cpu_device(mconfig, I8080, tag, owner, clock, CPUTYPE_8080) { } -i8080a_cpu_device::i8080a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +i8080a_cpu_device::i8080a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8085a_cpu_device(mconfig, I8080A, tag, owner, clock, CPUTYPE_8080A) { } diff --git a/src/devices/cpu/i8085/i8085.h b/src/devices/cpu/i8085/i8085.h index 5378a712e5e..66186946a40 100644 --- a/src/devices/cpu/i8085/i8085.h +++ b/src/devices/cpu/i8085/i8085.h @@ -40,7 +40,7 @@ public: static constexpr u8 STATUS_MEMR = 0x80; // construction/destruction - i8085a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + i8085a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // CLK rate callback (8085A only) template <typename... T> void set_clk_out(T &&... args) { m_clk_out_func.set(std::forward<T>(args)...); } @@ -61,7 +61,7 @@ public: auto out_sod_func() { return m_out_sod_func.bind(); } protected: - i8085a_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int cputype); + i8085a_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cputype); // device-level overrides virtual void device_config_complete() override; @@ -181,7 +181,7 @@ class i8080_cpu_device : public i8085a_cpu_device { public: // construction/destruction - i8080_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + i8080_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual u32 execute_input_lines() const noexcept override { return 1; } @@ -194,7 +194,7 @@ class i8080a_cpu_device : public i8085a_cpu_device { public: // construction/destruction - i8080a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + i8080a_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual u32 execute_input_lines() const noexcept override { return 1; } diff --git a/src/devices/cpu/i8089/i8089.cpp b/src/devices/cpu/i8089/i8089.cpp index 7cc3420a619..3a9d3915536 100644 --- a/src/devices/cpu/i8089/i8089.cpp +++ b/src/devices/cpu/i8089/i8089.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(I8089, i8089_device, "i8089", "Intel 8089 I/O Processor") // i8089_device - constructor //------------------------------------------------- -i8089_device::i8089_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i8089_device::i8089_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, I8089, tag, owner, clock), m_icount(0), m_ch1(*this, "1"), @@ -210,8 +210,8 @@ void i8089_device::state_string_export(const device_state_entry &entry, std::str void i8089_device::device_add_mconfig(machine_config &config) { - I8089_CHANNEL(config, m_ch1, 0).sintr().set(FUNC(i8089_device::ch1_sintr_w)); - I8089_CHANNEL(config, m_ch2, 0).sintr().set(FUNC(i8089_device::ch2_sintr_w)); + I8089_CHANNEL(config, m_ch1).sintr().set(FUNC(i8089_device::ch1_sintr_w)); + I8089_CHANNEL(config, m_ch2).sintr().set(FUNC(i8089_device::ch2_sintr_w)); } diff --git a/src/devices/cpu/i8089/i8089.h b/src/devices/cpu/i8089/i8089.h index 19f81136336..36068c8c4e7 100644 --- a/src/devices/cpu/i8089/i8089.h +++ b/src/devices/cpu/i8089/i8089.h @@ -11,20 +11,12 @@ #pragma once -#ifdef _MSC_VER -// MSVC seems to want to actually instantiate templates when it gets an extern template declaration, effectively defeating the purpose of extern template declatations altogether -// In this case it causes a problem because the required_device template can't be instantiated for the incomplete i8089_channel_device type #include "i8089_channel.h" -#endif - //************************************************************************** // TYPE DEFINITIONS //************************************************************************** -// forward declaration -class i8089_channel_device; - // ======================> i8089_device class i8089_device : public cpu_device @@ -33,7 +25,7 @@ class i8089_device : public cpu_device public: // construction/destruction - i8089_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8089_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto sintr1() { return m_write_sintr1.bind(); } diff --git a/src/devices/cpu/i8089/i8089_channel.cpp b/src/devices/cpu/i8089/i8089_channel.cpp index d13606a1ca5..fd88674fb86 100644 --- a/src/devices/cpu/i8089/i8089_channel.cpp +++ b/src/devices/cpu/i8089/i8089_channel.cpp @@ -49,7 +49,7 @@ DEFINE_DEVICE_TYPE(I8089_CHANNEL, i8089_channel_device, "i8089_channel", "Intel // i8089_channel_device - constructor //------------------------------------------------- -i8089_channel_device::i8089_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i8089_channel_device::i8089_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I8089_CHANNEL, tag, owner, clock), m_write_sintr(*this), m_iop(nullptr), diff --git a/src/devices/cpu/i8089/i8089_channel.h b/src/devices/cpu/i8089/i8089_channel.h index 89aa511193b..c7d7d8aeac4 100644 --- a/src/devices/cpu/i8089/i8089_channel.h +++ b/src/devices/cpu/i8089/i8089_channel.h @@ -25,7 +25,7 @@ class i8089_channel_device : public device_t { public: // construction/destruction - i8089_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8089_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto sintr() { return m_write_sintr.bind(); } diff --git a/src/devices/cpu/i86/i186.cpp b/src/devices/cpu/i86/i186.cpp index 2847607a278..77465ea053c 100644 --- a/src/devices/cpu/i86/i186.cpp +++ b/src/devices/cpu/i86/i186.cpp @@ -133,27 +133,27 @@ DEFINE_DEVICE_TYPE(I80188, i80188_cpu_device, "i80188", "Intel 80188") DEFINE_DEVICE_TYPE(AM186EM, am186em_device, "am186em", "AMD Am186EM") DEFINE_DEVICE_TYPE(AM188EM, am188em_device, "am188em", "AMD Am188EM") -i80186_cpu_device::i80186_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i80186_cpu_device::i80186_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80186_cpu_device(mconfig, I80186, tag, owner, clock, 16) { } -i80188_cpu_device::i80188_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i80188_cpu_device::i80188_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80186_cpu_device(mconfig, I80188, tag, owner, clock, 8) { } -am186em_device::am186em_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am186em_device::am186em_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80186_cpu_device(mconfig, AM186EM, tag, owner, clock, 16) { } -am188em_device::am188em_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am188em_device::am188em_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80186_cpu_device(mconfig, AM188EM, tag, owner, clock, 8) { } -i80186_cpu_device::i80186_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int data_bus_size) +i80186_cpu_device::i80186_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int data_bus_size) : i8086_common_cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, data_bus_size, 20, 0) , m_opcodes_config("opcodes", ENDIANNESS_LITTLE, data_bus_size, 20, 0) diff --git a/src/devices/cpu/i86/i186.h b/src/devices/cpu/i86/i186.h index f1b8c4633ea..8dda202b4bc 100644 --- a/src/devices/cpu/i86/i186.h +++ b/src/devices/cpu/i86/i186.h @@ -16,7 +16,7 @@ class i80186_cpu_device : public i8086_common_cpu_device { public: // construction/destruction - i80186_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i80186_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto read_slave_ack_callback() { return m_read_slave_ack_func.bind(); } auto chip_select_callback() { return m_out_chip_select_func.bind(); } @@ -60,7 +60,7 @@ protected: I80186_POLLSTS }; - i80186_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int data_bus_size); + i80186_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int data_bus_size); // device_execute_interface overrides virtual uint64_t execute_clocks_to_cycles(uint64_t clocks) const noexcept override { return (clocks / 2); } @@ -168,14 +168,14 @@ class i80188_cpu_device : public i80186_cpu_device { public: // construction/destruction - i80188_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i80188_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class am186em_device : public i80186_cpu_device { public: // construction/destruction - am186em_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + am186em_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides @@ -187,7 +187,7 @@ class am188em_device : public i80186_cpu_device { public: // construction/destruction - am188em_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + am188em_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides diff --git a/src/devices/cpu/i86/i286.cpp b/src/devices/cpu/i86/i286.cpp index 2d2f2d1b650..d56b4f99895 100644 --- a/src/devices/cpu/i86/i286.cpp +++ b/src/devices/cpu/i86/i286.cpp @@ -166,7 +166,7 @@ const uint8_t i80286_cpu_device::m_i80286_timing[] = DEFINE_DEVICE_TYPE(I80286, i80286_cpu_device, "i80286", "Intel 80286") -i80286_cpu_device::i80286_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i80286_cpu_device::i80286_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8086_common_cpu_device(mconfig, I80286, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 24, 0) , m_opcodes_config("opcodes", ENDIANNESS_LITTLE, 16, 24, 0) diff --git a/src/devices/cpu/i86/i286.h b/src/devices/cpu/i86/i286.h index 489e7beb099..1454f14c67e 100644 --- a/src/devices/cpu/i86/i286.h +++ b/src/devices/cpu/i86/i286.h @@ -76,7 +76,7 @@ class i80286_cpu_device : public i8086_common_cpu_device { public: // construction/destruction - i80286_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i80286_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_memory_interface overrides virtual space_config_vector memory_space_config() const override; diff --git a/src/devices/cpu/i86/i86.cpp b/src/devices/cpu/i86/i86.cpp index fd85830e86b..446ce7981dc 100644 --- a/src/devices/cpu/i86/i86.cpp +++ b/src/devices/cpu/i86/i86.cpp @@ -90,19 +90,19 @@ const uint8_t i8086_cpu_device::m_i8086_timing[] = DEFINE_DEVICE_TYPE(I8086, i8086_cpu_device, "i8086", "Intel 8086") DEFINE_DEVICE_TYPE(I8088, i8088_cpu_device, "i8088", "Intel 8088") -i8088_cpu_device::i8088_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8088_cpu_device::i8088_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8086_cpu_device(mconfig, I8088, tag, owner, clock, 8) { memcpy(m_timing, m_i8086_timing, sizeof(m_i8086_timing)); } -i8086_cpu_device::i8086_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8086_cpu_device::i8086_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8086_cpu_device(mconfig, I8086, tag, owner, clock, 16) { memcpy(m_timing, m_i8086_timing, sizeof(m_i8086_timing)); } -i8086_cpu_device::i8086_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int data_bus_size) +i8086_cpu_device::i8086_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int data_bus_size) : i8086_common_cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, data_bus_size, 20, 0) , m_opcodes_config("opcodes", ENDIANNESS_LITTLE, data_bus_size, 20, 0) @@ -362,7 +362,7 @@ void i8086_cpu_device::device_start() state_add( I8086_HALT, "HALT", m_halt ).mask(1); } -i8086_common_cpu_device::i8086_common_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +i8086_common_cpu_device::i8086_common_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_ip(0) , m_TF(0) diff --git a/src/devices/cpu/i86/i86.h b/src/devices/cpu/i86/i86.h index f08a8e0c2ba..a3fb2ab4fd8 100644 --- a/src/devices/cpu/i86/i86.h +++ b/src/devices/cpu/i86/i86.h @@ -108,7 +108,7 @@ protected: enum WREGS { AX=0, CX, DX, BX, SP, BP, SI, DI }; // construction/destruction - i8086_common_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + i8086_common_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -345,7 +345,7 @@ public: AS_EXTRA }; // construction/destruction - i8086_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8086_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_memory_interface overrides virtual space_config_vector memory_space_config() const override; @@ -354,7 +354,7 @@ public: auto esc_data_handler() { return m_esc_data_handler.bind(); } protected: - i8086_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int data_bus_size); + i8086_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int data_bus_size); virtual void execute_run() override; virtual void device_start() override; @@ -387,7 +387,7 @@ class i8088_cpu_device : public i8086_cpu_device { public: // construction/destruction - i8088_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8088_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/i860/i860.cpp b/src/devices/cpu/i860/i860.cpp index 0cef6e6bec4..9f56afa8ea4 100644 --- a/src/devices/cpu/i860/i860.cpp +++ b/src/devices/cpu/i860/i860.cpp @@ -34,7 +34,7 @@ enum { DEFINE_DEVICE_TYPE(I860, i860_cpu_device, "i860xr", "Intel i860XR") -i860_cpu_device::i860_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i860_cpu_device::i860_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, I860, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 64, 32, 0) , m_pc(0), m_merge(0), m_pin_bus_hold(0), m_pin_reset(0), m_exiting_readmem(0), m_exiting_ifetch(0), m_pc_updated(0), m_pending_trap(0), m_fir_gets_trap_addr(0), m_single_stepping(0), m_program(nullptr), m_icount(0) diff --git a/src/devices/cpu/i860/i860.h b/src/devices/cpu/i860/i860.h index 3f37dda5b87..a9207ad3491 100644 --- a/src/devices/cpu/i860/i860.h +++ b/src/devices/cpu/i860/i860.h @@ -24,7 +24,7 @@ class i860_cpu_device : public cpu_device { public: // construction/destruction - i860_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i860_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); /* This is the external interface for asserting an external interrupt to the i860. */ diff --git a/src/devices/cpu/i960/i960.cpp b/src/devices/cpu/i960/i960.cpp index 7d87f4955b0..d89689826c4 100644 --- a/src/devices/cpu/i960/i960.cpp +++ b/src/devices/cpu/i960/i960.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(I960, i960_cpu_device, "i960kb", "Intel i960KB") -i960_cpu_device::i960_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i960_cpu_device::i960_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, I960, tag, owner, clock) , m_stalled(false), m_program_config("program", ENDIANNESS_LITTLE, 32, 32, 0) , m_rcache_pos(0), m_SAT(0), m_PRCB(0), m_PC(0), m_AC(0), m_IP(0), m_PIP(0), m_ICR(0), m_immediate_irq(0) diff --git a/src/devices/cpu/i960/i960.h b/src/devices/cpu/i960/i960.h index 1efab1d328a..e8fa1dfff2f 100644 --- a/src/devices/cpu/i960/i960.h +++ b/src/devices/cpu/i960/i960.h @@ -69,7 +69,7 @@ public: static constexpr uint16_t BURST = 0x0001; // construction/destruction - i960_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i960_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void i960_stall() { diff --git a/src/devices/cpu/ie15/ie15.cpp b/src/devices/cpu/ie15/ie15.cpp index d3db6f0ef1b..0bed6be6070 100644 --- a/src/devices/cpu/ie15/ie15.cpp +++ b/src/devices/cpu/ie15/ie15.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(IE15_CPU, ie15_cpu_device, "ie15_cpu", "ie15 CPU") //------------------------------------------------- // ie15_cpu_device - constructor //------------------------------------------------- -ie15_cpu_device::ie15_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ie15_cpu_device::ie15_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, IE15_CPU, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 14) , m_io_config("io", ENDIANNESS_LITTLE, 8, 8), m_A(0), m_CF(0), m_ZF(0), m_RF(0), m_flags(0) diff --git a/src/devices/cpu/ie15/ie15.h b/src/devices/cpu/ie15/ie15.h index a0885ce55f1..b07c7741e41 100644 --- a/src/devices/cpu/ie15/ie15.h +++ b/src/devices/cpu/ie15/ie15.h @@ -13,7 +13,7 @@ class ie15_cpu_device : public cpu_device { public: // construction/destruction - ie15_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ie15_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: enum diff --git a/src/devices/cpu/jaguar/jaguar.cpp b/src/devices/cpu/jaguar/jaguar.cpp index 84d5a999dbb..504fab20b10 100644 --- a/src/devices/cpu/jaguar/jaguar.cpp +++ b/src/devices/cpu/jaguar/jaguar.cpp @@ -149,7 +149,7 @@ DEFINE_DEVICE_TYPE(JAGUARGPU, jaguargpu_cpu_device, "jaguargpu", "Motorola Atari DEFINE_DEVICE_TYPE(JAGUARDSP, jaguardsp_cpu_device, "jaguardsp", "Motorola Atari Jaguar DSP \"Jerry\"") -jaguar_cpu_device::jaguar_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 version, bool isdsp, address_map_constructor io_map) +jaguar_cpu_device::jaguar_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 version, bool isdsp, address_map_constructor io_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 32, 24, 0) , m_io_config("io", ENDIANNESS_BIG, 32, 8, 0, io_map) @@ -190,13 +190,13 @@ jaguar_cpu_device::jaguar_cpu_device(const machine_config &mconfig, device_type } -jaguargpu_cpu_device::jaguargpu_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +jaguargpu_cpu_device::jaguargpu_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : jaguar_cpu_device(mconfig, JAGUARGPU, tag, owner, clock, 2, false, address_map_constructor(FUNC(jaguargpu_cpu_device::io_map), this)) { } -jaguardsp_cpu_device::jaguardsp_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +jaguardsp_cpu_device::jaguardsp_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : jaguar_cpu_device(mconfig, JAGUARDSP, tag, owner, clock, 2, true, address_map_constructor(FUNC(jaguardsp_cpu_device::io_map), this)) { } diff --git a/src/devices/cpu/jaguar/jaguar.h b/src/devices/cpu/jaguar/jaguar.h index 90ee5aef405..b034fc05895 100644 --- a/src/devices/cpu/jaguar/jaguar.h +++ b/src/devices/cpu/jaguar/jaguar.h @@ -64,7 +64,7 @@ public: DECLARE_WRITE_LINE_MEMBER(go_w); protected: - jaguar_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 version, bool isdsp, address_map_constructor io_map); + jaguar_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 version, bool isdsp, address_map_constructor io_map); // device-level overrides virtual void device_start() override; @@ -270,7 +270,7 @@ class jaguargpu_cpu_device : public jaguar_cpu_device { public: // construction/destruction - jaguargpu_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + jaguargpu_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void io_map(address_map &map); @@ -287,7 +287,7 @@ class jaguardsp_cpu_device : public jaguar_cpu_device { public: // construction/destruction - jaguardsp_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + jaguardsp_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void io_map(address_map &map); diff --git a/src/devices/cpu/ks0164/ks0164.cpp b/src/devices/cpu/ks0164/ks0164.cpp index 5b8f57fb776..ca8eabe5cd4 100644 --- a/src/devices/cpu/ks0164/ks0164.cpp +++ b/src/devices/cpu/ks0164/ks0164.cpp @@ -14,7 +14,7 @@ const u16 ks0164_cpu_device::imask[16] = { 0x01ff, 0x03ff, 0x07ff, 0x0fff, 0x1fff, 0x3fff, 0x7fff, 0xffff }; -ks0164_cpu_device::ks0164_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ks0164_cpu_device::ks0164_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, KS0164CPU, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, 16) { diff --git a/src/devices/cpu/ks0164/ks0164.h b/src/devices/cpu/ks0164/ks0164.h index 1df7e6f5e4b..e4a046d8080 100644 --- a/src/devices/cpu/ks0164/ks0164.h +++ b/src/devices/cpu/ks0164/ks0164.h @@ -11,7 +11,7 @@ class ks0164_cpu_device : public cpu_device { public: - ks0164_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ks0164_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: enum { diff --git a/src/devices/cpu/lc8670/lc8670.cpp b/src/devices/cpu/lc8670/lc8670.cpp index d0ab5bbc19d..452b3d118f8 100644 --- a/src/devices/cpu/lc8670/lc8670.cpp +++ b/src/devices/cpu/lc8670/lc8670.cpp @@ -170,7 +170,7 @@ void lc8670_cpu_device::lc8670_internal_map(address_map &map) // lc8670_cpu_device - constructor //------------------------------------------------- -lc8670_cpu_device::lc8670_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lc8670_cpu_device::lc8670_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, LC8670, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, 16, 0) , m_data_config("data", ENDIANNESS_BIG, 8, 9, 0, address_map_constructor(FUNC(lc8670_cpu_device::lc8670_internal_map), this)) diff --git a/src/devices/cpu/lc8670/lc8670.h b/src/devices/cpu/lc8670/lc8670.h index a00658a7d4d..946850e1957 100644 --- a/src/devices/cpu/lc8670/lc8670.h +++ b/src/devices/cpu/lc8670/lc8670.h @@ -68,7 +68,7 @@ public: void xram_w(offs_t offset, uint8_t data); // configuration helpers - void set_cpu_clock(clock_source source, uint32_t clock) { m_clocks[unsigned(source)] = clock; } + void set_cpu_clock(clock_source source, const XTAL &clock) { m_clocks[unsigned(source)] = clock; } void set_cpu_clock(clock_source source, const XTAL &clock) { set_cpu_clock(source, clock.value()); } template <typename T, typename U, typename V> void set_clock_sources(T &&sub_clock, U &&rc_clock, V &&cf_clock) diff --git a/src/devices/cpu/lh5801/lh5801.cpp b/src/devices/cpu/lh5801/lh5801.cpp index 3f9045ae57e..ce7e8f7610b 100644 --- a/src/devices/cpu/lh5801/lh5801.cpp +++ b/src/devices/cpu/lh5801/lh5801.cpp @@ -65,7 +65,7 @@ enum DEFINE_DEVICE_TYPE(LH5801, lh5801_cpu_device, "lh5801", "Sharp LH5801") -lh5801_cpu_device::lh5801_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lh5801_cpu_device::lh5801_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, LH5801, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0) , m_io_config("io", ENDIANNESS_LITTLE, 8, 16, 0) diff --git a/src/devices/cpu/lh5801/lh5801.h b/src/devices/cpu/lh5801/lh5801.h index 68c028289af..9f9a20376a4 100644 --- a/src/devices/cpu/lh5801/lh5801.h +++ b/src/devices/cpu/lh5801/lh5801.h @@ -64,7 +64,7 @@ class lh5801_cpu_device : public cpu_device { public: // construction/destruction - lh5801_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + lh5801_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto in_func() { return m_in_func.bind(); } diff --git a/src/devices/cpu/lr35902/lr35902.cpp b/src/devices/cpu/lr35902/lr35902.cpp index 86eba6464d2..227eda6c369 100644 --- a/src/devices/cpu/lr35902/lr35902.cpp +++ b/src/devices/cpu/lr35902/lr35902.cpp @@ -63,7 +63,7 @@ enum lr35902_flag DEFINE_DEVICE_TYPE(LR35902, lr35902_cpu_device, "lr35902", "Sharp LR35902") -lr35902_cpu_device::lr35902_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lr35902_cpu_device::lr35902_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, LR35902, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0) , m_A(0) diff --git a/src/devices/cpu/lr35902/lr35902.h b/src/devices/cpu/lr35902/lr35902.h index f723213137c..75f36d09486 100644 --- a/src/devices/cpu/lr35902/lr35902.h +++ b/src/devices/cpu/lr35902/lr35902.h @@ -20,7 +20,7 @@ class lr35902_cpu_device : public cpu_device { public: // construction/destruction - lr35902_cpu_device(const machine_config &mconfig, const char *_tag, device_t *_owner, uint32_t _clock); + lr35902_cpu_device(const machine_config &mconfig, const char *_tag, device_t *_owner, const XTAL &_clock); // configuration helpers auto timer_cb() { return m_timer_func.bind(); } diff --git a/src/devices/cpu/m37710/m37710.cpp b/src/devices/cpu/m37710/m37710.cpp index 6ca096d1e4f..9d0ed9ea66b 100644 --- a/src/devices/cpu/m37710/m37710.cpp +++ b/src/devices/cpu/m37710/m37710.cpp @@ -334,7 +334,7 @@ void m37732s4_device::map(address_map &map) // many other combinations of RAM and ROM size exist -m37710_cpu_device::m37710_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor map_delegate) +m37710_cpu_device::m37710_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map_delegate) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 24, 0, map_delegate) , m_port_in_cb(*this) @@ -344,40 +344,40 @@ m37710_cpu_device::m37710_cpu_device(const machine_config &mconfig, device_type } -m37702m2_device::m37702m2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m37702m2_device::m37702m2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m37702m2_device(mconfig, M37702M2, tag, owner, clock) { } -m37702m2_device::m37702m2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +m37702m2_device::m37702m2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m37710_cpu_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(m37702m2_device::map), this)) { } -m37702s1_device::m37702s1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m37702s1_device::m37702s1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m37710_cpu_device(mconfig, M37702S1, tag, owner, clock, address_map_constructor(FUNC(m37702s1_device::map), this)) { } -m37710s4_device::m37710s4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m37710s4_device::m37710s4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m37710_cpu_device(mconfig, M37710S4, tag, owner, clock, address_map_constructor(FUNC(m37710s4_device::map), this)) { } -m37720s1_device::m37720s1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m37720s1_device::m37720s1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m37710_cpu_device(mconfig, M37720S1, tag, owner, clock, address_map_constructor(FUNC(m37720s1_device::map), this)) { } -m37730s2_device::m37730s2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m37730s2_device::m37730s2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m37710_cpu_device(mconfig, M37730S2, tag, owner, clock, address_map_constructor(FUNC(m37730s2_device::map), this)) { } -m37732s4_device::m37732s4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m37732s4_device::m37732s4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m37710_cpu_device(mconfig, M37732S4, tag, owner, clock, address_map_constructor(FUNC(m37732s4_device::map), this)) { } diff --git a/src/devices/cpu/m37710/m37710.h b/src/devices/cpu/m37710/m37710.h index 6426c2eb54f..3ac8036c81c 100644 --- a/src/devices/cpu/m37710/m37710.h +++ b/src/devices/cpu/m37710/m37710.h @@ -197,7 +197,7 @@ protected: void set_int_control(int level, uint8_t data); // construction/destruction - m37710_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor map_delegate); + m37710_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map_delegate); // device-level overrides virtual void device_start() override; @@ -2144,7 +2144,7 @@ class m37702s1_device : public m37710_cpu_device { public: // construction/destruction - m37702s1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m37702s1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void map(address_map &map); }; @@ -2153,9 +2153,9 @@ class m37702m2_device : public m37710_cpu_device { public: // construction/destruction - m37702m2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m37702m2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - m37702m2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m37702m2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void map(address_map &map); }; @@ -2163,7 +2163,7 @@ class m37710s4_device : public m37710_cpu_device { public: // construction/destruction - m37710s4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m37710s4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void map(address_map &map); }; @@ -2172,7 +2172,7 @@ class m37720s1_device : public m37710_cpu_device { public: // construction/destruction - m37720s1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m37720s1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void map(address_map &map); }; @@ -2181,7 +2181,7 @@ class m37730s2_device : public m37710_cpu_device { public: // construction/destruction - m37730s2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m37730s2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void map(address_map &map); }; @@ -2190,7 +2190,7 @@ class m37732s4_device : public m37710_cpu_device { public: // construction/destruction - m37732s4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m37732s4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void map(address_map &map); }; diff --git a/src/devices/cpu/m6502/deco16.cpp b/src/devices/cpu/m6502/deco16.cpp index acd9983cc12..0b16a6db8b3 100644 --- a/src/devices/cpu/m6502/deco16.cpp +++ b/src/devices/cpu/m6502/deco16.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(DECO16, deco16_device, "deco16", "Data East DECO16") -deco16_device::deco16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +deco16_device::deco16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, DECO16, tag, owner, clock), io(nullptr), io_config("io", ENDIANNESS_LITTLE, 8, 16) diff --git a/src/devices/cpu/m6502/deco16.h b/src/devices/cpu/m6502/deco16.h index 63494f6b1d4..0d170f43df0 100644 --- a/src/devices/cpu/m6502/deco16.h +++ b/src/devices/cpu/m6502/deco16.h @@ -16,7 +16,7 @@ class deco16_device : public m6502_device { public: - deco16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + deco16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/m6502/m3745x.cpp b/src/devices/cpu/m6502/m3745x.cpp index 20b881f217e..60c23046544 100644 --- a/src/devices/cpu/m6502/m3745x.cpp +++ b/src/devices/cpu/m6502/m3745x.cpp @@ -37,7 +37,7 @@ DEFINE_DEVICE_TYPE(M37450, m37450_device, "m37450", "Mitsubishi M37450") //------------------------------------------------- // m3745x_device - constructor //------------------------------------------------- -m3745x_device::m3745x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map) : +m3745x_device::m3745x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map) : m740_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0, internal_map), m_read_p(*this), @@ -393,12 +393,12 @@ void m37450_device::m37450_map(address_map &map) map(0x0100, 0x01ff).ram(); } -m37450_device::m37450_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m37450_device::m37450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m37450_device(mconfig, M37450, tag, owner, clock) { } -m37450_device::m37450_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +m37450_device::m37450_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m3745x_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(m37450_device::m37450_map), this)) { } diff --git a/src/devices/cpu/m6502/m3745x.h b/src/devices/cpu/m6502/m3745x.h index bab3558e0a2..c98c3d32f7c 100644 --- a/src/devices/cpu/m6502/m3745x.h +++ b/src/devices/cpu/m6502/m3745x.h @@ -53,7 +53,7 @@ public: protected: // construction/destruction - m3745x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map); + m3745x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map); // device-level overrides virtual void device_start() override; @@ -88,11 +88,11 @@ private: class m37450_device : public m3745x_device { public: - m37450_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m37450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void m37450_map(address_map &map); protected: - m37450_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m37450_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(M37450, m37450_device) diff --git a/src/devices/cpu/m6502/m4510.cpp b/src/devices/cpu/m6502/m4510.cpp index aa29a820dcd..56867b2a3ea 100644 --- a/src/devices/cpu/m6502/m4510.cpp +++ b/src/devices/cpu/m6502/m4510.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(M4510, m4510_device, "m4510", "CSG 4510") -m4510_device::m4510_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m4510_device::m4510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m65ce02_device(mconfig, M4510, tag, owner, clock), map_enable(0), nomap(false) diff --git a/src/devices/cpu/m6502/m4510.h b/src/devices/cpu/m6502/m4510.h index eb6cf818489..fdbf3831a39 100644 --- a/src/devices/cpu/m6502/m4510.h +++ b/src/devices/cpu/m6502/m4510.h @@ -17,7 +17,7 @@ class m4510_device : public m65ce02_device { public: - m4510_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m4510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/m6502/m50734.cpp b/src/devices/cpu/m6502/m50734.cpp index b4e31f003c7..bd6cb72cf2f 100644 --- a/src/devices/cpu/m6502/m50734.cpp +++ b/src/devices/cpu/m6502/m50734.cpp @@ -23,7 +23,7 @@ // device type definition DEFINE_DEVICE_TYPE(M50734, m50734_device, "m50734", "Mitsubishi M50734") -m50734_device::m50734_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m50734_device::m50734_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m740_device(mconfig, M50734, tag, owner, clock) , m_data_config("data", ENDIANNESS_LITTLE, 8, 16, 0) , m_port_in_cb(*this) diff --git a/src/devices/cpu/m6502/m50734.h b/src/devices/cpu/m6502/m50734.h index 0c98f86aa31..2e48f4c5cd5 100644 --- a/src/devices/cpu/m6502/m50734.h +++ b/src/devices/cpu/m6502/m50734.h @@ -54,7 +54,7 @@ public: //enum { //}; - m50734_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m50734_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // port callback configuration auto p0_in_cb() { return m_port_in_cb[0].bind(); } diff --git a/src/devices/cpu/m6502/m5074x.cpp b/src/devices/cpu/m6502/m5074x.cpp index 2d961b694a5..ca272aec3b5 100644 --- a/src/devices/cpu/m6502/m5074x.cpp +++ b/src/devices/cpu/m6502/m5074x.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(M50753, m50753_device, "m50753", "Mitsubishi M50753") //------------------------------------------------- // m5074x_device - constructor //------------------------------------------------- -m5074x_device::m5074x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int addrbits, address_map_constructor internal_map) : +m5074x_device::m5074x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addrbits, address_map_constructor internal_map) : m740_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 8, addrbits, 0, internal_map), m_read_p(*this), @@ -231,13 +231,13 @@ void m5074x_device::recalc_timer(int timer) switch (timer) { case 0: - hz = clock() / 16; + hz = clock().value() / 16; hz /= (m_tmr12pre + 2); m_timers[TIMER_1]->adjust(attotime::from_hz(hz), 0, attotime::from_hz(hz)); break; case 1: - hz = clock() / 16; + hz = clock().value() / 16; hz /= (m_tmr12pre + 2); m_timers[TIMER_2]->adjust(attotime::from_hz(hz), 0, attotime::from_hz(hz)); break; @@ -254,7 +254,7 @@ void m5074x_device::recalc_timer(int timer) } else { - hz = clock() / 16; + hz = clock().value() / 16; hz /= (m_tmrxpre + 2); m_timers[TIMER_X]->adjust(attotime::from_hz(hz), 0, attotime::from_hz(hz)); } @@ -458,12 +458,12 @@ void m50740_device::m50740_map(address_map &map) map(0x1400, 0x1fff).rom().region(DEVICE_SELF, 0); } -m50740_device::m50740_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m50740_device::m50740_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m50740_device(mconfig, M50740, tag, owner, clock) { } -m50740_device::m50740_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +m50740_device::m50740_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m5074x_device(mconfig, type, tag, owner, clock, 13, address_map_constructor(FUNC(m50740_device::m50740_map), this)) { } @@ -477,12 +477,12 @@ void m50741_device::m50741_map(address_map &map) map(0x1000, 0x1fff).rom().region(DEVICE_SELF, 0); } -m50741_device::m50741_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m50741_device::m50741_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m50741_device(mconfig, M50741, tag, owner, clock) { } -m50741_device::m50741_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +m50741_device::m50741_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m5074x_device(mconfig, type, tag, owner, clock, 13, address_map_constructor(FUNC(m50741_device::m50741_map), this)) { } @@ -506,12 +506,12 @@ static constexpr u8 IRQ_50753_INT1REQ = 0x80; static constexpr u8 IRQ_50753_INTADC = 0x20; static constexpr u8 IRQ_50753_INT2REQ = 0x02; -m50753_device::m50753_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m50753_device::m50753_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m50753_device(mconfig, M50753, tag, owner, clock) { } -m50753_device::m50753_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +m50753_device::m50753_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m5074x_device(mconfig, type, tag, owner, clock, 16, address_map_constructor(FUNC(m50753_device::m50753_map), this)), m_ad_in(*this), m_in_p(*this), diff --git a/src/devices/cpu/m6502/m5074x.h b/src/devices/cpu/m6502/m5074x.h index 2b860a56e83..21f0b21402b 100644 --- a/src/devices/cpu/m6502/m5074x.h +++ b/src/devices/cpu/m6502/m5074x.h @@ -51,7 +51,7 @@ public: protected: // construction/destruction - m5074x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int addrbits, address_map_constructor internal_map); + m5074x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addrbits, address_map_constructor internal_map); // device-level overrides virtual void device_start() override; @@ -90,10 +90,10 @@ private: class m50740_device : public m5074x_device { public: - m50740_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m50740_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - m50740_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m50740_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); private: void m50740_map(address_map &map); @@ -102,10 +102,10 @@ private: class m50741_device : public m5074x_device { public: - m50741_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m50741_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - m50741_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m50741_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); private: void m50741_map(address_map &map); @@ -114,7 +114,7 @@ private: class m50753_device : public m5074x_device { public: - m50753_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m50753_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); enum { @@ -127,7 +127,7 @@ public: auto read_in_p() { return m_in_p.bind(); } protected: - m50753_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m50753_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/m6502/m6500_1.cpp b/src/devices/cpu/m6502/m6500_1.cpp index 5767899755e..c40582e13b3 100644 --- a/src/devices/cpu/m6502/m6500_1.cpp +++ b/src/devices/cpu/m6502/m6500_1.cpp @@ -91,7 +91,7 @@ constexpr u8 CR_CTRO = 0x80U; DEFINE_DEVICE_TYPE(M6500_1, m6500_1_device, "m6500_1", "MOS Technology 6500/1"); -m6500_1_device::m6500_1_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +m6500_1_device::m6500_1_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m6502_mcu_device(mconfig, M6500_1, tag, owner, clock) , m_port_in_cb{ *this } , m_port_out_cb{ *this } diff --git a/src/devices/cpu/m6502/m6500_1.h b/src/devices/cpu/m6502/m6500_1.h index 0a4a07a6ff9..45cc3acea90 100644 --- a/src/devices/cpu/m6502/m6500_1.h +++ b/src/devices/cpu/m6502/m6500_1.h @@ -44,7 +44,7 @@ class m6500_1_device : public m6502_mcu_device { public: - m6500_1_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m6500_1_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); auto pa_in_cb() { return m_port_in_cb[0].bind(); } auto pb_in_cb() { return m_port_in_cb[1].bind(); } diff --git a/src/devices/cpu/m6502/m6502.cpp b/src/devices/cpu/m6502/m6502.cpp index 55276aeba00..eece2c86708 100644 --- a/src/devices/cpu/m6502/m6502.cpp +++ b/src/devices/cpu/m6502/m6502.cpp @@ -15,17 +15,17 @@ DEFINE_DEVICE_TYPE(M6502, m6502_device, "m6502", "MOS Technology 6502") DEFINE_DEVICE_TYPE(M6512, m6512_device, "m6512", "MOS Technology 6512") -m6502_device::m6502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m6502_device::m6502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, M6502, tag, owner, clock) { } -m6512_device::m6512_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m6512_device::m6512_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, M6512, tag, owner, clock) { } -m6502_device::m6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +m6502_device::m6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock), sync_w(*this), program_config("program", ENDIANNESS_LITTLE, 8, 16), @@ -565,7 +565,7 @@ void m6502_device::mi_default14::write(uint16_t adr, uint8_t val) program14.write_byte(adr, val); } -m6502_mcu_device::m6502_mcu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +m6502_mcu_device::m6502_mcu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/m6502.h b/src/devices/cpu/m6502/m6502.h index 4b05d7a0846..445050e739e 100644 --- a/src/devices/cpu/m6502/m6502.h +++ b/src/devices/cpu/m6502/m6502.h @@ -35,7 +35,7 @@ public: virtual void write_9(uint16_t adr, uint8_t val); }; - m6502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_address_width(int width, bool custom_interface) { program_config.m_addr_width = width; @@ -54,7 +54,7 @@ public: devcb_write_line sync_w; protected: - m6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m6502_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); class mi_default : public memory_interface { public: @@ -278,7 +278,7 @@ protected: class m6502_mcu_device : public m6502_device { protected: - m6502_mcu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m6502_mcu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void internal_update() { internal_update(total_cycles()); } virtual void internal_update(uint64_t current_time) = 0; @@ -290,7 +290,7 @@ protected: class m6512_device : public m6502_device { public: - m6512_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6512_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; enum { diff --git a/src/devices/cpu/m6502/m6504.cpp b/src/devices/cpu/m6502/m6504.cpp index 51859f178f5..5d34e784249 100644 --- a/src/devices/cpu/m6502/m6504.cpp +++ b/src/devices/cpu/m6502/m6504.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(M6504, m6504_device, "m6504", "MOS Technology 6504") -m6504_device::m6504_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m6504_device::m6504_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, M6504, tag, owner, clock) { program_config.m_addr_width = 13; diff --git a/src/devices/cpu/m6502/m6504.h b/src/devices/cpu/m6502/m6504.h index bf4dee43a76..83dfe25b22c 100644 --- a/src/devices/cpu/m6502/m6504.h +++ b/src/devices/cpu/m6502/m6504.h @@ -15,7 +15,7 @@ class m6504_device : public m6502_device { public: - m6504_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6504_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/m6502/m6507.cpp b/src/devices/cpu/m6502/m6507.cpp index 7a102e4b110..6ec2a023881 100644 --- a/src/devices/cpu/m6502/m6507.cpp +++ b/src/devices/cpu/m6502/m6507.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(M6507, m6507_device, "m6507", "MOS Technology 6507") -m6507_device::m6507_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m6507_device::m6507_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, M6507, tag, owner, clock) { program_config.m_addr_width = 13; diff --git a/src/devices/cpu/m6502/m6507.h b/src/devices/cpu/m6502/m6507.h index 50466608d2a..037dc7a7c87 100644 --- a/src/devices/cpu/m6502/m6507.h +++ b/src/devices/cpu/m6502/m6507.h @@ -15,7 +15,7 @@ class m6507_device : public m6502_device { public: - m6507_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6507_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/m6502/m6509.cpp b/src/devices/cpu/m6502/m6509.cpp index 3ffbeda05fc..212ca66171f 100644 --- a/src/devices/cpu/m6502/m6509.cpp +++ b/src/devices/cpu/m6502/m6509.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(M6509, m6509_device, "m6509", "MOS Technology 6509") -m6509_device::m6509_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m6509_device::m6509_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, M6509, tag, owner, clock), bank_i(0), bank_y(0) { program_config.m_addr_width = 20; diff --git a/src/devices/cpu/m6502/m6509.h b/src/devices/cpu/m6502/m6509.h index 4359c691c0e..d86f14e2d0c 100644 --- a/src/devices/cpu/m6502/m6509.h +++ b/src/devices/cpu/m6502/m6509.h @@ -15,7 +15,7 @@ class m6509_device : public m6502_device { public: - m6509_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6509_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; virtual void do_exec_full() override; diff --git a/src/devices/cpu/m6502/m6510.cpp b/src/devices/cpu/m6502/m6510.cpp index 706c1407fcb..2188fa17802 100644 --- a/src/devices/cpu/m6502/m6510.cpp +++ b/src/devices/cpu/m6502/m6510.cpp @@ -18,12 +18,12 @@ DEFINE_DEVICE_TYPE(M6510, m6510_device, "m6510", "MOS Technology 6510") DEFINE_DEVICE_TYPE(M6508, m6508_device, "m6508", "MOS Technology 6508") -m6510_device::m6510_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m6510_device::m6510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6510_device(mconfig, M6510, tag, owner, clock) { } -m6510_device::m6510_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +m6510_device::m6510_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, type, tag, owner, clock), read_port(*this), write_port(*this), dir(0), port(0), drive(0) @@ -151,7 +151,7 @@ void m6510_device::mi_6510::write(uint16_t adr, uint8_t val) } -m6508_device::m6508_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m6508_device::m6508_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6510_device(mconfig, M6508, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/m6510.h b/src/devices/cpu/m6502/m6510.h index 284bc885180..6e96f36bd6d 100644 --- a/src/devices/cpu/m6502/m6510.h +++ b/src/devices/cpu/m6502/m6510.h @@ -16,7 +16,7 @@ class m6510_device : public m6502_device { public: - m6510_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t get_port(); void set_pulls(uint8_t pullup, uint8_t pulldown); @@ -29,7 +29,7 @@ public: virtual void do_exec_partial() override; protected: - m6510_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m6510_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); class mi_6510 : public memory_interface { public: @@ -75,7 +75,7 @@ protected: class m6508_device : public m6510_device { public: - m6508_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6508_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/cpu/m6502/m6510t.cpp b/src/devices/cpu/m6502/m6510t.cpp index a8b543a8198..6094a20ff29 100644 --- a/src/devices/cpu/m6502/m6510t.cpp +++ b/src/devices/cpu/m6502/m6510t.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(M6510T, m6510t_device, "m6510t", "MOS Technology 6510T") -m6510t_device::m6510t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m6510t_device::m6510t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6510_device(mconfig, M6510T, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/m6510t.h b/src/devices/cpu/m6502/m6510t.h index 20db82b97e9..47fa8063355 100644 --- a/src/devices/cpu/m6502/m6510t.h +++ b/src/devices/cpu/m6502/m6510t.h @@ -15,7 +15,7 @@ class m6510t_device : public m6510_device { public: - m6510t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6510t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; enum { diff --git a/src/devices/cpu/m6502/m65c02.cpp b/src/devices/cpu/m6502/m65c02.cpp index fbfd2964f20..61d8b09c3e2 100644 --- a/src/devices/cpu/m6502/m65c02.cpp +++ b/src/devices/cpu/m6502/m65c02.cpp @@ -15,12 +15,12 @@ DEFINE_DEVICE_TYPE(M65C02, m65c02_device, "m65c02", "WDC W65C02") -m65c02_device::m65c02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m65c02_device::m65c02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, M65C02, tag, owner, clock) { } -m65c02_device::m65c02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +m65c02_device::m65c02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/m65c02.h b/src/devices/cpu/m6502/m65c02.h index 5a89f301236..3f2a39e6871 100644 --- a/src/devices/cpu/m6502/m65c02.h +++ b/src/devices/cpu/m6502/m65c02.h @@ -17,14 +17,14 @@ class m65c02_device : public m6502_device { public: - m65c02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m65c02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; virtual void do_exec_full() override; virtual void do_exec_partial() override; protected: - m65c02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m65c02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); #define O(o) void o ## _full(); void o ## _partial() diff --git a/src/devices/cpu/m6502/m65ce02.cpp b/src/devices/cpu/m6502/m65ce02.cpp index e6f80e4df09..88c391e7a6b 100644 --- a/src/devices/cpu/m6502/m65ce02.cpp +++ b/src/devices/cpu/m6502/m65ce02.cpp @@ -14,12 +14,12 @@ DEFINE_DEVICE_TYPE(M65CE02, m65ce02_device, "m65ce02", "CSG 65CE02") -m65ce02_device::m65ce02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m65ce02_device::m65ce02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m65ce02_device(mconfig, M65CE02, tag, owner, clock) { } -m65ce02_device::m65ce02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +m65ce02_device::m65ce02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m65c02_device(mconfig, type, tag, owner, clock), TMP3(0), Z(0), B(0) { } diff --git a/src/devices/cpu/m6502/m65ce02.h b/src/devices/cpu/m6502/m65ce02.h index 6e27c66e010..159e214f75f 100644 --- a/src/devices/cpu/m6502/m65ce02.h +++ b/src/devices/cpu/m6502/m65ce02.h @@ -16,14 +16,14 @@ class m65ce02_device : public m65c02_device { public: - m65ce02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m65ce02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; virtual void do_exec_full() override; virtual void do_exec_partial() override; protected: - m65ce02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m65ce02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); uint16_t TMP3; /* temporary internal values */ uint8_t Z; /* Z index register */ diff --git a/src/devices/cpu/m6502/m65sc02.cpp b/src/devices/cpu/m6502/m65sc02.cpp index 93a9f18c7b6..9dc161f973a 100644 --- a/src/devices/cpu/m6502/m65sc02.cpp +++ b/src/devices/cpu/m6502/m65sc02.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(M65SC02, m65sc02_device, "m65sc02", "GTE G65SC02") -m65sc02_device::m65sc02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m65sc02_device::m65sc02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : r65c02_device(mconfig, M65SC02, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/m65sc02.h b/src/devices/cpu/m6502/m65sc02.h index 686411c0b22..6ebd3602792 100644 --- a/src/devices/cpu/m6502/m65sc02.h +++ b/src/devices/cpu/m6502/m65sc02.h @@ -15,7 +15,7 @@ class m65sc02_device : public r65c02_device { public: - m65sc02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m65sc02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; enum { diff --git a/src/devices/cpu/m6502/m740.cpp b/src/devices/cpu/m6502/m740.cpp index d9feb8071d5..e1494e0e7fa 100644 --- a/src/devices/cpu/m6502/m740.cpp +++ b/src/devices/cpu/m6502/m740.cpp @@ -11,7 +11,7 @@ #include "emu.h" #include "m740.h" -m740_device::m740_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +m740_device::m740_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, type, tag, owner, clock), m_irq_multiplex(0), m_irq_vector(0) { } diff --git a/src/devices/cpu/m6502/m740.h b/src/devices/cpu/m6502/m740.h index de483675f81..a1a243bf258 100644 --- a/src/devices/cpu/m6502/m740.h +++ b/src/devices/cpu/m6502/m740.h @@ -51,7 +51,7 @@ protected: virtual void do_exec_partial() override; virtual void execute_set_input(int inputnum, int state) override; - m740_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + m740_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); #define O(o) void o ## _full(); void o ## _partial() diff --git a/src/devices/cpu/m6502/m7501.cpp b/src/devices/cpu/m6502/m7501.cpp index 912a7a023dd..b5b86dde7d3 100644 --- a/src/devices/cpu/m6502/m7501.cpp +++ b/src/devices/cpu/m6502/m7501.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(M7501, m7501_device, "m7501", "M7501") -m7501_device::m7501_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m7501_device::m7501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6510_device(mconfig, M7501, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/m7501.h b/src/devices/cpu/m6502/m7501.h index baa26668fab..88c711df2db 100644 --- a/src/devices/cpu/m6502/m7501.h +++ b/src/devices/cpu/m6502/m7501.h @@ -15,7 +15,7 @@ class m7501_device : public m6510_device { public: - m7501_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m7501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; enum { diff --git a/src/devices/cpu/m6502/m8502.cpp b/src/devices/cpu/m6502/m8502.cpp index 356ed95c0fe..f956a98a08f 100644 --- a/src/devices/cpu/m6502/m8502.cpp +++ b/src/devices/cpu/m6502/m8502.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(M8502, m8502_device, "m8502", "MOS Technology 8502") -m8502_device::m8502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m8502_device::m8502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6510_device(mconfig, M8502, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/m8502.h b/src/devices/cpu/m6502/m8502.h index cdd9c8c702f..734d5509e88 100644 --- a/src/devices/cpu/m6502/m8502.h +++ b/src/devices/cpu/m6502/m8502.h @@ -16,7 +16,7 @@ class m8502_device : public m6510_device { public: - m8502_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m8502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; enum { diff --git a/src/devices/cpu/m6502/r65c02.cpp b/src/devices/cpu/m6502/r65c02.cpp index 190f370c933..ecda0a9f29d 100644 --- a/src/devices/cpu/m6502/r65c02.cpp +++ b/src/devices/cpu/m6502/r65c02.cpp @@ -14,12 +14,12 @@ DEFINE_DEVICE_TYPE(R65C02, r65c02_device, "r65c02", "Rockwell R65C02") -r65c02_device::r65c02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +r65c02_device::r65c02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : r65c02_device(mconfig, R65C02, tag, owner, clock) { } -r65c02_device::r65c02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +r65c02_device::r65c02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m65c02_device(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/r65c02.h b/src/devices/cpu/m6502/r65c02.h index a28ccd9d932..2e8fa666d68 100644 --- a/src/devices/cpu/m6502/r65c02.h +++ b/src/devices/cpu/m6502/r65c02.h @@ -15,14 +15,14 @@ class r65c02_device : public m65c02_device { public: - r65c02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + r65c02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; virtual void do_exec_full() override; virtual void do_exec_partial() override; protected: - r65c02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + r65c02_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; enum { diff --git a/src/devices/cpu/m6502/r65c19.cpp b/src/devices/cpu/m6502/r65c19.cpp index ffd6c3ee2db..d685b3e6703 100644 --- a/src/devices/cpu/m6502/r65c19.cpp +++ b/src/devices/cpu/m6502/r65c19.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(R65C19, r65c19_device, "r65c19", "Rockwell R65C19 MCU") DEFINE_DEVICE_TYPE(L2800, l2800_device, "l2800", "Rockwell L2800 MCU") -r65c19_device::r65c19_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor internal_map) +r65c19_device::r65c19_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map) : r65c02_device(mconfig, type, tag, owner, clock) , m_w(0) , m_i(0) @@ -26,19 +26,19 @@ r65c19_device::r65c19_device(const machine_config &mconfig, device_type type, co program_config.m_internal_map = std::move(internal_map); } -r65c19_device::r65c19_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +r65c19_device::r65c19_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : r65c19_device(mconfig, R65C19, tag, owner, clock, address_map_constructor()) { } -c39_device::c39_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor internal_map) +c39_device::c39_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map) : r65c19_device(mconfig, type, tag, owner, clock, internal_map) , m_exp_config("expansion", ENDIANNESS_LITTLE, 8, 21, 0) , m_es4_config("es4", ENDIANNESS_LITTLE, 8, 9, 0) { } -l2800_device::l2800_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +l2800_device::l2800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c39_device(mconfig, L2800, tag, owner, clock, address_map_constructor(FUNC(l2800_device::internal_map), this)) { } diff --git a/src/devices/cpu/m6502/r65c19.h b/src/devices/cpu/m6502/r65c19.h index 6f018fb661b..20cd9fe7442 100644 --- a/src/devices/cpu/m6502/r65c19.h +++ b/src/devices/cpu/m6502/r65c19.h @@ -18,10 +18,10 @@ public: R65C19_I }; - r65c19_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + r65c19_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - r65c19_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor internal_map); + r65c19_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map); virtual void device_start() override; virtual void device_reset() override; @@ -110,7 +110,7 @@ public: }; protected: - c39_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor internal_map); + c39_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map); virtual space_config_vector memory_space_config() const override; @@ -153,7 +153,7 @@ private: class l2800_device : public c39_device { public: - l2800_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + l2800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: void internal_map(address_map &map); diff --git a/src/devices/cpu/m6502/rp2a03.cpp b/src/devices/cpu/m6502/rp2a03.cpp index 25e43144db8..c14b3995445 100644 --- a/src/devices/cpu/m6502/rp2a03.cpp +++ b/src/devices/cpu/m6502/rp2a03.cpp @@ -53,19 +53,19 @@ void rp2a03_device::rp2a03_map(address_map &map) -rp2a03_core_device::rp2a03_core_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +rp2a03_core_device::rp2a03_core_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, type, tag, owner, clock) { } -rp2a03_core_device::rp2a03_core_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rp2a03_core_device::rp2a03_core_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rp2a03_core_device(mconfig, RP2A03_CORE, tag, owner, clock) { } -rp2a03_device::rp2a03_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +rp2a03_device::rp2a03_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : rp2a03_core_device(mconfig, type, tag, owner, clock) , device_mixer_interface(mconfig, *this, 1) , m_apu(*this, "nesapu") @@ -73,12 +73,12 @@ rp2a03_device::rp2a03_device(const machine_config &mconfig, device_type type, co program_config.m_internal_map = address_map_constructor(FUNC(rp2a03_device::rp2a03_map), this); } -rp2a03_device::rp2a03_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rp2a03_device::rp2a03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rp2a03_device(mconfig, RP2A03, tag, owner, clock) { } -rp2a03g_device::rp2a03g_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rp2a03g_device::rp2a03g_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rp2a03_device(mconfig, RP2A03G, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/rp2a03.h b/src/devices/cpu/m6502/rp2a03.h index 412837cd885..99079341623 100644 --- a/src/devices/cpu/m6502/rp2a03.h +++ b/src/devices/cpu/m6502/rp2a03.h @@ -17,7 +17,7 @@ class rp2a03_core_device : public m6502_device { public: - rp2a03_core_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rp2a03_core_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -25,7 +25,7 @@ public: virtual void do_exec_partial() override; protected: - rp2a03_core_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + rp2a03_core_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); #define O(o) void o ## _full(); void o ## _partial() @@ -43,7 +43,7 @@ private: class rp2a03_device : public rp2a03_core_device, public device_mixer_interface { public: - rp2a03_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rp2a03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t psg1_4014_r(); uint8_t psg1_4015_r(); @@ -53,7 +53,7 @@ public: void rp2a03_map(address_map &map); protected: - rp2a03_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + rp2a03_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); required_device<nesapu_device> m_apu; @@ -66,7 +66,7 @@ protected: class rp2a03g_device : public rp2a03_device { public: - rp2a03g_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rp2a03g_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/cpu/m6502/st2204.cpp b/src/devices/cpu/m6502/st2204.cpp index 0e8541be87a..dc1fb605de4 100644 --- a/src/devices/cpu/m6502/st2204.cpp +++ b/src/devices/cpu/m6502/st2204.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(ST2202, st2202_device, "st2202", "Sitronix ST2202 Integrated Microcontroller") DEFINE_DEVICE_TYPE(ST2204, st2204_device, "st2204", "Sitronix ST2204 Integrated Microcontroller") -st2204_device::st2204_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map) +st2204_device::st2204_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map) : st2xxx_device(mconfig, type, tag, owner, clock, map, 26, false) // logical; only 23 address lines are brought out , m_dac_callback(*this) , m_tmode{0} @@ -58,12 +58,12 @@ st2204_device::st2204_device(const machine_config &mconfig, device_type type, co { } -st2204_device::st2204_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +st2204_device::st2204_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : st2204_device(mconfig, ST2204, tag, owner, clock, address_map_constructor(FUNC(st2204_device::int_map), this)) { } -st2202_device::st2202_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +st2202_device::st2202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : st2204_device(mconfig, ST2202, tag, owner, clock, address_map_constructor(FUNC(st2202_device::int_map), this)) { } diff --git a/src/devices/cpu/m6502/st2204.h b/src/devices/cpu/m6502/st2204.h index c1fbe707fd9..f30b3765f50 100644 --- a/src/devices/cpu/m6502/st2204.h +++ b/src/devices/cpu/m6502/st2204.h @@ -30,12 +30,12 @@ public: ST_DMD }; - st2204_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + st2204_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto dac_callback() { return m_dac_callback.bind(); } protected: - st2204_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor int_map); + st2204_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor int_map); virtual void device_resolve_objects() override; virtual void device_start() override; @@ -148,7 +148,7 @@ private: class st2202_device : public st2204_device { public: - st2202_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + st2202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual u8 st2xxx_misc_mask() const override { return 0x0f; } diff --git a/src/devices/cpu/m6502/st2205u.cpp b/src/devices/cpu/m6502/st2205u.cpp index ac50492e325..673c0815770 100644 --- a/src/devices/cpu/m6502/st2205u.cpp +++ b/src/devices/cpu/m6502/st2205u.cpp @@ -51,7 +51,7 @@ DEFINE_DEVICE_TYPE(ST2205U, st2205u_device, "st2205u", "Sitronix ST2205U Integrated Microcontroller") DEFINE_DEVICE_TYPE(ST2302U, st2302u_device, "st2302u", "Sitronix ST2302U Integrated Microcontroller") -st2205u_base_device::st2205u_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor internal_map, int data_bits, bool has_banked_ram) +st2205u_base_device::st2205u_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map, int data_bits, bool has_banked_ram) : st2xxx_device(mconfig, type, tag, owner, clock, internal_map, data_bits, has_banked_ram) , device_sound_interface(mconfig, *this) , m_stream(nullptr) @@ -82,7 +82,7 @@ st2205u_base_device::st2205u_base_device(const machine_config &mconfig, device_t { } -st2205u_device::st2205u_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +st2205u_device::st2205u_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : st2205u_base_device(mconfig, ST2205U, tag, owner, clock, address_map_constructor(FUNC(st2205u_device::int_map), this), 26, // logical; only 23 address lines are brought out @@ -93,7 +93,7 @@ st2205u_device::st2205u_device(const machine_config &mconfig, const char *tag, d { } -st2302u_device::st2302u_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +st2302u_device::st2302u_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : st2205u_base_device(mconfig, ST2302U, tag, owner, clock, address_map_constructor(FUNC(st2302u_device::int_map), this), 26, // ??? diff --git a/src/devices/cpu/m6502/st2205u.h b/src/devices/cpu/m6502/st2205u.h index bd73e481822..bbf0e8f05cd 100644 --- a/src/devices/cpu/m6502/st2205u.h +++ b/src/devices/cpu/m6502/st2205u.h @@ -59,7 +59,7 @@ public: static constexpr feature_type imperfect_features() { return feature::SOUND; } protected: - st2205u_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor internal_map, int data_bits, bool has_banked_ram); + st2205u_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map, int data_bits, bool has_banked_ram); virtual void device_reset() override; @@ -180,7 +180,7 @@ public: ST_BRR }; - st2205u_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + st2205u_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -254,7 +254,7 @@ private: class st2302u_device : public st2205u_base_device { public: - st2302u_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + st2302u_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/cpu/m6502/st2xxx.cpp b/src/devices/cpu/m6502/st2xxx.cpp index 480460bbe67..c9dd74ca018 100644 --- a/src/devices/cpu/m6502/st2xxx.cpp +++ b/src/devices/cpu/m6502/st2xxx.cpp @@ -42,7 +42,7 @@ //#define VERBOSE (LOG_IRQ | LOG_BT | LOG_LCDC) #include "logmacro.h" -st2xxx_device::st2xxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor internal_map, int data_bits, bool has_banked_ram) +st2xxx_device::st2xxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map, int data_bits, bool has_banked_ram) : w65c02s_device(mconfig, type, tag, owner, clock) , m_data_config("data", ENDIANNESS_LITTLE, 8, data_bits, 0) , m_in_port_cb(*this) diff --git a/src/devices/cpu/m6502/st2xxx.h b/src/devices/cpu/m6502/st2xxx.h index 811c2008d49..430fac1df1e 100644 --- a/src/devices/cpu/m6502/st2xxx.h +++ b/src/devices/cpu/m6502/st2xxx.h @@ -85,7 +85,7 @@ public: auto out_pl_callback() { return m_out_port_cb[6].bind(); } protected: - st2xxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor internal_map, int data_bits, bool has_banked_ram); + st2xxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map, int data_bits, bool has_banked_ram); virtual space_config_vector memory_space_config() const override; virtual void device_resolve_objects() override; diff --git a/src/devices/cpu/m6502/w65c02s.cpp b/src/devices/cpu/m6502/w65c02s.cpp index 171db777dc2..d44c05ec5a8 100644 --- a/src/devices/cpu/m6502/w65c02s.cpp +++ b/src/devices/cpu/m6502/w65c02s.cpp @@ -15,12 +15,12 @@ DEFINE_DEVICE_TYPE(W65C02S, w65c02s_device, "w65c02s", "WDC W65C02S") -w65c02s_device::w65c02s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +w65c02s_device::w65c02s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : w65c02s_device(mconfig, W65C02S, tag, owner, clock) { } -w65c02s_device::w65c02s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +w65c02s_device::w65c02s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m65c02_device(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/w65c02s.h b/src/devices/cpu/m6502/w65c02s.h index a5848f86e68..b07da3ab58b 100644 --- a/src/devices/cpu/m6502/w65c02s.h +++ b/src/devices/cpu/m6502/w65c02s.h @@ -16,14 +16,14 @@ class w65c02s_device : public m65c02_device { public: - w65c02s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + w65c02s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; virtual void do_exec_full() override; virtual void do_exec_partial() override; protected: - w65c02s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + w65c02s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read_vector(uint16_t adr) { return mintf->read_arg(adr); } virtual void end_interrupt() { } diff --git a/src/devices/cpu/m6502/xavix.cpp b/src/devices/cpu/m6502/xavix.cpp index c8f98a0e8f7..1ae031ee81f 100644 --- a/src/devices/cpu/m6502/xavix.cpp +++ b/src/devices/cpu/m6502/xavix.cpp @@ -33,12 +33,12 @@ DEFINE_DEVICE_TYPE(XAVIX, xavix_device, "xavix", "XaviX (SSD 97 / SSD 98)") -xavix_device::xavix_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +xavix_device::xavix_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : xavix_device(mconfig, XAVIX, tag, owner, clock) { } -xavix_device::xavix_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +xavix_device::xavix_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m6502_device(mconfig, type, tag, owner, clock), XPC(0), m_lowbus_config("lowbus", ENDIANNESS_LITTLE, 8, 15), diff --git a/src/devices/cpu/m6502/xavix.h b/src/devices/cpu/m6502/xavix.h index ccab73f75d4..7fe24a30587 100644 --- a/src/devices/cpu/m6502/xavix.h +++ b/src/devices/cpu/m6502/xavix.h @@ -14,7 +14,7 @@ class xavix_device : public m6502_device { public: - xavix_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xavix_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; virtual void do_exec_full() override; @@ -164,7 +164,7 @@ protected: uint8_t m_codebank; uint32_t XPC; - xavix_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + xavix_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); uint32_t adr_with_codebank(uint16_t adr) { return adr | (get_codebank() << 16); } diff --git a/src/devices/cpu/m6502/xavix2000.cpp b/src/devices/cpu/m6502/xavix2000.cpp index 35da0f522b3..78f2cedffe5 100644 --- a/src/devices/cpu/m6502/xavix2000.cpp +++ b/src/devices/cpu/m6502/xavix2000.cpp @@ -36,7 +36,7 @@ DEFINE_DEVICE_TYPE(XAVIX2002, xavix2002_device, "xavix2002", "XaviX (SSD 2002) ( -xavix2000_device::xavix2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +xavix2000_device::xavix2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : xavix_device(mconfig, type, tag, owner, clock) { program_config.m_addr_width = 24; @@ -45,12 +45,12 @@ xavix2000_device::xavix2000_device(const machine_config &mconfig, device_type ty sprogram_config.m_logaddr_width = 24; } -xavix2000_device::xavix2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +xavix2000_device::xavix2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : xavix2000_device(mconfig, XAVIX2000, tag, owner, clock) { } -xavix2002_device::xavix2002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +xavix2002_device::xavix2002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : xavix2000_device(mconfig, XAVIX2002, tag, owner, clock) { } diff --git a/src/devices/cpu/m6502/xavix2000.h b/src/devices/cpu/m6502/xavix2000.h index c5e3113e840..80cc55f1895 100644 --- a/src/devices/cpu/m6502/xavix2000.h +++ b/src/devices/cpu/m6502/xavix2000.h @@ -14,12 +14,12 @@ class xavix2000_device : public xavix_device { public: - xavix2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xavix2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; protected: - xavix2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + xavix2000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void do_exec_full() override; virtual void do_exec_partial() override; @@ -164,7 +164,7 @@ enum { class xavix2002_device : public xavix2000_device { public: - xavix2002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xavix2002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/m6800/m6800.cpp b/src/devices/cpu/m6800/m6800.cpp index 4df393c0a4c..674cb487fd9 100644 --- a/src/devices/cpu/m6800/m6800.cpp +++ b/src/devices/cpu/m6800/m6800.cpp @@ -383,12 +383,12 @@ DEFINE_DEVICE_TYPE(M6808, m6808_cpu_device, "m6808", "Motorola MC6808") DEFINE_DEVICE_TYPE(NSC8105, nsc8105_cpu_device, "nsc8105", "NSC8105") -m6800_cpu_device::m6800_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m6800_cpu_device::m6800_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6800_cpu_device(mconfig, M6800, tag, owner, clock, m6800_insn, cycles_6800, address_map_constructor()) { } -m6800_cpu_device::m6800_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const op_func *insn, const uint8_t *cycles, address_map_constructor internal) +m6800_cpu_device::m6800_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const op_func *insn, const uint8_t *cycles, address_map_constructor internal) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, 16, 0, internal) , m_decrypted_opcodes_config("program", ENDIANNESS_BIG, 8, 16, 0) @@ -397,12 +397,12 @@ m6800_cpu_device::m6800_cpu_device(const machine_config &mconfig, device_type ty { } -m6802_cpu_device::m6802_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m6802_cpu_device::m6802_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6802_cpu_device(mconfig, M6802, tag, owner, clock, m6800_insn, cycles_6800) { } -m6802_cpu_device::m6802_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const op_func *insn, const uint8_t *cycles) +m6802_cpu_device::m6802_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const op_func *insn, const uint8_t *cycles) : m6800_cpu_device(mconfig, type, tag, owner, clock, insn, cycles, address_map_constructor(FUNC(m6802_cpu_device::ram_map), this)) , m_ram_enable(true) { @@ -414,7 +414,7 @@ void m6802_cpu_device::ram_map(address_map &map) map(0x0000, 0x007f).ram(); } -m6808_cpu_device::m6808_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m6808_cpu_device::m6808_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6802_cpu_device(mconfig, M6808, tag, owner, clock, m6800_insn, cycles_6800) { set_ram_enable(false); @@ -426,7 +426,7 @@ void m6808_cpu_device::device_validity_check(validity_checker &valid) const osd_printf_error("MC6808 should not have internal RAM enabled\n"); } -nsc8105_cpu_device::nsc8105_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nsc8105_cpu_device::nsc8105_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6802_cpu_device(mconfig, NSC8105, tag, owner, clock, nsc8105_insn, cycles_nsc8105) { } diff --git a/src/devices/cpu/m6800/m6800.h b/src/devices/cpu/m6800/m6800.h index 10e40ab3a3f..c4229d07fa3 100644 --- a/src/devices/cpu/m6800/m6800.h +++ b/src/devices/cpu/m6800/m6800.h @@ -34,7 +34,7 @@ public: typedef void (m6800_cpu_device::*op_func)(); // construction/destruction - m6800_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6800_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: enum @@ -43,7 +43,7 @@ protected: M6800_SLP = 0x10 /* HD63701 only */ }; - m6800_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const m6800_cpu_device::op_func *insn, const uint8_t *cycles, address_map_constructor internal); + m6800_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const m6800_cpu_device::op_func *insn, const uint8_t *cycles, address_map_constructor internal); // device-level overrides virtual void device_start() override; @@ -364,12 +364,12 @@ protected: class m6802_cpu_device : public m6800_cpu_device { public: - m6802_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6802_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_ram_enable(bool re) { assert(!configured()); m_ram_enable = re; } protected: - m6802_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const m6800_cpu_device::op_func *insn, const uint8_t *cycles); + m6802_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const m6800_cpu_device::op_func *insn, const uint8_t *cycles); virtual uint64_t execute_clocks_to_cycles(uint64_t clocks) const noexcept override { return (clocks + 4 - 1) / 4; } virtual uint64_t execute_cycles_to_clocks(uint64_t cycles) const noexcept override { return (cycles * 4); } @@ -385,7 +385,7 @@ private: class m6808_cpu_device : public m6802_cpu_device { public: - m6808_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6808_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -396,7 +396,7 @@ protected: class nsc8105_cpu_device : public m6802_cpu_device { public: - nsc8105_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nsc8105_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/m6800/m6801.cpp b/src/devices/cpu/m6800/m6801.cpp index e759a0b57cc..9bce8f303fb 100644 --- a/src/devices/cpu/m6800/m6801.cpp +++ b/src/devices/cpu/m6800/m6801.cpp @@ -309,12 +309,12 @@ DEFINE_DEVICE_TYPE(HD6303R, hd6303r_cpu_device, "hd6303r", "Hitachi HD6303R") DEFINE_DEVICE_TYPE(HD6303X, hd6303x_cpu_device, "hd6303x", "Hitachi HD6303X") DEFINE_DEVICE_TYPE(HD6303Y, hd6303y_cpu_device, "hd6303y", "Hitachi HD6303Y") -m6801_cpu_device::m6801_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m6801_cpu_device::m6801_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6801_cpu_device(mconfig, M6801, tag, owner, clock, m6803_insn, cycles_6803, address_map_constructor()) { } -m6801_cpu_device::m6801_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const op_func *insn, const uint8_t *cycles, address_map_constructor internal) +m6801_cpu_device::m6801_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const op_func *insn, const uint8_t *cycles, address_map_constructor internal) : m6800_cpu_device(mconfig, type, tag, owner, clock, insn, cycles, internal) , m_in_port_func(*this) , m_out_port_func(*this) @@ -324,37 +324,37 @@ m6801_cpu_device::m6801_cpu_device(const machine_config &mconfig, device_type ty { } -m6803_cpu_device::m6803_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m6803_cpu_device::m6803_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6801_cpu_device(mconfig, M6803, tag, owner, clock, m6803_insn, cycles_6803, address_map_constructor(FUNC(m6803_cpu_device::m6803_mem), this)) { } -m6803e_cpu_device::m6803e_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m6803e_cpu_device::m6803e_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6801_cpu_device(mconfig, M6803E, tag, owner, clock, m6803_insn, cycles_6803, address_map_constructor(FUNC(m6803e_cpu_device::m6803_mem), this)) { } -hd6301_cpu_device::hd6301_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +hd6301_cpu_device::hd6301_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : m6801_cpu_device(mconfig, type, tag, owner, clock, hd63701_insn, cycles_63701) { } -hd6301v1_cpu_device::hd6301v1_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd6301v1_cpu_device::hd6301v1_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6301_cpu_device(mconfig, HD6301V1, tag, owner, clock) { } -hd63701v0_cpu_device::hd63701v0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd63701v0_cpu_device::hd63701v0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6301_cpu_device(mconfig, HD63701V0, tag, owner, clock) { } -hd6303r_cpu_device::hd6303r_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd6303r_cpu_device::hd6303r_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6301_cpu_device(mconfig, HD6303R, tag, owner, clock) { } -hd6301x_cpu_device::hd6301x_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +hd6301x_cpu_device::hd6301x_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : hd6301_cpu_device(mconfig, type, tag, owner, clock) , m_in_portx_func(*this) , m_out_portx_func(*this) @@ -362,37 +362,37 @@ hd6301x_cpu_device::hd6301x_cpu_device(const machine_config &mconfig, device_typ m_sclk_divider = 16; } -hd6301x0_cpu_device::hd6301x0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd6301x0_cpu_device::hd6301x0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6301x_cpu_device(mconfig, HD6301X0, tag, owner, clock) { } -hd63701x0_cpu_device::hd63701x0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd63701x0_cpu_device::hd63701x0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6301x_cpu_device(mconfig, HD63701X0, tag, owner, clock) { } -hd6303x_cpu_device::hd6303x_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd6303x_cpu_device::hd6303x_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6301x_cpu_device(mconfig, HD6303X, tag, owner, clock) { } -hd6301y_cpu_device::hd6301y_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +hd6301y_cpu_device::hd6301y_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : hd6301x_cpu_device(mconfig, type, tag, owner, clock) { } -hd6301y0_cpu_device::hd6301y0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd6301y0_cpu_device::hd6301y0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6301y_cpu_device(mconfig, HD6301Y0, tag, owner, clock) { } -hd63701y0_cpu_device::hd63701y0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd63701y0_cpu_device::hd63701y0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6301y_cpu_device(mconfig, HD63701Y0, tag, owner, clock) { } -hd6303y_cpu_device::hd6303y_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd6303y_cpu_device::hd6303y_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6301y_cpu_device(mconfig, HD6303Y, tag, owner, clock) { } diff --git a/src/devices/cpu/m6800/m6801.h b/src/devices/cpu/m6800/m6801.h index de74fed4ff7..435c3e7836a 100644 --- a/src/devices/cpu/m6800/m6801.h +++ b/src/devices/cpu/m6800/m6801.h @@ -43,7 +43,7 @@ enum class m6801_cpu_device : public m6800_cpu_device { public: - m6801_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6801_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto in_p1_cb() { return m_in_port_func[0].bind(); } auto out_p1_cb() { return m_out_port_func[0].bind(); } @@ -62,7 +62,7 @@ public: void m6801_clock_serial(); protected: - m6801_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const m6800_cpu_device::op_func *insn, const uint8_t *cycles, address_map_constructor internal = address_map_constructor()); + m6801_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const m6800_cpu_device::op_func *insn, const uint8_t *cycles, address_map_constructor internal = address_map_constructor()); // device-level overrides virtual void device_resolve_objects() override; @@ -184,7 +184,7 @@ protected: class m6803_cpu_device : public m6801_cpu_device { public: - m6803_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6803_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -194,7 +194,7 @@ protected: class m6803e_cpu_device : public m6801_cpu_device { public: - m6803e_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6803e_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual uint64_t execute_clocks_to_cycles(uint64_t clocks) const noexcept override { return clocks; } @@ -207,7 +207,7 @@ protected: class hd6301_cpu_device : public m6801_cpu_device { protected: - hd6301_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + hd6301_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -224,7 +224,7 @@ protected: class hd6301v1_cpu_device : public hd6301_cpu_device { public: - hd6301v1_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd6301v1_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -233,7 +233,7 @@ public: class hd63701v0_cpu_device : public hd6301_cpu_device { public: - hd63701v0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd63701v0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -244,7 +244,7 @@ public: class hd6303r_cpu_device : public hd6301_cpu_device { public: - hd6303r_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd6303r_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -261,7 +261,7 @@ public: void hd6301x_io(address_map &map); protected: - hd6301x_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + hd6301x_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -328,7 +328,7 @@ protected: class hd6301x0_cpu_device : public hd6301x_cpu_device { public: - hd6301x0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd6301x0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -337,7 +337,7 @@ public: class hd63701x0_cpu_device : public hd6301x_cpu_device { public: - hd63701x0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd63701x0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -348,7 +348,7 @@ public: class hd6303x_cpu_device : public hd6301x_cpu_device { public: - hd6303x_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd6303x_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -359,7 +359,7 @@ public: void hd6301y_io(address_map &map); protected: - hd6301y_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + hd6301y_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -392,7 +392,7 @@ protected: class hd6301y0_cpu_device : public hd6301y_cpu_device { public: - hd6301y0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd6301y0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -401,7 +401,7 @@ public: class hd63701y0_cpu_device : public hd6301y_cpu_device { public: - hd63701y0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd63701y0_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -413,7 +413,7 @@ public: class hd6303y_cpu_device : public hd6301y_cpu_device { public: - hd6303y_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd6303y_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/m68000/fscpu32.cpp b/src/devices/cpu/m68000/fscpu32.cpp index e633d7a059d..a1ce0e2814f 100644 --- a/src/devices/cpu/m68000/fscpu32.cpp +++ b/src/devices/cpu/m68000/fscpu32.cpp @@ -10,7 +10,7 @@ std::unique_ptr<util::disasm_interface> fscpu32_device::create_disassembler() return std::make_unique<m68k_disassembler>(m68k_disassembler::TYPE_CPU32); } -fscpu32_device::fscpu32_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, +fscpu32_device::fscpu32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, address_map_constructor internal_map) : m68000_base_device(mconfig, tag, owner, clock, type, 16,32, internal_map) { diff --git a/src/devices/cpu/m68000/fscpu32.h b/src/devices/cpu/m68000/fscpu32.h index 66bb7e1f114..7ff86b870d9 100644 --- a/src/devices/cpu/m68000/fscpu32.h +++ b/src/devices/cpu/m68000/fscpu32.h @@ -19,7 +19,7 @@ public: virtual void device_start() override; protected: - fscpu32_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, + fscpu32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, address_map_constructor internal_map); }; diff --git a/src/devices/cpu/m68000/m68000.cpp b/src/devices/cpu/m68000/m68000.cpp index 751ded698d2..8cf4ea3d28f 100644 --- a/src/devices/cpu/m68000/m68000.cpp +++ b/src/devices/cpu/m68000/m68000.cpp @@ -12,12 +12,12 @@ std::unique_ptr<util::disasm_interface> m68000_device::create_disassembler() return std::make_unique<m68k_disassembler>(m68k_disassembler::TYPE_68000); } -m68000_device::m68000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68000_device::m68000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_device(mconfig, M68000, tag, owner, clock) { } -m68000_device::m68000_device(const machine_config &mconfig, const device_type type, const char *tag, device_t *owner, u32 clock) +m68000_device::m68000_device(const machine_config &mconfig, const device_type type, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, type, 16,24) { } @@ -28,7 +28,7 @@ void m68000_device::device_start() init_cpu_m68000(); } -m68000_device::m68000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, +m68000_device::m68000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, u32 prg_data_width, u32 prg_address_bits, address_map_constructor internal_map) : m68000_base_device(mconfig, tag, owner, clock, type, prg_data_width, prg_address_bits, internal_map) { diff --git a/src/devices/cpu/m68000/m68000.h b/src/devices/cpu/m68000/m68000.h index f97fd11c1c7..a53042f3018 100644 --- a/src/devices/cpu/m68000/m68000.h +++ b/src/devices/cpu/m68000/m68000.h @@ -11,7 +11,7 @@ class m68000_device : public m68000_base_device { public: // construction/destruction - m68000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -23,9 +23,9 @@ public: virtual void device_start() override; protected: - m68000_device(const machine_config &mconfig, const device_type type, const char *tag, device_t *owner, u32 clock); + m68000_device(const machine_config &mconfig, const device_type type, const char *tag, device_t *owner, const XTAL &clock); - m68000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, + m68000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, u32 prg_data_width, u32 prg_address_bits, address_map_constructor internal_map); }; diff --git a/src/devices/cpu/m68000/m68008.cpp b/src/devices/cpu/m68000/m68008.cpp index 2b83211d9c5..f29f671fea1 100644 --- a/src/devices/cpu/m68000/m68008.cpp +++ b/src/devices/cpu/m68000/m68008.cpp @@ -18,7 +18,7 @@ std::unique_ptr<util::disasm_interface> m68008fn_device::create_disassembler() return std::make_unique<m68k_disassembler>(m68k_disassembler::TYPE_68008); } -m68008_device::m68008_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68008_device::m68008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68008, 8,20) { } @@ -30,7 +30,7 @@ void m68008_device::device_start() } -m68008fn_device::m68008fn_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68008fn_device::m68008fn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68008FN, 8,22) { } diff --git a/src/devices/cpu/m68000/m68008.h b/src/devices/cpu/m68000/m68008.h index b6d4e06062e..442d8b8f22a 100644 --- a/src/devices/cpu/m68000/m68008.h +++ b/src/devices/cpu/m68000/m68008.h @@ -11,7 +11,7 @@ class m68008_device : public m68000_base_device { public: // construction/destruction - m68008_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -26,7 +26,7 @@ class m68008fn_device : public m68000_base_device { public: // construction/destruction - m68008fn_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68008fn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/m68000/m68010.cpp b/src/devices/cpu/m68000/m68010.cpp index 6983ec1d7fc..3d37cf0c533 100644 --- a/src/devices/cpu/m68000/m68010.cpp +++ b/src/devices/cpu/m68000/m68010.cpp @@ -13,7 +13,7 @@ std::unique_ptr<util::disasm_interface> m68010_device::create_disassembler() } -m68010_device::m68010_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68010_device::m68010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68010, 16,24) { } diff --git a/src/devices/cpu/m68000/m68010.h b/src/devices/cpu/m68000/m68010.h index dff4a1d96e5..6d0ef8e6f31 100644 --- a/src/devices/cpu/m68000/m68010.h +++ b/src/devices/cpu/m68000/m68010.h @@ -11,7 +11,7 @@ class m68010_device : public m68000_base_device { public: // construction/destruction - m68010_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/m68000/m68020.cpp b/src/devices/cpu/m68000/m68020.cpp index 0e0e0ea3992..9a54c6a284e 100644 --- a/src/devices/cpu/m68000/m68020.cpp +++ b/src/devices/cpu/m68000/m68020.cpp @@ -36,7 +36,7 @@ std::unique_ptr<util::disasm_interface> m68020hmmu_device::create_disassembler() return std::make_unique<m68k_disassembler>(m68k_disassembler::TYPE_68020); } -m68020_device::m68020_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68020_device::m68020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68020, 32,32) { } @@ -48,7 +48,7 @@ void m68020_device::device_start() } -m68020fpu_device::m68020fpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68020fpu_device::m68020fpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68020FPU, 32,32) { } @@ -60,7 +60,7 @@ void m68020fpu_device::device_start() } // 68020 with 68851 PMMU -m68020pmmu_device::m68020pmmu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68020pmmu_device::m68020pmmu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68020PMMU, 32,32) { } @@ -86,7 +86,7 @@ bool m68020hmmu_device::memory_translate(int space, int intention, offs_t &addre // 68020 with Apple HMMU & 68881 FPU // case CPUINFO_FCT_TRANSLATE: info->translate = CPU_TRANSLATE_NAME(m68khmmu); break; -m68020hmmu_device::m68020hmmu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68020hmmu_device::m68020hmmu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68020HMMU, 32,32) { } @@ -98,7 +98,7 @@ void m68020hmmu_device::device_start() } -m68ec020_device::m68ec020_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68ec020_device::m68ec020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68EC020, 32,24) { } diff --git a/src/devices/cpu/m68000/m68020.h b/src/devices/cpu/m68000/m68020.h index 265174c5076..19b643a0f93 100644 --- a/src/devices/cpu/m68000/m68020.h +++ b/src/devices/cpu/m68000/m68020.h @@ -11,7 +11,7 @@ class m68ec020_device : public m68000_base_device { public: // construction/destruction - m68ec020_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68ec020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -26,7 +26,7 @@ class m68020_device : public m68000_base_device { public: // construction/destruction - m68020_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -41,7 +41,7 @@ class m68020fpu_device : public m68000_base_device { public: // construction/destruction - m68020fpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68020fpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -56,7 +56,7 @@ class m68020pmmu_device : public m68000_base_device { public: // construction/destruction - m68020pmmu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68020pmmu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -71,7 +71,7 @@ class m68020hmmu_device : public m68000_base_device { public: // construction/destruction - m68020hmmu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68020hmmu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/m68000/m68030.cpp b/src/devices/cpu/m68000/m68030.cpp index f2e7c3c759a..84b69d81631 100644 --- a/src/devices/cpu/m68000/m68030.cpp +++ b/src/devices/cpu/m68000/m68030.cpp @@ -18,7 +18,7 @@ std::unique_ptr<util::disasm_interface> m68030_device::create_disassembler() return std::make_unique<m68k_disassembler>(m68k_disassembler::TYPE_68030); } -m68030_device::m68030_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68030_device::m68030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68030, 32,32) { } @@ -29,7 +29,7 @@ void m68030_device::device_start() init_cpu_m68030(); } -m68ec030_device::m68ec030_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68ec030_device::m68ec030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68EC030, 32,32) { } diff --git a/src/devices/cpu/m68000/m68030.h b/src/devices/cpu/m68000/m68030.h index d2206e5f084..527edd536df 100644 --- a/src/devices/cpu/m68000/m68030.h +++ b/src/devices/cpu/m68000/m68030.h @@ -11,7 +11,7 @@ class m68ec030_device : public m68000_base_device { public: // construction/destruction - m68ec030_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68ec030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -26,7 +26,7 @@ class m68030_device : public m68000_base_device { public: // construction/destruction - m68030_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/m68000/m68040.cpp b/src/devices/cpu/m68000/m68040.cpp index d01b7cc927c..7dcb3b12746 100644 --- a/src/devices/cpu/m68000/m68040.cpp +++ b/src/devices/cpu/m68000/m68040.cpp @@ -24,7 +24,7 @@ std::unique_ptr<util::disasm_interface> m68040_device::create_disassembler() return std::make_unique<m68k_disassembler>(m68k_disassembler::TYPE_68040); } -m68040_device::m68040_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68040_device::m68040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68040, 32,32) { } @@ -38,7 +38,7 @@ void m68040_device::device_start() -m68ec040_device::m68ec040_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68ec040_device::m68ec040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68EC040, 32,32) { } @@ -51,7 +51,7 @@ void m68ec040_device::device_start() -m68lc040_device::m68lc040_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m68lc040_device::m68lc040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, M68LC040, 32,32) { } diff --git a/src/devices/cpu/m68000/m68040.h b/src/devices/cpu/m68000/m68040.h index b09def174d8..bef31785212 100644 --- a/src/devices/cpu/m68000/m68040.h +++ b/src/devices/cpu/m68000/m68040.h @@ -11,7 +11,7 @@ class m68ec040_device : public m68000_base_device { public: // construction/destruction - m68ec040_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68ec040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -26,7 +26,7 @@ class m68lc040_device : public m68000_base_device { public: // construction/destruction - m68lc040_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68lc040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -41,7 +41,7 @@ class m68040_device : public m68000_base_device { public: // construction/destruction - m68040_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/m68000/m68kcommon.h b/src/devices/cpu/m68000/m68kcommon.h index 6e2ab7de5d7..86659ec7beb 100644 --- a/src/devices/cpu/m68000/m68kcommon.h +++ b/src/devices/cpu/m68000/m68kcommon.h @@ -102,7 +102,7 @@ public: }; // construction/destruction - m68000_base_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m68000_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr u8 autovector(int level) { return 0x18 + level; } void autovectors_map(address_map &map); @@ -173,10 +173,10 @@ public: void set_cpu_space(int space_id) { m_cpu_space_id = space_id; } protected: - m68000_base_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, + m68000_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, u32 prg_data_width, u32 prg_address_bits); - m68000_base_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, + m68000_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, u32 prg_data_width, u32 prg_address_bits, address_map_constructor internal_map); int m_has_fpu; /* Indicates if a FPU is available (yes on 030, 040, may be on 020) */ diff --git a/src/devices/cpu/m68000/m68kcpu.cpp b/src/devices/cpu/m68000/m68kcpu.cpp index 2b00922c9e1..8ccdebe84b2 100644 --- a/src/devices/cpu/m68000/m68kcpu.cpp +++ b/src/devices/cpu/m68000/m68kcpu.cpp @@ -2257,7 +2257,7 @@ void m68000_base_device::m68ki_exception_interrupt(u32 int_level) // m68000_base_device - constructor //------------------------------------------------- -m68000_base_device::m68000_base_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, +m68000_base_device::m68000_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, u32 prg_data_width, u32 prg_address_bits, address_map_constructor internal_map) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_BIG, prg_data_width, prg_address_bits, 0, internal_map), @@ -2274,7 +2274,7 @@ m68000_base_device::m68000_base_device(const machine_config &mconfig, const char } -m68000_base_device::m68000_base_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, +m68000_base_device::m68000_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, u32 prg_data_width, u32 prg_address_bits) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_BIG, prg_data_width, prg_address_bits), diff --git a/src/devices/cpu/m68000/mcf5206e.cpp b/src/devices/cpu/m68000/mcf5206e.cpp index 3a20ad7e473..fd5835d7fd8 100644 --- a/src/devices/cpu/m68000/mcf5206e.cpp +++ b/src/devices/cpu/m68000/mcf5206e.cpp @@ -12,7 +12,7 @@ std::unique_ptr<util::disasm_interface> mcf5206e_device::create_disassembler() return std::make_unique<m68k_disassembler>(m68k_disassembler::TYPE_COLDFIRE); } -mcf5206e_device::mcf5206e_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mcf5206e_device::mcf5206e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_base_device(mconfig, tag, owner, clock, MCF5206E, 32,32) { } diff --git a/src/devices/cpu/m68000/mcf5206e.h b/src/devices/cpu/m68000/mcf5206e.h index 508f2c812a7..8a190b2f3b4 100644 --- a/src/devices/cpu/m68000/mcf5206e.h +++ b/src/devices/cpu/m68000/mcf5206e.h @@ -11,7 +11,7 @@ class mcf5206e_device : public m68000_base_device { public: // construction/destruction - mcf5206e_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mcf5206e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/m68000/scc68070.cpp b/src/devices/cpu/m68000/scc68070.cpp index e0daf10b68f..bff9340edc9 100644 --- a/src/devices/cpu/m68000/scc68070.cpp +++ b/src/devices/cpu/m68000/scc68070.cpp @@ -11,7 +11,7 @@ std::unique_ptr<util::disasm_interface> scc68070_base_device::create_disassemble } -scc68070_base_device::scc68070_base_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, +scc68070_base_device::scc68070_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, address_map_constructor internal_map) : m68000_base_device(mconfig, tag, owner, clock, type, 16,32, internal_map) { diff --git a/src/devices/cpu/m68000/scc68070.h b/src/devices/cpu/m68000/scc68070.h index 20d2d8c62d6..1e6b5b46278 100644 --- a/src/devices/cpu/m68000/scc68070.h +++ b/src/devices/cpu/m68000/scc68070.h @@ -18,7 +18,7 @@ protected: // device-level overrides virtual void device_start() override; - scc68070_base_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, + scc68070_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, address_map_constructor internal_map); }; diff --git a/src/devices/cpu/m6805/m6805.cpp b/src/devices/cpu/m6805/m6805.cpp index 26cc630f3bb..8a01e0fef5d 100644 --- a/src/devices/cpu/m6805/m6805.cpp +++ b/src/devices/cpu/m6805/m6805.cpp @@ -314,7 +314,7 @@ m6805_base_device::m6805_base_device( machine_config const &mconfig, char const *tag, device_t *owner, - uint32_t clock, + const XTAL &clock, device_type const type, configuration_params const ¶ms) : cpu_device(mconfig, type, tag, owner, clock) @@ -327,7 +327,7 @@ m6805_base_device::m6805_base_device( machine_config const &mconfig, char const *tag, device_t *owner, - uint32_t clock, + const XTAL &clock, device_type const type, configuration_params const ¶ms, address_map_constructor internal_map) @@ -632,7 +632,7 @@ void m6805_base_device::execute_set_input(int inputnum, int state) /**************************************************************************** * M68HC05EG section ****************************************************************************/ -m68hc05eg_device::m68hc05eg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m68hc05eg_device::m68hc05eg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6805_base_device( mconfig, tag, @@ -687,7 +687,7 @@ std::unique_ptr<util::disasm_interface> m68hc05eg_device::create_disassembler() /**************************************************************************** * HD63705 section ****************************************************************************/ -hd63705_device::hd63705_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd63705_device::hd63705_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6805_base_device(mconfig, tag, owner, diff --git a/src/devices/cpu/m6805/m6805.h b/src/devices/cpu/m6805/m6805.h index 824c664b829..f0ce42bc0f8 100644 --- a/src/devices/cpu/m6805/m6805.h +++ b/src/devices/cpu/m6805/m6805.h @@ -111,14 +111,14 @@ protected: machine_config const &mconfig, char const *tag, device_t *owner, - uint32_t clock, + const XTAL &clock, device_type const type, configuration_params const ¶ms); m6805_base_device( machine_config const &mconfig, char const *tag, device_t *owner, - uint32_t clock, + const XTAL &clock, device_type const type, configuration_params const ¶ms, address_map_constructor internal_map); @@ -313,7 +313,7 @@ class m68hc05eg_device : public m6805_base_device { public: // construction/destruction - m68hc05eg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m68hc05eg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -332,7 +332,7 @@ class hd63705_device : public m6805_base_device { public: // construction/destruction - hd63705_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd63705_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/m6805/m68705.cpp b/src/devices/cpu/m6805/m68705.cpp index 96a36d2c711..7c9284fe74e 100644 --- a/src/devices/cpu/m6805/m68705.cpp +++ b/src/devices/cpu/m6805/m68705.cpp @@ -214,7 +214,7 @@ Ux Parts: */ -m6805_hmos_device::m6805_hmos_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type, u32 addr_width, unsigned ram_size) +m6805_hmos_device::m6805_hmos_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type, u32 addr_width, unsigned ram_size) : m6805_base_device(mconfig, tag, owner, clock, type, { addr_width > 13 ? s_hmos_b_ops : s_hmos_s_ops, s_hmos_cycles, addr_width, 0x007f, 0x0060, M6805_VECTOR_SWI }, address_map_constructor(FUNC(m6805_hmos_device::map), this)) , m_timer(*this) , m_port_open_drain{ false, false, false, false } @@ -228,7 +228,7 @@ m6805_hmos_device::m6805_hmos_device(machine_config const &mconfig, char const * { } -m68705_device::m68705_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type, u32 addr_width, unsigned ram_size) +m68705_device::m68705_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type, u32 addr_width, unsigned ram_size) : m6805_hmos_device(mconfig, tag, owner, clock, type, addr_width, ram_size) , device_nvram_interface(mconfig, *this) , m_user_rom(*this, DEVICE_SELF) @@ -634,7 +634,7 @@ void m68705p_device::internal_map(address_map &map) map(0x07f8, 0x07ff).rw(FUNC(m68705p_device::eprom_r<0x07f8>), FUNC(m68705p_device::eprom_w<0x07f8>)); // Interrupt vectors } -m68705p_device::m68705p_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type) +m68705p_device::m68705p_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type) : m68705_device(mconfig, tag, owner, clock, type, 11, 112) { set_port_open_drain<0>(true); // Port A is open drain with internal pull-ups @@ -669,7 +669,7 @@ void m68705u_device::internal_map(address_map &map) map(0x0ff8, 0x0fff).rw(FUNC(m68705u_device::eprom_r<0x0ff8>), FUNC(m68705u_device::eprom_w<0x0ff8>)); // Interrupt vectors } -m68705u_device::m68705u_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type) +m68705u_device::m68705u_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type) : m68705_device(mconfig, tag, owner, clock, type, 12, 112) { set_port_open_drain<0>(true); // Port A is open drain with internal pull-ups @@ -705,7 +705,7 @@ void m68705r_device::internal_map(address_map &map) map(0x0ff8, 0x0fff).rw(FUNC(m68705r_device::eprom_r<0x0ff8>), FUNC(m68705r_device::eprom_w<0x0ff8>)); // Interrupt vectors } -m68705r_device::m68705r_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type) +m68705r_device::m68705r_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type) : m68705u_device(mconfig, tag, owner, clock, type) { } @@ -726,7 +726,7 @@ std::unique_ptr<util::disasm_interface> m68705r_device::create_disassembler() * M68705P3 device ****************************************************************************/ -m68705p3_device::m68705p3_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +m68705p3_device::m68705p3_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68705p_device(mconfig, tag, owner, clock, M68705P3) { } @@ -746,7 +746,7 @@ u8 m68705p3_device::get_mask_options() const * M68705P5 device ****************************************************************************/ -m68705p5_device::m68705p5_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +m68705p5_device::m68705p5_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68705p_device(mconfig, tag, owner, clock, M68705P5) { } @@ -766,7 +766,7 @@ u8 m68705p5_device::get_mask_options() const * M68705R3 device ****************************************************************************/ -m68705r3_device::m68705r3_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +m68705r3_device::m68705r3_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68705r_device(mconfig, tag, owner, clock, M68705R3) { } @@ -786,7 +786,7 @@ u8 m68705r3_device::get_mask_options() const * M68705U3 device ****************************************************************************/ -m68705u3_device::m68705u3_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +m68705u3_device::m68705u3_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68705u_device(mconfig, tag, owner, clock, M68705U3) { } @@ -801,7 +801,7 @@ u8 m68705u3_device::get_mask_options() const return get_user_rom()[0x0f38] & 0xf7; // no SNM bit } -m6805p2_device::m6805p2_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +m6805p2_device::m6805p2_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m6805_mrom_device(mconfig, tag, owner, clock, M6805P2, 11, 64) { /* @@ -816,7 +816,7 @@ m6805p2_device::m6805p2_device(machine_config const &mconfig, char const *tag, d set_port_mask<3>(0xff); // Port D isn't present } -m6805p6_device::m6805p6_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +m6805p6_device::m6805p6_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m6805_mrom_device(mconfig, tag, owner, clock, M6805P6, 11, 64) { m_timer.set_options(m6805_timer::TIMER_MOR /* | m6805::TIMER_NPC */); @@ -826,33 +826,33 @@ m6805p6_device::m6805p6_device(machine_config const &mconfig, char const *tag, d set_port_mask<3>(0xff); // Port D isn't present } -m6805r2_device::m6805r2_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +m6805r2_device::m6805r2_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m6805_mrom_device(mconfig, tag, owner, clock, M6805R2, 12, 64) { m_timer.set_options(m6805_timer::TIMER_MOR); m_timer.set_source(m6805_timer::CLOCK_TIMER); } -m6805r3_device::m6805r3_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +m6805r3_device::m6805r3_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m6805_mrom_device(mconfig, tag, owner, clock, M6805R3, 12, 112) { m_timer.set_options(m6805_timer::TIMER_PGM); } -m6805u2_device::m6805u2_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +m6805u2_device::m6805u2_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m6805_mrom_device(mconfig, tag, owner, clock, M6805U2, 12, 64) { m_timer.set_options(m6805_timer::TIMER_MOR); m_timer.set_source(m6805_timer::CLOCK_TIMER); } -m6805u3_device::m6805u3_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +m6805u3_device::m6805u3_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m6805_mrom_device(mconfig, tag, owner, clock, M6805U3, 12, 112) { m_timer.set_options(m6805_timer::TIMER_PGM); } -hd6805s1_device::hd6805s1_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +hd6805s1_device::hd6805s1_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m6805_mrom_device(mconfig, tag, owner, clock, HD6805S1, 11, 64) { m_timer.set_options(m6805_timer::TIMER_NPC); @@ -861,7 +861,7 @@ hd6805s1_device::hd6805s1_device(machine_config const &mconfig, char const *tag, set_port_mask<3>(0xff); // Port D isn't present } -hd6805u1_device::hd6805u1_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +hd6805u1_device::hd6805u1_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m6805_mrom_device(mconfig, tag, owner, clock, HD6805U1, 12, 96) { // Port D has optional analog comparator but no INT2 (no MISC register, either) diff --git a/src/devices/cpu/m6805/m68705.h b/src/devices/cpu/m6805/m68705.h index e8bd0659135..af90a7d7d4c 100644 --- a/src/devices/cpu/m6805/m68705.h +++ b/src/devices/cpu/m6805/m68705.h @@ -164,7 +164,7 @@ protected: static unsigned const PORT_COUNT = 4; - m6805_hmos_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type, u32 addr_width, unsigned ram_size); + m6805_hmos_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type, u32 addr_width, unsigned ram_size); void map(address_map &map) { internal_map(map); } virtual void internal_map(address_map &map); @@ -225,7 +225,7 @@ private: class m6805_mrom_device : public m6805_hmos_device { protected: - m6805_mrom_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type, u32 addr_width, unsigned ram_size) + m6805_mrom_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type, u32 addr_width, unsigned ram_size) : m6805_hmos_device(mconfig, tag, owner, clock, type, addr_width, ram_size) { } @@ -248,7 +248,7 @@ public: protected: virtual void internal_map(address_map &map) override; - m68705_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type, u32 addr_width, unsigned ram_size); + m68705_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type, u32 addr_width, unsigned ram_size); template <offs_t B> u8 eprom_r(offs_t offset); template <offs_t B> void eprom_w(offs_t offset, u8 data); @@ -290,7 +290,7 @@ public: protected: virtual void internal_map(address_map &map) override; - m68705p_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type); + m68705p_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type); virtual void device_start() override; @@ -308,7 +308,7 @@ public: protected: virtual void internal_map(address_map &map) override; - m68705u_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type); + m68705u_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type); virtual void device_start() override; @@ -323,7 +323,7 @@ public: protected: virtual void internal_map(address_map &map) override; - m68705r_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, device_type type); + m68705r_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, device_type type); virtual void device_start() override; @@ -334,7 +334,7 @@ protected: class m6805p2_device : public m6805_mrom_device { public: - m6805p2_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m6805p2_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // mask options void set_timer_divisor(unsigned divisor) { m_timer.set_divisor(divisor); } @@ -344,7 +344,7 @@ public: class m6805p6_device : public m6805_mrom_device { public: - m6805p6_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m6805p6_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // mask options void set_timer_divisor(unsigned divisor) { m_timer.set_divisor(divisor); } @@ -354,7 +354,7 @@ public: class m6805r2_device : public m6805_mrom_device { public: - m6805r2_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m6805r2_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // mask options void set_timer_divisor(unsigned divisor) { m_timer.set_divisor(divisor); } @@ -367,7 +367,7 @@ protected: class m6805r3_device : public m6805_mrom_device { public: - m6805r3_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m6805r3_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual void internal_map(address_map &map) override; @@ -376,7 +376,7 @@ protected: class m6805u2_device : public m6805_mrom_device { public: - m6805u2_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m6805u2_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // mask options void set_timer_divisor(unsigned divisor) { m_timer.set_divisor(divisor); } @@ -386,7 +386,7 @@ public: class m6805u3_device : public m6805_mrom_device { public: - m6805u3_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m6805u3_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: }; @@ -394,19 +394,19 @@ protected: class hd6805s1_device : public m6805_mrom_device { public: - hd6805s1_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + hd6805s1_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class hd6805u1_device : public m6805_mrom_device { public: - hd6805u1_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + hd6805u1_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class m68705p3_device : public m68705p_device { public: - m68705p3_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68705p3_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual tiny_rom_entry const *device_rom_region() const override; @@ -417,7 +417,7 @@ protected: class m68705p5_device : public m68705p_device { public: - m68705p5_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68705p5_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual tiny_rom_entry const *device_rom_region() const override; @@ -428,7 +428,7 @@ protected: class m68705r3_device : public m68705r_device { public: - m68705r3_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68705r3_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual tiny_rom_entry const *device_rom_region() const override; @@ -439,7 +439,7 @@ protected: class m68705u3_device : public m68705u_device { public: - m68705u3_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68705u3_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); static auto parent_rom_device_type() { return &M68705R3; } diff --git a/src/devices/cpu/m6805/m68hc05.cpp b/src/devices/cpu/m6805/m68hc05.cpp index df7c590d3a3..a18fdd7ccfb 100644 --- a/src/devices/cpu/m6805/m68hc05.cpp +++ b/src/devices/cpu/m6805/m68hc05.cpp @@ -138,7 +138,7 @@ m68hc05_device::m68hc05_device( machine_config const &mconfig, char const *tag, device_t *owner, - u32 clock, + const XTAL &clock, device_type type, u32 addr_width, u16 vector_mask, @@ -759,7 +759,7 @@ m68hc705_device::m68hc705_device( machine_config const &mconfig, char const *tag, device_t *owner, - u32 clock, + const XTAL &clock, device_type type, u32 addr_width, address_map_constructor internal_map) @@ -805,7 +805,7 @@ void m68hc05c4_device::c4_map(address_map &map) } -m68hc05c4_device::m68hc05c4_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +m68hc05c4_device::m68hc05c4_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68hc05_device( mconfig, tag, @@ -872,7 +872,7 @@ void m68hc05c8_device::c8_map(address_map &map) } -m68hc05c8_device::m68hc05c8_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +m68hc05c8_device::m68hc05c8_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68hc05_device( mconfig, tag, @@ -943,7 +943,7 @@ void m68hc705c4a_device::c4a_map(address_map &map) } -m68hc705c4a_device::m68hc705c4a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +m68hc705c4a_device::m68hc705c4a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68hc705_device( mconfig, tag, @@ -1039,7 +1039,7 @@ void m68hc705c8a_device::c8a_map(address_map &map) } -m68hc705c8a_device::m68hc705c8a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +m68hc705c8a_device::m68hc705c8a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68hc705_device( mconfig, tag, @@ -1155,7 +1155,7 @@ void m68hc705j1a_device::j1a_map(address_map &map) } -m68hc705j1a_device::m68hc705j1a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +m68hc705j1a_device::m68hc705j1a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68hc705_device( mconfig, tag, @@ -1235,7 +1235,7 @@ void m68hc05l9_device::l9_map(address_map &map) } -m68hc05l9_device::m68hc05l9_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +m68hc05l9_device::m68hc05l9_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68hc05_device( mconfig, tag, @@ -1318,7 +1318,7 @@ void m68hc05l11_device::l11_map(address_map &map) } -m68hc05l11_device::m68hc05l11_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +m68hc05l11_device::m68hc05l11_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : m68hc05_device( mconfig, tag, diff --git a/src/devices/cpu/m6805/m68hc05.h b/src/devices/cpu/m6805/m68hc05.h index 939f71de211..5843a7df2f0 100644 --- a/src/devices/cpu/m6805/m68hc05.h +++ b/src/devices/cpu/m6805/m68hc05.h @@ -87,7 +87,7 @@ protected: machine_config const &mconfig, char const *tag, device_t *owner, - u32 clock, + const XTAL &clock, device_type type, u32 addr_width, u16 vector_mask, @@ -189,7 +189,7 @@ protected: machine_config const &mconfig, char const *tag, device_t *owner, - u32 clock, + const XTAL &clock, device_type type, u32 addr_width, address_map_constructor internal_map); @@ -201,7 +201,7 @@ protected: class m68hc05c4_device : public m68hc05_device { public: - m68hc05c4_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68hc05c4_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: void c4_map(address_map &map); @@ -217,7 +217,7 @@ protected: class m68hc05c8_device : public m68hc05_device { public: - m68hc05c8_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68hc05c8_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: void c8_map(address_map &map); @@ -233,7 +233,7 @@ protected: class m68hc705c4a_device : public m68hc705_device { public: - m68hc705c4a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68hc705c4a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: void c4a_map(address_map &map); @@ -257,7 +257,7 @@ private: class m68hc705c8a_device : public m68hc705_device { public: - m68hc705c8a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68hc705c8a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: void c8a_map(address_map &map); @@ -287,7 +287,7 @@ private: class m68hc705j1a_device : public m68hc705_device { public: - m68hc705j1a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68hc705j1a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: void j1a_map(address_map &map); @@ -304,7 +304,7 @@ protected: class m68hc05l9_device : public m68hc05_device { public: - m68hc05l9_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68hc05l9_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: void l9_map(address_map &map); @@ -320,7 +320,7 @@ protected: class m68hc05l11_device : public m68hc05_device { public: - m68hc05l11_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + m68hc05l11_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: void l11_map(address_map &map); diff --git a/src/devices/cpu/m6809/hd6309.cpp b/src/devices/cpu/m6809/hd6309.cpp index 03eb11336e2..6da69f8ca05 100644 --- a/src/devices/cpu/m6809/hd6309.cpp +++ b/src/devices/cpu/m6809/hd6309.cpp @@ -132,19 +132,19 @@ DEFINE_DEVICE_TYPE(HD6309E, hd6309e_device, "hd6309e", "Hitachi HD6309E") // hd6309_device - constructor //------------------------------------------------- -hd6309_device::hd6309_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, device_type type, int divider) : +hd6309_device::hd6309_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, device_type type, int divider) : m6809_base_device(mconfig, tag, owner, clock, type, divider), m_md(0), m_temp_im(0) { } -hd6309_device::hd6309_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +hd6309_device::hd6309_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6309_device(mconfig, tag, owner, clock, HD6309, 4) { } -hd6309e_device::hd6309e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +hd6309e_device::hd6309e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6309_device(mconfig, tag, owner, clock, HD6309E, 1) { } diff --git a/src/devices/cpu/m6809/hd6309.h b/src/devices/cpu/m6809/hd6309.h index 99065882116..5764d5314de 100644 --- a/src/devices/cpu/m6809/hd6309.h +++ b/src/devices/cpu/m6809/hd6309.h @@ -30,11 +30,11 @@ class hd6309_device : public m6809_base_device { public: // construction/destruction - hd6309_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd6309_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // delegating constructor - hd6309_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, device_type type, int divider); + hd6309_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, device_type type, int divider); // device-level overrides virtual void device_start() override; @@ -148,7 +148,7 @@ class hd6309e_device : public hd6309_device { public: // construction/destruction - hd6309e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd6309e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; #define HD6309_IRQ_LINE M6809_IRQ_LINE /* 0 - IRQ line number */ diff --git a/src/devices/cpu/m6809/konami.cpp b/src/devices/cpu/m6809/konami.cpp index 95bd6765526..b0c76e0f8fc 100644 --- a/src/devices/cpu/m6809/konami.cpp +++ b/src/devices/cpu/m6809/konami.cpp @@ -84,7 +84,7 @@ DEFINE_DEVICE_TYPE(KONAMI, konami_cpu_device, "konami_cpu", "KONAMI CPU") // konami_cpu_device - constructor //------------------------------------------------- -konami_cpu_device::konami_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +konami_cpu_device::konami_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6809_base_device(mconfig, tag, owner, clock, KONAMI, 1) , m_set_lines(*this) { diff --git a/src/devices/cpu/m6809/konami.h b/src/devices/cpu/m6809/konami.h index edb595d771e..44e08872724 100644 --- a/src/devices/cpu/m6809/konami.h +++ b/src/devices/cpu/m6809/konami.h @@ -29,7 +29,7 @@ class konami_cpu_device : public m6809_base_device { public: // construction/destruction - konami_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + konami_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration auto line() { return m_set_lines.bind(); } diff --git a/src/devices/cpu/m6809/m6809.cpp b/src/devices/cpu/m6809/m6809.cpp index 52ddfa433c6..9536081d001 100644 --- a/src/devices/cpu/m6809/m6809.cpp +++ b/src/devices/cpu/m6809/m6809.cpp @@ -136,7 +136,7 @@ DEFINE_DEVICE_TYPE(M6809, m6809_device, "m6809", "MC6809 (legacy)") // m6809_base_device - constructor //------------------------------------------------- -m6809_base_device::m6809_base_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, const device_type type, int divider) +m6809_base_device::m6809_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, int divider) : cpu_device(mconfig, type, tag, owner, clock), m_lic_func(*this), m_program_config("program", ENDIANNESS_BIG, 8, 16), @@ -603,7 +603,7 @@ void m6809_base_device::mi_default::write(uint16_t adr, uint8_t val) // mc6809_device //------------------------------------------------- -mc6809_device::mc6809_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6809_device::mc6809_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6809_base_device(mconfig, tag, owner, clock, MC6809, 4) { } @@ -614,7 +614,7 @@ mc6809_device::mc6809_device(const machine_config &mconfig, const char *tag, dev // mc6809e_device //------------------------------------------------- -mc6809e_device::mc6809e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6809e_device::mc6809e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6809_base_device(mconfig, tag, owner, clock, MC6809E, 1) { } @@ -625,7 +625,7 @@ mc6809e_device::mc6809e_device(const machine_config &mconfig, const char *tag, d // m6809_device //------------------------------------------------- -m6809_device::m6809_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m6809_device::m6809_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m6809_base_device(mconfig, tag, owner, clock, M6809, 1) { } diff --git a/src/devices/cpu/m6809/m6809.h b/src/devices/cpu/m6809/m6809.h index 3fc0b8bae1d..490a7658511 100644 --- a/src/devices/cpu/m6809/m6809.h +++ b/src/devices/cpu/m6809/m6809.h @@ -30,7 +30,7 @@ class m6809_base_device : public cpu_device { protected: // construction/destruction - m6809_base_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, const device_type type, int divider); + m6809_base_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const device_type type, int divider); class memory_interface { public: @@ -302,7 +302,7 @@ class mc6809_device : public m6809_base_device { public: // construction/destruction - mc6809_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6809_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> mc6809e_device @@ -311,7 +311,7 @@ class mc6809e_device : public m6809_base_device { public: // construction/destruction - mc6809e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6809e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // MC6809E has LIC line to indicate opcode/data fetch auto lic() { return m_lic_func.bind(); } @@ -323,7 +323,7 @@ class m6809_device : public m6809_base_device { public: // construction/destruction - m6809_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m6809_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; enum diff --git a/src/devices/cpu/m68hc16/cpu16.cpp b/src/devices/cpu/m68hc16/cpu16.cpp index ea6bfbefe78..313f28dff79 100644 --- a/src/devices/cpu/m68hc16/cpu16.cpp +++ b/src/devices/cpu/m68hc16/cpu16.cpp @@ -181,7 +181,7 @@ enum class cpu16_device::seq : u16 ALLOW_SAVE_TYPE(cpu16_device::seq) -cpu16_device::cpu16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map) +cpu16_device::cpu16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, 20, 0, map) , m_data_config("data", ENDIANNESS_BIG, 16, 20, 0, map) diff --git a/src/devices/cpu/m68hc16/cpu16.h b/src/devices/cpu/m68hc16/cpu16.h index bb8c47bbd1c..48c6dce7848 100644 --- a/src/devices/cpu/m68hc16/cpu16.h +++ b/src/devices/cpu/m68hc16/cpu16.h @@ -26,7 +26,7 @@ public: protected: // construction/destruction - cpu16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map); + cpu16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/m68hc16/m68hc16z.cpp b/src/devices/cpu/m68hc16/m68hc16z.cpp index 9bd136eb053..0974727634a 100644 --- a/src/devices/cpu/m68hc16/m68hc16z.cpp +++ b/src/devices/cpu/m68hc16/m68hc16z.cpp @@ -29,7 +29,7 @@ // device type definition DEFINE_DEVICE_TYPE(MC68HC16Z1, mc68hc16z1_device, "mc68hc16z1", "Motorola MC68HC16Z1") -m68hc16z_device::m68hc16z_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map) +m68hc16z_device::m68hc16z_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map) : cpu16_device(mconfig, type, tag, owner, clock, map) , m_pitr(0) , m_sccr{0, 0} @@ -38,7 +38,7 @@ m68hc16z_device::m68hc16z_device(const machine_config &mconfig, device_type type { } -mc68hc16z1_device::mc68hc16z1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mc68hc16z1_device::mc68hc16z1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68hc16z_device(mconfig, MC68HC16Z1, tag, owner, clock, address_map_constructor(FUNC(mc68hc16z1_device::internal_map), this)) { } diff --git a/src/devices/cpu/m68hc16/m68hc16z.h b/src/devices/cpu/m68hc16/m68hc16z.h index e28fb879df1..ebfc7fc08a0 100644 --- a/src/devices/cpu/m68hc16/m68hc16z.h +++ b/src/devices/cpu/m68hc16/m68hc16z.h @@ -12,7 +12,7 @@ class m68hc16z_device : public cpu16_device { protected: - m68hc16z_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map); + m68hc16z_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map); // device-level overrides virtual void device_start() override; @@ -92,7 +92,7 @@ class mc68hc16z1_device : public m68hc16z_device { public: // device type constructor - mc68hc16z1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mc68hc16z1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: void internal_map(address_map &map); diff --git a/src/devices/cpu/m88000/m88000.cpp b/src/devices/cpu/m88000/m88000.cpp index f3921bc8667..89d369d4020 100644 --- a/src/devices/cpu/m88000/m88000.cpp +++ b/src/devices/cpu/m88000/m88000.cpp @@ -127,7 +127,7 @@ enum fcr_mask : u32 // device type definitions DEFINE_DEVICE_TYPE(MC88100, mc88100_device, "mc88100", "Motorola MC88100") -mc88100_device::mc88100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mc88100_device::mc88100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, MC88100, tag, owner, clock) , m_code_config("code", ENDIANNESS_BIG, 32, 32, 0) , m_data_config("data", ENDIANNESS_BIG, 32, 32, 0) diff --git a/src/devices/cpu/m88000/m88000.h b/src/devices/cpu/m88000/m88000.h index 896ab05df51..cb361970f1a 100644 --- a/src/devices/cpu/m88000/m88000.h +++ b/src/devices/cpu/m88000/m88000.h @@ -17,7 +17,7 @@ class mc88100_device : public cpu_device { public: // construction/destruction - mc88100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mc88100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/mb86233/mb86233.cpp b/src/devices/cpu/mb86233/mb86233.cpp index 479b6fa0399..180e61d7472 100644 --- a/src/devices/cpu/mb86233/mb86233.cpp +++ b/src/devices/cpu/mb86233/mb86233.cpp @@ -48,7 +48,7 @@ DEFINE_DEVICE_TYPE(MB86233, mb86233_device, "mb86233", "Fujitsu MB86233 (TGP)") DEFINE_DEVICE_TYPE(MB86234, mb86234_device, "mb86234", "Fujitsu MB86234 (TGP)") -mb86233_device::mb86233_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mb86233_device::mb86233_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 32, 16, -2) , m_data_config("data", ENDIANNESS_LITTLE, 32, 16, -2) @@ -57,12 +57,12 @@ mb86233_device::mb86233_device(const machine_config &mconfig, device_type type, { } -mb86233_device::mb86233_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb86233_device::mb86233_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb86233_device(mconfig, MB86233, tag, owner, clock) { } -mb86234_device::mb86234_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb86234_device::mb86234_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb86233_device(mconfig, MB86234, tag, owner, clock) { } diff --git a/src/devices/cpu/mb86233/mb86233.h b/src/devices/cpu/mb86233/mb86233.h index 4b1915dc836..d62f24db785 100644 --- a/src/devices/cpu/mb86233/mb86233.h +++ b/src/devices/cpu/mb86233/mb86233.h @@ -58,7 +58,7 @@ public: F_ZC1 = 0x80000000 }; - mb86233_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb86233_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void stall() { m_stall = true; } @@ -68,7 +68,7 @@ public: DECLARE_WRITE_LINE_MEMBER(gpio3_w); protected: - mb86233_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mb86233_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -134,7 +134,7 @@ private: class mb86234_device : public mb86233_device { public: - mb86234_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb86234_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/mb86235/mb86235.cpp b/src/devices/cpu/mb86235/mb86235.cpp index 23e52b6d1be..5449c900ab3 100644 --- a/src/devices/cpu/mb86235/mb86235.cpp +++ b/src/devices/cpu/mb86235/mb86235.cpp @@ -258,7 +258,7 @@ void mb86235_cpu_device::execute_set_input(int irqline, int state) } #endif -mb86235_device::mb86235_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb86235_device::mb86235_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, MB86235, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 64, 32, -3) , m_dataa_config("data_a", ENDIANNESS_LITTLE, 32, 24, -2, address_map_constructor(FUNC(mb86235_device::internal_abus), this)) diff --git a/src/devices/cpu/mb86235/mb86235.h b/src/devices/cpu/mb86235/mb86235.h index c859807bf56..652b5798684 100644 --- a/src/devices/cpu/mb86235/mb86235.h +++ b/src/devices/cpu/mb86235/mb86235.h @@ -23,7 +23,7 @@ class mb86235_device : public cpu_device public: // construction/destruction - mb86235_device(const machine_config &mconfig, const char *_tag, device_t *_owner, uint32_t clock); + mb86235_device(const machine_config &mconfig, const char *_tag, device_t *_owner, const XTAL &clock); virtual ~mb86235_device() override; template <typename T> void set_fifoin_tag(T &&fifo_tag) { m_fifoin.set_tag(std::forward<T>(fifo_tag)); } diff --git a/src/devices/cpu/mb88xx/mb88xx.cpp b/src/devices/cpu/mb88xx/mb88xx.cpp index 1ef53c5e00b..c45520262e2 100644 --- a/src/devices/cpu/mb88xx/mb88xx.cpp +++ b/src/devices/cpu/mb88xx/mb88xx.cpp @@ -112,7 +112,7 @@ void mb88_cpu_device::data_7bit(address_map &map) } -mb88_cpu_device::mb88_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width) +mb88_cpu_device::mb88_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, program_width, 0, (program_width == 9) ? address_map_constructor(FUNC(mb88_cpu_device::program_9bit), this) : (program_width == 10) ? address_map_constructor(FUNC(mb88_cpu_device::program_10bit), this) : address_map_constructor(FUNC(mb88_cpu_device::program_11bit), this)) , m_data_config("data", ENDIANNESS_BIG, 8, data_width, 0, (data_width == 4) ? address_map_constructor(FUNC(mb88_cpu_device::data_4bit), this) : (data_width == 5) ? address_map_constructor(FUNC(mb88_cpu_device::data_5bit), this) : (data_width == 6) ? address_map_constructor(FUNC(mb88_cpu_device::data_6bit), this) : address_map_constructor(FUNC(mb88_cpu_device::data_7bit), this)) @@ -127,36 +127,36 @@ mb88_cpu_device::mb88_cpu_device(const machine_config &mconfig, device_type type { } -mb88201_cpu_device::mb88201_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb88201_cpu_device::mb88201_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb88_cpu_device(mconfig, MB88201, tag, owner, clock, 9, 4) { } -mb88202_cpu_device::mb88202_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb88202_cpu_device::mb88202_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb88_cpu_device(mconfig, MB88202, tag, owner, clock, 10, 5) { } -mb8841_cpu_device::mb8841_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb8841_cpu_device::mb8841_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb88_cpu_device(mconfig, MB8841, tag, owner, clock, 11, 7) { } -mb8842_cpu_device::mb8842_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb8842_cpu_device::mb8842_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb88_cpu_device(mconfig, MB8842, tag, owner, clock, 11, 7) { } -mb8843_cpu_device::mb8843_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb8843_cpu_device::mb8843_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb88_cpu_device(mconfig, MB8843, tag, owner, clock, 10, 6) { } -mb8844_cpu_device::mb8844_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb8844_cpu_device::mb8844_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb88_cpu_device(mconfig, MB8844, tag, owner, clock, 10, 6) { } diff --git a/src/devices/cpu/mb88xx/mb88xx.h b/src/devices/cpu/mb88xx/mb88xx.h index 6bae70de879..fc4b23950eb 100644 --- a/src/devices/cpu/mb88xx/mb88xx.h +++ b/src/devices/cpu/mb88xx/mb88xx.h @@ -106,7 +106,7 @@ public: void program_11bit(address_map &map); void program_9bit(address_map &map); protected: - mb88_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width); + mb88_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width); // device-level overrides virtual void device_start() override; @@ -199,7 +199,7 @@ class mb88201_cpu_device : public mb88_cpu_device { public: // construction/destruction - mb88201_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb88201_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -207,7 +207,7 @@ class mb88202_cpu_device : public mb88_cpu_device { public: // construction/destruction - mb88202_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb88202_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -215,7 +215,7 @@ class mb8841_cpu_device : public mb88_cpu_device { public: // construction/destruction - mb8841_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb8841_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -223,7 +223,7 @@ class mb8842_cpu_device : public mb88_cpu_device { public: // construction/destruction - mb8842_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb8842_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -231,7 +231,7 @@ class mb8843_cpu_device : public mb88_cpu_device { public: // construction/destruction - mb8843_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb8843_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -239,7 +239,7 @@ class mb8844_cpu_device : public mb88_cpu_device { public: // construction/destruction - mb8844_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb8844_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/mc68hc11/mc68hc11.cpp b/src/devices/cpu/mc68hc11/mc68hc11.cpp index 6a03dcb769b..2a9da9bb22a 100644 --- a/src/devices/cpu/mc68hc11/mc68hc11.cpp +++ b/src/devices/cpu/mc68hc11/mc68hc11.cpp @@ -53,7 +53,7 @@ DEFINE_DEVICE_TYPE(MC68HC11K1, mc68hc11k1_device, "mc68hc11k1", "Motorola MC68HC DEFINE_DEVICE_TYPE(MC68HC11M0, mc68hc11m0_device, "mc68hc11m0", "Motorola MC68HC11M0") -mc68hc11_cpu_device::mc68hc11_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint16_t ram_size, uint16_t reg_block_size, uint16_t rom_size, uint16_t eeprom_size, uint8_t init_value, uint8_t config_mask, uint8_t option_mask) +mc68hc11_cpu_device::mc68hc11_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint16_t ram_size, uint16_t reg_block_size, uint16_t rom_size, uint16_t eeprom_size, uint8_t init_value, uint8_t config_mask, uint8_t option_mask) : cpu_device(mconfig, type, tag, owner, clock) , device_nvram_interface(mconfig, *this, (config_mask & 0xf9) != 0) , m_program_config("program", ENDIANNESS_BIG, 8, 16, 0, address_map_constructor(FUNC(mc68hc11_cpu_device::internal_map), this)) @@ -107,38 +107,38 @@ void mc68hc11_cpu_device::internal_map(address_map &map) } } -mc68hc11a1_device::mc68hc11a1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68hc11a1_device::mc68hc11a1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68hc11_cpu_device(mconfig, MC68HC11A1, tag, owner, clock, 256, 64, 0, 512, 0x01, 0x0f, 0xfb) { } -mc68hc11d0_device::mc68hc11d0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68hc11d0_device::mc68hc11d0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68hc11_cpu_device(mconfig, MC68HC11D0, tag, owner, clock, 192, 64, 0, 0, 0x00, 0x06, 0x3b) { } -mc68hc11e1_device::mc68hc11e1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68hc11e1_device::mc68hc11e1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68hc11_cpu_device(mconfig, MC68HC11E1, tag, owner, clock, 512, 64, 0, 512, 0x01, 0x0f, 0xfb) { } -mc68hc811e2_device::mc68hc811e2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68hc811e2_device::mc68hc811e2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68hc11_cpu_device(mconfig, MC68HC811E2, tag, owner, clock, 256, 64, 0, 2048, 0x01, 0xf5, 0xfb) { } -mc68hc11f1_device::mc68hc11f1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68hc11f1_device::mc68hc11f1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68hc11_cpu_device(mconfig, MC68HC11F1, tag, owner, clock, 1024, 96, 0, 512, 0x01, 0xf5, 0xff) { m_config &= 0x0f; } -mc68hc11k1_device::mc68hc11k1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68hc11k1_device::mc68hc11k1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68hc11_cpu_device(mconfig, MC68HC11K1, tag, owner, clock, 768, 128, 0, 640, 0x00, 0xbf, 0xff) { } -mc68hc11m0_device::mc68hc11m0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68hc11m0_device::mc68hc11m0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68hc11_cpu_device(mconfig, MC68HC11M0, tag, owner, clock, 1280, 256, 0, 0, 0x00, 0x06, 0xff) { } diff --git a/src/devices/cpu/mc68hc11/mc68hc11.h b/src/devices/cpu/mc68hc11/mc68hc11.h index f4b60849063..45564643f3b 100644 --- a/src/devices/cpu/mc68hc11/mc68hc11.h +++ b/src/devices/cpu/mc68hc11/mc68hc11.h @@ -54,7 +54,7 @@ public: void set_default_config(uint8_t data) { assert(!configured()); m_config = data & m_config_mask; } protected: - mc68hc11_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint16_t ram_size, uint16_t reg_block_size, uint16_t rom_size, uint16_t eeprom_size, uint8_t init_value, uint8_t config_mask, uint8_t option_mask); + mc68hc11_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint16_t ram_size, uint16_t reg_block_size, uint16_t rom_size, uint16_t eeprom_size, uint8_t init_value, uint8_t config_mask, uint8_t option_mask); // device-level overrides virtual void device_resolve_objects() override; @@ -560,7 +560,7 @@ class mc68hc11a1_device : public mc68hc11_cpu_device { public: // construction/destruction - mc68hc11a1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc68hc11a1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; @@ -575,7 +575,7 @@ class mc68hc11d0_device : public mc68hc11_cpu_device { public: // construction/destruction - mc68hc11d0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc68hc11d0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; @@ -590,7 +590,7 @@ class mc68hc11e1_device : public mc68hc11_cpu_device { public: // construction/destruction - mc68hc11e1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc68hc11e1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; @@ -602,7 +602,7 @@ class mc68hc811e2_device : public mc68hc11_cpu_device { public: // construction/destruction - mc68hc811e2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc68hc811e2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; @@ -614,7 +614,7 @@ class mc68hc11f1_device : public mc68hc11_cpu_device { public: // construction/destruction - mc68hc11f1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc68hc11f1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; @@ -626,7 +626,7 @@ class mc68hc11k1_device : public mc68hc11_cpu_device { public: // construction/destruction - mc68hc11k1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc68hc11k1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void mc68hc11_reg_map(memory_view::memory_view_entry &block, offs_t base) override; @@ -636,7 +636,7 @@ class mc68hc11m0_device : public mc68hc11_cpu_device { public: // construction/destruction - mc68hc11m0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc68hc11m0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void mc68hc11_reg_map(memory_view::memory_view_entry &block, offs_t base) override; diff --git a/src/devices/cpu/mcs40/mcs40.cpp b/src/devices/cpu/mcs40/mcs40.cpp index 0b9b80c719f..9e2c10031fd 100644 --- a/src/devices/cpu/mcs40/mcs40.cpp +++ b/src/devices/cpu/mcs40/mcs40.cpp @@ -85,7 +85,7 @@ mcs40_cpu_device_base::mcs40_cpu_device_base( device_type type, const char *tag, device_t *owner, - u32 clock, + const XTAL &clock, bool extended_cm, unsigned rom_width, unsigned stack_ptr_mask, @@ -822,7 +822,7 @@ inline void mcs40_cpu_device_base::update_4289_f_l(u8 val) -i4004_cpu_device::i4004_cpu_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +i4004_cpu_device::i4004_cpu_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mcs40_cpu_device_base(mconfig, I4004, tag, owner, clock, false, 12U, 0x3U, 16U, 0x7U) { } @@ -1132,7 +1132,7 @@ u8 i4004_cpu_device::do_io(u8 opr, u8 opa) -i4040_cpu_device::i4040_cpu_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +i4040_cpu_device::i4040_cpu_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : i4004_cpu_device(mconfig, I4040, tag, owner, clock, true, 13U, 0x7U, 24U, 0xfU) { } diff --git a/src/devices/cpu/mcs40/mcs40.h b/src/devices/cpu/mcs40/mcs40.h index 68a8dca161f..69e11def3c9 100644 --- a/src/devices/cpu/mcs40/mcs40.h +++ b/src/devices/cpu/mcs40/mcs40.h @@ -74,7 +74,7 @@ protected: device_type type, char const *tag, device_t *owner, - u32 clock, + const XTAL &clock, bool extended_cm, unsigned rom_width, unsigned stack_ptr_mask, @@ -253,7 +253,7 @@ public: auto cm_rom_cb() { return mcs40_cpu_device_base::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); + i4004_cpu_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: using mcs40_cpu_device_base::mcs40_cpu_device_base; @@ -282,7 +282,7 @@ public: auto cy_cb() { return i4004_cpu_device::cy_cb(); } using mcs40_cpu_device_base::stp_ack_cb; - i4040_cpu_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + i4040_cpu_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface implementation diff --git a/src/devices/cpu/mcs48/mcs48.cpp b/src/devices/cpu/mcs48/mcs48.cpp index b429ac28ead..df57397e7ee 100644 --- a/src/devices/cpu/mcs48/mcs48.cpp +++ b/src/devices/cpu/mcs48/mcs48.cpp @@ -199,7 +199,7 @@ void mcs48_cpu_device::data_8bit(address_map &map) } -mcs48_cpu_device::mcs48_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int rom_size, int ram_size, uint8_t feature_mask, const mcs48_cpu_device::mcs48_ophandler *opcode_table) +mcs48_cpu_device::mcs48_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int rom_size, int ram_size, uint8_t feature_mask, const mcs48_cpu_device::mcs48_ophandler *opcode_table) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, (feature_mask & MB_FEATURE) != 0 ? 12 : 11, 0 , (rom_size == 1024) ? address_map_constructor(FUNC(mcs48_cpu_device::program_10bit), this) : (rom_size == 2048) ? address_map_constructor(FUNC(mcs48_cpu_device::program_11bit), this) : (rom_size == 4096) ? address_map_constructor(FUNC(mcs48_cpu_device::program_12bit), this) : address_map_constructor()) @@ -231,117 +231,117 @@ mcs48_cpu_device::mcs48_cpu_device(const machine_config &mconfig, device_type ty } } -i8021_device::i8021_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8021_device::i8021_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8021, tag, owner, clock, 1024, 64, I802X_FEATURE, s_i8021_opcodes) { } -i8022_device::i8022_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8022_device::i8022_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8022, tag, owner, clock, 2048, 128, I802X_FEATURE, s_i8022_opcodes) { } -i8035_device::i8035_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8035_device::i8035_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8035, tag, owner, clock, 0, 64, I8048_FEATURE, s_mcs48_opcodes) { } -i8048_device::i8048_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8048_device::i8048_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8048, tag, owner, clock, 1024, 64, I8048_FEATURE, s_mcs48_opcodes) { } -i8648_device::i8648_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8648_device::i8648_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8648, tag, owner, clock, 1024, 64, I8048_FEATURE, s_mcs48_opcodes) { } -i8748_device::i8748_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8748_device::i8748_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8748, tag, owner, clock, 1024, 64, I8048_FEATURE, s_mcs48_opcodes) { } -i8039_device::i8039_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8039_device::i8039_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8039, tag, owner, clock, 0, 128, I8048_FEATURE, s_mcs48_opcodes) { } -i8049_device::i8049_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8049_device::i8049_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8049, tag, owner, clock, 2048, 128, I8048_FEATURE, s_mcs48_opcodes) { } -i8749_device::i8749_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8749_device::i8749_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8749, tag, owner, clock, 2048, 128, I8048_FEATURE, s_mcs48_opcodes) { } -i8040_device::i8040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8040_device::i8040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8040, tag, owner, clock, 0, 256, I8048_FEATURE, s_mcs48_opcodes) { } -i8050_device::i8050_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8050_device::i8050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, I8050, tag, owner, clock, 4096, 256, I8048_FEATURE, s_mcs48_opcodes) { } -mb8884_device::mb8884_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb8884_device::mb8884_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, MB8884, tag, owner, clock, 0, 64, I8048_FEATURE, s_mcs48_opcodes) { } -n7751_device::n7751_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +n7751_device::n7751_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, N7751, tag, owner, clock, 1024, 64, I8048_FEATURE, s_mcs48_opcodes) { } -m58715_device::m58715_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m58715_device::m58715_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs48_cpu_device(mconfig, M58715, tag, owner, clock, 2048, 128, I8048_FEATURE, s_mcs48_opcodes) { } -upi41_cpu_device::upi41_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int rom_size, int ram_size) +upi41_cpu_device::upi41_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int rom_size, int ram_size) : mcs48_cpu_device(mconfig, type, tag, owner, clock, rom_size, ram_size, UPI41_FEATURE, s_upi41_opcodes) { } -i8041a_device::i8041a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8041a_device::i8041a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upi41_cpu_device(mconfig, I8041A, tag, owner, clock, 1024, 64) { } -i8741a_device::i8741a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8741a_device::i8741a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upi41_cpu_device(mconfig, I8741A, tag, owner, clock, 1024, 64) { } -i8041ah_device::i8041ah_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8041ah_device::i8041ah_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upi41_cpu_device(mconfig, I8041AH, tag, owner, clock, 1024, 128) { } -i8741ah_device::i8741ah_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8741ah_device::i8741ah_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upi41_cpu_device(mconfig, I8741AH, tag, owner, clock, 1024, 128) { } -i8042_device::i8042_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8042_device::i8042_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upi41_cpu_device(mconfig, I8042, tag, owner, clock, 2048, 128) { } -i8742_device::i8742_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8742_device::i8742_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upi41_cpu_device(mconfig, I8742, tag, owner, clock, 2048, 128) { } -i8042ah_device::i8042ah_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8042ah_device::i8042ah_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upi41_cpu_device(mconfig, I8042AH, tag, owner, clock, 2048, 256) { } -i8742ah_device::i8742ah_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8742ah_device::i8742ah_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upi41_cpu_device(mconfig, I8742AH, tag, owner, clock, 2048, 256) { } @@ -1226,7 +1226,7 @@ void mcs48_cpu_device::device_reset() m_flags_enabled = false; m_dma_enabled = false; if (!m_t0_clk_func.isnull()) - m_t0_clk_func(0); + m_t0_clk_func(XTAL()); // confirmed from interrupt logic description m_irq_in_progress = false; diff --git a/src/devices/cpu/mcs48/mcs48.h b/src/devices/cpu/mcs48/mcs48.h index bb5d3da44f9..f61609b3907 100644 --- a/src/devices/cpu/mcs48/mcs48.h +++ b/src/devices/cpu/mcs48/mcs48.h @@ -141,7 +141,7 @@ protected: typedef void (mcs48_cpu_device::*mcs48_ophandler)(); // construction/destruction - mcs48_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int rom_size, int ram_size, uint8_t feature_mask, const mcs48_ophandler *opcode_table); + mcs48_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int rom_size, int ram_size, uint8_t feature_mask, const mcs48_ophandler *opcode_table); // device-level overrides virtual void device_start() override; @@ -516,7 +516,7 @@ public: auto p0_out_cb() { return bus_out_cb(); } // construction/destruction - i8021_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8021_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides @@ -528,7 +528,7 @@ class i8022_device : public mcs48_cpu_device { public: // construction/destruction - i8022_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8022_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides @@ -540,84 +540,84 @@ class i8035_device : public mcs48_cpu_device { public: // construction/destruction - i8035_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8035_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8048_device : public mcs48_cpu_device { public: // construction/destruction - i8048_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8048_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8648_device : public mcs48_cpu_device { public: // construction/destruction - i8648_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8648_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8748_device : public mcs48_cpu_device { public: // construction/destruction - i8748_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8748_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8039_device : public mcs48_cpu_device { public: // construction/destruction - i8039_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8039_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8049_device : public mcs48_cpu_device { public: // construction/destruction - i8049_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8049_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8749_device : public mcs48_cpu_device { public: // construction/destruction - i8749_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8749_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8040_device : public mcs48_cpu_device { public: // construction/destruction - i8040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8050_device : public mcs48_cpu_device { public: // construction/destruction - i8050_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mb8884_device : public mcs48_cpu_device { public: // construction/destruction - mb8884_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb8884_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class n7751_device : public mcs48_cpu_device { public: // construction/destruction - n7751_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + n7751_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class m58715_device : public mcs48_cpu_device { public: // construction/destruction - m58715_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m58715_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -630,7 +630,7 @@ public: protected: // construction/destruction - upi41_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int rom_size, int ram_size); + upi41_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int rom_size, int ram_size); TIMER_CALLBACK_MEMBER( master_callback ); }; @@ -639,56 +639,56 @@ class i8041a_device : public upi41_cpu_device { public: // construction/destruction - i8041a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8041a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8741a_device : public upi41_cpu_device { public: // construction/destruction - i8741a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8741a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8041ah_device : public upi41_cpu_device { public: // construction/destruction - i8041ah_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8041ah_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8741ah_device : public upi41_cpu_device { public: // construction/destruction - i8741ah_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8741ah_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8042_device : public upi41_cpu_device { public: // construction/destruction - i8042_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8042_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8742_device : public upi41_cpu_device { public: // construction/destruction - i8742_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8742_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8042ah_device : public upi41_cpu_device { public: // construction/destruction - i8042ah_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8042ah_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8742ah_device : public upi41_cpu_device { public: // construction/destruction - i8742ah_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8742ah_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/mcs51/mcs51.cpp b/src/devices/cpu/mcs51/mcs51.cpp index 9f5bd04e4c0..a463992cebc 100644 --- a/src/devices/cpu/mcs51/mcs51.cpp +++ b/src/devices/cpu/mcs51/mcs51.cpp @@ -267,7 +267,7 @@ void mcs51_cpu_device::data_internal(address_map &map) -mcs51_cpu_device::mcs51_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor program_map, address_map_constructor data_map, int program_width, int data_width, uint8_t features) +mcs51_cpu_device::mcs51_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program_map, address_map_constructor data_map, int program_width, int data_width, uint8_t features) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0, program_map) , m_data_config("data", ENDIANNESS_LITTLE, 8, 9, 0, data_map) @@ -295,147 +295,147 @@ mcs51_cpu_device::mcs51_cpu_device(const machine_config &mconfig, device_type ty } -mcs51_cpu_device::mcs51_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features) +mcs51_cpu_device::mcs51_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features) : mcs51_cpu_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(mcs51_cpu_device::program_internal), this), address_map_constructor(FUNC(mcs51_cpu_device::data_internal), this), program_width, data_width, features) { } -i8031_device::i8031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8031_device::i8031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs51_cpu_device(mconfig, I8031, tag, owner, clock, 0, 7) { } -i8051_device::i8051_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8051_device::i8051_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs51_cpu_device(mconfig, I8051, tag, owner, clock, 12, 7) { } -i8751_device::i8751_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8751_device::i8751_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs51_cpu_device(mconfig, I8751, tag, owner, clock, 12, 7) { } -am8753_device::am8753_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am8753_device::am8753_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs51_cpu_device(mconfig, AM8753, tag, owner, clock, 13, 7) { } -i8052_device::i8052_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features) +i8052_device::i8052_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features) : mcs51_cpu_device(mconfig, type, tag, owner, clock, program_width, data_width, features | FEATURE_I8052) { m_num_interrupts = 6; } -i8052_device::i8052_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8052_device::i8052_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8052_device(mconfig, I8052, tag, owner, clock, 13, 8) { } -i8032_device::i8032_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8032_device::i8032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8052_device(mconfig, I8032, tag, owner, clock, 0, 8) { } -i8752_device::i8752_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8752_device::i8752_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8052_device(mconfig, I8752, tag, owner, clock, 13, 8) { } -i80c31_device::i80c31_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i80c31_device::i80c31_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8052_device(mconfig, I80C31, tag, owner, clock, 0, 7) { } -i80c51_device::i80c51_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features) +i80c51_device::i80c51_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features) : mcs51_cpu_device(mconfig, type, tag, owner, clock, program_width, data_width, features | FEATURE_CMOS) { } -i80c51_device::i80c51_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i80c51_device::i80c51_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80c51_device(mconfig, I80C51, tag, owner, clock, 12, 7) { } -i87c51_device::i87c51_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i87c51_device::i87c51_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80c51_device(mconfig, I87C51, tag, owner, clock, 12, 7) { } -i80c52_device::i80c52_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features) +i80c52_device::i80c52_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features) : i8052_device(mconfig, type, tag, owner, clock, program_width, data_width, features | FEATURE_I80C52 | FEATURE_CMOS) { } -i80c52_device::i80c52_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i80c52_device::i80c52_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80c52_device(mconfig, I80C52, tag, owner, clock, 13, 8) { } -i80c32_device::i80c32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i80c32_device::i80c32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80c52_device(mconfig, I80C32, tag, owner, clock, 0, 8) { } -i87c52_device::i87c52_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i87c52_device::i87c52_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80c52_device(mconfig, I87C52, tag, owner, clock, 13, 8) { } -i87c51fa_device::i87c51fa_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features) +i87c51fa_device::i87c51fa_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features) : i80c52_device(mconfig, type, tag, owner, clock, program_width, data_width, features) { } -i87c51fa_device::i87c51fa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i87c51fa_device::i87c51fa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i87c51fa_device(mconfig, I87C51FA, tag, owner, clock, 13, 8) { } -i80c51gb_device::i80c51gb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i80c51gb_device::i80c51gb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i87c51fa_device(mconfig, I80C51GB, tag, owner, clock, 0, 8) { } -at89c52_device::at89c52_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at89c52_device::at89c52_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80c52_device(mconfig, AT89C52, tag, owner, clock, 13, 8) { } -at89s52_device::at89s52_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at89s52_device::at89s52_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80c52_device(mconfig, AT89S52, tag, owner, clock, 13, 8) { } -at89c4051_device::at89c4051_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at89c4051_device::at89c4051_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80c51_device(mconfig, AT89C4051, tag, owner, clock, 12, 7) { } -ds80c320_device::ds80c320_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds80c320_device::ds80c320_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80c52_device(mconfig, DS80C320, tag, owner, clock, 0, 8) { } -sab80c535_device::sab80c535_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sab80c535_device::sab80c535_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i80c51_device(mconfig, SAB80C535, tag, owner, clock, 0, 8) { } -i8344_device::i8344_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8344_device::i8344_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs51_cpu_device(mconfig, I8344, tag, owner, clock, 0, 8) { } -i8744_device::i8744_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8744_device::i8744_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs51_cpu_device(mconfig, I8744, tag, owner, clock, 12, 8) { } /* program width field is set to 0 because technically the SRAM isn't internal */ -ds5002fp_device::ds5002fp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds5002fp_device::ds5002fp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mcs51_cpu_device(mconfig, DS5002FP, tag, owner, clock, 0, 7, FEATURE_DS5002FP | FEATURE_CMOS) , device_nvram_interface(mconfig, *this) , m_region(*this, "internal") diff --git a/src/devices/cpu/mcs51/mcs51.h b/src/devices/cpu/mcs51/mcs51.h index 32925c23de8..39940b2e157 100644 --- a/src/devices/cpu/mcs51/mcs51.h +++ b/src/devices/cpu/mcs51/mcs51.h @@ -71,8 +71,8 @@ public: void data_internal(address_map &map); protected: // construction/destruction - mcs51_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features = 0); - mcs51_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor program_map, address_map_constructor data_map, int program_width, int data_width, uint8_t features = 0); + mcs51_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features = 0); + mcs51_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program_map, address_map_constructor data_map, int program_width, int data_width, uint8_t features = 0); // device-level overrides virtual void device_start() override; @@ -358,28 +358,28 @@ class i8031_device : public mcs51_cpu_device { public: // construction/destruction - i8031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8051_device : public mcs51_cpu_device { public: // construction/destruction - i8051_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8051_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8751_device : public mcs51_cpu_device { public: // construction/destruction - i8751_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8751_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class am8753_device : public mcs51_cpu_device { public: // construction/destruction - am8753_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + am8753_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -387,10 +387,10 @@ class i8052_device : public mcs51_cpu_device { public: // construction/destruction - i8052_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8052_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - i8052_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features = 0); + i8052_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features = 0); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -403,21 +403,21 @@ class i8032_device : public i8052_device { public: // construction/destruction - i8032_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i8752_device : public i8052_device { public: // construction/destruction - i8752_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8752_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i80c31_device : public i8052_device { public: // construction/destruction - i80c31_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i80c31_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -428,10 +428,10 @@ class i80c51_device : public mcs51_cpu_device { public: // construction/destruction - i80c51_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i80c51_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - i80c51_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features = 0); + i80c51_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features = 0); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; }; @@ -440,7 +440,7 @@ class i87c51_device : public i80c51_device { public: // construction/destruction - i87c51_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i87c51_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -448,10 +448,10 @@ class i80c52_device : public i8052_device { public: // construction/destruction - i80c52_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i80c52_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - i80c52_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features = 0); + i80c52_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features = 0); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -464,24 +464,24 @@ class i80c32_device : public i80c52_device { public: // construction/destruction - i80c32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i80c32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i87c52_device : public i80c52_device { public: // construction/destruction - i87c52_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i87c52_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i87c51fa_device : public i80c52_device { public: // construction/destruction - i87c51fa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i87c51fa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - i87c51fa_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, uint8_t features = 0); + i87c51fa_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, uint8_t features = 0); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; }; @@ -490,7 +490,7 @@ class i80c51gb_device : public i87c51fa_device { public: // construction/destruction - i80c51gb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i80c51gb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -500,28 +500,28 @@ class at89c52_device : public i80c52_device { public: // construction/destruction - at89c52_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + at89c52_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class at89s52_device : public i80c52_device { public: // construction/destruction - at89s52_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + at89s52_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class at89c4051_device : public i80c51_device { public: // construction/destruction - at89c4051_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + at89c4051_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ds80c320_device : public i80c52_device { public: // construction/destruction - ds80c320_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds80c320_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -531,7 +531,7 @@ class sab80c535_device : public i80c51_device { public: // construction/destruction - sab80c535_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sab80c535_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -541,7 +541,7 @@ class i8344_device : public mcs51_cpu_device { public: // construction/destruction - i8344_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8344_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -551,7 +551,7 @@ class i8744_device : public mcs51_cpu_device { public: // construction/destruction - i8744_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8744_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -588,7 +588,7 @@ class ds5002fp_device : public mcs51_cpu_device, public device_nvram_interface { public: // construction/destruction - ds5002fp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds5002fp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_mcon(uint8_t mcon) { m_ds5002fp.mcon = mcon; } void set_rpctl(uint8_t rpctl) { m_ds5002fp.rpctl = rpctl; } diff --git a/src/devices/cpu/mcs96/i8x9x.cpp b/src/devices/cpu/mcs96/i8x9x.cpp index 792cc1378bb..bc98ac9122b 100644 --- a/src/devices/cpu/mcs96/i8x9x.cpp +++ b/src/devices/cpu/mcs96/i8x9x.cpp @@ -12,7 +12,7 @@ #include "i8x9x.h" #include "i8x9xd.h" -i8x9x_device::i8x9x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int data_width) : +i8x9x_device::i8x9x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int data_width) : mcs96_device(mconfig, type, tag, owner, clock, data_width, address_map_constructor(FUNC(i8x9x_device::internal_regs), this)), m_ach_cb(*this), m_hso_cb(*this), @@ -571,22 +571,22 @@ void i8x9x_device::execute_set_input(int linenum, int state) } } -c8095_90_device::c8095_90_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +c8095_90_device::c8095_90_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8x9x_device(mconfig, C8095_90, tag, owner, clock, 16) { } -n8097bh_device::n8097bh_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +n8097bh_device::n8097bh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8x9x_device(mconfig, N8097BH, tag, owner, clock, 16) { } -p8098_device::p8098_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +p8098_device::p8098_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8x9x_device(mconfig, P8098, tag, owner, clock, 8) { } -p8798_device::p8798_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +p8798_device::p8798_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8x9x_device(mconfig, P8798, tag, owner, clock, 8) { } diff --git a/src/devices/cpu/mcs96/i8x9x.h b/src/devices/cpu/mcs96/i8x9x.h index 5f4ab03f8a5..e066886a653 100644 --- a/src/devices/cpu/mcs96/i8x9x.h +++ b/src/devices/cpu/mcs96/i8x9x.h @@ -68,7 +68,7 @@ public: virtual u8 i8x9x_p2_mask() const noexcept { return 0xff; } protected: - i8x9x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int data_width); + i8x9x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int data_width); virtual void device_resolve_objects() override; virtual void device_start() override; @@ -170,7 +170,7 @@ private: class c8095_90_device : public i8x9x_device { public: - c8095_90_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + c8095_90_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual u8 i8x9x_p0_mask() const noexcept override { return 0xf0; } @@ -180,12 +180,12 @@ protected: class n8097bh_device : public i8x9x_device { public: - n8097bh_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + n8097bh_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class p8098_device : public i8x9x_device { public: - p8098_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + p8098_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual u8 i8x9x_p0_mask() const noexcept override { return 0xf0; } @@ -195,7 +195,7 @@ protected: class p8798_device : public i8x9x_device { public: - p8798_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + p8798_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual u8 i8x9x_p0_mask() const noexcept override { return 0xf0; } diff --git a/src/devices/cpu/mcs96/i8xc196.cpp b/src/devices/cpu/mcs96/i8xc196.cpp index dd10d5a6b60..1a9b0f63bf5 100644 --- a/src/devices/cpu/mcs96/i8xc196.cpp +++ b/src/devices/cpu/mcs96/i8xc196.cpp @@ -12,7 +12,7 @@ #include "i8xc196.h" #include "i8xc196d.h" -i8xc196_device::i8xc196_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +i8xc196_device::i8xc196_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : mcs96_device(mconfig, type, tag, owner, clock, 16, address_map_constructor(FUNC(i8xc196_device::internal_regs), this)) { } diff --git a/src/devices/cpu/mcs96/i8xc196.h b/src/devices/cpu/mcs96/i8xc196.h index 02d3e3d9840..6cff1920d2c 100644 --- a/src/devices/cpu/mcs96/i8xc196.h +++ b/src/devices/cpu/mcs96/i8xc196.h @@ -15,7 +15,7 @@ class i8xc196_device : public mcs96_device { protected: - i8xc196_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + i8xc196_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/mcs96/mcs96.cpp b/src/devices/cpu/mcs96/mcs96.cpp index ddf7a7604b5..2a4d784362b 100644 --- a/src/devices/cpu/mcs96/mcs96.cpp +++ b/src/devices/cpu/mcs96/mcs96.cpp @@ -11,7 +11,7 @@ #include "emu.h" #include "mcs96.h" -mcs96_device::mcs96_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int data_width, address_map_constructor regs_map) : +mcs96_device::mcs96_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int data_width, address_map_constructor regs_map) : cpu_device(mconfig, type, tag, owner, clock), program_config("program", ENDIANNESS_LITTLE, data_width, 16), regs_config("register", ENDIANNESS_LITTLE, 16, 8, 0, regs_map), diff --git a/src/devices/cpu/mcs96/mcs96.h b/src/devices/cpu/mcs96/mcs96.h index b27d13044c7..a470aa9457f 100644 --- a/src/devices/cpu/mcs96/mcs96.h +++ b/src/devices/cpu/mcs96/mcs96.h @@ -44,7 +44,7 @@ protected: }; - mcs96_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int data_width, address_map_constructor regs_map); + mcs96_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int data_width, address_map_constructor regs_map); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/melps4/m58846.cpp b/src/devices/cpu/melps4/m58846.cpp index 0440375e47d..1a1e5079791 100644 --- a/src/devices/cpu/melps4/m58846.cpp +++ b/src/devices/cpu/melps4/m58846.cpp @@ -27,7 +27,7 @@ void m58846_device::data_128x4(address_map &map) // device definitions -m58846_device::m58846_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m58846_device::m58846_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : melps4_cpu_device(mconfig, M58846, tag, owner, clock, 11, address_map_constructor(FUNC(m58846_device::program_2kx9), this), 7, address_map_constructor(FUNC(m58846_device::data_128x4), this), 12 /* number of D pins */, 2 /* subroutine page */, 1 /* interrupt page */), m_timer(nullptr) { } diff --git a/src/devices/cpu/melps4/m58846.h b/src/devices/cpu/melps4/m58846.h index 2ba855e3dd2..2eb019e0837 100644 --- a/src/devices/cpu/melps4/m58846.h +++ b/src/devices/cpu/melps4/m58846.h @@ -19,7 +19,7 @@ class m58846_device : public melps4_cpu_device { public: - m58846_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m58846_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/melps4/melps4.cpp b/src/devices/cpu/melps4/melps4.cpp index 973d3b42ce3..eb2f748d9be 100644 --- a/src/devices/cpu/melps4/melps4.cpp +++ b/src/devices/cpu/melps4/melps4.cpp @@ -42,7 +42,7 @@ #include "melps4d.h" -melps4_cpu_device::melps4_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data, int d_pins, u8 sm_page, u8 int_page) +melps4_cpu_device::melps4_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data, int d_pins, u8 sm_page, u8 int_page) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, prgwidth, -1, program) , m_data_config("data", ENDIANNESS_LITTLE, 8, datawidth, 0, data) diff --git a/src/devices/cpu/melps4/melps4.h b/src/devices/cpu/melps4/melps4.h index 09894a1fa8e..0e5a576901a 100644 --- a/src/devices/cpu/melps4/melps4.h +++ b/src/devices/cpu/melps4/melps4.h @@ -90,7 +90,7 @@ public: protected: // construction/destruction - melps4_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data, int d_pins, u8 sm_page, u8 int_page); + melps4_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data, int d_pins, u8 sm_page, u8 int_page); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/minx/minx.cpp b/src/devices/cpu/minx/minx.cpp index 018842ecfbd..bd6aa16afe1 100644 --- a/src/devices/cpu/minx/minx.cpp +++ b/src/devices/cpu/minx/minx.cpp @@ -76,7 +76,7 @@ TODO: DEFINE_DEVICE_TYPE(MINX, minx_cpu_device, "minx", "Nintendo Minx") -minx_cpu_device::minx_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +minx_cpu_device::minx_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, MINX, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, 24, 0) { diff --git a/src/devices/cpu/minx/minx.h b/src/devices/cpu/minx/minx.h index 991916435ee..06f4b5a3bfb 100644 --- a/src/devices/cpu/minx/minx.h +++ b/src/devices/cpu/minx/minx.h @@ -18,7 +18,7 @@ class minx_cpu_device : public cpu_device { public: // construction/destruction - minx_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + minx_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/mips/mips1.cpp b/src/devices/cpu/mips/mips1.cpp index 6f45a954d50..824cd47e762 100644 --- a/src/devices/cpu/mips/mips1.cpp +++ b/src/devices/cpu/mips/mips1.cpp @@ -55,7 +55,7 @@ DEFINE_DEVICE_TYPE(SONYPS2_IOP, iop_device, "sonyiop", "Sony Playstation 2 ALLOW_SAVE_TYPE(mips1core_device_base::branch_state); -mips1core_device_base::mips1core_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, u32 cpurev, size_t icache_size, size_t dcache_size) +mips1core_device_base::mips1core_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, u32 cpurev, size_t icache_size, size_t dcache_size) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config_be("program", ENDIANNESS_BIG, 32, 32) , m_program_config_le("program", ENDIANNESS_LITTLE, 32, 32) @@ -70,64 +70,64 @@ mips1core_device_base::mips1core_device_base(machine_config const &mconfig, devi { } -mips1_device_base::mips1_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, u32 cpurev, size_t icache_size, size_t dcache_size) +mips1_device_base::mips1_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, u32 cpurev, size_t icache_size, size_t dcache_size) : mips1core_device_base(mconfig, type, tag, owner, clock, cpurev, icache_size, dcache_size) , m_fcr0(0) { } -r2000_device::r2000_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size, size_t dcache_size) +r2000_device::r2000_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size, size_t dcache_size) : mips1_device_base(mconfig, R2000, tag, owner, clock, 0x0100, icache_size, dcache_size) { } -r2000a_device::r2000a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size, size_t dcache_size) +r2000a_device::r2000a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size, size_t dcache_size) : mips1_device_base(mconfig, R2000A, tag, owner, clock, 0x0210, icache_size, dcache_size) { } -r3000_device::r3000_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size, size_t dcache_size) +r3000_device::r3000_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size, size_t dcache_size) : mips1_device_base(mconfig, R3000, tag, owner, clock, 0x0220, icache_size, dcache_size) { } -r3000a_device::r3000a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size, size_t dcache_size) +r3000a_device::r3000a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size, size_t dcache_size) : mips1_device_base(mconfig, R3000A, tag, owner, clock, 0x0230, icache_size, dcache_size) { } -r3041_device::r3041_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +r3041_device::r3041_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mips1core_device_base(mconfig, R3041, tag, owner, clock, 0x0700, 2048, 512) { } -r3051_device::r3051_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +r3051_device::r3051_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mips1core_device_base(mconfig, R3051, tag, owner, clock, 0x0200, 4096, 2048) { } -r3052_device::r3052_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +r3052_device::r3052_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mips1core_device_base(mconfig, R3052, tag, owner, clock, 0x0200, 8192, 2048) { } -r3052e_device::r3052e_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +r3052e_device::r3052e_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mips1_device_base(mconfig, R3052E, tag, owner, clock, 0x0200, 8192, 2048) { } -r3071_device::r3071_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size, size_t dcache_size) +r3071_device::r3071_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size, size_t dcache_size) : mips1_device_base(mconfig, R3071, tag, owner, clock, 0x0200, icache_size, dcache_size) { } -r3081_device::r3081_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size, size_t dcache_size) +r3081_device::r3081_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size, size_t dcache_size) : mips1_device_base(mconfig, R3081, tag, owner, clock, 0x0200, icache_size, dcache_size) { set_fpu(0x0300); } -iop_device::iop_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +iop_device::iop_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : mips1core_device_base(mconfig, SONYPS2_IOP, tag, owner, clock, 0x001f, 4096, 1024) { m_endianness = ENDIANNESS_LITTLE; diff --git a/src/devices/cpu/mips/mips1.h b/src/devices/cpu/mips/mips1.h index df6b1c8e6c9..bdf5c67f51d 100644 --- a/src/devices/cpu/mips/mips1.h +++ b/src/devices/cpu/mips/mips1.h @@ -17,7 +17,7 @@ public: void berr_w(int state) { m_bus_error = bool(state); } protected: - mips1core_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, u32 cpurev, size_t icache_size, size_t dcache_size); + mips1core_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, u32 cpurev, size_t icache_size, size_t dcache_size); enum registers : unsigned { @@ -261,7 +261,7 @@ public: void set_fpu(u32 revision, unsigned interrupt = 3) { m_fcr0 = revision; m_fpu_irq = interrupt; } protected: - mips1_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, u32 cpurev, size_t icache_size, size_t dcache_size); + mips1_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, u32 cpurev, size_t icache_size, size_t dcache_size); enum cp1_fcr31_mask : u32 { @@ -324,31 +324,31 @@ private: class r2000_device : public mips1_device_base { public: - r2000_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size = 0, size_t dcache_size = 0); + r2000_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size = 0, size_t dcache_size = 0); }; class r2000a_device : public mips1_device_base { public: - r2000a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size = 0, size_t dcache_size = 0); + r2000a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size = 0, size_t dcache_size = 0); }; class r3000_device : public mips1_device_base { public: - r3000_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size = 0, size_t dcache_size = 0); + r3000_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size = 0, size_t dcache_size = 0); }; class r3000a_device : public mips1_device_base { public: - r3000a_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size = 0, size_t dcache_size = 0); + r3000a_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size = 0, size_t dcache_size = 0); }; class r3041_device : public mips1core_device_base { public: - r3041_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + r3041_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -358,37 +358,37 @@ protected: class r3051_device : public mips1core_device_base { public: - r3051_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + r3051_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class r3052_device : public mips1core_device_base { public: - r3052_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + r3052_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class r3052e_device : public mips1_device_base { public: - r3052e_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + r3052e_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class r3071_device : public mips1_device_base { public: - r3071_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size = 16384, size_t dcache_size = 4096); + r3071_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size = 16384, size_t dcache_size = 4096); }; class r3081_device : public mips1_device_base { public: - r3081_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock, size_t icache_size = 16384, size_t dcache_size = 4096); + r3081_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock, size_t icache_size = 16384, size_t dcache_size = 4096); }; class iop_device : public mips1core_device_base { public: - iop_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + iop_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(R2000, r2000_device) diff --git a/src/devices/cpu/mips/mips3.cpp b/src/devices/cpu/mips/mips3.cpp index 9b6067e5fa4..b1e0f2d57a6 100644 --- a/src/devices/cpu/mips/mips3.cpp +++ b/src/devices/cpu/mips/mips3.cpp @@ -131,7 +131,7 @@ DEFINE_DEVICE_TYPE(RM7000LE, rm7000le_device, "rm7000le", "MIPS RM7000 (littl // VR4300 and VR5432 have 4 fewer PFN bits, and only 32 TLB entries -mips3_device::mips3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, mips3_flavor flavor, endianness_t endianness, uint32_t data_bits) +mips3_device::mips3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, mips3_flavor flavor, endianness_t endianness, uint32_t data_bits) : cpu_device(mconfig, type, tag, owner, clock) , device_vtlb_interface(mconfig, *this, AS_PROGRAM) , m_core(nullptr) diff --git a/src/devices/cpu/mips/mips3.h b/src/devices/cpu/mips/mips3.h index 0bf7e49e5cc..3801a935f18 100644 --- a/src/devices/cpu/mips/mips3.h +++ b/src/devices/cpu/mips/mips3.h @@ -297,7 +297,7 @@ protected: public: // construction/destruction - mips3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, mips3_flavor flavor, endianness_t endiannes, uint32_t data_bits); + mips3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, mips3_flavor flavor, endianness_t endiannes, uint32_t data_bits); void set_icache_size(size_t icache_size) { c_icache_size = icache_size; } void set_dcache_size(size_t dcache_size) { c_dcache_size = dcache_size; } @@ -658,7 +658,7 @@ private: class r4000be_device : public mips3_device { public: // construction/destruction - r4000be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r4000be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R4000BE, tag, owner, clock, MIPS3_TYPE_R4000, ENDIANNESS_BIG, 64) { } @@ -667,7 +667,7 @@ public: class r4000le_device : public mips3_device { public: // construction/destruction - r4000le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r4000le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R4000LE, tag, owner, clock, MIPS3_TYPE_R4000, ENDIANNESS_LITTLE, 64) { } @@ -676,7 +676,7 @@ public: class r4400be_device : public mips3_device { public: // construction/destruction - r4400be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r4400be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R4400BE, tag, owner, clock, MIPS3_TYPE_R4400, ENDIANNESS_BIG, 64) { } @@ -685,7 +685,7 @@ public: class r4400le_device : public mips3_device { public: // construction/destruction - r4400le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r4400le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R4400LE, tag, owner, clock, MIPS3_TYPE_R4400, ENDIANNESS_LITTLE, 32) // Should be 64 bits { } @@ -694,7 +694,7 @@ public: class vr4300be_device : public mips3_device { public: // construction/destruction - vr4300be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + vr4300be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, VR4300BE, tag, owner, clock, MIPS3_TYPE_VR4300, ENDIANNESS_BIG, 32) { } @@ -703,7 +703,7 @@ public: class vr4300le_device : public mips3_device { public: // construction/destruction - vr4300le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + vr4300le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, VR4300LE, tag, owner, clock, MIPS3_TYPE_VR4300, ENDIANNESS_LITTLE, 32) { } @@ -712,7 +712,7 @@ public: class vr4310be_device : public mips3_device { public: // construction/destruction - vr4310be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + vr4310be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, VR4310BE, tag, owner, clock, MIPS3_TYPE_VR4300, ENDIANNESS_BIG, 32) { } @@ -721,7 +721,7 @@ public: class vr4310le_device : public mips3_device { public: // construction/destruction - vr4310le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + vr4310le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, VR4310LE, tag, owner, clock, MIPS3_TYPE_VR4300, ENDIANNESS_LITTLE, 32) { } @@ -730,7 +730,7 @@ public: class r4600be_device : public mips3_device { public: // construction/destruction - r4600be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r4600be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R4600BE, tag, owner, clock, MIPS3_TYPE_R4600, ENDIANNESS_BIG, 64) { } @@ -739,7 +739,7 @@ public: class r4600le_device : public mips3_device { public: // construction/destruction - r4600le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r4600le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R4600LE, tag, owner, clock, MIPS3_TYPE_R4600, ENDIANNESS_LITTLE, 32) // Should be 64 bits { } @@ -748,7 +748,7 @@ public: class r4650be_device : public mips3_device { public: // construction/destruction - r4650be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r4650be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R4650BE, tag, owner, clock, MIPS3_TYPE_R4650, ENDIANNESS_BIG, 32) // Should be 64 bits { } @@ -757,7 +757,7 @@ public: class r4650le_device : public mips3_device { public: // construction/destruction - r4650le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r4650le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R4650LE, tag, owner, clock, MIPS3_TYPE_R4650, ENDIANNESS_LITTLE, 32) // Should be 64 bits { } @@ -766,7 +766,7 @@ public: class r4700be_device : public mips3_device { public: // construction/destruction - r4700be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r4700be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R4700BE, tag, owner, clock, MIPS3_TYPE_R4700, ENDIANNESS_BIG, 32) // Should be 64 bits { } @@ -775,7 +775,7 @@ public: class r4700le_device : public mips3_device { public: // construction/destruction - r4700le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r4700le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R4700LE, tag, owner, clock, MIPS3_TYPE_R4700, ENDIANNESS_LITTLE, 32) // Should be 64 bits { } @@ -784,7 +784,7 @@ public: class tx4925be_device : public mips3_device { public: // construction/destruction - tx4925be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + tx4925be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, TX4925BE, tag, owner, clock, MIPS3_TYPE_TX4925, ENDIANNESS_BIG, 32) // Should be 64 bits { } @@ -793,7 +793,7 @@ public: class tx4925le_device : public mips3_device { public: // construction/destruction - tx4925le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + tx4925le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, TX4925LE, tag, owner, clock, MIPS3_TYPE_TX4925, ENDIANNESS_LITTLE, 32) // Should be 64 bits { } @@ -802,7 +802,7 @@ public: class r5000be_device : public mips3_device { public: // construction/destruction - r5000be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r5000be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R5000BE, tag, owner, clock, MIPS3_TYPE_R5000, ENDIANNESS_BIG, 64) { } @@ -814,7 +814,7 @@ protected: class r5000le_device : public mips3_device { public: // construction/destruction - r5000le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r5000le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R5000LE, tag, owner, clock, MIPS3_TYPE_R5000, ENDIANNESS_LITTLE, 32) // FIXME: Should be 64 bits, Galileo blows up though { } @@ -823,7 +823,7 @@ public: class vr5500be_device : public mips3_device { public: // construction/destruction - vr5500be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + vr5500be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, VR5500BE, tag, owner, clock, MIPS3_TYPE_R5000, ENDIANNESS_BIG, 32) // Should be 64 bits { } @@ -832,7 +832,7 @@ public: class vr5500le_device : public mips3_device { public: // construction/destruction - vr5500le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + vr5500le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, VR5500LE, tag, owner, clock, MIPS3_TYPE_R5000, ENDIANNESS_LITTLE, 32) // Should be 64 bits { } @@ -842,13 +842,13 @@ class r5900le_device : public mips3_device { public: // construction/destruction template <typename T> - r5900le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&vu0_tag) + r5900le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&vu0_tag) : r5900le_device(mconfig, tag, owner, clock) { m_vu0.set_tag(std::forward<T>(vu0_tag)); } - r5900le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + r5900le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, R5900LE, tag, owner, clock, MIPS3_TYPE_R5900, ENDIANNESS_LITTLE, 64) , m_vu0(*this, finder_base::DUMMY_TAG) { @@ -907,7 +907,7 @@ protected: class qed5271be_device : public mips3_device { public: // construction/destruction - qed5271be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + qed5271be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, QED5271BE, tag, owner, clock, MIPS3_TYPE_QED5271, ENDIANNESS_BIG, 32) // Should be 64 bits { } @@ -916,7 +916,7 @@ public: class qed5271le_device : public mips3_device { public: // construction/destruction - qed5271le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + qed5271le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, QED5271LE, tag, owner, clock, MIPS3_TYPE_QED5271, ENDIANNESS_LITTLE, 32) // Should be 64 bits { } @@ -925,7 +925,7 @@ public: class rm7000be_device : public mips3_device { public: // construction/destruction - rm7000be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + rm7000be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, RM7000BE, tag, owner, clock, MIPS3_TYPE_RM7000, ENDIANNESS_BIG, 32) // Should be 64 bits { } @@ -934,7 +934,7 @@ public: class rm7000le_device : public mips3_device { public: // construction/destruction - rm7000le_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + rm7000le_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mips3_device(mconfig, RM7000LE, tag, owner, clock, MIPS3_TYPE_RM7000, ENDIANNESS_LITTLE, 32) // Should be 64 bits { } diff --git a/src/devices/cpu/mips/ps2vif1.cpp b/src/devices/cpu/mips/ps2vif1.cpp index 43fc71a2267..091be49d774 100644 --- a/src/devices/cpu/mips/ps2vif1.cpp +++ b/src/devices/cpu/mips/ps2vif1.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(SONYPS2_VIF1, ps2_vif1_device, "ps2vif1", "PlayStation 2 VIF1 4, 2, 1, 2 }; -ps2_vif1_device::ps2_vif1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ps2_vif1_device::ps2_vif1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYPS2_VIF1, tag, owner, clock) , device_execute_interface(mconfig, *this) , m_gs(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/cpu/mips/ps2vif1.h b/src/devices/cpu/mips/ps2vif1.h index 171a3839f8f..a03afe2111a 100644 --- a/src/devices/cpu/mips/ps2vif1.h +++ b/src/devices/cpu/mips/ps2vif1.h @@ -23,14 +23,14 @@ class ps2_vif1_device : public device_t, public device_execute_interface { public: template <typename T, typename U> - ps2_vif1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&gs_tag, U &&vu1_tag) + ps2_vif1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&gs_tag, U &&vu1_tag) : ps2_vif1_device(mconfig, tag, owner, clock) { m_gs.set_tag(std::forward<T>(gs_tag)); m_vu1.set_tag(std::forward<U>(vu1_tag)); } - ps2_vif1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ps2_vif1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~ps2_vif1_device() override; uint64_t mmio_r(offs_t offset); diff --git a/src/devices/cpu/mips/ps2vu.cpp b/src/devices/cpu/mips/ps2vu.cpp index 8f0b125314d..b16fcc663f4 100644 --- a/src/devices/cpu/mips/ps2vu.cpp +++ b/src/devices/cpu/mips/ps2vu.cpp @@ -23,7 +23,7 @@ sonyvu_device::sonyvu_device( device_type type, const char *tag, device_t *owner, - uint32_t clock, + const XTAL &clock, address_map_constructor micro_cons, address_map_constructor vu_cons, chip_type chiptype, @@ -54,13 +54,13 @@ sonyvu_device::sonyvu_device( { } -sonyvu0_device::sonyvu0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sonyvu0_device::sonyvu0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sonyvu_device(mconfig, SONYPS2_VU0, tag, owner, clock, address_map_constructor(FUNC(sonyvu0_device::micro_map), this), address_map_constructor(FUNC(sonyvu0_device::vu_map), this), CHIP_TYPE_VU0, 0x1000) , m_vu1(*this, finder_base::DUMMY_TAG) { } -sonyvu1_device::sonyvu1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sonyvu1_device::sonyvu1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sonyvu_device(mconfig, SONYPS2_VU1, tag, owner, clock, address_map_constructor(FUNC(sonyvu1_device::micro_map), this), address_map_constructor(FUNC(sonyvu1_device::vu_map), this), CHIP_TYPE_VU0, 0x4000) , m_gs(*this, finder_base::DUMMY_TAG) , m_vif(*this, "vif") diff --git a/src/devices/cpu/mips/ps2vu.h b/src/devices/cpu/mips/ps2vu.h index cc898ffa58d..b0ccb2a2134 100644 --- a/src/devices/cpu/mips/ps2vu.h +++ b/src/devices/cpu/mips/ps2vu.h @@ -98,7 +98,7 @@ protected: CHIP_TYPE_VU1, }; - sonyvu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor micro_cons, address_map_constructor vu_cons, chip_type chiptype, uint32_t mem_size); + sonyvu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor micro_cons, address_map_constructor vu_cons, chip_type chiptype, uint32_t mem_size); enum : uint64_t { @@ -178,13 +178,13 @@ class sonyvu1_device : public sonyvu_device { public: template <typename T> - sonyvu1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&gs_tag) + sonyvu1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&gs_tag) : sonyvu1_device(mconfig, tag, owner, clock) { m_gs.set_tag(std::forward<T>(gs_tag)); } - sonyvu1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sonyvu1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ps2_vif1_device* interface(); @@ -213,13 +213,13 @@ class sonyvu0_device : public sonyvu_device { public: template <typename T> - sonyvu0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&vu1_tag) + sonyvu0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&vu1_tag) : sonyvu0_device(mconfig, tag, owner, clock) { m_vu1.set_tag(std::forward<T>(vu1_tag)); } - sonyvu0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sonyvu0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/cpu/mips/r4000.cpp b/src/devices/cpu/mips/r4000.cpp index 15f161b32c3..433f3b640fd 100644 --- a/src/devices/cpu/mips/r4000.cpp +++ b/src/devices/cpu/mips/r4000.cpp @@ -92,7 +92,7 @@ DEFINE_DEVICE_TYPE(R5000, r5000_device, "r5000", "MIPS R5000") u32 const r5000_device::s_fcc_masks[8] = { (1U << 23), (1U << 25), (1U << 26), (1U << 27), (1U << 28), (1U << 29), (1U << 30), (1U << 31) }; u32 const r5000_device::s_fcc_shifts[8] = { 23, 25, 26, 27, 28, 29, 30, 31 }; -r4000_base_device::r4000_base_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, u32 prid, u32 fcr, cache_size icache_size, cache_size dcache_size, unsigned m32, unsigned m64, unsigned d32, unsigned d64, bool timer_interrupt_disabled) +r4000_base_device::r4000_base_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, u32 prid, u32 fcr, cache_size icache_size, cache_size dcache_size, unsigned m32, unsigned m64, unsigned d32, unsigned d64, bool timer_interrupt_disabled) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config_le("program", ENDIANNESS_LITTLE, 64, 32) , m_program_config_be("program", ENDIANNESS_BIG, 64, 32) diff --git a/src/devices/cpu/mips/r4000.h b/src/devices/cpu/mips/r4000.h index adc9ccd1f3d..71345e45b22 100644 --- a/src/devices/cpu/mips/r4000.h +++ b/src/devices/cpu/mips/r4000.h @@ -57,7 +57,7 @@ protected: CACHE_256K = 6, CACHE_512K = 7, }; - r4000_base_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, u32 prid, u32 fcr, cache_size icache_size, cache_size dcache_size, unsigned m32, unsigned m64, unsigned d32, unsigned d64, bool timer_interrupt_disabled); + r4000_base_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, u32 prid, u32 fcr, cache_size icache_size, cache_size dcache_size, unsigned m32, unsigned m64, unsigned d32, unsigned d64, bool timer_interrupt_disabled); enum cp0_reg : int { @@ -489,14 +489,14 @@ class r4000_device : public r4000_base_device { public: // NOTE: R4000 chips prior to 3.0 have an xtlb bug - r4000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, bool timer_interrupt_disabled) + r4000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool timer_interrupt_disabled) : r4000_base_device(mconfig, R4000, tag, owner, clock, 0x0430, 0x0500, CACHE_8K, CACHE_8K, 10, 20, 69, 133, timer_interrupt_disabled) { // no secondary cache m_cp0[CP0_Config] |= CONFIG_SC; } - r4000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + r4000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : r4000_device(mconfig, tag, owner, clock, false) { } @@ -505,7 +505,7 @@ public: class r4400_device : public r4000_base_device { public: - r4400_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, bool timer_interrupt_disabled, u32 scache_size, u8 scache_line_size) + r4400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool timer_interrupt_disabled, u32 scache_size, u8 scache_line_size) : r4000_base_device(mconfig, R4400, tag, owner, clock, 0x0440, 0x0500, CACHE_16K, CACHE_16K, 10, 20, 69, 133, timer_interrupt_disabled) { m_scache_size = scache_size; @@ -513,7 +513,7 @@ public: configure_scache(); } - r4400_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + r4400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : r4400_device(mconfig, tag, owner, clock, false, 0, 0) { } @@ -522,14 +522,14 @@ public: class r4600_device : public r4000_base_device { public: - r4600_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, bool timer_interrupt_disabled) + r4600_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool timer_interrupt_disabled) : r4000_base_device(mconfig, R4600, tag, owner, clock, 0x2020, 0x2020, CACHE_16K, CACHE_16K, 10, 12, 42, 74, timer_interrupt_disabled) { // no secondary cache m_cp0[CP0_Config] |= CONFIG_SC; } - r4600_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + r4600_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : r4600_device(mconfig, tag, owner, clock, false) { } @@ -538,14 +538,14 @@ public: class r5000_device : public r4000_base_device { public: - r5000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, bool timer_interrupt_disabled) + r5000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool timer_interrupt_disabled) : r4000_base_device(mconfig, R5000, tag, owner, clock, 0x2320, 0x2320, CACHE_32K, CACHE_32K, 5, 9, 36, 68, timer_interrupt_disabled) { // no secondary cache m_cp0[CP0_Config] |= CONFIG_SC; } - r5000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + r5000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : r5000_device(mconfig, tag, owner, clock, false) { } diff --git a/src/devices/cpu/mk1/mk1.cpp b/src/devices/cpu/mk1/mk1.cpp index cdeb3fb6fcc..c67ce39f5da 100644 --- a/src/devices/cpu/mk1/mk1.cpp +++ b/src/devices/cpu/mk1/mk1.cpp @@ -45,7 +45,7 @@ // device type definition DEFINE_DEVICE_TYPE(MK1_CPU, mk1_cpu_device, "mk1_cpu", "Mark 1 CPU") -mk1_cpu_device::mk1_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mk1_cpu_device::mk1_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, MK1_CPU, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 12, 0) , m_data_config("data", ENDIANNESS_LITTLE, 8, 16, 0) diff --git a/src/devices/cpu/mk1/mk1.h b/src/devices/cpu/mk1/mk1.h index dad3f3ab9f7..66162ffb9bd 100644 --- a/src/devices/cpu/mk1/mk1.h +++ b/src/devices/cpu/mk1/mk1.h @@ -22,7 +22,7 @@ public: static constexpr int IRQ_LINE = 0; // device type constructor - mk1_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mk1_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/mn10200/mn10200.cpp b/src/devices/cpu/mn10200/mn10200.cpp index 64da0efe23f..e0267f418f2 100644 --- a/src/devices/cpu/mn10200/mn10200.cpp +++ b/src/devices/cpu/mn10200/mn10200.cpp @@ -45,7 +45,7 @@ void mn10200_device::mn1020012a_internal_map(address_map &map) } -mn10200_device::mn10200_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor program) +mn10200_device::mn10200_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 24, 0, program), m_program(nullptr) , m_read_port(*this) @@ -55,7 +55,7 @@ mn10200_device::mn10200_device(const machine_config &mconfig, device_type type, { } // device definitions -mn1020012a_device::mn1020012a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mn1020012a_device::mn1020012a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mn10200_device(mconfig, MN1020012A, tag, owner, clock, address_map_constructor(FUNC(mn1020012a_device::mn1020012a_internal_map), this)) { } diff --git a/src/devices/cpu/mn10200/mn10200.h b/src/devices/cpu/mn10200/mn10200.h index 8ea31fa1d4b..32994b46001 100644 --- a/src/devices/cpu/mn10200/mn10200.h +++ b/src/devices/cpu/mn10200/mn10200.h @@ -51,7 +51,7 @@ protected: // construction/destruction - mn10200_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor program); + mn10200_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program); // device-level overrides virtual void device_start() override; @@ -189,7 +189,7 @@ private: class mn1020012a_device : public mn10200_device { public: - mn1020012a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mn1020012a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/mn1880/mn1880.cpp b/src/devices/cpu/mn1880/mn1880.cpp index 0843947a480..12e28ddb46f 100644 --- a/src/devices/cpu/mn1880/mn1880.cpp +++ b/src/devices/cpu/mn1880/mn1880.cpp @@ -88,7 +88,7 @@ DEFINE_DEVICE_TYPE(MN18801A, mn18801a_device, "mn18801a", "Panasonic MN18801A") ALLOW_SAVE_TYPE(mn1880_device::microstate) -mn1880_device::mn1880_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool has_mmu, address_map_constructor data_map) +mn1880_device::mn1880_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool has_mmu, address_map_constructor data_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, has_mmu ? 21 : 16, 0, 16, 14) , m_data_config("data", ENDIANNESS_LITTLE, 8, has_mmu ? 21 : 16, 0, 16, 14, data_map) @@ -107,12 +107,12 @@ mn1880_device::mn1880_device(const machine_config &mconfig, device_type type, co { } -mn1880_device::mn1880_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mn1880_device::mn1880_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mn1880_device(mconfig, MN1880, tag, owner, clock, false, address_map_constructor(FUNC(mn1880_device::internal_data_map), this)) { } -mn18801a_device::mn18801a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mn18801a_device::mn18801a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mn1880_device(mconfig, MN18801A, tag, owner, clock, true, address_map_constructor(FUNC(mn18801a_device::internal_data_map), this)) { } diff --git a/src/devices/cpu/mn1880/mn1880.h b/src/devices/cpu/mn1880/mn1880.h index 47f470c02a8..cb0b59bc656 100644 --- a/src/devices/cpu/mn1880/mn1880.h +++ b/src/devices/cpu/mn1880/mn1880.h @@ -9,7 +9,7 @@ class mn1880_device : public cpu_device { public: - mn1880_device(const machine_config &config, const char *tag, device_t *owner, u32 clock); + mn1880_device(const machine_config &config, const char *tag, device_t *owner, const XTAL &clock); enum { MN1880_IP, MN1880_IPA, MN1880_IPB, @@ -29,7 +29,7 @@ public: }; protected: - mn1880_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool has_mmu, address_map_constructor data_map); + mn1880_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool has_mmu, address_map_constructor data_map); // device-level overrides virtual void device_start() override; @@ -235,7 +235,7 @@ private: class mn18801a_device : public mn1880_device { public: - mn18801a_device(const machine_config &config, const char *tag, device_t *owner, u32 clock); + mn18801a_device(const machine_config &config, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(MN1880, mn1880_device) diff --git a/src/devices/cpu/nanoprocessor/nanoprocessor.cpp b/src/devices/cpu/nanoprocessor/nanoprocessor.cpp index 197efcc0b4a..421107fc692 100644 --- a/src/devices/cpu/nanoprocessor/nanoprocessor.cpp +++ b/src/devices/cpu/nanoprocessor/nanoprocessor.cpp @@ -50,7 +50,7 @@ namespace { DEFINE_DEVICE_TYPE(HP_NANOPROCESSOR, hp_nanoprocessor_device, "nanoprocessor", "Hewlett Packard HP-Nanoprocessor") -hp_nanoprocessor_device::hp_nanoprocessor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +hp_nanoprocessor_device::hp_nanoprocessor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, HP_NANOPROCESSOR, tag, owner, clock), m_dc_changed_func(*this), m_read_dc_func(*this), diff --git a/src/devices/cpu/nanoprocessor/nanoprocessor.h b/src/devices/cpu/nanoprocessor/nanoprocessor.h index 2aa8cf3a4ab..23b3d3462a9 100644 --- a/src/devices/cpu/nanoprocessor/nanoprocessor.h +++ b/src/devices/cpu/nanoprocessor/nanoprocessor.h @@ -71,7 +71,7 @@ constexpr unsigned HP_NANO_IE_DC = 7; // DC line used as interrupt enable/ma class hp_nanoprocessor_device : public cpu_device { public: - hp_nanoprocessor_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_nanoprocessor_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // DC changed callback // The callback receives a 8-bit word holding the state of all DC lines. diff --git a/src/devices/cpu/nec/nec.cpp b/src/devices/cpu/nec/nec.cpp index 3a961a0a4be..743b6061a46 100644 --- a/src/devices/cpu/nec/nec.cpp +++ b/src/devices/cpu/nec/nec.cpp @@ -121,7 +121,7 @@ DEFINE_DEVICE_TYPE(V33, v33_device, "v33", "NEC V33") DEFINE_DEVICE_TYPE(V33A, v33a_device, "v33a", "NEC V33A") -nec_common_device::nec_common_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool is_16bit, uint8_t prefetch_size, uint8_t prefetch_cycles, uint32_t chip_type, address_map_constructor internal_port_map) +nec_common_device::nec_common_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_16bit, uint8_t prefetch_size, uint8_t prefetch_cycles, uint32_t chip_type, address_map_constructor internal_port_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, is_16bit ? 16 : 8, chip_type == V33_TYPE ? 24 : 20, 0, 20, chip_type == V33_TYPE ? 14 : 0) , m_io_config("io", ENDIANNESS_LITTLE, is_16bit ? 16 : 8, 16, 0, internal_port_map) @@ -133,13 +133,13 @@ nec_common_device::nec_common_device(const machine_config &mconfig, device_type } -v20_device::v20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v20_device::v20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nec_common_device(mconfig, V20, tag, owner, clock, false, 4, 4, V20_TYPE) { } -v30_device::v30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v30_device::v30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nec_common_device(mconfig, V30, tag, owner, clock, true, 6, 2, V30_TYPE) { } @@ -156,19 +156,19 @@ device_memory_interface::space_config_vector nec_common_device::memory_space_con /* FIXME: Need information about prefetch size and cycles for V33. * complete guess below, nbbatman will not work * properly without. */ -v33_base_device::v33_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_port_map) +v33_base_device::v33_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_port_map) : nec_common_device(mconfig, type, tag, owner, clock, true, 6, 1, V33_TYPE, internal_port_map) { } -v33_device::v33_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v33_device::v33_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v33_base_device(mconfig, V33, tag, owner, clock, address_map_constructor(FUNC(v33_device::v33_internal_port_map), this)) { } -v33a_device::v33a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v33a_device::v33a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v33_base_device(mconfig, V33A, tag, owner, clock, address_map_constructor(FUNC(v33a_device::v33_internal_port_map), this)) { } diff --git a/src/devices/cpu/nec/nec.h b/src/devices/cpu/nec/nec.h index 764afdd76c1..19a2ee22cf5 100644 --- a/src/devices/cpu/nec/nec.h +++ b/src/devices/cpu/nec/nec.h @@ -28,7 +28,7 @@ class nec_common_device : public cpu_device, public nec_disassembler::config protected: // construction/destruction - nec_common_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool is_16bit, uint8_t prefetch_size, uint8_t prefetch_cycles, uint32_t chip_type, address_map_constructor internal_port_map = address_map_constructor()); + nec_common_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_16bit, uint8_t prefetch_size, uint8_t prefetch_cycles, uint32_t chip_type, address_map_constructor internal_port_map = address_map_constructor()); // device-level overrides virtual void device_start() override; @@ -672,21 +672,21 @@ private: class v20_device : public nec_common_device { public: - v20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class v30_device : public nec_common_device { public: - v30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class v33_base_device : public nec_common_device { protected: - v33_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_port_map); + v33_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_port_map); // device_memory_interface overrides virtual bool memory_translate(int spacenum, int intention, offs_t &address) override; @@ -698,13 +698,13 @@ protected: class v33_device : public v33_base_device { public: - v33_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v33_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class v33a_device : public v33_base_device { public: - v33a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v33a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/nec/v25.cpp b/src/devices/cpu/nec/v25.cpp index 321db738a04..5cacb9006f9 100644 --- a/src/devices/cpu/nec/v25.cpp +++ b/src/devices/cpu/nec/v25.cpp @@ -50,7 +50,7 @@ DEFINE_DEVICE_TYPE(V25, v25_device, "v25", "NEC V25") DEFINE_DEVICE_TYPE(V35, v35_device, "v35", "NEC V35") -v25_common_device::v25_common_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool is_16bit, uint8_t prefetch_size, uint8_t prefetch_cycles, uint32_t chip_type) +v25_common_device::v25_common_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_16bit, uint8_t prefetch_size, uint8_t prefetch_cycles, uint32_t chip_type) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, is_16bit ? 16 : 8, 20, 0) , m_data_config("data", ENDIANNESS_LITTLE, 16, 9, 0, address_map_constructor(FUNC(v25_common_device::ida_sfr_map), this)) @@ -72,13 +72,13 @@ v25_common_device::v25_common_device(const machine_config &mconfig, device_type } -v25_device::v25_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v25_device::v25_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v25_common_device(mconfig, V25, tag, owner, clock, false, 4, 4, V20_TYPE) { } -v35_device::v35_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v35_device::v35_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v25_common_device(mconfig, V35, tag, owner, clock, true, 6, 2, V30_TYPE) { } diff --git a/src/devices/cpu/nec/v25.h b/src/devices/cpu/nec/v25.h index 1afeb9a7eb5..f92460fb927 100644 --- a/src/devices/cpu/nec/v25.h +++ b/src/devices/cpu/nec/v25.h @@ -43,7 +43,7 @@ public: protected: // construction/destruction - v25_common_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool is_16bit, uint8_t prefetch_size, uint8_t prefetch_cycles, uint32_t chip_type); + v25_common_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_16bit, uint8_t prefetch_size, uint8_t prefetch_cycles, uint32_t chip_type); // device-level overrides virtual void device_start() override; @@ -536,14 +536,14 @@ private: class v25_device : public v25_common_device { public: - v25_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v25_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class v35_device : public v25_common_device { public: - v35_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v35_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/nec/v5x.cpp b/src/devices/cpu/nec/v5x.cpp index 9faeed6bfd9..39eef1b4cc0 100644 --- a/src/devices/cpu/nec/v5x.cpp +++ b/src/devices/cpu/nec/v5x.cpp @@ -213,14 +213,14 @@ void device_v5x_interface::v5x_add_mconfig(machine_config &config) { PIT8254(config, m_tcu); - V5X_DMAU(config, m_dmau, 4000000); + V5X_DMAU(config, m_dmau, XTAL::u(4000000)); - V5X_ICU(config, m_icu, 0); + V5X_ICU(config, m_icu); m_icu->out_int_callback().set(FUNC(device_v5x_interface::internal_irq_w)); m_icu->in_sp_callback().set_constant(1); m_icu->read_slave_ack_callback().set(FUNC(device_v5x_interface::get_pic_ack)); - V5X_SCU(config, m_scu, 0); + V5X_SCU(config, m_scu); } void device_v5x_interface::remappable_io_map(address_map &map) @@ -516,7 +516,7 @@ device_memory_interface::space_config_vector v50_base_device::memory_space_confi return spaces; } -v50_base_device::v50_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool is_16bit, u8 prefetch_size, u8 prefetch_cycles, u32 chip_type) +v50_base_device::v50_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_16bit, u8 prefetch_size, u8 prefetch_cycles, u32 chip_type) : nec_common_device(mconfig, type, tag, owner, clock, is_16bit, prefetch_size, prefetch_cycles, chip_type, address_map_constructor(FUNC(v50_base_device::internal_port_map), this)) , device_v5x_interface(mconfig, *this, is_16bit) , m_tout1_callback(*this) @@ -527,12 +527,12 @@ v50_base_device::v50_base_device(const machine_config &mconfig, device_type type { } -v40_device::v40_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +v40_device::v40_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v50_base_device(mconfig, V40, tag, owner, clock, false, 4, 4, V20_TYPE) { } -v50_device::v50_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +v50_device::v50_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v50_base_device(mconfig, V50, tag, owner, clock, true, 6, 2, V30_TYPE) { } @@ -785,18 +785,18 @@ device_memory_interface::space_config_vector v53_device::memory_space_config() c }; } -v53_device::v53_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +v53_device::v53_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : v33_base_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(v53_device::internal_port_map), this)) , device_v5x_interface(mconfig, *this, true) { } -v53_device::v53_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +v53_device::v53_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v53_device(mconfig, V53, tag, owner, clock) { } -v53a_device::v53a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +v53a_device::v53a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v53_device(mconfig, V53A, tag, owner, clock) { } diff --git a/src/devices/cpu/nec/v5x.h b/src/devices/cpu/nec/v5x.h index 23fcdc265a9..c07341fbe91 100644 --- a/src/devices/cpu/nec/v5x.h +++ b/src/devices/cpu/nec/v5x.h @@ -149,7 +149,7 @@ public: auto tout2_cb() { return subdevice<pit8253_device>("tcu")->out_handler<2>(); } protected: - v50_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool is_16bit, u8 prefetch_size, u8 prefetch_cycles, u32 chip_type); + v50_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_16bit, u8 prefetch_size, u8 prefetch_cycles, u32 chip_type); // device-specific overrides virtual void device_add_mconfig(machine_config &config) override; @@ -191,7 +191,7 @@ private: class v40_device : public v50_base_device { public: - v40_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + v40_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void install_peripheral_io() override; @@ -200,7 +200,7 @@ protected: class v50_device : public v50_base_device { public: - v50_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + v50_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void install_peripheral_io() override; @@ -209,7 +209,7 @@ protected: class v53_device : public v33_base_device, public device_v5x_interface { public: - v53_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + v53_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <unsigned Channel> DECLARE_WRITE_LINE_MEMBER(dreq_w) { @@ -228,7 +228,7 @@ public: template <unsigned Timer> auto out_handler() { return subdevice<pit8253_device>("tcu")->out_handler<Timer>(); } protected: - v53_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + v53_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-specific overrides virtual void device_add_mconfig(machine_config &config) override; @@ -262,7 +262,7 @@ private: class v53a_device : public v53_device { public: - v53a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + v53a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(V40, v40_device) diff --git a/src/devices/cpu/nios2/nios2.cpp b/src/devices/cpu/nios2/nios2.cpp index 39dd0fc6209..8f4893f2710 100644 --- a/src/devices/cpu/nios2/nios2.cpp +++ b/src/devices/cpu/nios2/nios2.cpp @@ -15,7 +15,7 @@ // device type definition DEFINE_DEVICE_TYPE(NIOS2, nios2_device, "nios2", "Altera Nios II Processor") -nios2_device::nios2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nios2_device::nios2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, NIOS2, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 32, 32, 0) { diff --git a/src/devices/cpu/nios2/nios2.h b/src/devices/cpu/nios2/nios2.h index de2073e0e47..34925655a3e 100644 --- a/src/devices/cpu/nios2/nios2.h +++ b/src/devices/cpu/nios2/nios2.h @@ -18,7 +18,7 @@ public: }; // construction/destruction - nios2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nios2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/ns32000/ns32000.cpp b/src/devices/cpu/ns32000/ns32000.cpp index d3f04bbd5d3..f28b7144532 100644 --- a/src/devices/cpu/ns32000/ns32000.cpp +++ b/src/devices/cpu/ns32000/ns32000.cpp @@ -96,7 +96,7 @@ static const u32 size_mask[] = { 0x000000ffU, 0x0000ffffU, 0x00000000U, 0xffffff #define SP ((m_psr & PSR_S) ? m_sp1 : m_sp0) -template <int Width>ns32000_device<Width>::ns32000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int databits, int addrbits) +template <int Width>ns32000_device<Width>::ns32000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int databits, int addrbits) : cpu_device(mconfig, type, tag, owner, clock) , m_address_mask(0xffffffffU >> (32 - addrbits)) , m_program_config("program", ENDIANNESS_LITTLE, databits, addrbits, 0) @@ -130,22 +130,22 @@ template <int Width>ns32000_device<Width>::ns32000_device(const machine_config & { } -ns32008_device::ns32008_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ns32008_device::ns32008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ns32000_device(mconfig, NS32008, tag, owner, clock, 8, 24) { } -ns32016_device::ns32016_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ns32016_device::ns32016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ns32000_device(mconfig, NS32016, tag, owner, clock, 16, 24) { } -ns32032_device::ns32032_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ns32032_device::ns32032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ns32000_device(mconfig, NS32032, tag, owner, clock, 32, 24) { } -ns32332_device::ns32332_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ns32332_device::ns32332_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ns32000_device(mconfig, NS32332, tag, owner, clock, 32, 32) { } diff --git a/src/devices/cpu/ns32000/ns32000.h b/src/devices/cpu/ns32000/ns32000.h index 654d8661f8a..ae41f9fbb07 100644 --- a/src/devices/cpu/ns32000/ns32000.h +++ b/src/devices/cpu/ns32000/ns32000.h @@ -16,10 +16,10 @@ public: template <typename T> void set_mmu(T &&tag) { m_mmu.set_tag(std::forward<T>(tag)); } // construction/destruction - ns32000_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + ns32000_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); protected: - ns32000_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, int databits, int addrbits); + ns32000_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, int databits, int addrbits); // device_t overrides virtual void device_start() override; @@ -191,25 +191,25 @@ private: class ns32008_device : public ns32000_device<0> { public: - ns32008_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + ns32008_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class ns32016_device : public ns32000_device<1> { public: - ns32016_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + ns32016_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class ns32032_device : public ns32000_device<2> { public: - ns32032_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + ns32032_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class ns32332_device : public ns32000_device<2> { public: - ns32332_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + ns32332_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(NS32008, ns32008_device) diff --git a/src/devices/cpu/nuon/nuon.cpp b/src/devices/cpu/nuon/nuon.cpp index 00d35cddc39..e45908b450f 100644 --- a/src/devices/cpu/nuon/nuon.cpp +++ b/src/devices/cpu/nuon/nuon.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(NUON, nuon_device, "nuon", "Aries 3 \"Nuon\"") // nuon_device - constructor //------------------------------------------------- -nuon_device::nuon_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nuon_device::nuon_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, NUON, tag, owner, clock) , m_program_configs{{"program_mpe0", ENDIANNESS_BIG, 32, 32}, {"program_mpe1", ENDIANNESS_BIG, 32, 32}, diff --git a/src/devices/cpu/nuon/nuon.h b/src/devices/cpu/nuon/nuon.h index f3a7311e985..ecdb5cc6d76 100644 --- a/src/devices/cpu/nuon/nuon.h +++ b/src/devices/cpu/nuon/nuon.h @@ -20,7 +20,7 @@ class nuon_device : public cpu_device { public: - nuon_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nuon_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/pace/pace.cpp b/src/devices/cpu/pace/pace.cpp index 2bfba2cc338..38c6d5fe4e4 100644 --- a/src/devices/cpu/pace/pace.cpp +++ b/src/devices/cpu/pace/pace.cpp @@ -62,7 +62,7 @@ ALLOW_SAVE_TYPE(pace_device::cycle); // pace_device - constructor //------------------------------------------------- -pace_device::pace_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +pace_device::pace_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_space_config("program", ENDIANNESS_LITTLE, 16, 16, -1) , m_bps_callback(*this) @@ -89,7 +89,7 @@ pace_device::pace_device(const machine_config &mconfig, device_type type, const // ins8900_device - constructor //------------------------------------------------- -ins8900_device::ins8900_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ins8900_device::ins8900_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pace_device(mconfig, INS8900, tag, owner, clock) { } diff --git a/src/devices/cpu/pace/pace.h b/src/devices/cpu/pace/pace.h index c96c38e5c02..d11c021b065 100644 --- a/src/devices/cpu/pace/pace.h +++ b/src/devices/cpu/pace/pace.h @@ -68,7 +68,7 @@ public: protected: // construction/destruction - pace_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + pace_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-specific overrides virtual void device_resolve_objects() override; @@ -216,7 +216,7 @@ class ins8900_device : public pace_device { public: // device type constructor - ins8900_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ins8900_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type declarations diff --git a/src/devices/cpu/patinhofeio/patinho_feio.cpp b/src/devices/cpu/patinhofeio/patinho_feio.cpp index d017ff8a318..e341ea40cbc 100644 --- a/src/devices/cpu/patinhofeio/patinho_feio.cpp +++ b/src/devices/cpu/patinhofeio/patinho_feio.cpp @@ -56,7 +56,7 @@ void patinho_feio_cpu_device::prog_8bit(address_map &map) map(0x0000, 0x0fff).ram().share("internalram"); } -patinho_feio_cpu_device::patinho_feio_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +patinho_feio_cpu_device::patinho_feio_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, PATO_FEIO_CPU, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 12, 0, address_map_constructor(FUNC(patinho_feio_cpu_device::prog_8bit), this)) , m_update_panel_cb(*this) diff --git a/src/devices/cpu/pdp1/pdp1.cpp b/src/devices/cpu/pdp1/pdp1.cpp index 77c97ebcddc..8ef280e4860 100644 --- a/src/devices/cpu/pdp1/pdp1.cpp +++ b/src/devices/cpu/pdp1/pdp1.cpp @@ -380,7 +380,7 @@ DEFINE_DEVICE_TYPE(PDP1, pdp1_device, "pdp1_cpu", "DEC PDP-1 Central Processor") -pdp1_device::pdp1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pdp1_device::pdp1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, PDP1, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 32, 18, -2) // data is actually 18 bits wide , m_extern_iot(*this) diff --git a/src/devices/cpu/pdp1/pdp1.h b/src/devices/cpu/pdp1/pdp1.h index f1a4e934236..db80b85e311 100644 --- a/src/devices/cpu/pdp1/pdp1.h +++ b/src/devices/cpu/pdp1/pdp1.h @@ -71,7 +71,7 @@ public: }; // construction/destruction - pdp1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pdp1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <int I, typename... T> void set_iot_callback(T &&... args) { m_extern_iot[I].set(std::forward<T>(args)...); } template <typename... T> void set_io_sc_callback(T &&... args) { m_io_sc_callback.set(std::forward<T>(args)...); } diff --git a/src/devices/cpu/pdp8/hd6120.cpp b/src/devices/cpu/pdp8/hd6120.cpp index fda3deea264..75a608ecde1 100644 --- a/src/devices/cpu/pdp8/hd6120.cpp +++ b/src/devices/cpu/pdp8/hd6120.cpp @@ -164,7 +164,7 @@ DEFINE_DEVICE_TYPE(HD6120, hd6120_device, "hd6120", "Harris HD-6120") ALLOW_SAVE_TYPE(hd6120_device::minor_state) -hd6120_device::hd6120_device(const machine_config &config, const char *tag, device_t *owner, u32 clock) +hd6120_device::hd6120_device(const machine_config &config, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(config, HD6120, tag, owner, clock) , m_inst_config("instruction", ENDIANNESS_BIG, 16, 16, -1) // 12 data bits , m_data_config("data", ENDIANNESS_BIG, 16, 16, -1) // 12 data bits diff --git a/src/devices/cpu/pdp8/hd6120.h b/src/devices/cpu/pdp8/hd6120.h index 126ce115040..699157b75c8 100644 --- a/src/devices/cpu/pdp8/hd6120.h +++ b/src/devices/cpu/pdp8/hd6120.h @@ -68,7 +68,7 @@ public: }; // device type constructor - hd6120_device(const machine_config &config, const char *tag, device_t *owner, u32 clock); + hd6120_device(const machine_config &config, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto lxmar_callback() { return m_lxmar_callback.bind(); } diff --git a/src/devices/cpu/pdp8/pdp8.cpp b/src/devices/cpu/pdp8/pdp8.cpp index 31086b3fb48..1aab04e1702 100644 --- a/src/devices/cpu/pdp8/pdp8.cpp +++ b/src/devices/cpu/pdp8/pdp8.cpp @@ -48,7 +48,7 @@ DEFINE_DEVICE_TYPE(PDP8, pdp8_device, "pdp8_cpu", "DEC PDP8") // pdp8_device - constructor //------------------------------------------------- -pdp8_device::pdp8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pdp8_device::pdp8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, PDP8, tag, owner, clock), m_program_config("program", ENDIANNESS_BIG, 16, 12, -1), m_pc(0), diff --git a/src/devices/cpu/pdp8/pdp8.h b/src/devices/cpu/pdp8/pdp8.h index ef6c4af95ae..fb2b2295e1b 100644 --- a/src/devices/cpu/pdp8/pdp8.h +++ b/src/devices/cpu/pdp8/pdp8.h @@ -22,7 +22,7 @@ class pdp8_device : public cpu_device { public: // construction/destruction - pdp8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pdp8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/pic16c5x/pic16c5x.cpp b/src/devices/cpu/pic16c5x/pic16c5x.cpp index 5d6f14a1071..e5bc68a1790 100644 --- a/src/devices/cpu/pic16c5x/pic16c5x.cpp +++ b/src/devices/cpu/pic16c5x/pic16c5x.cpp @@ -123,7 +123,7 @@ void pic16c5x_device::ram_7(address_map &map) } -pic16c5x_device::pic16c5x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, int picmodel) +pic16c5x_device::pic16c5x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, int picmodel) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, program_width, -1 , ( ( program_width == 9 ) ? address_map_constructor(FUNC(pic16c5x_device::rom_9), this): ( ( program_width == 10 ) ? address_map_constructor(FUNC(pic16c5x_device::rom_10), this) : address_map_constructor(FUNC(pic16c5x_device::rom_11), this) ))) @@ -147,42 +147,42 @@ pic16c5x_device::pic16c5x_device(const machine_config &mconfig, device_type type } -pic16c54_device::pic16c54_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c54_device::pic16c54_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c5x_device(mconfig, PIC16C54, tag, owner, clock, 9, 5, 0x16C54) { } -pic16c55_device::pic16c55_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c55_device::pic16c55_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c5x_device(mconfig, PIC16C55, tag, owner, clock, 9, 5, 0x16C55) { } -pic16c56_device::pic16c56_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c56_device::pic16c56_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c5x_device(mconfig, PIC16C56, tag, owner, clock, 10, 5, 0x16C56) { } -pic16c57_device::pic16c57_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c57_device::pic16c57_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c5x_device(mconfig, PIC16C57, tag, owner, clock, 11, 7, 0x16C57) { } -pic16c58_device::pic16c58_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c58_device::pic16c58_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c5x_device(mconfig, PIC16C58, tag, owner, clock, 11, 7, 0x16C58) { } -pic1650_device::pic1650_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic1650_device::pic1650_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c5x_device(mconfig, PIC1650, tag, owner, clock, 9, 5, 0x1650) { } -pic1654s_device::pic1654s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic1654s_device::pic1654s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c5x_device(mconfig, PIC1654S, tag, owner, clock, 9, 5, 0x1654) { } -pic1655_device::pic1655_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic1655_device::pic1655_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c5x_device(mconfig, PIC1655, tag, owner, clock, 9, 5, 0x1655) { } diff --git a/src/devices/cpu/pic16c5x/pic16c5x.h b/src/devices/cpu/pic16c5x/pic16c5x.h index 177b9cae7a2..0ae1176a66c 100644 --- a/src/devices/cpu/pic16c5x/pic16c5x.h +++ b/src/devices/cpu/pic16c5x/pic16c5x.h @@ -79,7 +79,7 @@ public: void rom_9(address_map &map); protected: // construction/destruction - pic16c5x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int data_width, int picmodel); + pic16c5x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int data_width, int picmodel); // device-level overrides virtual void device_start() override; @@ -226,7 +226,7 @@ class pic16c54_device : public pic16c5x_device { public: // construction/destruction - pic16c54_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c54_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -234,7 +234,7 @@ class pic16c55_device : public pic16c5x_device { public: // construction/destruction - pic16c55_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c55_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -242,7 +242,7 @@ class pic16c56_device : public pic16c5x_device { public: // construction/destruction - pic16c56_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c56_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -250,7 +250,7 @@ class pic16c57_device : public pic16c5x_device { public: // construction/destruction - pic16c57_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c57_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -258,7 +258,7 @@ class pic16c58_device : public pic16c5x_device { public: // construction/destruction - pic16c58_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c58_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -266,14 +266,14 @@ class pic1650_device : public pic16c5x_device { public: // construction/destruction - pic1650_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic1650_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class pic1654s_device : public pic16c5x_device { public: // construction/destruction - pic1654s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic1654s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // 1654S has a /8 clock divider instead of the typical /4 @@ -285,7 +285,7 @@ class pic1655_device : public pic16c5x_device { public: // construction/destruction - pic1655_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic1655_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; #endif // MAME_CPU_PIC16C5X_PIC16C5X_H diff --git a/src/devices/cpu/pic16c62x/pic16c62x.cpp b/src/devices/cpu/pic16c62x/pic16c62x.cpp index ddb6d3c9bb8..59bc368faff 100644 --- a/src/devices/cpu/pic16c62x/pic16c62x.cpp +++ b/src/devices/cpu/pic16c62x/pic16c62x.cpp @@ -119,7 +119,7 @@ void pic16c62x_device::pic16c62xa_ram(address_map &map) } -pic16c62x_device::pic16c62x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int picmodel) +pic16c62x_device::pic16c62x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int picmodel) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, program_width, -1 , ( ( program_width == 9 ) ? address_map_constructor(FUNC(pic16c62x_device::pic16c62x_rom_9), this) : @@ -138,32 +138,32 @@ pic16c62x_device::pic16c62x_device(const machine_config &mconfig, device_type ty } -pic16c620_device::pic16c620_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c620_device::pic16c620_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c62x_device(mconfig, PIC16C620, tag, owner, clock, 9, 0x16C620) { } -pic16c620a_device::pic16c620a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c620a_device::pic16c620a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c62x_device(mconfig, PIC16C620A, tag, owner, clock, 9, 0x16C620A) { } -pic16c621_device::pic16c621_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c621_device::pic16c621_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c62x_device(mconfig, PIC16C621, tag, owner, clock, 10, 0x16C621) { } -pic16c621a_device::pic16c621a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c621a_device::pic16c621a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c62x_device(mconfig, PIC16C621A, tag, owner, clock, 10, 0x16C621A) { } -pic16c622_device::pic16c622_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c622_device::pic16c622_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c62x_device(mconfig, PIC16C622, tag, owner, clock, 11, 0x16C622) { } -pic16c622a_device::pic16c622a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic16c622a_device::pic16c622a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic16c62x_device(mconfig, PIC16C622A, tag, owner, clock, 11, 0x16C622A) { } diff --git a/src/devices/cpu/pic16c62x/pic16c62x.h b/src/devices/cpu/pic16c62x/pic16c62x.h index d0b9390078f..427bcc0dad4 100644 --- a/src/devices/cpu/pic16c62x/pic16c62x.h +++ b/src/devices/cpu/pic16c62x/pic16c62x.h @@ -58,7 +58,7 @@ public: protected: // construction/destruction - pic16c62x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int program_width, int picmodel); + pic16c62x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int program_width, int picmodel); // device-level overrides virtual void device_start() override; @@ -208,14 +208,14 @@ class pic16c620_device : public pic16c62x_device { public: // construction/destruction - pic16c620_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c620_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class pic16c620a_device : public pic16c62x_device { public: // construction/destruction - pic16c620a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c620a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; /* @@ -223,35 +223,35 @@ class pic16cr620a_device : public pic16c62x_device { public: // construction/destruction - pic16cr620a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16cr620a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }*/ class pic16c621_device : public pic16c62x_device { public: // construction/destruction - pic16c621_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c621_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class pic16c621a_device : public pic16c62x_device { public: // construction/destruction - pic16c621a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c621a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class pic16c622_device : public pic16c62x_device { public: // construction/destruction - pic16c622_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c622_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class pic16c622a_device : public pic16c62x_device { public: // construction/destruction - pic16c622a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pic16c622a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/pic17/pic17.cpp b/src/devices/cpu/pic17/pic17.cpp index 99dff413d54..347b9c0e943 100644 --- a/src/devices/cpu/pic17/pic17.cpp +++ b/src/devices/cpu/pic17/pic17.cpp @@ -64,7 +64,7 @@ ALLOW_SAVE_TYPE(pic17_cpu_device::exec_phase); -pic17_cpu_device::pic17_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 rom_size, address_map_constructor data_map) +pic17_cpu_device::pic17_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 rom_size, address_map_constructor data_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 16, -1, address_map_constructor(FUNC(pic17_cpu_device::program_map), this)) , m_data_config("data", ENDIANNESS_LITTLE, 8, 12, 0, data_map) diff --git a/src/devices/cpu/pic17/pic17.h b/src/devices/cpu/pic17/pic17.h index fed49748a67..f139a04568f 100644 --- a/src/devices/cpu/pic17/pic17.h +++ b/src/devices/cpu/pic17/pic17.h @@ -40,7 +40,7 @@ public: void set_mode(mode m) { m_mode = m; } protected: - pic17_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 rom_size, address_map_constructor data_map); + pic17_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 rom_size, address_map_constructor data_map); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/pic17/pic17c4x.cpp b/src/devices/cpu/pic17/pic17c4x.cpp index 07976c32b79..4ed8654bca4 100644 --- a/src/devices/cpu/pic17/pic17c4x.cpp +++ b/src/devices/cpu/pic17/pic17c4x.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(PIC17C43, pic17c43_device, "pic17c43", "Microchip PIC17C43") DEFINE_DEVICE_TYPE(PIC17C44, pic17c44_device, "pic17c44", "Microchip PIC17C44") -pic17c4x_device::pic17c4x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 rom_size, address_map_constructor data_map) +pic17c4x_device::pic17c4x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 rom_size, address_map_constructor data_map) : pic17_cpu_device(mconfig, type, tag, owner, clock, rom_size, data_map) , m_port_out_cb(*this) , m_rain(0x3f) @@ -56,17 +56,17 @@ pic17c4x_device::pic17c4x_device(const machine_config &mconfig, device_type type { } -pic17c43_device::pic17c43_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 rom_size) +pic17c43_device::pic17c43_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 rom_size) : pic17c4x_device(mconfig, type, tag, owner, clock, rom_size, address_map_constructor(FUNC(pic17c43_device::data_map), this)) { } -pic17c43_device::pic17c43_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pic17c43_device::pic17c43_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic17c43_device(mconfig, PIC17C43, tag, owner, clock, 0x1000) { } -pic17c44_device::pic17c44_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pic17c44_device::pic17c44_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic17c43_device(mconfig, PIC17C44, tag, owner, clock, 0x2000) { } diff --git a/src/devices/cpu/pic17/pic17c4x.h b/src/devices/cpu/pic17/pic17c4x.h index e1ae9290230..101b9cada5b 100644 --- a/src/devices/cpu/pic17/pic17c4x.h +++ b/src/devices/cpu/pic17/pic17c4x.h @@ -75,7 +75,7 @@ public: auto re_out_cb() { return m_port_out_cb[4].bind(); } protected: - pic17c4x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 rom_size, address_map_constructor data_map); + pic17c4x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 rom_size, address_map_constructor data_map); // device-level overrides virtual void device_resolve_objects() override; @@ -158,10 +158,10 @@ class pic17c43_device : public pic17c4x_device { public: // device type constructor - pic17c43_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pic17c43_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - pic17c43_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 rom_size); + pic17c43_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 rom_size); private: void data_map(address_map &map); @@ -171,7 +171,7 @@ class pic17c44_device : public pic17c43_device { public: // device type constructor - pic17c44_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pic17c44_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type declarations diff --git a/src/devices/cpu/powerpc/ppc.h b/src/devices/cpu/powerpc/ppc.h index b27f80efc7e..799371ca363 100644 --- a/src/devices/cpu/powerpc/ppc.h +++ b/src/devices/cpu/powerpc/ppc.h @@ -205,7 +205,7 @@ protected: }; // construction/destruction - ppc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int address_bits, int data_bits, powerpc_flavor flavor, uint32_t cap, uint32_t tb_divisor, address_map_constructor internal_map); + ppc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int address_bits, int data_bits, powerpc_flavor flavor, uint32_t cap, uint32_t tb_divisor, address_map_constructor internal_map); public: virtual ~ppc_device() override; @@ -686,7 +686,7 @@ private: //class ppc403_device : public ppc_device //{ //public: -// ppc403_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); +// ppc403_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // //protected: // virtual uint32_t execute_input_lines() const noexcept { return 8; } @@ -696,7 +696,7 @@ private: //class ppc405_device : public ppc_device //{ //public: -// ppc405_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); +// ppc405_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // //protected: // virtual uint32_t execute_input_lines() const noexcept { return 8; } @@ -706,49 +706,49 @@ private: class ppc603_device : public ppc_device { public: - ppc603_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ppc603_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ppc603e_device : public ppc_device { public: - ppc603e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ppc603e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ppc603r_device : public ppc_device { public: - ppc603r_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ppc603r_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ppc602_device : public ppc_device { public: - ppc602_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ppc602_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mpc8240_device : public ppc_device { public: - mpc8240_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpc8240_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ppc601_device : public ppc_device { public: - ppc601_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ppc601_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ppc604_device : public ppc_device { public: - ppc604_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ppc604_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -768,7 +768,7 @@ public: void internal_ppc4xx(address_map &map); protected: - ppc4xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, powerpc_flavor flavor, uint32_t cap, uint32_t tb_divisor); + ppc4xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, powerpc_flavor flavor, uint32_t cap, uint32_t tb_divisor); virtual uint32_t execute_input_lines() const noexcept override { return 5; } virtual void execute_set_input(int inputnum, int state) override; @@ -778,21 +778,21 @@ protected: class ppc403ga_device : public ppc4xx_device { public: - ppc403ga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ppc403ga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ppc403gcx_device : public ppc4xx_device { public: - ppc403gcx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ppc403gcx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ppc405gp_device : public ppc4xx_device { public: - ppc405gp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ppc405gp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/powerpc/ppccom.cpp b/src/devices/cpu/powerpc/ppccom.cpp index aecc85d1709..86499979c61 100644 --- a/src/devices/cpu/powerpc/ppccom.cpp +++ b/src/devices/cpu/powerpc/ppccom.cpp @@ -207,7 +207,7 @@ DEFINE_DEVICE_TYPE(PPC403GCX, ppc403gcx_device, "ppc403gcx", "IBM PowerPC 403GC DEFINE_DEVICE_TYPE(PPC405GP, ppc405gp_device, "ppc405gp", "IBM PowerPC 405GP") -ppc_device::ppc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int address_bits, int data_bits, powerpc_flavor flavor, uint32_t cap, uint32_t tb_divisor, address_map_constructor internal_map) +ppc_device::ppc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int address_bits, int data_bits, powerpc_flavor flavor, uint32_t cap, uint32_t tb_divisor, address_map_constructor internal_map) : cpu_device(mconfig, type, tag, owner, clock) , device_vtlb_interface(mconfig, *this, AS_PROGRAM) , m_program_config("program", ENDIANNESS_BIG, data_bits, address_bits, 0, internal_map) @@ -242,47 +242,47 @@ ppc_device::~ppc_device() { } -//ppc403_device::ppc403_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +//ppc403_device::ppc403_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) // : ppc_device(mconfig, PPC403, "PPC403", tag, owner, clock, "ppc403", 32?, 64?) //{ //} // -//ppc405_device::ppc405_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +//ppc405_device::ppc405_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) // : ppc_device(mconfig, PPC405, "PPC405", tag, owner, clock, "ppc405", 32?, 64?) //{ //} -ppc603_device::ppc603_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ppc603_device::ppc603_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ppc_device(mconfig, PPC603, tag, owner, clock, 32, 64, PPC_MODEL_603, PPCCAP_OEA | PPCCAP_VEA | PPCCAP_FPU | PPCCAP_MISALIGNED | PPCCAP_603_MMU, 4, address_map_constructor()) { } -ppc603e_device::ppc603e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ppc603e_device::ppc603e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ppc_device(mconfig, PPC603E, tag, owner, clock, 32, 64, PPC_MODEL_603E, PPCCAP_OEA | PPCCAP_VEA | PPCCAP_FPU | PPCCAP_MISALIGNED | PPCCAP_603_MMU, 4, address_map_constructor()) { } -ppc603r_device::ppc603r_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ppc603r_device::ppc603r_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ppc_device(mconfig, PPC603R, tag, owner, clock, 32, 64, PPC_MODEL_603R, PPCCAP_OEA | PPCCAP_VEA | PPCCAP_FPU | PPCCAP_MISALIGNED | PPCCAP_603_MMU, 4, address_map_constructor()) { } -ppc602_device::ppc602_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ppc602_device::ppc602_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ppc_device(mconfig, PPC602, tag, owner, clock, 32, 64, PPC_MODEL_602, PPCCAP_OEA | PPCCAP_VEA | PPCCAP_FPU | PPCCAP_MISALIGNED | PPCCAP_603_MMU, 4, address_map_constructor()) { } -mpc8240_device::mpc8240_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpc8240_device::mpc8240_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ppc_device(mconfig, MPC8240, tag, owner, clock, 32, 64, PPC_MODEL_MPC8240, PPCCAP_OEA | PPCCAP_VEA | PPCCAP_FPU | PPCCAP_MISALIGNED | PPCCAP_603_MMU, 4/* unknown */, address_map_constructor()) { } -ppc601_device::ppc601_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ppc601_device::ppc601_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ppc_device(mconfig, PPC601, tag, owner, clock, 32, 64, PPC_MODEL_601, PPCCAP_OEA | PPCCAP_VEA | PPCCAP_FPU | PPCCAP_MISALIGNED | PPCCAP_MFIOC | PPCCAP_601BAT, 0/* no TB */, address_map_constructor()) { } -ppc604_device::ppc604_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ppc604_device::ppc604_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ppc_device(mconfig, PPC604, tag, owner, clock, 32, 64, PPC_MODEL_604, PPCCAP_OEA | PPCCAP_VEA | PPCCAP_FPU | PPCCAP_MISALIGNED | PPCCAP_604_MMU, 4, address_map_constructor()) { } @@ -292,22 +292,22 @@ void ppc4xx_device::internal_ppc4xx(address_map &map) map(0x40000000, 0x4000000f).rw(FUNC(ppc4xx_device::ppc4xx_spu_r), FUNC(ppc4xx_device::ppc4xx_spu_w)); } -ppc4xx_device::ppc4xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, powerpc_flavor flavor, uint32_t cap, uint32_t tb_divisor) +ppc4xx_device::ppc4xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, powerpc_flavor flavor, uint32_t cap, uint32_t tb_divisor) : ppc_device(mconfig, type, tag, owner, clock, 31, 32, flavor, cap, tb_divisor, address_map_constructor(FUNC(ppc4xx_device::internal_ppc4xx), this)) { } -ppc403ga_device::ppc403ga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ppc403ga_device::ppc403ga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ppc4xx_device(mconfig, PPC403GA, tag, owner, clock, PPC_MODEL_403GA, PPCCAP_4XX, 1) { } -ppc403gcx_device::ppc403gcx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ppc403gcx_device::ppc403gcx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ppc4xx_device(mconfig, PPC403GCX, tag, owner, clock, PPC_MODEL_403GCX, PPCCAP_4XX, 1) { } -ppc405gp_device::ppc405gp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ppc405gp_device::ppc405gp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ppc4xx_device(mconfig, PPC405GP, tag, owner, clock, PPC_MODEL_405GP, PPCCAP_4XX | PPCCAP_VEA, 1) { } diff --git a/src/devices/cpu/pps4/pps4.cpp b/src/devices/cpu/pps4/pps4.cpp index 1a44fa2a39b..e5025928bc2 100644 --- a/src/devices/cpu/pps4/pps4.cpp +++ b/src/devices/cpu/pps4/pps4.cpp @@ -86,7 +86,7 @@ DEFINE_DEVICE_TYPE(PPS4, pps4_device, "pps4", "Rockwell PPS4-4") DEFINE_DEVICE_TYPE(PPS4_2, pps4_2_device, "pps4_2", "Rockwell PPS-4/2") -pps4_device::pps4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +pps4_device::pps4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 12) , m_data_config("data", ENDIANNESS_LITTLE, 8, 12) // 4bit RAM @@ -99,12 +99,12 @@ pps4_device::pps4_device(const machine_config &mconfig, device_type type, const { } -pps4_device::pps4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pps4_device::pps4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pps4_device(mconfig, PPS4, tag, owner, clock) { } -pps4_2_device::pps4_2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pps4_2_device::pps4_2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pps4_device(mconfig, PPS4_2, tag, owner, clock) { } diff --git a/src/devices/cpu/pps4/pps4.h b/src/devices/cpu/pps4/pps4.h index 4b9b82f37c0..35901965c95 100644 --- a/src/devices/cpu/pps4/pps4.h +++ b/src/devices/cpu/pps4/pps4.h @@ -40,7 +40,7 @@ class pps4_device : public cpu_device { public: // construction/destruction - pps4_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pps4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto dia_cb() { return m_dia_cb.bind(); } @@ -50,7 +50,7 @@ public: u16 address_bus_r(address_space &space); protected: - pps4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + pps4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -171,7 +171,7 @@ class pps4_2_device : public pps4_device { public: // construction/destruction - pps4_2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pps4_2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/pps41/mm75.cpp b/src/devices/cpu/pps41/mm75.cpp index 83c5ae06368..d89fa319701 100644 --- a/src/devices/cpu/pps41/mm75.cpp +++ b/src/devices/cpu/pps41/mm75.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(MM75, mm75_device, "mm75", "Rockwell MM75 A7500") // stripped // constructor -mm75_device::mm75_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm75_device::mm75_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm76_device(mconfig, MM75, tag, owner, clock, 10, address_map_constructor(FUNC(mm75_device::program_0_6k), this), 6, address_map_constructor(FUNC(mm75_device::data_48x4), this)) { } diff --git a/src/devices/cpu/pps41/mm75.h b/src/devices/cpu/pps41/mm75.h index 39a14245cae..5eaba622bbd 100644 --- a/src/devices/cpu/pps41/mm75.h +++ b/src/devices/cpu/pps41/mm75.h @@ -37,7 +37,7 @@ class mm75_device : public mm76_device { public: - mm75_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm75_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/cpu/pps41/mm76.cpp b/src/devices/cpu/pps41/mm76.cpp index bb7d9cd7a53..c0dacb2d371 100644 --- a/src/devices/cpu/pps41/mm76.cpp +++ b/src/devices/cpu/pps41/mm76.cpp @@ -19,27 +19,27 @@ DEFINE_DEVICE_TYPE(MM76EL, mm76el_device, "mm76el", "Rockwell MM76EL B8600") // // constructor -mm76_device::mm76_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm76_device::mm76_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm76_device(mconfig, MM76, tag, owner, clock, 10, address_map_constructor(FUNC(mm76_device::program_0_6k), this), 6, address_map_constructor(FUNC(mm76_device::data_48x4), this)) { } -mm76_device::mm76_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +mm76_device::mm76_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : pps41_base_device(mconfig, type, tag, owner, clock, prgwidth, program, datawidth, data) { } -mm76l_device::mm76l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm76l_device::mm76l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm76_device(mconfig, MM76L, tag, owner, clock, 10, address_map_constructor(FUNC(mm76l_device::program_0_6k), this), 6, address_map_constructor(FUNC(mm76l_device::data_48x4), this)) { } -mm76e_device::mm76e_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm76e_device::mm76e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm76e_device(mconfig, MM76E, tag, owner, clock, 10, address_map_constructor(FUNC(mm76e_device::program_1k), this), 6, address_map_constructor(FUNC(mm76e_device::data_48x4), this)) { } -mm76e_device::mm76e_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +mm76e_device::mm76e_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : mm76_device(mconfig, type, tag, owner, clock, prgwidth, program, datawidth, data) { } -mm76el_device::mm76el_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm76el_device::mm76el_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm76e_device(mconfig, MM76EL, tag, owner, clock, 10, address_map_constructor(FUNC(mm76el_device::program_1k), this), 6, address_map_constructor(FUNC(mm76el_device::data_48x4), this)) { } diff --git a/src/devices/cpu/pps41/mm76.h b/src/devices/cpu/pps41/mm76.h index 54db25fc93b..5ec1193ecb9 100644 --- a/src/devices/cpu/pps41/mm76.h +++ b/src/devices/cpu/pps41/mm76.h @@ -44,10 +44,10 @@ class mm76_device : public pps41_base_device { public: - mm76_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm76_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - mm76_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + mm76_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device-level overrides virtual void device_start() override; @@ -136,16 +136,16 @@ protected: class mm76l_device : public mm76_device { public: - mm76l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm76l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mm76e_device : public mm76_device { public: - mm76e_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm76e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - mm76e_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + mm76e_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); void program_1k(address_map &map); }; @@ -153,7 +153,7 @@ protected: class mm76el_device : public mm76e_device { public: - mm76el_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm76el_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/pps41/mm78.cpp b/src/devices/cpu/pps41/mm78.cpp index 8512c8f3f07..ae23593ee3f 100644 --- a/src/devices/cpu/pps41/mm78.cpp +++ b/src/devices/cpu/pps41/mm78.cpp @@ -19,27 +19,27 @@ DEFINE_DEVICE_TYPE(MM77L, mm77l_device, "mm77l", "Rockwell MM77L B7700") // 1.5K // constructor -mm78_device::mm78_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm78_device::mm78_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm78_device(mconfig, MM78, tag, owner, clock, 11, address_map_constructor(FUNC(mm78_device::program_2k), this), 7, address_map_constructor(FUNC(mm78_device::data_128x4), this)) { } -mm78_device::mm78_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +mm78_device::mm78_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : mm76_device(mconfig, type, tag, owner, clock, prgwidth, program, datawidth, data) { } -mm78l_device::mm78l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm78l_device::mm78l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm78_device(mconfig, MM78L, tag, owner, clock, 11, address_map_constructor(FUNC(mm78l_device::program_2k), this), 7, address_map_constructor(FUNC(mm78l_device::data_128x4), this)) { } -mm77_device::mm77_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm77_device::mm77_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm77_device(mconfig, MM77, tag, owner, clock, 11, address_map_constructor(FUNC(mm77_device::program_1_3k), this), 7, address_map_constructor(FUNC(mm77_device::data_96x4), this)) { } -mm77_device::mm77_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +mm77_device::mm77_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : mm78_device(mconfig, type, tag, owner, clock, prgwidth, program, datawidth, data) { } -mm77l_device::mm77l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm77l_device::mm77l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm77_device(mconfig, MM77L, tag, owner, clock, 11, address_map_constructor(FUNC(mm77l_device::program_1_5k), this), 7, address_map_constructor(FUNC(mm77l_device::data_96x4), this)) { } diff --git a/src/devices/cpu/pps41/mm78.h b/src/devices/cpu/pps41/mm78.h index d901d87988c..14ef3f2fe3d 100644 --- a/src/devices/cpu/pps41/mm78.h +++ b/src/devices/cpu/pps41/mm78.h @@ -45,10 +45,10 @@ class mm78_device : public mm76_device { public: - mm78_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm78_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - mm78_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + mm78_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device-level overrides virtual void device_start() override; @@ -101,22 +101,22 @@ protected: class mm78l_device : public mm78_device { public: - mm78l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm78l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mm77_device : public mm78_device { public: - mm77_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm77_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - mm77_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + mm77_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); }; class mm77l_device : public mm77_device { public: - mm77l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm77l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/pps41/mm78la.cpp b/src/devices/cpu/pps41/mm78la.cpp index 0e03e77935d..2509df48334 100644 --- a/src/devices/cpu/pps41/mm78la.cpp +++ b/src/devices/cpu/pps41/mm78la.cpp @@ -15,15 +15,15 @@ DEFINE_DEVICE_TYPE(MM77LA, mm77la_device, "mm77la", "Rockwell MM77LA B8000") // // constructor -mm78la_device::mm78la_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm78la_device::mm78la_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm78la_device(mconfig, MM78LA, tag, owner, clock, 11, address_map_constructor(FUNC(mm78la_device::program_2k), this), 7, address_map_constructor(FUNC(mm78la_device::data_128x4), this)) { } -mm78la_device::mm78la_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +mm78la_device::mm78la_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : mm78_device(mconfig, type, tag, owner, clock, prgwidth, program, datawidth, data) { } -mm77la_device::mm77la_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm77la_device::mm77la_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm78la_device(mconfig, MM77LA, tag, owner, clock, 11, address_map_constructor(FUNC(mm77la_device::program_1_5k), this), 7, address_map_constructor(FUNC(mm77la_device::data_96x4), this)) { } diff --git a/src/devices/cpu/pps41/mm78la.h b/src/devices/cpu/pps41/mm78la.h index a9c58ab4572..a4f67d321ab 100644 --- a/src/devices/cpu/pps41/mm78la.h +++ b/src/devices/cpu/pps41/mm78la.h @@ -46,10 +46,10 @@ class mm78la_device : public mm78_device { public: - mm78la_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm78la_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - mm78la_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + mm78la_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device-level overrides virtual void device_start() override; @@ -79,7 +79,7 @@ protected: class mm77la_device : public mm78la_device { public: - mm77la_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm77la_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/pps41/pps41base.cpp b/src/devices/cpu/pps41/pps41base.cpp index 9fa004640b3..ff5c02426c7 100644 --- a/src/devices/cpu/pps41/pps41base.cpp +++ b/src/devices/cpu/pps41/pps41base.cpp @@ -56,7 +56,7 @@ TODO: #include "pps41base.h" -pps41_base_device::pps41_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +pps41_base_device::pps41_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 8, prgwidth, 0, program), m_data_config("data", ENDIANNESS_LITTLE, 8, datawidth, 0, data), diff --git a/src/devices/cpu/pps41/pps41base.h b/src/devices/cpu/pps41/pps41base.h index 2d962b5a5d3..dd19e4c633c 100644 --- a/src/devices/cpu/pps41/pps41base.h +++ b/src/devices/cpu/pps41/pps41base.h @@ -56,7 +56,7 @@ public: protected: // construction/destruction - pps41_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + pps41_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/psx/dma.cpp b/src/devices/cpu/psx/dma.cpp index 0a901228944..5b4e12d760b 100644 --- a/src/devices/cpu/psx/dma.cpp +++ b/src/devices/cpu/psx/dma.cpp @@ -29,7 +29,7 @@ static inline void ATTR_PRINTF(3,4) verboselog( device_t& device, int n_level, c DEFINE_DEVICE_TYPE(PSX_DMA, psxdma_device, "psxdma", "Sony PSX DMA") -psxdma_device::psxdma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psxdma_device::psxdma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSX_DMA, tag, owner, clock), m_ram(), m_ramsize(0), m_dpcp(0), m_dicr(0), m_irq_handler(*this) { diff --git a/src/devices/cpu/psx/dma.h b/src/devices/cpu/psx/dma.h index 0d81d67da7d..35f1480006c 100644 --- a/src/devices/cpu/psx/dma.h +++ b/src/devices/cpu/psx/dma.h @@ -21,7 +21,7 @@ public: typedef delegate<void (uint32_t *, uint32_t, int32_t)> read_delegate; typedef delegate<void (uint32_t *, uint32_t, int32_t)> write_delegate; - psxdma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psxdma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); //configuration helpers auto irq() { return m_irq_handler.bind(); } diff --git a/src/devices/cpu/psx/irq.cpp b/src/devices/cpu/psx/irq.cpp index d14e8f7cdc0..7207daa83c7 100644 --- a/src/devices/cpu/psx/irq.cpp +++ b/src/devices/cpu/psx/irq.cpp @@ -32,7 +32,7 @@ static inline void ATTR_PRINTF(3,4) verboselog( device_t& device, int n_level, c DEFINE_DEVICE_TYPE(PSX_IRQ, psxirq_device, "psxirq", "Sony PSX IRQ") -psxirq_device::psxirq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psxirq_device::psxirq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSX_IRQ, tag, owner, clock), n_irqdata(0), n_irqmask(0), m_irq_handler(*this) { diff --git a/src/devices/cpu/psx/irq.h b/src/devices/cpu/psx/irq.h index b4ee28e712a..2708a0584a2 100644 --- a/src/devices/cpu/psx/irq.h +++ b/src/devices/cpu/psx/irq.h @@ -18,7 +18,7 @@ DECLARE_DEVICE_TYPE(PSX_IRQ, psxirq_device) class psxirq_device : public device_t { public: - psxirq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psxirq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq() { return m_irq_handler.bind(); } diff --git a/src/devices/cpu/psx/mdec.cpp b/src/devices/cpu/psx/mdec.cpp index 8b4421e4062..a2aa588175b 100644 --- a/src/devices/cpu/psx/mdec.cpp +++ b/src/devices/cpu/psx/mdec.cpp @@ -32,7 +32,7 @@ static inline void ATTR_PRINTF(3,4) verboselog( device_t& device, int n_level, c DEFINE_DEVICE_TYPE(PSX_MDEC, psxmdec_device, "psxmdec", "Sony PSX MDEC") -psxmdec_device::psxmdec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +psxmdec_device::psxmdec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSX_MDEC, tag, owner, clock), n_decoded(0), n_offset(0), n_0_command(0), n_0_address(0), n_0_size(0), n_1_command(0), n_1_status(0) { } diff --git a/src/devices/cpu/psx/mdec.h b/src/devices/cpu/psx/mdec.h index 8d9da890069..a597c3e69c1 100644 --- a/src/devices/cpu/psx/mdec.h +++ b/src/devices/cpu/psx/mdec.h @@ -18,7 +18,7 @@ DECLARE_DEVICE_TYPE(PSX_MDEC, psxmdec_device) class psxmdec_device : public device_t { public: - psxmdec_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psxmdec_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint32_t data); uint32_t read(offs_t offset); diff --git a/src/devices/cpu/psx/psx.cpp b/src/devices/cpu/psx/psx.cpp index 1e7ed448c2e..cb51a087212 100644 --- a/src/devices/cpu/psx/psx.cpp +++ b/src/devices/cpu/psx/psx.cpp @@ -1784,7 +1784,7 @@ void psxcpu_device::psxcpu_internal_map(address_map &map) // psxcpu_device - constructor //------------------------------------------------- -psxcpu_device::psxcpu_device( const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock ) : +psxcpu_device::psxcpu_device( const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock ) : cpu_device( mconfig, type, tag, owner, clock ), m_program_config( "program", ENDIANNESS_LITTLE, 32, 32, 0, address_map_constructor(FUNC(psxcpu_device::psxcpu_internal_map), this)), m_gpu_read_handler( *this ), @@ -1799,32 +1799,32 @@ psxcpu_device::psxcpu_device( const machine_config &mconfig, device_type type, c m_disable_rom_berr = false; } -cxd8530aq_device::cxd8530aq_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +cxd8530aq_device::cxd8530aq_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : psxcpu_device( mconfig, CXD8530AQ, tag, owner, clock) { } -cxd8530bq_device::cxd8530bq_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +cxd8530bq_device::cxd8530bq_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : psxcpu_device( mconfig, CXD8530BQ, tag, owner, clock) { } -cxd8530cq_device::cxd8530cq_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +cxd8530cq_device::cxd8530cq_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : psxcpu_device( mconfig, CXD8530CQ, tag, owner, clock) { } -cxd8661r_device::cxd8661r_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +cxd8661r_device::cxd8661r_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : psxcpu_device( mconfig, CXD8661R, tag, owner, clock) { } -cxd8606bq_device::cxd8606bq_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +cxd8606bq_device::cxd8606bq_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : psxcpu_device( mconfig, CXD8606BQ, tag, owner, clock) { } -cxd8606cq_device::cxd8606cq_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +cxd8606cq_device::cxd8606cq_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : psxcpu_device( mconfig, CXD8606CQ, tag, owner, clock) { } @@ -3450,17 +3450,17 @@ device_memory_interface::space_config_vector psxcpu_device::memory_space_config( void psxcpu_device::device_add_mconfig(machine_config &config) { - auto &irq(PSX_IRQ(config, "irq", 0)); + auto &irq(PSX_IRQ(config, "irq")); irq.irq().set_inputline(DEVICE_SELF, PSXCPU_IRQ0); - auto &dma(PSX_DMA(config, "dma", 0)); + auto &dma(PSX_DMA(config, "dma")); dma.irq().set("irq", FUNC(psxirq_device::intin3)); - auto &mdec(PSX_MDEC(config, "mdec", 0)); + auto &mdec(PSX_MDEC(config, "mdec")); dma.install_write_handler(0, psxdma_device::write_delegate(&psxmdec_device::dma_write, &mdec)); dma.install_read_handler(1, psxdma_device::write_delegate(&psxmdec_device::dma_read, &mdec)); - auto &rcnt(PSX_RCNT(config, "rcnt", 0)); + auto &rcnt(PSX_RCNT(config, "rcnt")); rcnt.irq0().set("irq", FUNC(psxirq_device::intin4)); rcnt.irq1().set("irq", FUNC(psxirq_device::intin5)); rcnt.irq2().set("irq", FUNC(psxirq_device::intin6)); diff --git a/src/devices/cpu/psx/psx.h b/src/devices/cpu/psx/psx.h index 4ab779d9139..73e756ae332 100644 --- a/src/devices/cpu/psx/psx.h +++ b/src/devices/cpu/psx/psx.h @@ -168,7 +168,7 @@ protected: static constexpr unsigned ICACHE_ENTRIES = 0x400; static constexpr unsigned DCACHE_ENTRIES = 0x100; - psxcpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + psxcpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -325,42 +325,42 @@ class cxd8530aq_device : public psxcpu_device { public: // construction/destruction - cxd8530aq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8530aq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cxd8530bq_device : public psxcpu_device { public: // construction/destruction - cxd8530bq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8530bq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cxd8530cq_device : public psxcpu_device { public: // construction/destruction - cxd8530cq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8530cq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cxd8661r_device : public psxcpu_device { public: // construction/destruction - cxd8661r_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8661r_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cxd8606bq_device : public psxcpu_device { public: // construction/destruction - cxd8606bq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8606bq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cxd8606cq_device : public psxcpu_device { public: // construction/destruction - cxd8606cq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8606cq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/cpu/psx/rcnt.cpp b/src/devices/cpu/psx/rcnt.cpp index 02e55dd5333..cdd71510846 100644 --- a/src/devices/cpu/psx/rcnt.cpp +++ b/src/devices/cpu/psx/rcnt.cpp @@ -29,7 +29,7 @@ static inline void ATTR_PRINTF(3,4) verboselog( device_t& device, int n_level, c DEFINE_DEVICE_TYPE(PSX_RCNT, psxrcnt_device, "psxrcnt", "Sony PSX RCNT") -psxrcnt_device::psxrcnt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psxrcnt_device::psxrcnt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PSX_RCNT, tag, owner, clock), m_irq0_handler(*this), m_irq1_handler(*this), diff --git a/src/devices/cpu/psx/rcnt.h b/src/devices/cpu/psx/rcnt.h index 8e0a471f4e1..61e1e852195 100644 --- a/src/devices/cpu/psx/rcnt.h +++ b/src/devices/cpu/psx/rcnt.h @@ -27,7 +27,7 @@ DECLARE_DEVICE_TYPE(PSX_RCNT, psxrcnt_device) class psxrcnt_device : public device_t { public: - psxrcnt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psxrcnt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq0() { return m_irq0_handler.bind(); } diff --git a/src/devices/cpu/psx/sio.cpp b/src/devices/cpu/psx/sio.cpp index 46b73d6b3a9..fc71b4d8055 100644 --- a/src/devices/cpu/psx/sio.cpp +++ b/src/devices/cpu/psx/sio.cpp @@ -30,17 +30,17 @@ static inline void ATTR_PRINTF(3,4) verboselog( device_t& device, int n_level, c DEFINE_DEVICE_TYPE(PSX_SIO0, psxsio0_device, "psxsio0", "Sony PSX SIO-0") DEFINE_DEVICE_TYPE(PSX_SIO1, psxsio1_device, "psxsio1", "Sony PSX SIO-1") -psxsio0_device::psxsio0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psxsio0_device::psxsio0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : psxsio_device(mconfig, PSX_SIO0, tag, owner, clock) { } -psxsio1_device::psxsio1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +psxsio1_device::psxsio1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : psxsio_device(mconfig, PSX_SIO1, tag, owner, clock) { } -psxsio_device::psxsio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +psxsio_device::psxsio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_status(SIO_STATUS_TX_EMPTY | SIO_STATUS_TX_RDY), m_mode(0), m_control(0), m_baud(0), m_rxd(1), m_tx_data(0), m_rx_data(0), m_tx_shift(0), m_rx_shift(0), m_tx_bits(0), m_rx_bits(0), m_timer(nullptr), diff --git a/src/devices/cpu/psx/sio.h b/src/devices/cpu/psx/sio.h index 482a8081d6a..afe6a3dceec 100644 --- a/src/devices/cpu/psx/sio.h +++ b/src/devices/cpu/psx/sio.h @@ -50,7 +50,7 @@ public: DECLARE_WRITE_LINE_MEMBER(write_dsr); protected: - psxsio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + psxsio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -86,13 +86,13 @@ private: class psxsio0_device : public psxsio_device { public: - psxsio0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psxsio0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class psxsio1_device : public psxsio_device { public: - psxsio1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + psxsio1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; #endif // MAME_CPU_PSX_SIO_H diff --git a/src/devices/cpu/rii/riscii.cpp b/src/devices/cpu/rii/riscii.cpp index f7c642a2f0a..7a28cde5437 100644 --- a/src/devices/cpu/rii/riscii.cpp +++ b/src/devices/cpu/rii/riscii.cpp @@ -61,7 +61,7 @@ std::unique_ptr<util::disasm_interface> epg3231_device::create_disassembler() return std::make_unique<epg3231_disassembler>(); } -riscii_series_device::riscii_series_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, unsigned addrbits, unsigned pcbits, unsigned bankbits, u8 maxbank, u8 post_id_mask, address_map_constructor regs) +riscii_series_device::riscii_series_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, unsigned addrbits, unsigned pcbits, unsigned bankbits, u8 maxbank, u8 post_id_mask, address_map_constructor regs) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, addrbits, -1) , m_regs_config("register", ENDIANNESS_LITTLE, 8, 8 + bankbits, 0, regs) @@ -175,7 +175,7 @@ void epg3231_device::regs_map(address_map &map) map(0x0050, 0x007f).ram(); } -epg3231_device::epg3231_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +epg3231_device::epg3231_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : riscii_series_device(mconfig, EPG3231, tag, owner, clock, 22, 18, 5, 0x1f, 0xbb, address_map_constructor(FUNC(epg3231_device::regs_map), this)) { diff --git a/src/devices/cpu/rii/riscii.h b/src/devices/cpu/rii/riscii.h index 41b54d93a9e..2fe311bc6c9 100644 --- a/src/devices/cpu/rii/riscii.h +++ b/src/devices/cpu/rii/riscii.h @@ -92,7 +92,7 @@ public: auto out_portk_cb() { return m_port_out_cb[9].bind(); } protected: - riscii_series_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, unsigned addrbits, unsigned pcbits, unsigned bankbits, u8 maxbank, u8 post_id_mask, address_map_constructor regs); + riscii_series_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, unsigned addrbits, unsigned pcbits, unsigned bankbits, u8 maxbank, u8 post_id_mask, address_map_constructor regs); // device-level overrides virtual void device_resolve_objects() override; @@ -387,7 +387,7 @@ class epg3231_device : public riscii_series_device { public: // construction/destruction - epg3231_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + epg3231_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides diff --git a/src/devices/cpu/romp/romp.cpp b/src/devices/cpu/romp/romp.cpp index bd652f7adc2..f4918f9da4b 100644 --- a/src/devices/cpu/romp/romp.cpp +++ b/src/devices/cpu/romp/romp.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(ROMP, romp_device, "romp", "IBM ROMP") ALLOW_SAVE_TYPE(romp_device::branch_state); -romp_device::romp_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +romp_device::romp_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, ROMP, tag, owner, clock) , m_mem_config("memory", ENDIANNESS_BIG, 32, 32) , m_mmu(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/cpu/romp/romp.h b/src/devices/cpu/romp/romp.h index 27a710f1d84..3846ff3534f 100644 --- a/src/devices/cpu/romp/romp.h +++ b/src/devices/cpu/romp/romp.h @@ -11,7 +11,7 @@ class romp_device : public cpu_device { public: - romp_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + romp_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); template <typename T> void set_mmu(T &&tag) { m_mmu.set_tag(std::forward<T>(tag)); } template <typename T> void set_iou(T &&tag) { m_iou.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/cpu/rsp/rsp.cpp b/src/devices/cpu/rsp/rsp.cpp index 6e280b7003c..d222053f74b 100644 --- a/src/devices/cpu/rsp/rsp.cpp +++ b/src/devices/cpu/rsp/rsp.cpp @@ -109,7 +109,7 @@ static const int vector_elements_2[16][8] = #define CACHE_SIZE (32 * 1024 * 1024) -rsp_device::rsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rsp_device::rsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, RSP, tag, owner, clock) , m_imem_config("imem", ENDIANNESS_BIG, 32, 12) , m_dmem_config("dmem", ENDIANNESS_BIG, 32, 12) diff --git a/src/devices/cpu/rsp/rsp.h b/src/devices/cpu/rsp/rsp.h index b33012bddda..000e6247445 100644 --- a/src/devices/cpu/rsp/rsp.h +++ b/src/devices/cpu/rsp/rsp.h @@ -84,7 +84,7 @@ class rsp_device : public cpu_device public: // construction/destruction - rsp_device(const machine_config &mconfig, const char *_tag, device_t *_owner, uint32_t _clock); + rsp_device(const machine_config &mconfig, const char *_tag, device_t *_owner, const XTAL &_clock); virtual ~rsp_device() override; void resolve_cb(); diff --git a/src/devices/cpu/rw5000/a5000.cpp b/src/devices/cpu/rw5000/a5000.cpp index bb39455cc18..369c7a3d1eb 100644 --- a/src/devices/cpu/rw5000/a5000.cpp +++ b/src/devices/cpu/rw5000/a5000.cpp @@ -16,11 +16,11 @@ DEFINE_DEVICE_TYPE(A5000, a5000_cpu_device, "a5000", "Rockwell A5000") // constructor -a5000_cpu_device::a5000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +a5000_cpu_device::a5000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : b5000_cpu_device(mconfig, type, tag, owner, clock, prgwidth, program, datawidth, data) { } -a5000_cpu_device::a5000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +a5000_cpu_device::a5000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a5000_cpu_device(mconfig, A5000, tag, owner, clock, 9, address_map_constructor(FUNC(a5000_cpu_device::program_448x8), this), 6, address_map_constructor(FUNC(a5000_cpu_device::data_45x4), this)) { } diff --git a/src/devices/cpu/rw5000/a5000.h b/src/devices/cpu/rw5000/a5000.h index 704c1e7e8e0..6926fe24224 100644 --- a/src/devices/cpu/rw5000/a5000.h +++ b/src/devices/cpu/rw5000/a5000.h @@ -17,10 +17,10 @@ class a5000_cpu_device : public b5000_cpu_device { public: - a5000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + a5000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a5000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + a5000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device_disasm_interface overrides virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/rw5000/a5500.cpp b/src/devices/cpu/rw5000/a5500.cpp index 2d8cee136f1..beef8e4433b 100644 --- a/src/devices/cpu/rw5000/a5500.cpp +++ b/src/devices/cpu/rw5000/a5500.cpp @@ -16,11 +16,11 @@ DEFINE_DEVICE_TYPE(A5500, a5500_cpu_device, "a5500", "Rockwell A5500") // constructor -a5500_cpu_device::a5500_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +a5500_cpu_device::a5500_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : a5000_cpu_device(mconfig, type, tag, owner, clock, prgwidth, program, datawidth, data) { } -a5500_cpu_device::a5500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +a5500_cpu_device::a5500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a5500_cpu_device(mconfig, A5500, tag, owner, clock, 10, address_map_constructor(FUNC(a5500_cpu_device::program_768x8), this), 6, address_map_constructor(FUNC(a5500_cpu_device::data_48x4), this)) { } diff --git a/src/devices/cpu/rw5000/a5500.h b/src/devices/cpu/rw5000/a5500.h index 138c38df630..d2dddabef19 100644 --- a/src/devices/cpu/rw5000/a5500.h +++ b/src/devices/cpu/rw5000/a5500.h @@ -17,10 +17,10 @@ class a5500_cpu_device : public a5000_cpu_device { public: - a5500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + a5500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - a5500_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + a5500_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device_disasm_interface overrides virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/rw5000/a5900.cpp b/src/devices/cpu/rw5000/a5900.cpp index e294469f35b..12c9794fc69 100644 --- a/src/devices/cpu/rw5000/a5900.cpp +++ b/src/devices/cpu/rw5000/a5900.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(A5900, a5900_cpu_device, "a5900", "Rockwell A5900") // constructor -a5900_cpu_device::a5900_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +a5900_cpu_device::a5900_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a5000_cpu_device(mconfig, A5900, tag, owner, clock, 9, address_map_constructor(FUNC(a5900_cpu_device::program_512x8), this), 6, address_map_constructor(FUNC(a5900_cpu_device::data_45x4), this)) { } diff --git a/src/devices/cpu/rw5000/a5900.h b/src/devices/cpu/rw5000/a5900.h index b6b59508578..1976b01d0cf 100644 --- a/src/devices/cpu/rw5000/a5900.h +++ b/src/devices/cpu/rw5000/a5900.h @@ -17,7 +17,7 @@ class a5900_cpu_device : public a5000_cpu_device { public: - a5900_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + a5900_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void program_512x8(address_map &map); diff --git a/src/devices/cpu/rw5000/b5000.cpp b/src/devices/cpu/rw5000/b5000.cpp index 685fb1b5190..afc49a9f4be 100644 --- a/src/devices/cpu/rw5000/b5000.cpp +++ b/src/devices/cpu/rw5000/b5000.cpp @@ -23,11 +23,11 @@ DEFINE_DEVICE_TYPE(B5000, b5000_cpu_device, "b5000", "Rockwell B5000") // constructor -b5000_cpu_device::b5000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +b5000_cpu_device::b5000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : rw5000_base_device(mconfig, type, tag, owner, clock, prgwidth, program, datawidth, data) { } -b5000_cpu_device::b5000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +b5000_cpu_device::b5000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : b5000_cpu_device(mconfig, B5000, tag, owner, clock, 9, address_map_constructor(FUNC(b5000_cpu_device::program_448x8), this), 6, address_map_constructor(FUNC(b5000_cpu_device::data_45x4), this)) { } diff --git a/src/devices/cpu/rw5000/b5000.h b/src/devices/cpu/rw5000/b5000.h index 828ef1d9bd7..ee0e120f272 100644 --- a/src/devices/cpu/rw5000/b5000.h +++ b/src/devices/cpu/rw5000/b5000.h @@ -44,10 +44,10 @@ class b5000_cpu_device : public rw5000_base_device { public: - b5000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + b5000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - b5000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + b5000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device_disasm_interface overrides virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/rw5000/b5500.cpp b/src/devices/cpu/rw5000/b5500.cpp index df3fac30507..6b0fd83b470 100644 --- a/src/devices/cpu/rw5000/b5500.cpp +++ b/src/devices/cpu/rw5000/b5500.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(B5500, b5500_cpu_device, "b5500", "Rockwell B5500") // constructor -b5500_cpu_device::b5500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +b5500_cpu_device::b5500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : a5500_cpu_device(mconfig, B5500, tag, owner, clock, 10, address_map_constructor(FUNC(b5500_cpu_device::program_768x8), this), 6, address_map_constructor(FUNC(b5500_cpu_device::data_48x4), this)) { } diff --git a/src/devices/cpu/rw5000/b5500.h b/src/devices/cpu/rw5000/b5500.h index 596cc178485..6d69164ccef 100644 --- a/src/devices/cpu/rw5000/b5500.h +++ b/src/devices/cpu/rw5000/b5500.h @@ -17,7 +17,7 @@ class b5500_cpu_device : public a5500_cpu_device { public: - b5500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + b5500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides diff --git a/src/devices/cpu/rw5000/b6000.cpp b/src/devices/cpu/rw5000/b6000.cpp index 3b18d4793b0..253640bb83b 100644 --- a/src/devices/cpu/rw5000/b6000.cpp +++ b/src/devices/cpu/rw5000/b6000.cpp @@ -23,11 +23,11 @@ DEFINE_DEVICE_TYPE(B6000, b6000_cpu_device, "b6000", "Rockwell B6000") // constructor -b6000_cpu_device::b6000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +b6000_cpu_device::b6000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : b5000_cpu_device(mconfig, type, tag, owner, clock, prgwidth, program, datawidth, data) { } -b6000_cpu_device::b6000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +b6000_cpu_device::b6000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : b6000_cpu_device(mconfig, B6000, tag, owner, clock, 9, address_map_constructor(FUNC(b6000_cpu_device::program_512x8), this), 6, address_map_constructor(FUNC(b6000_cpu_device::data_45x4), this)) { } diff --git a/src/devices/cpu/rw5000/b6000.h b/src/devices/cpu/rw5000/b6000.h index e415c353ee5..143cc08d7de 100644 --- a/src/devices/cpu/rw5000/b6000.h +++ b/src/devices/cpu/rw5000/b6000.h @@ -44,10 +44,10 @@ class b6000_cpu_device : public b5000_cpu_device { public: - b6000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + b6000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - b6000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + b6000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device_disasm_interface overrides virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/rw5000/b6100.cpp b/src/devices/cpu/rw5000/b6100.cpp index cb5b9bdf23a..c0f187015ef 100644 --- a/src/devices/cpu/rw5000/b6100.cpp +++ b/src/devices/cpu/rw5000/b6100.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(B6100, b6100_cpu_device, "b6100", "Rockwell B6100") // constructor -b6100_cpu_device::b6100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +b6100_cpu_device::b6100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : b6000_cpu_device(mconfig, B6100, tag, owner, clock, 10, address_map_constructor(FUNC(b6100_cpu_device::program_896x8), this), 6, address_map_constructor(FUNC(b6100_cpu_device::data_48x4), this)) { } diff --git a/src/devices/cpu/rw5000/b6100.h b/src/devices/cpu/rw5000/b6100.h index bd6a3db9e1b..aa203d27079 100644 --- a/src/devices/cpu/rw5000/b6100.h +++ b/src/devices/cpu/rw5000/b6100.h @@ -44,7 +44,7 @@ class b6100_cpu_device : public b6000_cpu_device { public: - b6100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + b6100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides diff --git a/src/devices/cpu/rw5000/rw5000base.cpp b/src/devices/cpu/rw5000/rw5000base.cpp index 1d0fc237dc8..90f54f7a5d3 100644 --- a/src/devices/cpu/rw5000/rw5000base.cpp +++ b/src/devices/cpu/rw5000/rw5000base.cpp @@ -24,7 +24,7 @@ It is similar, but too many differences to emulate in this device, probably. #include "rw5000base.h" -rw5000_base_device::rw5000_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +rw5000_base_device::rw5000_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 8, prgwidth, 0, program), m_data_config("data", ENDIANNESS_LITTLE, 8, datawidth, 0, data), diff --git a/src/devices/cpu/rw5000/rw5000base.h b/src/devices/cpu/rw5000/rw5000base.h index f6dc6146af8..850ba219963 100644 --- a/src/devices/cpu/rw5000/rw5000base.h +++ b/src/devices/cpu/rw5000/rw5000base.h @@ -38,7 +38,7 @@ public: protected: // construction/destruction - rw5000_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + rw5000_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/rx01/rx01.cpp b/src/devices/cpu/rx01/rx01.cpp index 07ac688e1d7..6d02b2c4140 100644 --- a/src/devices/cpu/rx01/rx01.cpp +++ b/src/devices/cpu/rx01/rx01.cpp @@ -35,7 +35,7 @@ // device type definition DEFINE_DEVICE_TYPE(RX01_CPU, rx01_cpu_device, "rx01_cpu", "DEC RX01 CPU") -rx01_cpu_device::rx01_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rx01_cpu_device::rx01_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, RX01_CPU, tag, owner, clock) , m_inst_config("program", ENDIANNESS_LITTLE, 8, 12, 0) , m_data_config("sectordata", ENDIANNESS_LITTLE, 8, 10, 0) // actually 1 bit wide diff --git a/src/devices/cpu/rx01/rx01.h b/src/devices/cpu/rx01/rx01.h index b8806c354f3..f543279859b 100644 --- a/src/devices/cpu/rx01/rx01.h +++ b/src/devices/cpu/rx01/rx01.h @@ -38,7 +38,7 @@ public: }; // device type constructor - rx01_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rx01_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto error_callback() { return m_interface_callback[0].bind(); } diff --git a/src/devices/cpu/s2650/s2650.cpp b/src/devices/cpu/s2650/s2650.cpp index 4b668f569a7..f503e443f29 100644 --- a/src/devices/cpu/s2650/s2650.cpp +++ b/src/devices/cpu/s2650/s2650.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(S2650, s2650_device, "s2650", "Signetics 2650") -s2650_device::s2650_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s2650_device::s2650_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, S2650, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, 15) , m_io_config("io", ENDIANNESS_BIG, 8, 8) diff --git a/src/devices/cpu/s2650/s2650.h b/src/devices/cpu/s2650/s2650.h index 008ea0bb31f..efd2515eb6d 100644 --- a/src/devices/cpu/s2650/s2650.h +++ b/src/devices/cpu/s2650/s2650.h @@ -29,7 +29,7 @@ class s2650_device : public cpu_device, public s2650_disassembler::config { public: // construction/destruction - s2650_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s2650_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto sense_handler() { return m_sense_handler.bind(); } diff --git a/src/devices/cpu/saturn/saturn.cpp b/src/devices/cpu/saturn/saturn.cpp index fcbafdb5a7f..27891b1490b 100644 --- a/src/devices/cpu/saturn/saturn.cpp +++ b/src/devices/cpu/saturn/saturn.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(SATURN, saturn_device, "saturn_cpu", "Hewlett-Packard Saturn") -saturn_device::saturn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saturn_device::saturn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, SATURN, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 20, 0) , m_out_func(*this) diff --git a/src/devices/cpu/saturn/saturn.h b/src/devices/cpu/saturn/saturn.h index 5111de6d7ed..58eaa628c74 100644 --- a/src/devices/cpu/saturn/saturn.h +++ b/src/devices/cpu/saturn/saturn.h @@ -66,7 +66,7 @@ class saturn_device : public cpu_device, public saturn_disassembler::config { public: // construction/destruction - saturn_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saturn_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto out_func() { return m_out_func.bind(); } diff --git a/src/devices/cpu/sc61860/sc61860.cpp b/src/devices/cpu/sc61860/sc61860.cpp index 9719ebc7069..24bc81b1ba3 100644 --- a/src/devices/cpu/sc61860/sc61860.cpp +++ b/src/devices/cpu/sc61860/sc61860.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(SC61860, sc61860_device, "sc61860", "Sharp SC61860") -sc61860_device::sc61860_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sc61860_device::sc61860_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, SC61860, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, 16, 0) , m_reset(*this) diff --git a/src/devices/cpu/sc61860/sc61860.h b/src/devices/cpu/sc61860/sc61860.h index df019b6b845..f4893f0212a 100644 --- a/src/devices/cpu/sc61860/sc61860.h +++ b/src/devices/cpu/sc61860/sc61860.h @@ -49,7 +49,7 @@ class sc61860_device : public cpu_device { public: // construction/destruction - sc61860_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sc61860_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto reset_cb() { return m_reset.bind(); } diff --git a/src/devices/cpu/scmp/scmp.cpp b/src/devices/cpu/scmp/scmp.cpp index 5eb4bba0be9..8eee52cc73f 100644 --- a/src/devices/cpu/scmp/scmp.cpp +++ b/src/devices/cpu/scmp/scmp.cpp @@ -20,13 +20,13 @@ DEFINE_DEVICE_TYPE(SCMP, scmp_device, "ins8050", "National Semiconductor I DEFINE_DEVICE_TYPE(INS8060, ins8060_device, "ins8060", "National Semiconductor INS 8060 SC/MP II") -scmp_device::scmp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scmp_device::scmp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scmp_device(mconfig, SCMP, tag, owner, clock) { } -scmp_device::scmp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +scmp_device::scmp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0) , m_AC(0), m_ER(0), m_SR(0), m_icount(0) @@ -47,7 +47,7 @@ device_memory_interface::space_config_vector scmp_device::memory_space_config() } -ins8060_device::ins8060_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ins8060_device::ins8060_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scmp_device(mconfig, INS8060, tag, owner, clock) { } diff --git a/src/devices/cpu/scmp/scmp.h b/src/devices/cpu/scmp/scmp.h index 7145973bdb1..0dace0a9623 100644 --- a/src/devices/cpu/scmp/scmp.h +++ b/src/devices/cpu/scmp/scmp.h @@ -10,7 +10,7 @@ class scmp_device : public cpu_device { public: // construction/destruction - scmp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scmp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto flag_out() { return m_flag_out_func.bind(); } @@ -26,7 +26,7 @@ protected: SCMP_PC, SCMP_P1, SCMP_P2, SCMP_P3, SCMP_AC, SCMP_ER, SCMP_SR }; - scmp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + scmp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -88,7 +88,7 @@ class ins8060_device : public scmp_device { public: // construction/destruction - ins8060_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ins8060_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual uint64_t execute_clocks_to_cycles(uint64_t clocks) const noexcept override { return (clocks + 2 - 1) / 2; } diff --git a/src/devices/cpu/score/score.cpp b/src/devices/cpu/score/score.cpp index ffa95aee8c7..df5346cd287 100644 --- a/src/devices/cpu/score/score.cpp +++ b/src/devices/cpu/score/score.cpp @@ -58,7 +58,7 @@ const score7_cpu_device::op_handler score7_cpu_device::s_opcode16_table[8] = // score7_cpu_device - constructor //------------------------------------------------- -score7_cpu_device::score7_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +score7_cpu_device::score7_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, SCORE7, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 32, 32, 0) , m_pc(0) diff --git a/src/devices/cpu/score/score.h b/src/devices/cpu/score/score.h index b55be226043..4baa6830131 100644 --- a/src/devices/cpu/score/score.h +++ b/src/devices/cpu/score/score.h @@ -33,7 +33,7 @@ class score7_cpu_device : public cpu_device { public: // construction/destruction - score7_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + score7_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/scudsp/scudsp.cpp b/src/devices/cpu/scudsp/scudsp.cpp index 4f4d697a900..858a1c736d9 100644 --- a/src/devices/cpu/scudsp/scudsp.cpp +++ b/src/devices/cpu/scudsp/scudsp.cpp @@ -1020,7 +1020,7 @@ void scudsp_cpu_device::data_map(address_map &map) map(0x00, 0xff).ram(); } -scudsp_cpu_device::scudsp_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scudsp_cpu_device::scudsp_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, SCUDSP, tag, owner, clock) , m_out_irq_cb(*this) , m_in_dma_cb(*this) diff --git a/src/devices/cpu/se3208/se3208.cpp b/src/devices/cpu/se3208/se3208.cpp index f67ed4e0948..ee345e3dabc 100644 --- a/src/devices/cpu/se3208/se3208.cpp +++ b/src/devices/cpu/se3208/se3208.cpp @@ -46,7 +46,7 @@ DEFINE_DEVICE_TYPE(SE3208, se3208_device, "se3208", "ADChips SE3208") -se3208_device::se3208_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +se3208_device::se3208_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, SE3208, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 32, 32, 0) , m_machinex_cb(*this) diff --git a/src/devices/cpu/se3208/se3208.h b/src/devices/cpu/se3208/se3208.h index d006a071bb4..4dbb2a7581a 100644 --- a/src/devices/cpu/se3208/se3208.h +++ b/src/devices/cpu/se3208/se3208.h @@ -18,7 +18,7 @@ class se3208_device : public cpu_device { public: // construction/destruction - se3208_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + se3208_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto machinex_cb() { return m_machinex_cb.bind(); } diff --git a/src/devices/cpu/sh/sh.h b/src/devices/cpu/sh/sh.h index d87c1e9742d..1533bca32e5 100644 --- a/src/devices/cpu/sh/sh.h +++ b/src/devices/cpu/sh/sh.h @@ -101,7 +101,7 @@ class sh_common_execution : public cpu_device { public: - sh_common_execution(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endianness, address_map_constructor internal) + sh_common_execution(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endianness, address_map_constructor internal) : cpu_device(mconfig, type, tag, owner, clock) , m_sh2_state(nullptr) , m_cache(CACHE_SIZE + sizeof(internal_sh2_state)) diff --git a/src/devices/cpu/sh/sh2.cpp b/src/devices/cpu/sh/sh2.cpp index c117afadbe0..fce9a07bd8d 100644 --- a/src/devices/cpu/sh/sh2.cpp +++ b/src/devices/cpu/sh/sh2.cpp @@ -232,7 +232,7 @@ void sh1_device::sh7032_map(address_map &map) map(0x05fffe00, 0x05ffffff).rw(FUNC(sh1_device::sh7032_r), FUNC(sh1_device::sh7032_w)); // SH-7032H internal i/o } -sh2_device::sh2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sh2_device::sh2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sh2_device(mconfig, SH2, tag, owner, clock, CPU_TYPE_SH2, address_map_constructor(FUNC(sh2_device::sh7604_map), this), 32) { } @@ -249,7 +249,7 @@ void sh2_device::device_stop() -sh2_device::sh2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int cpu_type, address_map_constructor internal_map, int addrlines) +sh2_device::sh2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cpu_type, address_map_constructor internal_map, int addrlines) : sh_common_execution(mconfig, type, tag, owner, clock, ENDIANNESS_BIG, internal_map) , m_program_config("program", ENDIANNESS_BIG, 32, addrlines, 0, internal_map) , m_decrypted_program_config("decrypted_opcodes", ENDIANNESS_BIG, 32, addrlines, 0) @@ -265,13 +265,13 @@ sh2_device::sh2_device(const machine_config &mconfig, device_type type, const ch m_isdrc = allow_drc(); } -sh2a_device::sh2a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sh2a_device::sh2a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sh2_device(mconfig, SH2A, tag, owner, clock, CPU_TYPE_SH2, address_map_constructor(FUNC(sh2a_device::sh7021_map), this), 28) { std::fill(std::begin(m_sh7021_regs), std::end(m_sh7021_regs), 0); } -sh1_device::sh1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sh1_device::sh1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sh2_device(mconfig, SH1, tag, owner, clock, CPU_TYPE_SH1, address_map_constructor(FUNC(sh1_device::sh7032_map), this), 28) { std::fill(std::begin(m_sh7032_regs), std::end(m_sh7032_regs), 0); diff --git a/src/devices/cpu/sh/sh2.h b/src/devices/cpu/sh/sh2.h index c0ba7340d8b..0ce8c65bcbf 100644 --- a/src/devices/cpu/sh/sh2.h +++ b/src/devices/cpu/sh/sh2.h @@ -55,7 +55,7 @@ public: typedef device_delegate<void (uint32_t data)> ftcsr_read_delegate; // construction/destruction - sh2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sh2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~sh2_device() override; void set_is_slave(int slave) { m_is_slave = slave; } @@ -207,7 +207,7 @@ public: void sh7604_map(address_map &map); protected: - sh2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int cpu_type,address_map_constructor internal_map, int addrlines); + sh2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int cpu_type,address_map_constructor internal_map, int addrlines); // device-level overrides virtual void device_start() override; @@ -366,7 +366,7 @@ class sh2a_device : public sh2_device { public: // construction/destruction - sh2a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sh2a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t dma_sar0_r(); void dma_sar0_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0); @@ -400,7 +400,7 @@ class sh1_device : public sh2_device { public: // construction/destruction - sh1_device(const machine_config &mconfig, const char *_tag, device_t *_owner, uint32_t _clock); + sh1_device(const machine_config &mconfig, const char *_tag, device_t *_owner, const XTAL &_clock); uint16_t sh7032_r(offs_t offset); void sh7032_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/cpu/sh/sh4.cpp b/src/devices/cpu/sh/sh4.cpp index 7d64546d741..662f055d223 100644 --- a/src/devices/cpu/sh/sh4.cpp +++ b/src/devices/cpu/sh/sh4.cpp @@ -71,7 +71,7 @@ void sh3_base_device::sh3_internal_map(address_map &map) } -sh34_base_device::sh34_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endianness, address_map_constructor internal) +sh34_base_device::sh34_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endianness, address_map_constructor internal) : sh_common_execution(mconfig, type, tag, owner, clock, endianness, internal) , m_program_config("program", endianness, 64, 32, 0, internal) , m_io_config("io", endianness, 64, 8) @@ -90,7 +90,7 @@ device_memory_interface::space_config_vector sh34_base_device::memory_space_conf } -sh3_base_device::sh3_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endianness) +sh3_base_device::sh3_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endianness) : sh34_base_device(mconfig, type, tag, owner, clock, endianness, address_map_constructor(FUNC(sh3_base_device::sh3_internal_map), this)) { m_cpu_type = CPU_TYPE_SH3; @@ -98,7 +98,7 @@ sh3_base_device::sh3_base_device(const machine_config &mconfig, device_type type } -sh4_base_device::sh4_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endianness) +sh4_base_device::sh4_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endianness) : sh34_base_device(mconfig, type, tag, owner, clock, endianness, address_map_constructor(FUNC(sh4_base_device::sh4_internal_map), this)) { m_cpu_type = CPU_TYPE_SH4; @@ -106,25 +106,25 @@ sh4_base_device::sh4_base_device(const machine_config &mconfig, device_type type } -sh3_device::sh3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sh3_device::sh3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sh3_base_device(mconfig, SH3LE, tag, owner, clock, ENDIANNESS_LITTLE) { } -sh3be_device::sh3be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sh3be_device::sh3be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sh3_base_device(mconfig, SH3BE, tag, owner, clock, ENDIANNESS_BIG) { } -sh4_device::sh4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sh4_device::sh4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sh4_base_device(mconfig, SH4LE, tag, owner, clock, ENDIANNESS_LITTLE) { } -sh4be_device::sh4be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sh4be_device::sh4be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sh4_base_device(mconfig, SH4BE, tag, owner, clock, ENDIANNESS_BIG) { } diff --git a/src/devices/cpu/sh/sh4.h b/src/devices/cpu/sh/sh4.h index b2c97c9dc16..40b4bdd0dac 100644 --- a/src/devices/cpu/sh/sh4.h +++ b/src/devices/cpu/sh/sh4.h @@ -254,7 +254,7 @@ public: protected: // construction/destruction - sh34_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endianness, address_map_constructor internal); + sh34_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endianness, address_map_constructor internal); // device-level overrides virtual void device_start() override; @@ -690,7 +690,7 @@ public: void sh3_internal_map(address_map &map); protected: // construction/destruction - sh3_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endianness); + sh3_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endianness); virtual void device_reset() override; }; @@ -718,7 +718,7 @@ public: void sh4_internal_map(address_map &map); protected: // construction/destruction - sh4_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endianness); + sh4_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endianness); virtual void device_start() override; virtual void device_reset() override; @@ -729,7 +729,7 @@ class sh3_device : public sh3_base_device { friend class sh4_frontend; public: - sh3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sh3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); std::unique_ptr<sh4_frontend> m_drcfe; /* pointer to the DRC front-end state */ virtual const opcode_desc* get_desclist(offs_t pc) override; virtual void init_drc_frontend() override; @@ -741,7 +741,7 @@ class sh3be_device : public sh3_base_device friend class sh4be_frontend; public: - sh3be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sh3be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); std::unique_ptr<sh4be_frontend> m_drcfe; /* pointer to the DRC front-end state */ virtual const opcode_desc* get_desclist(offs_t pc) override; virtual void init_drc_frontend() override; @@ -756,7 +756,7 @@ class sh4_device : public sh4_base_device friend class sh4_frontend; public: - sh4_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sh4_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); std::unique_ptr<sh4_frontend> m_drcfe; /* pointer to the DRC front-end state */ virtual const opcode_desc* get_desclist(offs_t pc) override; virtual void init_drc_frontend() override; @@ -769,7 +769,7 @@ class sh4be_device : public sh4_base_device friend class sh4be_frontend; public: - sh4be_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sh4be_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); std::unique_ptr<sh4be_frontend> m_drcfe; /* pointer to the DRC front-end state */ virtual const opcode_desc* get_desclist(offs_t pc) override; virtual void init_drc_frontend() override; diff --git a/src/devices/cpu/sh/sh7604_bus.cpp b/src/devices/cpu/sh/sh7604_bus.cpp index a4b61bddae6..1ad437546b9 100644 --- a/src/devices/cpu/sh/sh7604_bus.cpp +++ b/src/devices/cpu/sh/sh7604_bus.cpp @@ -109,7 +109,7 @@ void sh7604_bus_device::bus_regs(address_map &map) // sh7604_bus_device - constructor //------------------------------------------------- -sh7604_bus_device::sh7604_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sh7604_bus_device::sh7604_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SH7604_BUS, tag, owner, clock) { } diff --git a/src/devices/cpu/sh/sh7604_bus.h b/src/devices/cpu/sh/sh7604_bus.h index 9d2915b6b6b..30298211fb8 100644 --- a/src/devices/cpu/sh/sh7604_bus.h +++ b/src/devices/cpu/sh/sh7604_bus.h @@ -23,7 +23,7 @@ class sh7604_bus_device : public device_t { public: // construction/destruction - sh7604_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sh7604_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations void bus_regs(address_map &map); diff --git a/src/devices/cpu/sh/sh7604_sci.cpp b/src/devices/cpu/sh/sh7604_sci.cpp index 5d49eab5c31..c79b46e73ff 100644 --- a/src/devices/cpu/sh/sh7604_sci.cpp +++ b/src/devices/cpu/sh/sh7604_sci.cpp @@ -113,7 +113,7 @@ void sh7604_sci_device::sci_regs(address_map &map) // sh7604_sci_device - constructor //------------------------------------------------- -sh7604_sci_device::sh7604_sci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sh7604_sci_device::sh7604_sci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SH7604_SCI, tag, owner, clock) { diff --git a/src/devices/cpu/sh/sh7604_sci.h b/src/devices/cpu/sh/sh7604_sci.h index b77630db074..b94f9652d1f 100644 --- a/src/devices/cpu/sh/sh7604_sci.h +++ b/src/devices/cpu/sh/sh7604_sci.h @@ -23,7 +23,7 @@ class sh7604_sci_device : public device_t { public: // construction/destruction - sh7604_sci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sh7604_sci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations void sci_regs(address_map &map); diff --git a/src/devices/cpu/sh/sh7604_wdt.cpp b/src/devices/cpu/sh/sh7604_wdt.cpp index 2b5ea9eb499..56d61c7b83b 100644 --- a/src/devices/cpu/sh/sh7604_wdt.cpp +++ b/src/devices/cpu/sh/sh7604_wdt.cpp @@ -39,7 +39,7 @@ void sh7604_wdt_device::wdt_regs(address_map &map) // sh7604_wdt_device - constructor //------------------------------------------------- -sh7604_wdt_device::sh7604_wdt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sh7604_wdt_device::sh7604_wdt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SH7604_WDT, tag, owner, clock) { } diff --git a/src/devices/cpu/sh/sh7604_wdt.h b/src/devices/cpu/sh/sh7604_wdt.h index dd39f4be514..12b7896fe44 100644 --- a/src/devices/cpu/sh/sh7604_wdt.h +++ b/src/devices/cpu/sh/sh7604_wdt.h @@ -23,7 +23,7 @@ class sh7604_wdt_device : public device_t { public: // construction/destruction - sh7604_wdt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sh7604_wdt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations void wdt_regs(address_map &map); diff --git a/src/devices/cpu/sharc/sharc.cpp b/src/devices/cpu/sharc/sharc.cpp index 7ce22652570..5c04fd3d5e2 100644 --- a/src/devices/cpu/sharc/sharc.cpp +++ b/src/devices/cpu/sharc/sharc.cpp @@ -75,7 +75,7 @@ void adsp21062_device::internal_data(address_map &map) map(0x70000, 0x7ffff).rw(FUNC(adsp21062_device::dmw1_r), FUNC(adsp21062_device::dmw1_w)); } -adsp21062_device::adsp21062_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adsp21062_device::adsp21062_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, ADSP21062, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 64, 24, -3, address_map_constructor(FUNC(adsp21062_device::internal_pgm), this)) , m_data_config("data", ENDIANNESS_LITTLE, 32, 32, -2, address_map_constructor(FUNC(adsp21062_device::internal_data), this)) diff --git a/src/devices/cpu/sharc/sharc.h b/src/devices/cpu/sharc/sharc.h index f7d2d8701cd..55a718d0fc5 100644 --- a/src/devices/cpu/sharc/sharc.h +++ b/src/devices/cpu/sharc/sharc.h @@ -90,7 +90,7 @@ public: // construction/destruction - adsp21062_device(const machine_config &mconfig, const char *_tag, device_t *_owner, uint32_t _clock); + adsp21062_device(const machine_config &mconfig, const char *_tag, device_t *_owner, const XTAL &_clock); virtual ~adsp21062_device() override; // configuration helpers diff --git a/src/devices/cpu/sm510/sm500.cpp b/src/devices/cpu/sm510/sm500.cpp index bb440388974..13e1c248c5c 100644 --- a/src/devices/cpu/sm510/sm500.cpp +++ b/src/devices/cpu/sm510/sm500.cpp @@ -35,12 +35,12 @@ void sm500_device::data_4x10x4(address_map &map) // device definitions -sm500_device::sm500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int o_pins, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +sm500_device::sm500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int o_pins, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : sm510_base_device(mconfig, type, tag, owner, clock, stack_levels, prgwidth, program, datawidth, data), m_o_pins(o_pins) { } -sm500_device::sm500_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sm500_device::sm500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm500_device(mconfig, SM500, tag, owner, clock, 1 /* stack levels */, 7 /* o group pins */, 11 /* prg width */, address_map_constructor(FUNC(sm500_device::program_1_2k), this), 6 /* data width */, address_map_constructor(FUNC(sm500_device::data_4x10x4), this)) { } diff --git a/src/devices/cpu/sm510/sm500.h b/src/devices/cpu/sm510/sm500.h index 90be21ca184..44cbc423b2d 100644 --- a/src/devices/cpu/sm510/sm500.h +++ b/src/devices/cpu/sm510/sm500.h @@ -54,10 +54,10 @@ O36 48 | * | 13 K2 class sm500_device : public sm510_base_device { public: - sm500_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 32768); + sm500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32768)); protected: - sm500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int o_pins, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + sm500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int o_pins, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); void program_1_2k(address_map &map); void data_4x10x4(address_map &map); diff --git a/src/devices/cpu/sm510/sm510.cpp b/src/devices/cpu/sm510/sm510.cpp index 624057181cb..75ddf45c5e5 100644 --- a/src/devices/cpu/sm510/sm510.cpp +++ b/src/devices/cpu/sm510/sm510.cpp @@ -33,7 +33,7 @@ void sm510_device::data_96_32x4(address_map &map) // device definitions -sm510_device::sm510_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sm510_device::sm510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm510_base_device(mconfig, SM510, tag, owner, clock, 2 /* stack levels */, 12 /* prg width */, address_map_constructor(FUNC(sm510_device::program_2_7k), this), 7 /* data width */, address_map_constructor(FUNC(sm510_device::data_96_32x4), this)) { } diff --git a/src/devices/cpu/sm510/sm510.h b/src/devices/cpu/sm510/sm510.h index af1e18d2861..4e234b0ac06 100644 --- a/src/devices/cpu/sm510/sm510.h +++ b/src/devices/cpu/sm510/sm510.h @@ -61,7 +61,7 @@ S8 60 | * | 16 b16 class sm510_device : public sm510_base_device { public: - sm510_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 32768); + sm510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32768)); protected: void program_2_7k(address_map &map); diff --git a/src/devices/cpu/sm510/sm510base.h b/src/devices/cpu/sm510/sm510base.h index bf061967fc4..b6a164ccddc 100644 --- a/src/devices/cpu/sm510/sm510base.h +++ b/src/devices/cpu/sm510/sm510base.h @@ -37,7 +37,7 @@ class sm510_base_device : public cpu_device { public: // construction/destruction - sm510_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : + sm510_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 8, prgwidth, 0, program), m_data_config("data", ENDIANNESS_LITTLE, 8, datawidth, 0, data), diff --git a/src/devices/cpu/sm510/sm511.cpp b/src/devices/cpu/sm510/sm511.cpp index dc3a3763d6c..dbd9688d200 100644 --- a/src/devices/cpu/sm510/sm511.cpp +++ b/src/devices/cpu/sm510/sm511.cpp @@ -53,15 +53,15 @@ std::unique_ptr<util::disasm_interface> sm511_device::create_disassembler() // device definitions -sm511_device::sm511_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +sm511_device::sm511_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : sm510_base_device(mconfig, type, tag, owner, clock, stack_levels, prgwidth, program, datawidth, data) { } -sm511_device::sm511_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sm511_device::sm511_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm511_device(mconfig, SM511, tag, owner, clock, 2 /* stack levels */, 12 /* prg width */, address_map_constructor(FUNC(sm511_device::program_4k), this), 7 /* data width */, address_map_constructor(FUNC(sm511_device::data_96_32x4), this)) { } -sm512_device::sm512_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sm512_device::sm512_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm511_device(mconfig, SM512, tag, owner, clock, 2, 12, address_map_constructor(FUNC(sm512_device::program_4k), this), 7, address_map_constructor(FUNC(sm512_device::data_80_48x4), this)) { } diff --git a/src/devices/cpu/sm510/sm511.h b/src/devices/cpu/sm510/sm511.h index 463ede6be04..362c1db9f86 100644 --- a/src/devices/cpu/sm510/sm511.h +++ b/src/devices/cpu/sm510/sm511.h @@ -27,10 +27,10 @@ SM512: can't be bothered to draw one here, it's 80 pins QFP, a lot of LCD segmen class sm511_device : public sm510_base_device { public: - sm511_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 32768); + sm511_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32768)); protected: - sm511_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + sm511_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); void program_4k(address_map &map); void data_96_32x4(address_map &map); @@ -50,7 +50,7 @@ protected: class sm512_device : public sm511_device { public: - sm512_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 32768); + sm512_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32768)); protected: void data_80_48x4(address_map &map); diff --git a/src/devices/cpu/sm510/sm530.cpp b/src/devices/cpu/sm510/sm530.cpp index a17213fa1cb..bb68b73d72b 100644 --- a/src/devices/cpu/sm510/sm530.cpp +++ b/src/devices/cpu/sm510/sm530.cpp @@ -45,12 +45,12 @@ std::unique_ptr<util::disasm_interface> sm530_device::create_disassembler() // device definitions -sm530_device::sm530_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +sm530_device::sm530_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : sm511_device(mconfig, type, tag, owner, clock, stack_levels, prgwidth, program, datawidth, data), m_write_f(*this) { } -sm530_device::sm530_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sm530_device::sm530_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm530_device(mconfig, SM530, tag, owner, clock, 1 /* stack levels */, 11 /* prg width */, address_map_constructor(FUNC(sm530_device::program_2k), this), 7 /* data width */, address_map_constructor(FUNC(sm530_device::data_64_24x4), this)) { } diff --git a/src/devices/cpu/sm510/sm530.h b/src/devices/cpu/sm510/sm530.h index 654bcf2963e..7580cfdc8b9 100644 --- a/src/devices/cpu/sm510/sm530.h +++ b/src/devices/cpu/sm510/sm530.h @@ -69,13 +69,13 @@ O26 80 | * class sm530_device : public sm511_device { public: - sm530_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 32768); + sm530_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32768)); // 4-bit F output port auto write_f() { return m_write_f.bind(); } protected: - sm530_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + sm530_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); void program_2k(address_map &map); void data_64_24x4(address_map &map); diff --git a/src/devices/cpu/sm510/sm590.cpp b/src/devices/cpu/sm510/sm590.cpp index 7237dbbfa5d..58b24ac880e 100644 --- a/src/devices/cpu/sm510/sm590.cpp +++ b/src/devices/cpu/sm510/sm590.cpp @@ -50,21 +50,21 @@ void sm590_device::data_56x4(address_map &map) // device definitions -sm590_device::sm590_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +sm590_device::sm590_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : sm510_base_device(mconfig, type, tag, owner, clock, stack_levels, prgwidth, program, datawidth, data), m_write_rx(*this), m_read_rx(*this) { } -sm590_device::sm590_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sm590_device::sm590_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm590_device(mconfig, SM590, tag, owner, clock, 4 /* stack levels */, 9 /* prg width */, address_map_constructor(FUNC(sm590_device::program_512x8), this), 5 /* data width */, address_map_constructor(FUNC(sm590_device::data_32x4), this)) { } -sm591_device::sm591_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sm591_device::sm591_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm590_device(mconfig, SM591, tag, owner, clock, 4, 10, address_map_constructor(FUNC(sm591_device::program_1kx8), this), 6, address_map_constructor(FUNC(sm591_device::data_56x4), this)) { } -sm595_device::sm595_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sm595_device::sm595_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm590_device(mconfig, SM595, tag, owner, clock, 4, 10, address_map_constructor(FUNC(sm595_device::program_768x8), this), 5, address_map_constructor(FUNC(sm595_device::data_32x4), this)) { } diff --git a/src/devices/cpu/sm510/sm590.h b/src/devices/cpu/sm510/sm590.h index 8e866b954f8..2fe61fc35e0 100644 --- a/src/devices/cpu/sm510/sm590.h +++ b/src/devices/cpu/sm510/sm590.h @@ -89,7 +89,7 @@ R3.3/CL2 => |_|6 15|_| <> R1.3 class sm590_device : public sm510_base_device { public: - sm590_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sm590_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // four 4-bit R I/O ports using sm510_base_device::write_r; @@ -97,7 +97,7 @@ public: template <std::size_t N> auto read_r() { return m_read_rx[N].bind(); } protected: - sm590_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + sm590_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); void program_512x8(address_map &map); void program_768x8(address_map &map); @@ -158,13 +158,13 @@ protected: class sm591_device : public sm590_device { public: - sm591_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sm591_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class sm595_device : public sm590_device { public: - sm595_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sm595_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/sm510/sm5a.cpp b/src/devices/cpu/sm510/sm5a.cpp index c2512aeaf71..1076f70014e 100644 --- a/src/devices/cpu/sm510/sm5a.cpp +++ b/src/devices/cpu/sm510/sm5a.cpp @@ -39,19 +39,19 @@ void sm5a_device::data_5x13x4(address_map &map) // device definitions -sm5a_device::sm5a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int o_pins, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : +sm5a_device::sm5a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int o_pins, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : sm500_device(mconfig, type, tag, owner, clock, stack_levels, o_pins, prgwidth, program, datawidth, data) { } -sm5a_device::sm5a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sm5a_device::sm5a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm5a_device(mconfig, SM5A, tag, owner, clock, 1 /* stack levels */, 9 /* o group pins */, 11 /* prg width */, address_map_constructor(FUNC(sm5a_device::program_1_8k), this), 7 /* data width */, address_map_constructor(FUNC(sm5a_device::data_5x13x4), this)) { } -sm5l_device::sm5l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sm5l_device::sm5l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm5a_device(mconfig, SM5L, tag, owner, clock, 1, 9, 11, address_map_constructor(FUNC(sm5l_device::program_1_8k), this), 7, address_map_constructor(FUNC(sm5l_device::data_5x13x4), this)) { } -kb1013vk12_device::kb1013vk12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +kb1013vk12_device::kb1013vk12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sm5a_device(mconfig, KB1013VK12, tag, owner, clock, 1, 9, 11, address_map_constructor(FUNC(kb1013vk12_device::program_1_8k), this), 7, address_map_constructor(FUNC(kb1013vk12_device::data_5x13x4), this)) { } diff --git a/src/devices/cpu/sm510/sm5a.h b/src/devices/cpu/sm510/sm5a.h index a44c687dfd9..86e223a5877 100644 --- a/src/devices/cpu/sm510/sm5a.h +++ b/src/devices/cpu/sm510/sm5a.h @@ -60,10 +60,10 @@ O34 60 | * | 16 O48 class sm5a_device : public sm500_device { public: - sm5a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 32768); + sm5a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32768)); protected: - sm5a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int stack_levels, int o_pins, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + sm5a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int stack_levels, int o_pins, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); void program_1_8k(address_map &map); void data_5x13x4(address_map &map); @@ -80,13 +80,13 @@ protected: class sm5l_device : public sm5a_device { public: - sm5l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 32768); + sm5l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32768)); }; class kb1013vk12_device : public sm5a_device { public: - kb1013vk12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 32768); + kb1013vk12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32768)); }; diff --git a/src/devices/cpu/sm8500/sm8500.cpp b/src/devices/cpu/sm8500/sm8500.cpp index d85b845d3dc..80648040143 100644 --- a/src/devices/cpu/sm8500/sm8500.cpp +++ b/src/devices/cpu/sm8500/sm8500.cpp @@ -32,7 +32,7 @@ static constexpr uint8_t sm8500_b2w[8] = { }; -sm8500_cpu_device::sm8500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sm8500_cpu_device::sm8500_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, SM8500, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, 16, 0) , m_dma_func(*this) diff --git a/src/devices/cpu/sparc/sparc.cpp b/src/devices/cpu/sparc/sparc.cpp index 2c4ef019be1..f72b736d3ef 100644 --- a/src/devices/cpu/sparc/sparc.cpp +++ b/src/devices/cpu/sparc/sparc.cpp @@ -79,7 +79,7 @@ const sparc_disassembler::asi_desc_map::value_type mb86930_asi_desc[] = { // sparc_base_device - constructor //------------------------------------------------- -sparc_base_device::sparc_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sparc_base_device::sparc_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_mmu(*this, finder_base::DUMMY_TAG) { @@ -100,12 +100,12 @@ sparc_base_device::sparc_base_device(const machine_config &mconfig, device_type // sparcv7_device - constructors //------------------------------------------------- -sparcv7_device::sparcv7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sparcv7_device::sparcv7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sparcv7_device(mconfig, SPARCV7, tag, owner, clock) { } -sparcv7_device::sparcv7_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sparcv7_device::sparcv7_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sparc_base_device(mconfig, type, tag, owner, clock) { } @@ -115,13 +115,13 @@ sparcv7_device::sparcv7_device(const machine_config &mconfig, device_type type, // sparcv8_device - constructor //------------------------------------------------- -sparcv8_device::sparcv8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sparcv8_device::sparcv8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sparcv8_device(mconfig, SPARCV8, tag, owner, clock) { } -sparcv8_device::sparcv8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sparcv8_device::sparcv8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : sparc_base_device(mconfig, type, tag, owner, clock) { } @@ -131,7 +131,7 @@ sparcv8_device::sparcv8_device(const machine_config &mconfig, device_type type, // mb86930_device - constructor //------------------------------------------------- -mb86930_device::mb86930_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb86930_device::mb86930_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sparcv8_device(mconfig, MB86930, tag, owner, clock) , m_cs_r(*this) , m_cs_w(*this) diff --git a/src/devices/cpu/sparc/sparc.h b/src/devices/cpu/sparc/sparc.h index df1e531f3ea..84acfa05583 100644 --- a/src/devices/cpu/sparc/sparc.h +++ b/src/devices/cpu/sparc/sparc.h @@ -21,7 +21,7 @@ class sparc_base_device : public cpu_device, public sparc_mmu_host_interface, protected sparc_disassembler::config { public: - sparc_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sparc_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_mmu(T &&tag) { m_mmu.set_tag(std::forward<T>(tag)); } @@ -273,10 +273,10 @@ protected: class sparcv7_device : public sparc_base_device { public: - sparcv7_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sparcv7_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - sparcv7_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sparcv7_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); protected: virtual bool execute_extra_group2(uint32_t op) override; @@ -288,13 +288,13 @@ protected: class sparcv8_device : public sparc_base_device { public: - sparcv8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sparcv8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_disasm_interface overrides virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; protected: - sparcv8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sparcv8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -320,7 +320,7 @@ private: class mb86930_device : public sparcv8_device { public: - mb86930_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb86930_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_disasm_interface overrides virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/spc700/spc700.cpp b/src/devices/cpu/spc700/spc700.cpp index b477ee008a1..7502d7935de 100644 --- a/src/devices/cpu/spc700/spc700.cpp +++ b/src/devices/cpu/spc700/spc700.cpp @@ -202,12 +202,12 @@ Address Function Register R/W When Reset Remarks DEFINE_DEVICE_TYPE(SPC700, spc700_device, "spc700", "Sony SPC700") -spc700_device::spc700_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spc700_device::spc700_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spc700_device(mconfig, SPC700, tag, owner, clock) { } -spc700_device::spc700_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map) +spc700_device::spc700_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0, internal_map) , m_a(0) diff --git a/src/devices/cpu/spc700/spc700.h b/src/devices/cpu/spc700/spc700.h index 33e3190ac10..26e3d61aaf9 100644 --- a/src/devices/cpu/spc700/spc700.h +++ b/src/devices/cpu/spc700/spc700.h @@ -10,11 +10,11 @@ class spc700_device : public cpu_device { public: // construction/destruction - spc700_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spc700_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // construction/destruction - spc700_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map = address_map_constructor()); + spc700_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map = address_map_constructor()); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/ssem/ssem.cpp b/src/devices/cpu/ssem/ssem.cpp index 77bc62edb14..71c743192ca 100644 --- a/src/devices/cpu/ssem/ssem.cpp +++ b/src/devices/cpu/ssem/ssem.cpp @@ -80,7 +80,7 @@ DEFINE_DEVICE_TYPE(SSEMCPU, ssem_device, "ssem_cpu", "Manchester SSEM") // ssem_device - constructor //------------------------------------------------- -ssem_device::ssem_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ssem_device::ssem_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, SSEMCPU, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16) , m_pc(1) diff --git a/src/devices/cpu/ssem/ssem.h b/src/devices/cpu/ssem/ssem.h index 7cfe5d17435..9bc56283ca5 100644 --- a/src/devices/cpu/ssem/ssem.h +++ b/src/devices/cpu/ssem/ssem.h @@ -22,7 +22,7 @@ class ssem_device : public cpu_device { public: // construction/destruction - ssem_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ssem_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/ssp1601/ssp1601.cpp b/src/devices/cpu/ssp1601/ssp1601.cpp index 245cfca4541..4e4555daf69 100644 --- a/src/devices/cpu/ssp1601/ssp1601.cpp +++ b/src/devices/cpu/ssp1601/ssp1601.cpp @@ -192,7 +192,7 @@ DEFINE_DEVICE_TYPE(SSP1601, ssp1601_device, "ssp1601", "Samsung SSP1601") -ssp1601_device::ssp1601_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ssp1601_device::ssp1601_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, SSP1601, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, 16, -1) , m_io_config("io", ENDIANNESS_BIG, 16, 4, 0) diff --git a/src/devices/cpu/ssp1601/ssp1601.h b/src/devices/cpu/ssp1601/ssp1601.h index e912ff9891b..8edee4077ea 100644 --- a/src/devices/cpu/ssp1601/ssp1601.h +++ b/src/devices/cpu/ssp1601/ssp1601.h @@ -22,7 +22,7 @@ class ssp1601_device : public cpu_device { public: // construction/destruction - ssp1601_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ssp1601_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/st62xx/st62xx.cpp b/src/devices/cpu/st62xx/st62xx.cpp index 81e25d72d01..5be3b3c1741 100644 --- a/src/devices/cpu/st62xx/st62xx.cpp +++ b/src/devices/cpu/st62xx/st62xx.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(ST6228, st6228_device, "st6228", "STmicro ST6228") -st6228_device::st6228_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +st6228_device::st6228_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, ST6228, tag, owner, clock) , m_pc(0) , m_mode(MODE_NMI) diff --git a/src/devices/cpu/st62xx/st62xx.h b/src/devices/cpu/st62xx/st62xx.h index 8442e1e798b..83fc0f4a8b9 100644 --- a/src/devices/cpu/st62xx/st62xx.h +++ b/src/devices/cpu/st62xx/st62xx.h @@ -38,7 +38,7 @@ class st6228_device : public cpu_device { public: - st6228_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + st6228_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <unsigned Bit> auto port_a() { diff --git a/src/devices/cpu/superfx/superfx.cpp b/src/devices/cpu/superfx/superfx.cpp index e14ac788c5e..6628c03378b 100644 --- a/src/devices/cpu/superfx/superfx.cpp +++ b/src/devices/cpu/superfx/superfx.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(SUPERFX1, superfx1_device, "superfx1", "Nintendo SuperFX 1") DEFINE_DEVICE_TYPE(SUPERFX2, superfx2_device, "superfx2", "Nintendo SuperFX 2") -superfx_device::superfx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +superfx_device::superfx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 32, 0) , m_out_irq_func(*this), m_pipeline(0), m_ramaddr(0), m_sfr(0), m_pbr(0), m_rombr(0), m_rambr(0), m_cbr(0), m_scbr(0), m_scmr(0), m_colr(0), m_por(0) @@ -16,12 +16,12 @@ superfx_device::superfx_device(const machine_config &mconfig, device_type type, { } -superfx1_device::superfx1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +superfx1_device::superfx1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : superfx_device(mconfig, SUPERFX1, tag, owner, clock) { } -superfx2_device::superfx2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +superfx2_device::superfx2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : superfx_device(mconfig, SUPERFX2, tag, owner, clock) { } @@ -546,7 +546,7 @@ void superfx_device::mmio_write(uint32_t addr, uint8_t data) } } -void superfx_device::superfx_add_clocks_internal(uint32_t clocks) +void superfx_device::superfx_add_clocks_internal(const XTAL &clocks) { if(m_romcl) { diff --git a/src/devices/cpu/superfx/superfx.h b/src/devices/cpu/superfx/superfx.h index 54f07ec184f..17e3a93c197 100644 --- a/src/devices/cpu/superfx/superfx.h +++ b/src/devices/cpu/superfx/superfx.h @@ -105,7 +105,7 @@ public: protected: // construction/destruction - superfx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + superfx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -203,7 +203,7 @@ private: inline uint8_t superfx_op_read(uint16_t addr); inline uint8_t superfx_peekpipe(); inline uint8_t superfx_pipe(); - inline void superfx_add_clocks_internal(uint32_t clocks); + inline void superfx_add_clocks_internal(const XTAL &clocks); void superfx_timing_reset(); inline void superfx_dreg_sfr_sz_update(); }; @@ -212,7 +212,7 @@ class superfx1_device : public superfx_device { public: // construction/destruction - superfx1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + superfx1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides @@ -224,7 +224,7 @@ class superfx2_device : public superfx_device { public: // construction/destruction - superfx2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + superfx2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(SUPERFX1, superfx1_device) diff --git a/src/devices/cpu/t11/t11.cpp b/src/devices/cpu/t11/t11.cpp index 422ea6e0510..5db68492043 100644 --- a/src/devices/cpu/t11/t11.cpp +++ b/src/devices/cpu/t11/t11.cpp @@ -39,12 +39,12 @@ DEFINE_DEVICE_TYPE(T11, t11_device, "t11", "DEC T11") DEFINE_DEVICE_TYPE(K1801VM2, k1801vm2_device, "k1801vm2", "K1801VM2") -k1801vm2_device::k1801vm2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +k1801vm2_device::k1801vm2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : t11_device(mconfig, K1801VM2, tag, owner, clock) { } -t11_device::t11_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +t11_device::t11_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 16, 0) , c_initial_mode(0) @@ -63,7 +63,7 @@ t11_device::t11_device(const machine_config &mconfig, device_type type, const ch m_ppc.d = 0; } -t11_device::t11_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +t11_device::t11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : t11_device(mconfig, T11, tag, owner, clock) { } diff --git a/src/devices/cpu/t11/t11.h b/src/devices/cpu/t11/t11.h index cf83f65638e..d1dd1922693 100644 --- a/src/devices/cpu/t11/t11.h +++ b/src/devices/cpu/t11/t11.h @@ -39,7 +39,7 @@ public: static constexpr uint8_t BUS_ERROR = 8; // construction/destruction - t11_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + t11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers void set_initial_mode(const uint16_t mode) { c_initial_mode = mode; } @@ -59,7 +59,7 @@ protected: T11_TRAP = 034 // TRAP instruction vector }; - t11_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + t11_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -1166,7 +1166,7 @@ class k1801vm2_device : public t11_device { public: // construction/destruction - k1801vm2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + k1801vm2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/tlcs870/tlcs870.cpp b/src/devices/cpu/tlcs870/tlcs870.cpp index c010de7e03b..cf300ba0686 100644 --- a/src/devices/cpu/tlcs870/tlcs870.cpp +++ b/src/devices/cpu/tlcs870/tlcs870.cpp @@ -104,7 +104,7 @@ void tlcs870_device::tmp87ph40an_mem(address_map &map) } -tlcs870_device::tlcs870_device(const machine_config &mconfig, device_type optype, const char *tag, device_t *owner, uint32_t clock, address_map_constructor program_map) +tlcs870_device::tlcs870_device(const machine_config &mconfig, device_type optype, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program_map) : cpu_device(mconfig, optype, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0, program_map) , m_io_config("io", ENDIANNESS_LITTLE, 8, 16, 0) @@ -118,7 +118,7 @@ tlcs870_device::tlcs870_device(const machine_config &mconfig, device_type optype } -tmp87ph40an_device::tmp87ph40an_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmp87ph40an_device::tmp87ph40an_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tlcs870_device(mconfig, TMP87PH40AN, tag, owner, clock, address_map_constructor(FUNC(tmp87ph40an_device::tmp87ph40an_mem), this)) { } diff --git a/src/devices/cpu/tlcs870/tlcs870.h b/src/devices/cpu/tlcs870/tlcs870.h index b6c3d73478d..c04b09ffcd8 100644 --- a/src/devices/cpu/tlcs870/tlcs870.h +++ b/src/devices/cpu/tlcs870/tlcs870.h @@ -42,7 +42,7 @@ public: protected: // construction/destruction - tlcs870_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor program_map); + tlcs870_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program_map); // device-level overrides virtual void device_start() override; @@ -550,7 +550,7 @@ class tmp87ph40an_device : public tlcs870_device { public: // construction/destruction - tmp87ph40an_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmp87ph40an_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/tlcs90/tlcs90.cpp b/src/devices/cpu/tlcs90/tlcs90.cpp index 148f2dbd4a8..2f993b7ab90 100644 --- a/src/devices/cpu/tlcs90/tlcs90.cpp +++ b/src/devices/cpu/tlcs90/tlcs90.cpp @@ -154,7 +154,7 @@ void tlcs90_device::tmp90ph44_mem(address_map &map) } -tlcs90_device::tlcs90_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor program_map) +tlcs90_device::tlcs90_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 20, 0, program_map) , m_port_read_cb(*this) @@ -163,36 +163,36 @@ tlcs90_device::tlcs90_device(const machine_config &mconfig, device_type type, co } -tmp90840_device::tmp90840_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmp90840_device::tmp90840_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tlcs90_device(mconfig, TMP90840, tag, owner, clock, address_map_constructor(FUNC(tmp90840_device::tmp90840_mem), this)) { } -tmp90841_device::tmp90841_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmp90841_device::tmp90841_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tlcs90_device(mconfig, TMP90841, tag, owner, clock, address_map_constructor(FUNC(tmp90841_device::tmp90841_mem), this)) { } -tmp90845_device::tmp90845_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmp90845_device::tmp90845_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tlcs90_device(mconfig, TMP90845, tag, owner, clock, address_map_constructor(FUNC(tmp90845_device::tmp90841_mem), this)) { } -tmp91640_device::tmp91640_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmp91640_device::tmp91640_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tlcs90_device(mconfig, TMP91640, tag, owner, clock, address_map_constructor(FUNC(tmp91640_device::tmp91640_mem), this)) { } -tmp91641_device::tmp91641_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmp91641_device::tmp91641_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tlcs90_device(mconfig, TMP91641, tag, owner, clock, address_map_constructor(FUNC(tmp91641_device::tmp91641_mem), this)) { } -tmp90ph44_device::tmp90ph44_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmp90ph44_device::tmp90ph44_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tlcs90_device(mconfig, TMP90PH44, tag, owner, clock, address_map_constructor(FUNC(tmp90ph44_device::tmp90ph44_mem), this)) { } diff --git a/src/devices/cpu/tlcs90/tlcs90.h b/src/devices/cpu/tlcs90/tlcs90.h index c1ef052dfe8..be685dc7c0e 100644 --- a/src/devices/cpu/tlcs90/tlcs90.h +++ b/src/devices/cpu/tlcs90/tlcs90.h @@ -35,7 +35,7 @@ public: protected: // construction/destruction - tlcs90_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor program_map); + tlcs90_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor program_map); // device-level overrides virtual void device_start() override; @@ -198,7 +198,7 @@ class tmp90840_device : public tlcs90_device { public: // construction/destruction - tmp90840_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmp90840_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides @@ -210,7 +210,7 @@ class tmp90841_device : public tlcs90_device { public: // construction/destruction - tmp90841_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmp90841_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides @@ -222,7 +222,7 @@ class tmp90845_device : public tlcs90_device { public: // construction/destruction - tmp90845_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmp90845_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides @@ -234,7 +234,7 @@ class tmp91640_device : public tlcs90_device { public: // construction/destruction - tmp91640_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmp91640_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides @@ -246,7 +246,7 @@ class tmp91641_device : public tlcs90_device { public: // construction/destruction - tmp91641_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmp91641_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides @@ -258,7 +258,7 @@ class tmp90ph44_device : public tlcs90_device { public: // construction/destruction - tmp90ph44_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmp90ph44_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides diff --git a/src/devices/cpu/tlcs900/tlcs900.cpp b/src/devices/cpu/tlcs900/tlcs900.cpp index 3fc240cdb4a..7bc112c24bd 100644 --- a/src/devices/cpu/tlcs900/tlcs900.cpp +++ b/src/devices/cpu/tlcs900/tlcs900.cpp @@ -15,7 +15,7 @@ TODO: #include "dasm900.h" -tlcs900_device::tlcs900_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +tlcs900_device::tlcs900_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock), m_am8_16(0), m_mnemonic_80(s_mnemonic_80), @@ -36,7 +36,7 @@ tlcs900_device::tlcs900_device(const machine_config &mconfig, device_type type, { } -tlcs900h_device::tlcs900h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +tlcs900h_device::tlcs900h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : tlcs900_device(mconfig, type, tag, owner, clock) { m_mnemonic_80 = s_mnemonic_80; diff --git a/src/devices/cpu/tlcs900/tlcs900.h b/src/devices/cpu/tlcs900/tlcs900.h index f3b77d44622..7f1e2d28068 100644 --- a/src/devices/cpu/tlcs900/tlcs900.h +++ b/src/devices/cpu/tlcs900/tlcs900.h @@ -48,7 +48,7 @@ public: protected: // construction/destruction - tlcs900_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + tlcs900_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -641,7 +641,7 @@ class tlcs900h_device : public tlcs900_device { protected: // construction/destruction - tlcs900h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + tlcs900h_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_reset() override; diff --git a/src/devices/cpu/tlcs900/tmp95c061.cpp b/src/devices/cpu/tlcs900/tmp95c061.cpp index d297ba73fcf..c38cebfd89a 100644 --- a/src/devices/cpu/tlcs900/tmp95c061.cpp +++ b/src/devices/cpu/tlcs900/tmp95c061.cpp @@ -12,7 +12,7 @@ Toshiba TMP95C061 emulation DEFINE_DEVICE_TYPE(TMP95C061, tmp95c061_device, "tmp95c061", "Toshiba TMP95C061") -tmp95c061_device::tmp95c061_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tmp95c061_device::tmp95c061_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tlcs900h_device(mconfig, TMP95C061, tag, owner, clock), m_port1_read(*this), m_port1_write(*this), diff --git a/src/devices/cpu/tlcs900/tmp95c061.h b/src/devices/cpu/tlcs900/tmp95c061.h index 10d8193f6e6..cda71c52b74 100644 --- a/src/devices/cpu/tlcs900/tmp95c061.h +++ b/src/devices/cpu/tlcs900/tmp95c061.h @@ -15,7 +15,7 @@ class tmp95c061_device : public tlcs900h_device { public: // construction/destruction - tmp95c061_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmp95c061_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto port1_read() { return m_port1_read.bind(); } diff --git a/src/devices/cpu/tlcs900/tmp95c063.cpp b/src/devices/cpu/tlcs900/tmp95c063.cpp index 90663eeaff3..17501a89c53 100644 --- a/src/devices/cpu/tlcs900/tmp95c063.cpp +++ b/src/devices/cpu/tlcs900/tmp95c063.cpp @@ -12,7 +12,7 @@ Toshiba TMP95C063 emulation DEFINE_DEVICE_TYPE(TMP95C063, tmp95c063_device, "tmp95c063", "Toshiba TMP95C063") -tmp95c063_device::tmp95c063_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tmp95c063_device::tmp95c063_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tlcs900h_device(mconfig, TMP95C063, tag, owner, clock), m_port1_read(*this), m_port1_write(*this), diff --git a/src/devices/cpu/tlcs900/tmp95c063.h b/src/devices/cpu/tlcs900/tmp95c063.h index 4c9c05bb433..d2446f383cd 100644 --- a/src/devices/cpu/tlcs900/tmp95c063.h +++ b/src/devices/cpu/tlcs900/tmp95c063.h @@ -15,7 +15,7 @@ class tmp95c063_device : public tlcs900h_device { public: // construction/destruction - tmp95c063_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmp95c063_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto port1_read() { return m_port1_read.bind(); } diff --git a/src/devices/cpu/tlcs900/tmp96c141.cpp b/src/devices/cpu/tlcs900/tmp96c141.cpp index b5e64be8da3..8e2f7958459 100644 --- a/src/devices/cpu/tlcs900/tmp96c141.cpp +++ b/src/devices/cpu/tlcs900/tmp96c141.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(TMP96C141, tmp96c141_device, "tmp96c141", "Toshiba TMP96C141" // tmp96c141_device - constructor //------------------------------------------------- -tmp96c141_device::tmp96c141_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tmp96c141_device::tmp96c141_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tlcs900_device(mconfig, TMP96C141, tag, owner, clock) { } diff --git a/src/devices/cpu/tlcs900/tmp96c141.h b/src/devices/cpu/tlcs900/tmp96c141.h index 973693a201b..32b8f47f9b7 100644 --- a/src/devices/cpu/tlcs900/tmp96c141.h +++ b/src/devices/cpu/tlcs900/tmp96c141.h @@ -69,7 +69,7 @@ class tmp96c141_device : public tlcs900_device { public: // device type constructor - tmp96c141_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tmp96c141_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // TODO: configuration helpers diff --git a/src/devices/cpu/tms1000/tms0270.cpp b/src/devices/cpu/tms1000/tms0270.cpp index 1a90eba3da1..cbfe810e2f9 100644 --- a/src/devices/cpu/tms1000/tms0270.cpp +++ b/src/devices/cpu/tms1000/tms0270.cpp @@ -24,7 +24,7 @@ TMS0260 is same or similar? DEFINE_DEVICE_TYPE(TMS0270, tms0270_cpu_device, "tms0270", "Texas Instruments TMS0270") // 40-pin DIP, 16 O pins, 8+ R pins (some R pins are internally hooked up to support more I/O) -tms0270_cpu_device::tms0270_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms0270_cpu_device::tms0270_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms0980_cpu_device(mconfig, TMS0270, tag, owner, clock, 16 /* o pins */, 16 /* r pins */, 7 /* pc bits */, 9 /* byte width */, 4 /* x width */, 1 /* stack levels */, 11 /* rom width */, address_map_constructor(FUNC(tms0270_cpu_device::rom_11bit), this), 8 /* ram width */, address_map_constructor(FUNC(tms0270_cpu_device::ram_144x4), this)) { } diff --git a/src/devices/cpu/tms1000/tms0270.h b/src/devices/cpu/tms1000/tms0270.h index e6f3f89197e..39a8ffbe696 100644 --- a/src/devices/cpu/tms1000/tms0270.h +++ b/src/devices/cpu/tms1000/tms0270.h @@ -17,7 +17,7 @@ class tms0270_cpu_device : public tms0980_cpu_device { public: - tms0270_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms0270_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // overrides diff --git a/src/devices/cpu/tms1000/tms0970.cpp b/src/devices/cpu/tms1000/tms0970.cpp index 869f3700b82..a922529895f 100644 --- a/src/devices/cpu/tms1000/tms0970.cpp +++ b/src/devices/cpu/tms1000/tms0970.cpp @@ -29,19 +29,19 @@ DEFINE_DEVICE_TYPE(TMS0970, tms0970_cpu_device, "tms0970", "Texas Instruments TM DEFINE_DEVICE_TYPE(TMS1990, tms1990_cpu_device, "tms1990", "Texas Instruments TMS1990") // 28-pin DIP, ? R pins.. -tms0970_cpu_device::tms0970_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms0970_cpu_device::tms0970_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms0970_cpu_device(mconfig, TMS0970, tag, owner, clock, 8 /* o pins */, 11 /* r pins */, 6 /* pc bits */, 8 /* byte width */, 2 /* x width */, 1 /* stack levels */, 10 /* rom width */, address_map_constructor(FUNC(tms0970_cpu_device::rom_10bit), this), 6 /* ram width */, address_map_constructor(FUNC(tms0970_cpu_device::ram_6bit), this)) { } -tms0970_cpu_device::tms0970_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms0970_cpu_device::tms0970_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms1000_cpu_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms0950_cpu_device::tms0950_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms0950_cpu_device::tms0950_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms0970_cpu_device(mconfig, TMS0950, tag, owner, clock, 8, 11, 6, 8, 2, 1, 10, address_map_constructor(FUNC(tms0950_cpu_device::rom_10bit), this), 6, address_map_constructor(FUNC(tms0950_cpu_device::ram_6bit), this)) { } -tms1990_cpu_device::tms1990_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1990_cpu_device::tms1990_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms0970_cpu_device(mconfig, TMS1990, tag, owner, clock, 8, 11, 6, 8, 2, 1, 10, address_map_constructor(FUNC(tms1990_cpu_device::rom_10bit), this), 6, address_map_constructor(FUNC(tms1990_cpu_device::ram_6bit), this)) { } diff --git a/src/devices/cpu/tms1000/tms0970.h b/src/devices/cpu/tms1000/tms0970.h index 583a9480e91..2d7d1b1d100 100644 --- a/src/devices/cpu/tms1000/tms0970.h +++ b/src/devices/cpu/tms1000/tms0970.h @@ -17,10 +17,10 @@ class tms0970_cpu_device : public tms1000_cpu_device { public: - tms0970_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms0970_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms0970_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms0970_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); // overrides virtual void device_reset() override; @@ -35,7 +35,7 @@ protected: class tms0950_cpu_device : public tms0970_cpu_device { public: - tms0950_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms0950_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // overrides @@ -49,7 +49,7 @@ protected: class tms1990_cpu_device : public tms0970_cpu_device { public: - tms1990_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1990_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/tms1000/tms0980.cpp b/src/devices/cpu/tms1000/tms0980.cpp index 664adb877ed..c6daf559d77 100644 --- a/src/devices/cpu/tms1000/tms0980.cpp +++ b/src/devices/cpu/tms1000/tms0980.cpp @@ -32,15 +32,15 @@ DEFINE_DEVICE_TYPE(TMS0980, tms0980_cpu_device, "tms0980", "Texas Instruments TM DEFINE_DEVICE_TYPE(TMS1980, tms1980_cpu_device, "tms1980", "Texas Instruments TMS1980") // 28-pin DIP, 7 O pins, 10 R pins, high voltage -tms0980_cpu_device::tms0980_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms0980_cpu_device::tms0980_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms0980_cpu_device(mconfig, TMS0980, tag, owner, clock, 8 /* o pins */, 9 /* r pins */, 7 /* pc bits */, 9 /* byte width */, 4 /* x width */, 1 /* stack levels */, 11 /* rom width */, address_map_constructor(FUNC(tms0980_cpu_device::rom_11bit), this), 8 /* ram width */, address_map_constructor(FUNC(tms0980_cpu_device::ram_144x4), this)) { } -tms0980_cpu_device::tms0980_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms0980_cpu_device::tms0980_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms0970_cpu_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms1980_cpu_device::tms1980_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1980_cpu_device::tms1980_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms0980_cpu_device(mconfig, TMS1980, tag, owner, clock, 7, 10, 7, 9, 4, 1, 11, address_map_constructor(FUNC(tms1980_cpu_device::rom_11bit), this), 8, address_map_constructor(FUNC(tms1980_cpu_device::ram_144x4), this)) { } diff --git a/src/devices/cpu/tms1000/tms0980.h b/src/devices/cpu/tms1000/tms0980.h index 038f54cf2e2..3c0367fa80d 100644 --- a/src/devices/cpu/tms1000/tms0980.h +++ b/src/devices/cpu/tms1000/tms0980.h @@ -41,10 +41,10 @@ class tms0980_cpu_device : public tms0970_cpu_device { public: - tms0980_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms0980_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms0980_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms0980_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); void ram_144x4(address_map &map); @@ -74,7 +74,7 @@ protected: class tms1980_cpu_device : public tms0980_cpu_device { public: - tms1980_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1980_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // overrides diff --git a/src/devices/cpu/tms1000/tms1000.cpp b/src/devices/cpu/tms1000/tms1000.cpp index 6937fc2ab35..31209f10ea8 100644 --- a/src/devices/cpu/tms1000/tms1000.cpp +++ b/src/devices/cpu/tms1000/tms1000.cpp @@ -37,39 +37,39 @@ DEFINE_DEVICE_TYPE(MC141000, mc141000_cpu_device, "mc141000", "Motorola MC141000 DEFINE_DEVICE_TYPE(MC141200, mc141200_cpu_device, "mc141200", "Motorola MC141200") // CMOS, 40-pin DIP, 16 R pins -tms1000_cpu_device::tms1000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1000_cpu_device::tms1000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1000_cpu_device(mconfig, TMS1000, tag, owner, clock, 8 /* o pins */, 11 /* r pins */, 6 /* pc bits */, 8 /* byte width */, 2 /* x width */, 1 /* stack levels */, 10 /* rom width */, address_map_constructor(FUNC(tms1000_cpu_device::rom_10bit), this), 6 /* ram width */, address_map_constructor(FUNC(tms1000_cpu_device::ram_6bit), this)) { } -tms1000_cpu_device::tms1000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms1000_cpu_device::tms1000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms1k_base_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms1070_cpu_device::tms1070_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1070_cpu_device::tms1070_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1000_cpu_device(mconfig, TMS1070, tag, owner, clock, 8, 11, 6, 8, 2, 1, 10, address_map_constructor(FUNC(tms1070_cpu_device::rom_10bit), this), 6, address_map_constructor(FUNC(tms1070_cpu_device::ram_6bit), this)) { } -tms1040_cpu_device::tms1040_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1040_cpu_device::tms1040_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1000_cpu_device(mconfig, TMS1040, tag, owner, clock, 8, 11, 6, 8, 2, 1, 10, address_map_constructor(FUNC(tms1040_cpu_device::rom_10bit), this), 6, address_map_constructor(FUNC(tms1040_cpu_device::ram_6bit), this)) { } -tms1200_cpu_device::tms1200_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1200_cpu_device::tms1200_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1000_cpu_device(mconfig, TMS1200, tag, owner, clock, 8, 13, 6, 8, 2, 1, 10, address_map_constructor(FUNC(tms1200_cpu_device::rom_10bit), this), 6, address_map_constructor(FUNC(tms1200_cpu_device::ram_6bit), this)) { } -tms1700_cpu_device::tms1700_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1700_cpu_device::tms1700_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1000_cpu_device(mconfig, TMS1700, tag, owner, clock, 8, 9, 6, 8, 2, 1, 10, address_map_constructor(FUNC(tms1700_cpu_device::rom_9bitm), this), 6, address_map_constructor(FUNC(tms1700_cpu_device::ram_32x4), this)) { } -tms1730_cpu_device::tms1730_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1730_cpu_device::tms1730_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1000_cpu_device(mconfig, TMS1730, tag, owner, clock, 8, 9, 6, 8, 2, 1, 10, address_map_constructor(FUNC(tms1730_cpu_device::rom_9bitm), this), 6, address_map_constructor(FUNC(tms1730_cpu_device::ram_32x4), this)) { } -mc141000_cpu_device::mc141000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mc141000_cpu_device::mc141000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1000_cpu_device(mconfig, MC141000, tag, owner, clock, 8, 11, 6, 8, 2, 1, 10, address_map_constructor(FUNC(mc141000_cpu_device::rom_10bit), this), 6, address_map_constructor(FUNC(mc141000_cpu_device::ram_6bit), this)) { } -mc141200_cpu_device::mc141200_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mc141200_cpu_device::mc141200_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1000_cpu_device(mconfig, MC141200, tag, owner, clock, 8, 16, 6, 8, 2, 1, 10, address_map_constructor(FUNC(mc141200_cpu_device::rom_10bit), this), 6, address_map_constructor(FUNC(mc141200_cpu_device::ram_6bit), this)) { } diff --git a/src/devices/cpu/tms1000/tms1000.h b/src/devices/cpu/tms1000/tms1000.h index 8e45216718b..bd9dd43fce8 100644 --- a/src/devices/cpu/tms1000/tms1000.h +++ b/src/devices/cpu/tms1000/tms1000.h @@ -61,10 +61,10 @@ class tms1000_cpu_device : public tms1k_base_device { public: - tms1000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms1000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms1000_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); void rom_9bitm(address_map &map); void ram_32x4(address_map &map); @@ -80,46 +80,46 @@ protected: class tms1070_cpu_device : public tms1000_cpu_device { public: - tms1070_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1070_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms1040_cpu_device : public tms1000_cpu_device { public: - tms1040_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1040_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms1200_cpu_device : public tms1000_cpu_device { public: - tms1200_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1200_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms1700_cpu_device : public tms1000_cpu_device { public: - tms1700_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1700_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms1730_cpu_device : public tms1000_cpu_device { public: - tms1730_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1730_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mc141000_cpu_device : public tms1000_cpu_device { public: - mc141000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mc141000_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mc141200_cpu_device : public tms1000_cpu_device { public: - mc141200_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mc141200_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/tms1000/tms1000c.cpp b/src/devices/cpu/tms1000/tms1000c.cpp index 977c8c90d37..ed6b7a9fd06 100644 --- a/src/devices/cpu/tms1000/tms1000c.cpp +++ b/src/devices/cpu/tms1000/tms1000c.cpp @@ -26,7 +26,7 @@ TODO: DEFINE_DEVICE_TYPE(TMS1000C, tms1000c_cpu_device, "tms1000c", "Texas Instruments TMS1000C") // 28-pin SDIP, 10 R pins -tms1000c_cpu_device::tms1000c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1000c_cpu_device::tms1000c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1000_cpu_device(mconfig, TMS1000C, tag, owner, clock, 8 /* o pins */, 10 /* r pins */, 6 /* pc bits */, 8 /* byte width */, 2 /* x width */, 3 /* stack levels */, 10 /* rom width */, address_map_constructor(FUNC(tms1000c_cpu_device::rom_10bit), this), 6 /* ram width */, address_map_constructor(FUNC(tms1000c_cpu_device::ram_6bit), this)) { } diff --git a/src/devices/cpu/tms1000/tms1000c.h b/src/devices/cpu/tms1000/tms1000c.h index bf165550045..600b57bb79e 100644 --- a/src/devices/cpu/tms1000/tms1000c.h +++ b/src/devices/cpu/tms1000/tms1000c.h @@ -17,7 +17,7 @@ class tms1000c_cpu_device : public tms1000_cpu_device { public: - tms1000c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1000c_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // overrides diff --git a/src/devices/cpu/tms1000/tms1100.cpp b/src/devices/cpu/tms1000/tms1100.cpp index 7af1237a5ad..9a799749a33 100644 --- a/src/devices/cpu/tms1000/tms1100.cpp +++ b/src/devices/cpu/tms1000/tms1100.cpp @@ -23,23 +23,23 @@ DEFINE_DEVICE_TYPE(TMS1300, tms1300_cpu_device, "tms1300", "Texas Instruments TM DEFINE_DEVICE_TYPE(TMS1370, tms1370_cpu_device, "tms1370", "Texas Instruments TMS1370") // high voltage version, also seen in 28-pin package(some O/R pins unavailable) -tms1100_cpu_device::tms1100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1100_cpu_device::tms1100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1100_cpu_device(mconfig, TMS1100, tag, owner, clock, 8 /* o pins */, 11 /* r pins */, 6 /* pc bits */, 8 /* byte width */, 3 /* x width */, 1 /* stack levels */, 11 /* rom width */, address_map_constructor(FUNC(tms1100_cpu_device::rom_11bit), this), 7 /* ram width */, address_map_constructor(FUNC(tms1100_cpu_device::ram_7bit), this)) { } -tms1100_cpu_device::tms1100_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms1100_cpu_device::tms1100_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms1000_cpu_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms1170_cpu_device::tms1170_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1170_cpu_device::tms1170_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1100_cpu_device(mconfig, TMS1170, tag, owner, clock, 8, 11, 6, 8, 3, 1, 11, address_map_constructor(FUNC(tms1170_cpu_device::rom_11bit), this), 7, address_map_constructor(FUNC(tms1170_cpu_device::ram_7bit), this)) { } -tms1300_cpu_device::tms1300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1300_cpu_device::tms1300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1100_cpu_device(mconfig, TMS1300, tag, owner, clock, 8, 16, 6, 8, 3, 1, 11, address_map_constructor(FUNC(tms1300_cpu_device::rom_11bit), this), 7, address_map_constructor(FUNC(tms1300_cpu_device::ram_7bit), this)) { } -tms1370_cpu_device::tms1370_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1370_cpu_device::tms1370_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1100_cpu_device(mconfig, TMS1370, tag, owner, clock, 8, 16, 6, 8, 3, 1, 11, address_map_constructor(FUNC(tms1370_cpu_device::rom_11bit), this), 7, address_map_constructor(FUNC(tms1370_cpu_device::ram_7bit), this)) { } diff --git a/src/devices/cpu/tms1000/tms1100.h b/src/devices/cpu/tms1000/tms1100.h index 4121a25f64e..812e670ad54 100644 --- a/src/devices/cpu/tms1000/tms1100.h +++ b/src/devices/cpu/tms1000/tms1100.h @@ -63,10 +63,10 @@ class tms1100_cpu_device : public tms1000_cpu_device { public: - tms1100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms1100_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms1100_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); // overrides virtual void device_start() override; @@ -81,19 +81,19 @@ protected: class tms1170_cpu_device : public tms1100_cpu_device { public: - tms1170_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1170_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms1300_cpu_device : public tms1100_cpu_device { public: - tms1300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms1370_cpu_device : public tms1100_cpu_device { public: - tms1370_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1370_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/tms1000/tms1400.cpp b/src/devices/cpu/tms1000/tms1400.cpp index 64eb906a2d1..f11f4567371 100644 --- a/src/devices/cpu/tms1000/tms1400.cpp +++ b/src/devices/cpu/tms1000/tms1400.cpp @@ -33,37 +33,37 @@ DEFINE_DEVICE_TYPE(TMS1600, tms1600_cpu_device, "tms1600", "Texas Instruments TM DEFINE_DEVICE_TYPE(TMS1670, tms1670_cpu_device, "tms1670", "Texas Instruments TMS1670") // high voltage version -tms1400_cpu_device::tms1400_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1400_cpu_device::tms1400_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1400_cpu_device(mconfig, TMS1400, tag, owner, clock, 8 /* o pins */, 11 /* r pins */, 6 /* pc bits */, 8 /* byte width */, 3 /* x width */, 3 /* stack levels */, 12 /* rom width */, address_map_constructor(FUNC(tms1400_cpu_device::rom_12bit), this), 7 /* ram width */, address_map_constructor(FUNC(tms1400_cpu_device::ram_7bit), this)) { } -tms1400_cpu_device::tms1400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms1400_cpu_device::tms1400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms1100_cpu_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms1470_cpu_device::tms1470_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1470_cpu_device::tms1470_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1470_cpu_device(mconfig, TMS1470, tag, owner, clock, 8, 10, 6, 8, 3, 3, 12, address_map_constructor(FUNC(tms1470_cpu_device::rom_12bit), this), 7, address_map_constructor(FUNC(tms1470_cpu_device::ram_7bit), this)) { } -tms1470_cpu_device::tms1470_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms1470_cpu_device::tms1470_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms1400_cpu_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms1475_cpu_device::tms1475_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1475_cpu_device::tms1475_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1470_cpu_device(mconfig, TMS1475, tag, owner, clock, 8, 22, 6, 8, 3, 3, 12, address_map_constructor(FUNC(tms1475_cpu_device::rom_12bit), this), 7, address_map_constructor(FUNC(tms1475_cpu_device::ram_7bit), this)) { } -tms1600_cpu_device::tms1600_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1600_cpu_device::tms1600_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1600_cpu_device(mconfig, TMS1600, tag, owner, clock, 8, 16, 6, 8, 3, 3, 12, address_map_constructor(FUNC(tms1600_cpu_device::rom_12bit), this), 7, address_map_constructor(FUNC(tms1600_cpu_device::ram_7bit), this)) { } -tms1600_cpu_device::tms1600_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms1600_cpu_device::tms1600_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms1400_cpu_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms1670_cpu_device::tms1670_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms1670_cpu_device::tms1670_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1600_cpu_device(mconfig, TMS1670, tag, owner, clock, 8, 16, 6, 8, 3, 3, 12, address_map_constructor(FUNC(tms1670_cpu_device::rom_12bit), this), 7, address_map_constructor(FUNC(tms1670_cpu_device::ram_7bit), this)) { } diff --git a/src/devices/cpu/tms1000/tms1400.h b/src/devices/cpu/tms1000/tms1400.h index acac9ea4ca1..b69b48ca5a5 100644 --- a/src/devices/cpu/tms1000/tms1400.h +++ b/src/devices/cpu/tms1000/tms1400.h @@ -41,10 +41,10 @@ class tms1400_cpu_device : public tms1100_cpu_device { public: - tms1400_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1400_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms1400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms1400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); // overrides virtual void device_reset() override; @@ -59,16 +59,16 @@ protected: class tms1470_cpu_device : public tms1400_cpu_device { public: - tms1470_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1470_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms1470_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms1470_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); }; class tms1475_cpu_device : public tms1470_cpu_device { public: - tms1475_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1475_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void op_setr() override { tms1100_cpu_device::op_setr(); } @@ -78,16 +78,16 @@ protected: class tms1600_cpu_device : public tms1400_cpu_device { public: - tms1600_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1600_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms1600_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms1600_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); }; class tms1670_cpu_device : public tms1600_cpu_device { public: - tms1670_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms1670_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/tms1000/tms1k_base.cpp b/src/devices/cpu/tms1000/tms1k_base.cpp index 8034c2c7b4c..729e8274476 100644 --- a/src/devices/cpu/tms1000/tms1k_base.cpp +++ b/src/devices/cpu/tms1000/tms1k_base.cpp @@ -71,7 +71,7 @@ unknown cycle: CME, SSE, SSS #include "emu.h" #include "tms1k_base.h" -tms1k_base_device::tms1k_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms1k_base_device::tms1k_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_BIG, byte_bits > 8 ? 16 : 8, rom_width, byte_bits > 8 ? -1 : 0, rom_map), m_data_config("data", ENDIANNESS_BIG, 8, ram_width, 0, ram_map), diff --git a/src/devices/cpu/tms1000/tms1k_base.h b/src/devices/cpu/tms1000/tms1k_base.h index 136a54e61c7..a65caa0b3ca 100644 --- a/src/devices/cpu/tms1000/tms1k_base.h +++ b/src/devices/cpu/tms1000/tms1k_base.h @@ -52,7 +52,7 @@ public: protected: // construction/destruction - tms1k_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms1k_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/tms1000/tms2100.cpp b/src/devices/cpu/tms1000/tms2100.cpp index b469e7c7b08..06ec33fd97d 100644 --- a/src/devices/cpu/tms1000/tms2100.cpp +++ b/src/devices/cpu/tms1000/tms2100.cpp @@ -40,27 +40,27 @@ DEFINE_DEVICE_TYPE(TMS2300, tms2300_cpu_device, "tms2300", "Texas Instruments TM DEFINE_DEVICE_TYPE(TMS2370, tms2370_cpu_device, "tms2370", "Texas Instruments TMS2370") // high voltage version, 1 R pin removed for Vpp -tms2100_cpu_device::tms2100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms2100_cpu_device::tms2100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms2100_cpu_device(mconfig, TMS2100, tag, owner, clock, 8 /* o pins */, 7 /* r pins */, 6 /* pc bits */, 8 /* byte width */, 3 /* x width */, 4 /* stack levels */, 11 /* rom width */, address_map_constructor(FUNC(tms2100_cpu_device::rom_11bit), this), 7 /* ram width */, address_map_constructor(FUNC(tms2100_cpu_device::ram_7bit), this)) { } -tms2100_cpu_device::tms2100_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms2100_cpu_device::tms2100_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms1100_cpu_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms2170_cpu_device::tms2170_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms2170_cpu_device::tms2170_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms2100_cpu_device(mconfig, TMS2170, tag, owner, clock, 8, 6, 6, 8, 3, 4, 11, address_map_constructor(FUNC(tms2170_cpu_device::rom_11bit), this), 7, address_map_constructor(FUNC(tms2170_cpu_device::ram_7bit), this)) { } -tms2300_cpu_device::tms2300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms2300_cpu_device::tms2300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms2300_cpu_device(mconfig, TMS2300, tag, owner, clock, 8, 15, 6, 8, 3, 4, 11, address_map_constructor(FUNC(tms2300_cpu_device::rom_11bit), this), 7, address_map_constructor(FUNC(tms2300_cpu_device::ram_7bit), this)) { } -tms2300_cpu_device::tms2300_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms2300_cpu_device::tms2300_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms2100_cpu_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms2370_cpu_device::tms2370_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms2370_cpu_device::tms2370_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms2300_cpu_device(mconfig, TMS2370, tag, owner, clock, 8, 14, 6, 8, 3, 4, 11, address_map_constructor(FUNC(tms2370_cpu_device::rom_11bit), this), 7, address_map_constructor(FUNC(tms2370_cpu_device::ram_7bit), this)) { } diff --git a/src/devices/cpu/tms1000/tms2100.h b/src/devices/cpu/tms1000/tms2100.h index 7f6c6ab340b..a6dbf3eb0b0 100644 --- a/src/devices/cpu/tms1000/tms2100.h +++ b/src/devices/cpu/tms1000/tms2100.h @@ -69,10 +69,10 @@ enum class tms2100_cpu_device : public tms1100_cpu_device { public: - tms2100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms2100_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms2100_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms2100_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); // overrides virtual void device_start() override; @@ -131,22 +131,22 @@ protected: class tms2170_cpu_device : public tms2100_cpu_device { public: - tms2170_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms2170_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms2300_cpu_device : public tms2100_cpu_device { public: - tms2300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms2300_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms2300_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms2300_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); }; class tms2370_cpu_device : public tms2300_cpu_device { public: - tms2370_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms2370_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/tms1000/tms2400.cpp b/src/devices/cpu/tms1000/tms2400.cpp index 289e4f94692..f5454923f94 100644 --- a/src/devices/cpu/tms1000/tms2400.cpp +++ b/src/devices/cpu/tms1000/tms2400.cpp @@ -20,27 +20,27 @@ DEFINE_DEVICE_TYPE(TMS2600, tms2600_cpu_device, "tms2600", "Texas Instruments TM DEFINE_DEVICE_TYPE(TMS2670, tms2670_cpu_device, "tms2670", "Texas Instruments TMS2670") // high voltage version, 1 R pin removed for Vpp -tms2400_cpu_device::tms2400_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms2400_cpu_device::tms2400_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms2400_cpu_device(mconfig, TMS2400, tag, owner, clock, 8 /* o pins */, 7 /* r pins */, 6 /* pc bits */, 8 /* byte width */, 4 /* x width */, 4 /* stack levels */, 12 /* rom width */, address_map_constructor(FUNC(tms2400_cpu_device::rom_12bit), this), 8 /* ram width */, address_map_constructor(FUNC(tms2400_cpu_device::ram_8bit), this)) { } -tms2400_cpu_device::tms2400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms2400_cpu_device::tms2400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms2100_cpu_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms2470_cpu_device::tms2470_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms2470_cpu_device::tms2470_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms2400_cpu_device(mconfig, TMS2470, tag, owner, clock, 8, 6, 6, 8, 4, 4, 12, address_map_constructor(FUNC(tms2470_cpu_device::rom_12bit), this), 8, address_map_constructor(FUNC(tms2470_cpu_device::ram_8bit), this)) { } -tms2600_cpu_device::tms2600_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms2600_cpu_device::tms2600_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms2600_cpu_device(mconfig, TMS2600, tag, owner, clock, 8, 15, 6, 8, 4, 4, 12, address_map_constructor(FUNC(tms2600_cpu_device::rom_12bit), this), 8, address_map_constructor(FUNC(tms2600_cpu_device::ram_8bit), this)) { } -tms2600_cpu_device::tms2600_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : +tms2600_cpu_device::tms2600_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map) : tms2400_cpu_device(mconfig, type, tag, owner, clock, o_pins, r_pins, pc_bits, byte_bits, x_bits, stack_levels, rom_width, rom_map, ram_width, ram_map) { } -tms2670_cpu_device::tms2670_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tms2670_cpu_device::tms2670_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms2600_cpu_device(mconfig, TMS2670, tag, owner, clock, 8, 14, 6, 8, 4, 4, 12, address_map_constructor(FUNC(tms2670_cpu_device::rom_12bit), this), 8, address_map_constructor(FUNC(tms2670_cpu_device::ram_8bit), this)) { } diff --git a/src/devices/cpu/tms1000/tms2400.h b/src/devices/cpu/tms1000/tms2400.h index 25692d3207e..b002bd9cefb 100644 --- a/src/devices/cpu/tms1000/tms2400.h +++ b/src/devices/cpu/tms1000/tms2400.h @@ -17,10 +17,10 @@ class tms2400_cpu_device : public tms2100_cpu_device { public: - tms2400_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms2400_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms2400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms2400_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); // overrides virtual void device_reset() override; @@ -34,22 +34,22 @@ protected: class tms2470_cpu_device : public tms2400_cpu_device { public: - tms2470_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms2470_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms2600_cpu_device : public tms2400_cpu_device { public: - tms2600_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms2600_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms2600_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); + tms2600_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 o_pins, u8 r_pins, u8 pc_bits, u8 byte_bits, u8 x_bits, u8 stack_levels, int rom_width, address_map_constructor rom_map, int ram_width, address_map_constructor ram_map); }; class tms2670_cpu_device : public tms2600_cpu_device { public: - tms2670_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms2670_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/tms1000/tp0320.cpp b/src/devices/cpu/tms1000/tp0320.cpp index 54eb8c368b5..72fd062ca17 100644 --- a/src/devices/cpu/tms1000/tp0320.cpp +++ b/src/devices/cpu/tms1000/tp0320.cpp @@ -28,7 +28,7 @@ TODO: DEFINE_DEVICE_TYPE(TP0320, tp0320_cpu_device, "tp0320", "Texas Instruments TP0320") // 28-pin SDIP, .. -tp0320_cpu_device::tp0320_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tp0320_cpu_device::tp0320_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms0980_cpu_device(mconfig, TP0320, tag, owner, clock, 7 /* o pins */, 10 /* r pins */, 7 /* pc bits */, 9 /* byte width */, 4 /* x width */, 1 /* stack levels */, 11 /* rom width */, address_map_constructor(FUNC(tp0320_cpu_device::rom_11bit), this), 8 /* ram width */, address_map_constructor(FUNC(tp0320_cpu_device::ram_192x4), this)) { } diff --git a/src/devices/cpu/tms1000/tp0320.h b/src/devices/cpu/tms1000/tp0320.h index 710dfb5b787..922245853f5 100644 --- a/src/devices/cpu/tms1000/tp0320.h +++ b/src/devices/cpu/tms1000/tp0320.h @@ -17,7 +17,7 @@ class tp0320_cpu_device : public tms0980_cpu_device { public: - tp0320_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tp0320_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void ram_192x4(address_map &map); diff --git a/src/devices/cpu/tms32010/tms32010.cpp b/src/devices/cpu/tms32010/tms32010.cpp index 7a9fb58b54c..086c2cca029 100644 --- a/src/devices/cpu/tms32010/tms32010.cpp +++ b/src/devices/cpu/tms32010/tms32010.cpp @@ -99,13 +99,13 @@ void tms32010_device::tms32015_ram(address_map &map) } -tms32010_device::tms32010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32010_device::tms32010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms32010_device(mconfig, TMS32010, tag, owner, clock, address_map_constructor(FUNC(tms32010_device::tms32010_ram), this), 0x0fff) { } -tms32010_device::tms32010_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor data_map, int addr_mask) +tms32010_device::tms32010_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor data_map, int addr_mask) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, 12, -1) , m_data_config("data", ENDIANNESS_BIG, 16, 8, -1, data_map) @@ -116,13 +116,13 @@ tms32010_device::tms32010_device(const machine_config &mconfig, device_type type } -tms32015_device::tms32015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32015_device::tms32015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms32010_device(mconfig, TMS32015, tag, owner, clock, address_map_constructor(FUNC(tms32015_device::tms32015_ram), this), 0x0fff) { } -tms32016_device::tms32016_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32016_device::tms32016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms32010_device(mconfig, TMS32016, tag, owner, clock, address_map_constructor(FUNC(tms32016_device::tms32015_ram), this), 0xffff) { } diff --git a/src/devices/cpu/tms32010/tms32010.h b/src/devices/cpu/tms32010/tms32010.h index beebee1b0b0..70ea8534d15 100644 --- a/src/devices/cpu/tms32010/tms32010.h +++ b/src/devices/cpu/tms32010/tms32010.h @@ -35,7 +35,7 @@ class tms32010_device : public cpu_device { public: // construction/destruction - tms32010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto bio() { return m_bio_in.bind(); } @@ -43,7 +43,7 @@ public: void tms32010_ram(address_map &map); void tms32015_ram(address_map &map); protected: - tms32010_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor data_map, int addr_mask); + tms32010_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor data_map, int addr_mask); // device-level overrides virtual void device_start() override; @@ -191,7 +191,7 @@ class tms32015_device : public tms32010_device { public: // construction/destruction - tms32015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -199,7 +199,7 @@ class tms32016_device : public tms32010_device { public: // construction/destruction - tms32016_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/tms32025/tms32025.cpp b/src/devices/cpu/tms32025/tms32025.cpp index 304280555a1..a0c08118878 100644 --- a/src/devices/cpu/tms32025/tms32025.cpp +++ b/src/devices/cpu/tms32025/tms32025.cpp @@ -240,7 +240,7 @@ const tiny_rom_entry *tms32025_device::device_rom_region() const } -tms32025_device::tms32025_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor prgmap, address_map_constructor datamap) +tms32025_device::tms32025_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor prgmap, address_map_constructor datamap) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, 16, -1, prgmap) , m_data_config("data", ENDIANNESS_BIG, 16, 16, -1, datamap) @@ -259,19 +259,19 @@ tms32025_device::tms32025_device(const machine_config &mconfig, device_type type { } -tms32025_device::tms32025_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32025_device::tms32025_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms32025_device(mconfig, TMS32025, tag, owner, clock, address_map_constructor(), address_map_constructor(FUNC(tms32025_device::tms32025_data), this)) { m_fixed_STR1 = 0x0180; } -tms32025_device::tms32025_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +tms32025_device::tms32025_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : tms32025_device(mconfig, type, tag, owner, clock, address_map_constructor(), address_map_constructor(FUNC(tms32025_device::tms32025_data), this)) { m_fixed_STR1 = 0x0180; } -tms32026_device::tms32026_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32026_device::tms32026_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms32025_device(mconfig, TMS32026, tag, owner, clock, address_map_constructor(), address_map_constructor(FUNC(tms32026_device::tms32026_data), this)) { m_fixed_STR1 = 0x0100; diff --git a/src/devices/cpu/tms32025/tms32025.h b/src/devices/cpu/tms32025/tms32025.h index de8b4442c08..0f5fb689706 100644 --- a/src/devices/cpu/tms32025/tms32025.h +++ b/src/devices/cpu/tms32025/tms32025.h @@ -62,8 +62,8 @@ class tms32025_device : public cpu_device { public: // construction/destruction - tms32025_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - tms32025_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + tms32025_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); + tms32025_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto bio_in_cb() { return m_bio_in.bind(); } @@ -79,7 +79,7 @@ public: void tms32025_data(address_map &map); void tms32026_data(address_map &map); protected: - tms32025_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor prgmap, address_map_constructor datamap); + tms32025_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor prgmap, address_map_constructor datamap); // device-level overrides virtual void device_start() override; @@ -368,7 +368,7 @@ class tms32026_device : public tms32025_device { public: // construction/destruction - tms32026_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32026_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; diff --git a/src/devices/cpu/tms32031/tms32031.cpp b/src/devices/cpu/tms32031/tms32031.cpp index f4516f27788..41c3792602e 100644 --- a/src/devices/cpu/tms32031/tms32031.cpp +++ b/src/devices/cpu/tms32031/tms32031.cpp @@ -406,7 +406,7 @@ void tms3203x_device::tmsreg::from_double(double val) // tms3203x_device - constructor //------------------------------------------------- -tms3203x_device::tms3203x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t chiptype, int clock_per_inst, address_map_constructor internal_map) +tms3203x_device::tms3203x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t chiptype, int clock_per_inst, address_map_constructor internal_map) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_LITTLE, 32, 24, -2, internal_map), m_chip_type(chiptype), @@ -438,22 +438,22 @@ tms3203x_device::tms3203x_device(const machine_config &mconfig, device_type type #endif } -tms32030_device::tms32030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32030_device::tms32030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms3203x_device(mconfig, TMS32030, tag, owner, clock, CHIP_TYPE_TMS32030, 2, address_map_constructor(FUNC(tms32030_device::internal_32030), this)) { } -tms32031_device::tms32031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32031_device::tms32031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms3203x_device(mconfig, TMS32031, tag, owner, clock, CHIP_TYPE_TMS32031, 2, address_map_constructor(FUNC(tms32031_device::internal_32031), this)) { } -tms32032_device::tms32032_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32032_device::tms32032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms3203x_device(mconfig, TMS32032, tag, owner, clock, CHIP_TYPE_TMS32032, 2, address_map_constructor(FUNC(tms32032_device::internal_32032), this)) { } -tms32033_device::tms32033_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32033_device::tms32033_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms3203x_device(mconfig, TMS32033, tag, owner, clock, CHIP_TYPE_TMS32031, 1, address_map_constructor(FUNC(tms32033_device::internal_32033), this)) { } diff --git a/src/devices/cpu/tms32031/tms32031.h b/src/devices/cpu/tms32031/tms32031.h index 975a8d1cb32..f4193e2cf93 100644 --- a/src/devices/cpu/tms32031/tms32031.h +++ b/src/devices/cpu/tms32031/tms32031.h @@ -143,7 +143,7 @@ protected: }; // construction/destruction - tms3203x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t chiptype, int clock_per_inst, address_map_constructor internal_map); + tms3203x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t chiptype, int clock_per_inst, address_map_constructor internal_map); void common_3203x(address_map &map); // device-level overrides @@ -803,7 +803,7 @@ class tms32030_device : public tms3203x_device { public: // construction/destruction - tms32030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void internal_32030(address_map &map); }; @@ -814,7 +814,7 @@ class tms32031_device : public tms3203x_device { public: // construction/destruction - tms32031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void internal_32031(address_map &map); }; @@ -825,7 +825,7 @@ class tms32032_device : public tms3203x_device { public: // construction/destruction - tms32032_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32032_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void internal_32032(address_map &map); }; @@ -836,7 +836,7 @@ class tms32033_device : public tms3203x_device { public: // construction/destruction - tms32033_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32033_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void internal_32033(address_map &map); }; diff --git a/src/devices/cpu/tms32051/tms32051.cpp b/src/devices/cpu/tms32051/tms32051.cpp index d03493df60f..590a952c842 100644 --- a/src/devices/cpu/tms32051/tms32051.cpp +++ b/src/devices/cpu/tms32051/tms32051.cpp @@ -71,7 +71,7 @@ void tms32051_device::tms32051_internal_data(address_map &map) } -tms32051_device::tms32051_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_pgm, address_map_constructor internal_data) +tms32051_device::tms32051_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_pgm, address_map_constructor internal_data) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 16, -1, internal_pgm) , m_data_config("data", ENDIANNESS_LITTLE, 16, 16, -1, internal_data) @@ -79,7 +79,7 @@ tms32051_device::tms32051_device(const machine_config &mconfig, device_type type { } -tms32051_device::tms32051_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32051_device::tms32051_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms32051_device(mconfig, TMS32051, tag, owner, clock, address_map_constructor(FUNC(tms32051_device::tms32051_internal_pgm), this), address_map_constructor(FUNC(tms32051_device::tms32051_internal_data), this)) { } @@ -115,7 +115,7 @@ void tms32053_device::tms32053_internal_data(address_map &map) } -tms32053_device::tms32053_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32053_device::tms32053_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms32051_device(mconfig, TMS32053, tag, owner, clock, address_map_constructor(FUNC(tms32053_device::tms32053_internal_pgm), this), address_map_constructor(FUNC(tms32053_device::tms32053_internal_data), this)) { } diff --git a/src/devices/cpu/tms32051/tms32051.h b/src/devices/cpu/tms32051/tms32051.h index 63552d7e605..abcb8f64626 100644 --- a/src/devices/cpu/tms32051/tms32051.h +++ b/src/devices/cpu/tms32051/tms32051.h @@ -57,7 +57,7 @@ class tms32051_device : public cpu_device { public: // construction/destruction - tms32051_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32051_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t cpuregs_r(offs_t offset); void cpuregs_w(offs_t offset, uint16_t data); @@ -65,7 +65,7 @@ public: void tms32051_internal_data(address_map &map); void tms32051_internal_pgm(address_map &map); protected: - tms32051_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_pgm, address_map_constructor internal_data); + tms32051_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_pgm, address_map_constructor internal_data); // device-level overrides virtual void device_start() override; @@ -373,7 +373,7 @@ class tms32053_device : public tms32051_device { public: // construction/destruction - tms32053_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32053_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void tms32053_internal_data(address_map &map); void tms32053_internal_pgm(address_map &map); diff --git a/src/devices/cpu/tms32082/tms32082.cpp b/src/devices/cpu/tms32082/tms32082.cpp index 7b1486470c0..16655f93472 100644 --- a/src/devices/cpu/tms32082/tms32082.cpp +++ b/src/devices/cpu/tms32082/tms32082.cpp @@ -43,7 +43,7 @@ const uint32_t tms32082_mp_device::SHIFT_MASK[] = -tms32082_mp_device::tms32082_mp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32082_mp_device::tms32082_mp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, TMS32082_MP, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 32, 32, 0, address_map_constructor(FUNC(tms32082_mp_device::mp_internal_map), this)) , m_cmd_callback(*this) @@ -528,7 +528,7 @@ void tms32082_pp_device::pp_internal_map(address_map &map) map(0x01001000, 0x01001fff).ram().share("pp1_param"); } -tms32082_pp_device::tms32082_pp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms32082_pp_device::tms32082_pp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, TMS32082_PP, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 32, 32, 0, address_map_constructor(FUNC(tms32082_pp_device::pp_internal_map), this)) { diff --git a/src/devices/cpu/tms32082/tms32082.h b/src/devices/cpu/tms32082/tms32082.h index 415ce95d564..7bc54639cbf 100644 --- a/src/devices/cpu/tms32082/tms32082.h +++ b/src/devices/cpu/tms32082/tms32082.h @@ -10,7 +10,7 @@ class tms32082_mp_device : public cpu_device { public: // construction/destruction - tms32082_mp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32082_mp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); enum { @@ -157,7 +157,7 @@ class tms32082_pp_device : public cpu_device { public: // construction/destruction - tms32082_pp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms32082_pp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); enum { diff --git a/src/devices/cpu/tms34010/tms34010.cpp b/src/devices/cpu/tms34010/tms34010.cpp index 729b6ed0bf6..8b3883db3e8 100644 --- a/src/devices/cpu/tms34010/tms34010.cpp +++ b/src/devices/cpu/tms34010/tms34010.cpp @@ -58,7 +58,7 @@ DEFINE_DEVICE_TYPE(TMS34020, tms34020_device, "tms34020", "Texas Instruments TMS GLOBAL VARIABLES ***************************************************************************/ -tms340x0_device::tms340x0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_regs_map, bool is_34020) +tms340x0_device::tms340x0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_regs_map, bool is_34020) : cpu_device(mconfig, type, tag, owner, clock) , device_video_interface(mconfig, *this) , m_program_config("program", ENDIANNESS_LITTLE, is_34020 ? 32 : 16, 32, 3, internal_regs_map) @@ -95,13 +95,13 @@ tms340x0_device::tms340x0_device(const machine_config &mconfig, device_type type } -tms34010_device::tms34010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms34010_device::tms34010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms340x0_device(mconfig, TMS34010, tag, owner, clock, address_map_constructor(FUNC(tms34010_device::internal_regs_map), this), false) { } -tms34020_device::tms34020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms34020_device::tms34020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms340x0_device(mconfig, TMS34020, tag, owner, clock, address_map_constructor(FUNC(tms34020_device::internal_regs_map), this), true) { } diff --git a/src/devices/cpu/tms34010/tms34010.h b/src/devices/cpu/tms34010/tms34010.h index b9165b17f77..f88f852a6d3 100644 --- a/src/devices/cpu/tms34010/tms34010.h +++ b/src/devices/cpu/tms34010/tms34010.h @@ -252,7 +252,7 @@ protected: }; // construction/destruction - tms340x0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_regs_map, bool is_34020); + tms340x0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_regs_map, bool is_34020); // device-level overrides virtual void device_start() override; @@ -958,7 +958,7 @@ protected: class tms34010_device : public tms340x0_device { public: - tms34010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms34010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); /* Reads & writes to the 34010 I/O registers; place at 0xc0000000 */ virtual void io_register_w(offs_t offset, u16 data, u16 mem_mask = ~u16(0)) override; @@ -998,7 +998,7 @@ DECLARE_DEVICE_TYPE(TMS34010, tms34010_device) class tms34020_device : public tms340x0_device { public: - tms34020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms34020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); /* Reads & writes to the 34020 I/O registers; place at 0xc0000000 */ virtual void io_register_w(offs_t offset, u16 data, u16 mem_mask = ~u16(0)) override; diff --git a/src/devices/cpu/tms57002/tms57002.cpp b/src/devices/cpu/tms57002/tms57002.cpp index e137a6b2efd..d3d091753b6 100644 --- a/src/devices/cpu/tms57002/tms57002.cpp +++ b/src/devices/cpu/tms57002/tms57002.cpp @@ -20,7 +20,7 @@ void tms57002_device::internal_pgm(address_map &map) map(0x00, 0xff).ram(); } -tms57002_device::tms57002_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tms57002_device::tms57002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, TMS57002, tag, owner, clock) , device_sound_interface(mconfig, *this) , macc(0), macc_read(0), macc_write(0), st0(0), st1(0), sti(0), txrd(0) diff --git a/src/devices/cpu/tms57002/tms57002.h b/src/devices/cpu/tms57002/tms57002.h index 12bcd732120..03b2fecd0bc 100644 --- a/src/devices/cpu/tms57002/tms57002.h +++ b/src/devices/cpu/tms57002/tms57002.h @@ -15,7 +15,7 @@ class tms57002_device : public cpu_device, public device_sound_interface { public: - tms57002_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms57002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto dready_callback() { return m_dready_callback.bind(); } auto pc0_callback() { return m_pc0_callback.bind(); } diff --git a/src/devices/cpu/tms7000/tms7000.cpp b/src/devices/cpu/tms7000/tms7000.cpp index 3ce6f001ca2..57e88914f61 100644 --- a/src/devices/cpu/tms7000/tms7000.cpp +++ b/src/devices/cpu/tms7000/tms7000.cpp @@ -111,12 +111,12 @@ void tms70c46_device::tms70c46_mem(address_map &map) // device definitions -tms7000_device::tms7000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms7000_device::tms7000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS7000, tag, owner, clock, address_map_constructor(FUNC(tms7000_device::tms7000_mem), this), 0) { } -tms7000_device::tms7000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal, uint32_t info_flags) : +tms7000_device::tms7000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal, uint32_t info_flags) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_BIG, 8, 16, 0, internal), m_port_in_cb(*this), @@ -126,57 +126,57 @@ tms7000_device::tms7000_device(const machine_config &mconfig, device_type type, { } -tms7020_device::tms7020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms7020_device::tms7020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS7020, tag, owner, clock, address_map_constructor(FUNC(tms7020_device::tms7020_mem), this), 0) { } -tms7020_exl_device::tms7020_exl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms7020_exl_device::tms7020_exl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS7020_EXL, tag, owner, clock, address_map_constructor(FUNC(tms7020_exl_device::tms7020_mem), this), 0) { } -tms7040_device::tms7040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms7040_device::tms7040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS7040, tag, owner, clock, address_map_constructor(FUNC(tms7040_device::tms7040_mem), this), 0) { } -tms70c00_device::tms70c00_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms70c00_device::tms70c00_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS70C00, tag, owner, clock, address_map_constructor(FUNC(tms70c00_device::tms7000_mem), this), CHIP_IS_CMOS) { } -tms70c20_device::tms70c20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms70c20_device::tms70c20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS70C20, tag, owner, clock, address_map_constructor(FUNC(tms70c20_device::tms7020_mem), this), CHIP_IS_CMOS) { } -tms70c40_device::tms70c40_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms70c40_device::tms70c40_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS70C40, tag, owner, clock, address_map_constructor(FUNC(tms70c40_device::tms7040_mem), this), CHIP_IS_CMOS) { } -tms7001_device::tms7001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms7001_device::tms7001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS7001, tag, owner, clock, address_map_constructor(FUNC(tms7001_device::tms7001_mem), this), CHIP_FAMILY_70X2) { } -tms7041_device::tms7041_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms7041_device::tms7041_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS7041, tag, owner, clock, address_map_constructor(FUNC(tms7041_device::tms7041_mem), this), CHIP_FAMILY_70X2) { } -tms7002_device::tms7002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms7002_device::tms7002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS7002, tag, owner, clock, address_map_constructor(FUNC(tms7002_device::tms7002_mem), this), CHIP_FAMILY_70X2) { } -tms7042_device::tms7042_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms7042_device::tms7042_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS7042, tag, owner, clock, address_map_constructor(FUNC(tms7042_device::tms7042_mem), this), CHIP_FAMILY_70X2) { } -tms70c46_device::tms70c46_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms70c46_device::tms70c46_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms7000_device(mconfig, TMS70C46, tag, owner, clock, address_map_constructor(FUNC(tms70c46_device::tms70c46_mem), this), CHIP_IS_CMOS) { } diff --git a/src/devices/cpu/tms7000/tms7000.h b/src/devices/cpu/tms7000/tms7000.h index 8d623f5c725..29d93839363 100644 --- a/src/devices/cpu/tms7000/tms7000.h +++ b/src/devices/cpu/tms7000/tms7000.h @@ -25,7 +25,7 @@ class tms7000_device : public cpu_device { public: // construction/destruction - tms7000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms7000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // read-only on 70x0 auto in_porta() { return m_port_in_cb[0].bind(); } @@ -75,7 +75,7 @@ protected: static constexpr uint32_t CHIP_FAMILY_70CX2 = 0x04; static constexpr uint32_t CHIP_FAMILY_MASK = 0x06; - tms7000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal, uint32_t info_flags); + tms7000_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal, uint32_t info_flags); // device-level overrides virtual void device_start() override; @@ -275,14 +275,14 @@ protected: class tms7020_device : public tms7000_device { public: - tms7020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms7020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms7020_exl_device : public tms7000_device { public: - tms7020_exl_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms7020_exl_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void execute_one(uint8_t op) override; @@ -295,35 +295,35 @@ private: class tms7040_device : public tms7000_device { public: - tms7040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms7040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms70c00_device : public tms7000_device { public: - tms70c00_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms70c00_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms70c20_device : public tms7000_device { public: - tms70c20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms70c20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms70c40_device : public tms7000_device { public: - tms70c40_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms70c40_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms70c46_device : public tms7000_device { public: - tms70c46_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms70c46_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t control_r(); void control_w(uint8_t data); @@ -351,28 +351,28 @@ private: class tms7001_device : public tms7000_device { public: - tms7001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms7001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms7041_device : public tms7000_device { public: - tms7041_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms7041_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms7002_device : public tms7000_device { public: - tms7002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms7002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms7042_device : public tms7000_device { public: - tms7042_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms7042_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/tms9900/ti990_10.cpp b/src/devices/cpu/tms9900/ti990_10.cpp index 99cf65dfb0b..18ac7da0b32 100644 --- a/src/devices/cpu/tms9900/ti990_10.cpp +++ b/src/devices/cpu/tms9900/ti990_10.cpp @@ -43,7 +43,7 @@ twice their number. Accordingly, the TMS9900 has a CRU bitmask 0x0fff. ****************************************************************************/ -ti990_10_device::ti990_10_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ti990_10_device::ti990_10_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, TI990_10, tag, owner, clock), m_program_config("program", ENDIANNESS_BIG, 16, 21), m_io_config("cru", ENDIANNESS_BIG, 8, 12), diff --git a/src/devices/cpu/tms9900/ti990_10.h b/src/devices/cpu/tms9900/ti990_10.h index 93d3ecec4a0..3f0587af544 100644 --- a/src/devices/cpu/tms9900/ti990_10.h +++ b/src/devices/cpu/tms9900/ti990_10.h @@ -16,7 +16,7 @@ class ti990_10_device : public cpu_device { public: - ti990_10_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ti990_10_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~ti990_10_device(); protected: diff --git a/src/devices/cpu/tms9900/tms9900.cpp b/src/devices/cpu/tms9900/tms9900.cpp index 6f9ef5f7926..eeeb15150a4 100644 --- a/src/devices/cpu/tms9900/tms9900.cpp +++ b/src/devices/cpu/tms9900/tms9900.cpp @@ -156,7 +156,7 @@ enum twice their number. Accordingly, the TMS9900 has a CRU bitmask 0x0fff. ****************************************************************************/ -tms99xx_device::tms99xx_device(const machine_config &mconfig, device_type type, const char *tag, int data_width, int prg_addr_bits, int cru_addr_bits, device_t *owner, uint32_t clock) +tms99xx_device::tms99xx_device(const machine_config &mconfig, device_type type, const char *tag, int data_width, int prg_addr_bits, int cru_addr_bits, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_BIG, data_width, prg_addr_bits), m_setaddress_config("setaddress", ENDIANNESS_BIG, data_width, prg_addr_bits), // choose the same width as the program space @@ -185,7 +185,7 @@ tms99xx_device::~tms99xx_device() Constructor for TMS9900 ****************************************************************************/ -tms9900_device::tms9900_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9900_device::tms9900_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms99xx_device(mconfig, TMS9900, tag, 16, 16, 12, owner, clock) { } diff --git a/src/devices/cpu/tms9900/tms9900.h b/src/devices/cpu/tms9900/tms9900.h index 1be5e10f679..5d7e094d48d 100644 --- a/src/devices/cpu/tms9900/tms9900.h +++ b/src/devices/cpu/tms9900/tms9900.h @@ -64,7 +64,7 @@ public: protected: tms99xx_device(const machine_config &mconfig, device_type type, const char *tag, int data_width, int prg_addr_bits, int cru_addr_bits, - device_t *owner, uint32_t clock); + device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -386,7 +386,7 @@ private: class tms9900_device : public tms99xx_device { public: - tms9900_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9900_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/tms9900/tms9980a.cpp b/src/devices/cpu/tms9900/tms9980a.cpp index d30dda66ae2..91cb8750481 100644 --- a/src/devices/cpu/tms9900/tms9980a.cpp +++ b/src/devices/cpu/tms9900/tms9980a.cpp @@ -80,17 +80,17 @@ /**************************************************************************** Constructor ****************************************************************************/ -tms9980a_device::tms9980a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +tms9980a_device::tms9980a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : tms99xx_device(mconfig, type, tag, 8, 14, 11, owner, clock) { } -tms9980a_device::tms9980a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9980a_device::tms9980a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9980a_device(mconfig, TMS9980A, tag, owner, clock) { } -tms9981_device::tms9981_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9981_device::tms9981_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9980a_device(mconfig, TMS9981, tag, owner, clock) { } diff --git a/src/devices/cpu/tms9900/tms9980a.h b/src/devices/cpu/tms9900/tms9980a.h index 9210007a5ec..88e35eb0693 100644 --- a/src/devices/cpu/tms9900/tms9980a.h +++ b/src/devices/cpu/tms9900/tms9980a.h @@ -26,10 +26,10 @@ enum class tms9980a_device : public tms99xx_device { public: - tms9980a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9980a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - tms9980a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + tms9980a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void mem_read(void) override; void mem_write(void) override; @@ -58,7 +58,7 @@ protected: class tms9981_device : public tms9980a_device { public: - tms9981_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9981_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/cpu/tms9900/tms9995.cpp b/src/devices/cpu/tms9900/tms9995.cpp index c1b07bcbc70..103d78186a5 100644 --- a/src/devices/cpu/tms9900/tms9995.cpp +++ b/src/devices/cpu/tms9900/tms9995.cpp @@ -157,13 +157,13 @@ constexpr int tms9995_device::AS_SETADDRESS; Constructor ****************************************************************************/ -tms9995_device::tms9995_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9995_device::tms9995_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9995_device(mconfig, TMS9995, tag, owner, clock) { m_mp9537 = false; } -tms9995_device::tms9995_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +tms9995_device::tms9995_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock), m_state_any(0), PC(0), diff --git a/src/devices/cpu/tms9900/tms9995.h b/src/devices/cpu/tms9900/tms9995.h index 8022ca74459..7eb767d4b4e 100644 --- a/src/devices/cpu/tms9900/tms9995.h +++ b/src/devices/cpu/tms9900/tms9995.h @@ -31,7 +31,7 @@ class tms9995_device : public cpu_device public: static constexpr int AS_SETADDRESS = 4; - tms9995_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9995_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // READY input line. When asserted (high), the memory is ready for data exchange. // We chose to use a direct method instead of a delegate to keep performance @@ -60,7 +60,7 @@ public: void set_overflow_interrupt( int enable ) { m_check_overflow = (enable!=0); } protected: - tms9995_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + tms9995_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -410,7 +410,7 @@ private: class tms9995_mp9537_device : public tms9995_device { public: - tms9995_mp9537_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + tms9995_mp9537_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9995_device(mconfig, TMS9995_MP9537, tag, owner, clock) { m_mp9537 = true; diff --git a/src/devices/cpu/tx0/tx0.cpp b/src/devices/cpu/tx0/tx0.cpp index 2a7b0c3775b..7add2254e58 100644 --- a/src/devices/cpu/tx0/tx0.cpp +++ b/src/devices/cpu/tx0/tx0.cpp @@ -46,7 +46,7 @@ DEFINE_DEVICE_TYPE(TX0_8KW_OLD, tx0_8kwo_device, "tx0_8kwo_cpu", "MIT Lincoln La DEFINE_DEVICE_TYPE(TX0_64KW, tx0_64kw_device, "tx0_64kw_cpu", "MIT Lincoln Laboratory TX-0 64KW") -tx0_device::tx0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int addr_bits, int address_mask, int ir_mask) +tx0_device::tx0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addr_bits, int address_mask, int ir_mask) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 32, addr_bits , -2), m_mbr(0), m_ac(0), m_mar(0), m_pc(0), m_ir(0), m_lr(0), m_xr(0), m_pf(0), m_tbr(0), m_tac(0), m_cm_sel(0) , m_lr_sel(0), m_gbl_cm_sel(0), m_stop_cyc0(0), m_stop_cyc1(0), m_run(0), m_rim(0), m_cycle(0), m_ioh(0), m_ios(0), m_rim_step(0) @@ -66,23 +66,23 @@ tx0_device::tx0_device(const machine_config &mconfig, device_type type, const ch m_program_config.m_is_octal = true; } -tx0_8kw_device::tx0_8kw_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +tx0_8kw_device::tx0_8kw_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : tx0_device(mconfig, type, tag, owner, clock, 13, ADDRESS_MASK_8KW, 037) { } -tx0_8kw_device::tx0_8kw_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tx0_8kw_device::tx0_8kw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tx0_8kw_device(mconfig, TX0_8KW, tag, owner, clock) { } -tx0_8kwo_device::tx0_8kwo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tx0_8kwo_device::tx0_8kwo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tx0_8kw_device(mconfig, TX0_8KW_OLD, tag, owner, clock) { } -tx0_64kw_device::tx0_64kw_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tx0_64kw_device::tx0_64kw_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tx0_device(mconfig, TX0_64KW, tag, owner, clock, 16, ADDRESS_MASK_64KW, 03) { } diff --git a/src/devices/cpu/tx0/tx0.h b/src/devices/cpu/tx0/tx0.h index 8c57c08e8f7..0ff15127e44 100644 --- a/src/devices/cpu/tx0/tx0.h +++ b/src/devices/cpu/tx0/tx0.h @@ -41,7 +41,7 @@ public: protected: // construction/destruction - tx0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int addr_bits, int address_mask, int ir_mask); + tx0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addr_bits, int address_mask, int ir_mask); // device-level overrides virtual void device_start() override; @@ -133,7 +133,7 @@ public: tx0_8kw_device(const machine_config &mconfig, const char *_tag, device_t *_owner, uint32_t _clock); protected: - tx0_8kw_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + tx0_8kw_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void execute_run() override; virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; diff --git a/src/devices/cpu/ucom4/ucom4.cpp b/src/devices/cpu/ucom4/ucom4.cpp index ade42ba1e12..45c9575cce1 100644 --- a/src/devices/cpu/ucom4/ucom4.cpp +++ b/src/devices/cpu/ucom4/ucom4.cpp @@ -64,7 +64,7 @@ void ucom4_cpu_device::data_96x4(address_map &map) // device definitions -ucom4_cpu_device::ucom4_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int family, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) +ucom4_cpu_device::ucom4_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int family, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, prgwidth, 0, program) , m_data_config("data", ENDIANNESS_BIG, 8, datawidth, 0, data) @@ -86,27 +86,27 @@ ucom4_cpu_device::ucom4_cpu_device(const machine_config &mconfig, device_type ty { } -upd546_cpu_device::upd546_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd546_cpu_device::upd546_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ucom4_cpu_device(mconfig, NEC_D546, tag, owner, clock, NEC_UCOM43, 3 /* stack levels */, 11 /* prg width */, address_map_constructor(FUNC(upd546_cpu_device::program_2k), this), 7 /* data width */, address_map_constructor(FUNC(upd546_cpu_device::data_96x4), this)) { } -upd553_cpu_device::upd553_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd553_cpu_device::upd553_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ucom4_cpu_device(mconfig, NEC_D553, tag, owner, clock, NEC_UCOM43, 3, 11, address_map_constructor(FUNC(upd553_cpu_device::program_2k), this), 7, address_map_constructor(FUNC(upd553_cpu_device::data_96x4), this)) { } -upd557l_cpu_device::upd557l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd557l_cpu_device::upd557l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ucom4_cpu_device(mconfig, NEC_D557L, tag, owner, clock, NEC_UCOM43, 3, 11, address_map_constructor(FUNC(upd557l_cpu_device::program_2k), this), 7, address_map_constructor(FUNC(upd557l_cpu_device::data_96x4), this)) { } -upd650_cpu_device::upd650_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd650_cpu_device::upd650_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ucom4_cpu_device(mconfig, NEC_D650, tag, owner, clock, NEC_UCOM43, 3, 11, address_map_constructor(FUNC(upd650_cpu_device::program_2k), this), 7, address_map_constructor(FUNC(upd650_cpu_device::data_96x4), this)) { } -upd552_cpu_device::upd552_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd552_cpu_device::upd552_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ucom4_cpu_device(mconfig, NEC_D552, tag, owner, clock, NEC_UCOM44, 1, 10, address_map_constructor(FUNC(upd552_cpu_device::program_1k), this), 6, address_map_constructor(FUNC(upd552_cpu_device::data_64x4), this)) { } diff --git a/src/devices/cpu/ucom4/ucom4.h b/src/devices/cpu/ucom4/ucom4.h index 29b766b5cd4..5111c8a0880 100644 --- a/src/devices/cpu/ucom4/ucom4.h +++ b/src/devices/cpu/ucom4/ucom4.h @@ -81,7 +81,7 @@ protected: }; // construction/destruction - ucom4_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int family, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); + ucom4_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int family, int stack_levels, int prgwidth, address_map_constructor program, int datawidth, address_map_constructor data); // device-level overrides virtual void device_start() override; @@ -269,21 +269,21 @@ protected: class upd546_cpu_device : public ucom4_cpu_device { public: - upd546_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd546_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class upd553_cpu_device : public ucom4_cpu_device { public: - upd553_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd553_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class upd557l_cpu_device : public ucom4_cpu_device { public: - upd557l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd557l_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual u8 input_r(int index) override; @@ -294,14 +294,14 @@ protected: class upd650_cpu_device : public ucom4_cpu_device { public: - upd650_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd650_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class upd552_cpu_device : public ucom4_cpu_device { public: - upd552_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd552_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/unsp/unsp.cpp b/src/devices/cpu/unsp/unsp.cpp index f0c0b929454..76b871bfd40 100644 --- a/src/devices/cpu/unsp/unsp.cpp +++ b/src/devices/cpu/unsp/unsp.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(UNSP_20, unsp_20_device, "unsp_20", "SunPlus u'nSP (ISA 2.0)" /* size of the execution code cache */ #define CACHE_SIZE (64 * 1024 * 1024) -unsp_device::unsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal) +unsp_device::unsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal) : cpu_device(mconfig, type, tag, owner, clock) , m_core(nullptr) , m_program_config("program", ENDIANNESS_BIG, 16, 23, -1, internal) @@ -63,21 +63,21 @@ unsp_device::unsp_device(const machine_config &mconfig, device_type type, const m_numregs = 8; } -unsp_device::unsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +unsp_device::unsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : unsp_device(mconfig, UNSP, tag, owner, clock, address_map_constructor()) { m_iso = 10; m_numregs = 8; } -unsp_11_device::unsp_11_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +unsp_11_device::unsp_11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : unsp_device(mconfig, UNSP_11, tag, owner, clock, address_map_constructor()) { m_iso = 11; m_numregs = 8; } -unsp_11_device::unsp_11_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal) +unsp_11_device::unsp_11_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal) : unsp_device(mconfig, type, tag, owner, clock, internal) { m_iso = 11; @@ -85,28 +85,28 @@ unsp_11_device::unsp_11_device(const machine_config &mconfig, device_type type, } -unsp_12_device::unsp_12_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +unsp_12_device::unsp_12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : unsp_11_device(mconfig, UNSP_12, tag, owner, clock, address_map_constructor()) { m_iso = 12; m_numregs = 8; } -unsp_12_device::unsp_12_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal) +unsp_12_device::unsp_12_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal) : unsp_11_device(mconfig, type, tag, owner, clock, internal) { m_iso = 12; m_numregs = 8; } -unsp_20_device::unsp_20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +unsp_20_device::unsp_20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : unsp_12_device(mconfig, UNSP_20, tag, owner, clock, address_map_constructor()) { m_iso = 20; m_numregs = 16; } -unsp_20_device::unsp_20_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal) +unsp_20_device::unsp_20_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal) : unsp_12_device(mconfig, type, tag, owner, clock, internal) { m_iso = 20; diff --git a/src/devices/cpu/unsp/unsp.h b/src/devices/cpu/unsp/unsp.h index 010720adeec..6e6c6542be5 100644 --- a/src/devices/cpu/unsp/unsp.h +++ b/src/devices/cpu/unsp/unsp.h @@ -96,7 +96,7 @@ class unsp_device : public cpu_device public: // construction/destruction - unsp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + unsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~unsp_device(); void set_vectorbase(uint16_t vector) { m_vectorbase = vector; } @@ -121,7 +121,7 @@ public: void cfunc_muls(); protected: - unsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal); + unsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal); // device-level overrides virtual void device_start() override; @@ -358,10 +358,10 @@ class unsp_11_device : public unsp_device { public: // construction/destruction - unsp_11_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + unsp_11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - unsp_11_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal); + unsp_11_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal); private: }; @@ -370,10 +370,10 @@ class unsp_12_device : public unsp_11_device { public: // construction/destruction - unsp_12_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + unsp_12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - unsp_12_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal); + unsp_12_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal); virtual void execute_fxxx_101_group(uint16_t op) override; virtual void execute_exxx_group(uint16_t op) override; @@ -387,10 +387,10 @@ class unsp_20_device : public unsp_12_device { public: // construction/destruction - unsp_20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + unsp_20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - unsp_20_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal); + unsp_20_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal); virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; virtual void execute_extended_group(uint16_t op) override; diff --git a/src/devices/cpu/upd7725/upd7725.cpp b/src/devices/cpu/upd7725/upd7725.cpp index 51c2faf3b6a..09bf25cc21b 100644 --- a/src/devices/cpu/upd7725/upd7725.cpp +++ b/src/devices/cpu/upd7725/upd7725.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(UPD7725, upd7725_device, "upd7725", "NEC uPD7725") DEFINE_DEVICE_TYPE(UPD96050, upd96050_device, "upd96050", "NEC uPD96050") -necdsp_device::necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t abits, uint32_t dbits) +necdsp_device::necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t abits, uint32_t dbits) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_BIG, 32, abits, -2), // data bus width, address bus width, -2 means DWORD-addressable m_data_config("data", ENDIANNESS_BIG, 16, dbits, -1), m_icount(0), // -1 for WORD-addressable @@ -45,12 +45,12 @@ necdsp_device::necdsp_device(const machine_config &mconfig, device_type type, co } -upd7725_device::upd7725_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd7725_device::upd7725_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : necdsp_device(mconfig, UPD7725, tag, owner, clock, 11, 11) { } -upd96050_device::upd96050_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd96050_device::upd96050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : necdsp_device(mconfig, UPD96050, tag, owner, clock, 14, 12) { } diff --git a/src/devices/cpu/upd7725/upd7725.h b/src/devices/cpu/upd7725/upd7725.h index ed17af002eb..fcd5fe8d473 100644 --- a/src/devices/cpu/upd7725/upd7725.h +++ b/src/devices/cpu/upd7725/upd7725.h @@ -41,7 +41,7 @@ public: protected: // construction/destruction - necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t abits, uint32_t dbits); + necdsp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t abits, uint32_t dbits); // device-level overrides virtual void device_start() override; @@ -166,14 +166,14 @@ class upd7725_device : public necdsp_device { public: // construction/destruction - upd7725_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7725_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class upd96050_device : public necdsp_device { public: // construction/destruction - upd96050_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd96050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t dataram_r(uint16_t addr) { return dataRAM[addr]; } void dataram_w(uint16_t addr, uint16_t data) { dataRAM[addr] = data; } diff --git a/src/devices/cpu/upd7810/upd7810.cpp b/src/devices/cpu/upd7810/upd7810.cpp index 929070e61fc..8569fa4ab04 100644 --- a/src/devices/cpu/upd7810/upd7810.cpp +++ b/src/devices/cpu/upd7810/upd7810.cpp @@ -404,7 +404,7 @@ void upd7810_device::upd_internal_4096_rom_256_ram_map(address_map &map) map(0xff00, 0xffff).ram(); } -upd7810_device::upd7810_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map) +upd7810_device::upd7810_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map) : cpu_device(mconfig, type, tag, owner, clock) , m_to_func(*this) , m_co0_func(*this) @@ -444,17 +444,17 @@ void upd7810_device::configure_ops() m_op74 = s_op74; } -upd7810_device::upd7810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd7810_device::upd7810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd7810_device(mconfig, UPD7810, tag, owner, clock, address_map_constructor(FUNC(upd7810_device::upd_internal_256_ram_map), this)) { } -upd78c10_device::upd78c10_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map) +upd78c10_device::upd78c10_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map) : upd7810_device(mconfig, type, tag, owner, clock, internal_map) { } -upd78c10_device::upd78c10_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd78c10_device::upd78c10_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd78c10_device(mconfig, UPD78C10, tag, owner, clock, address_map_constructor(FUNC(upd78c10_device::upd_internal_256_ram_map), this)) { } @@ -472,7 +472,7 @@ void upd7807_device::configure_ops() } -upd7807_device::upd7807_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd7807_device::upd7807_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd7810_device(mconfig, UPD7807, tag, owner, clock, address_map_constructor(FUNC(upd7807_device::upd_internal_256_ram_map), this)) { } @@ -489,7 +489,7 @@ void upd7801_device::configure_ops() m_opXX = s_opXX_7801; } -upd7801_device::upd7801_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd7801_device::upd7801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd7810_device(mconfig, UPD7801, tag, owner, clock, address_map_constructor(FUNC(upd7801_device::upd_internal_128_ram_map), this)) { } @@ -506,12 +506,12 @@ void upd78c05_device::configure_ops() m_opXX = s_opXX_78c05; } -upd78c05_device::upd78c05_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map) +upd78c05_device::upd78c05_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map) : upd7810_device(mconfig, type, tag, owner, clock, internal_map) { } -upd78c05_device::upd78c05_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd78c05_device::upd78c05_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd78c05_device(mconfig, UPD78C05, tag, owner, clock, address_map_constructor(FUNC(upd78c05_device::upd_internal_128_ram_map), this)) { } @@ -528,7 +528,7 @@ void upd78c06_device::configure_ops() m_opXX = s_opXX_78c06; } -upd78c06_device::upd78c06_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd78c06_device::upd78c06_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd78c05_device(mconfig, UPD78C06, tag, owner, clock, address_map_constructor(FUNC(upd78c06_device::upd_internal_4096_rom_128_ram_map), this)) { } diff --git a/src/devices/cpu/upd7810/upd7810.h b/src/devices/cpu/upd7810/upd7810.h index 40e4b89ff87..0f21e429311 100644 --- a/src/devices/cpu/upd7810/upd7810.h +++ b/src/devices/cpu/upd7810/upd7810.h @@ -41,7 +41,7 @@ class upd7810_device : public cpu_device { public: // construction/destruction - upd7810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto to_func() { return m_to_func.bind(); } @@ -131,7 +131,7 @@ protected: INTSB = 0x0010 }; - upd7810_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map); + upd7810_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map); // device-level overrides virtual void device_start() override; @@ -1356,10 +1356,10 @@ class upd78c10_device : public upd7810_device { public: // construction/destruction - upd78c10_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd78c10_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - upd78c10_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map); + upd78c10_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map); }; @@ -1367,7 +1367,7 @@ class upd7807_device : public upd7810_device { public: // construction/destruction - upd7807_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7807_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -1379,7 +1379,7 @@ class upd7801_device : public upd7810_device { public: // construction/destruction - upd7801_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; @@ -1397,10 +1397,10 @@ class upd78c05_device : public upd7810_device { public: // construction/destruction - upd78c05_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd78c05_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - upd78c05_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal_map); + upd78c05_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal_map); virtual void device_start() override; virtual void device_reset() override; @@ -1416,7 +1416,7 @@ class upd78c06_device : public upd78c05_device { public: // construction/destruction - upd78c06_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd78c06_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void configure_ops() override; }; diff --git a/src/devices/cpu/upd7810/upd7811.cpp b/src/devices/cpu/upd7810/upd7811.cpp index e5105e4f9b7..9da7d65f72c 100644 --- a/src/devices/cpu/upd7810/upd7811.cpp +++ b/src/devices/cpu/upd7810/upd7811.cpp @@ -26,12 +26,12 @@ DEFINE_DEVICE_TYPE(UPD7811, upd7811_device, "upd7811", "NEC uPD7811") DEFINE_DEVICE_TYPE(UPD78C11, upd78c11_device, "upd78c11", "NEC uPD78C11") -upd7811_device::upd7811_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd7811_device::upd7811_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd7810_device(mconfig, UPD7811, tag, owner, clock, address_map_constructor(FUNC(upd7811_device::upd_internal_4096_rom_256_ram_map), this)) { } -upd78c11_device::upd78c11_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd78c11_device::upd78c11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd78c10_device(mconfig, UPD78C11, tag, owner, clock, address_map_constructor(FUNC(upd78c11_device::upd_internal_4096_rom_256_ram_map), this)) { } diff --git a/src/devices/cpu/upd7810/upd7811.h b/src/devices/cpu/upd7810/upd7811.h index 2d98f64da5f..bac8854a871 100644 --- a/src/devices/cpu/upd7810/upd7811.h +++ b/src/devices/cpu/upd7810/upd7811.h @@ -15,14 +15,14 @@ class upd7811_device : public upd7810_device { public: // construction/destruction - upd7811_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7811_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class upd78c11_device : public upd78c10_device { public: // construction/destruction - upd78c11_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd78c11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; #endif // MAME_CPU_UPD7810_UPD7811_H diff --git a/src/devices/cpu/upd78k/upd78k0.cpp b/src/devices/cpu/upd78k/upd78k0.cpp index f1f48402226..b909b681a35 100644 --- a/src/devices/cpu/upd78k/upd78k0.cpp +++ b/src/devices/cpu/upd78k/upd78k0.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(UPD78053, upd78053_device, "upd78053", "NEC uPD78053") // upd78k0_device - constructor //------------------------------------------------- -upd78k0_device::upd78k0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 iram_size, address_map_constructor mem_map, address_map_constructor sfr_map) +upd78k0_device::upd78k0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 iram_size, address_map_constructor mem_map, address_map_constructor sfr_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0, mem_map) , m_iram_config("iram", ENDIANNESS_LITTLE, 16, iram_size > 0x200 ? 10 : iram_size > 0x100 ? 9 : 8, 0, @@ -192,7 +192,7 @@ void upd78k0_device::state_string_export(const device_state_entry &entry, std::s // upd78053_device - constructor //------------------------------------------------- -upd78053_device::upd78053_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd78053_device::upd78053_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd78k0_device(mconfig, UPD78053, tag, owner, clock, 0x400, address_map_constructor(FUNC(upd78053_device::mem_map), this), address_map_constructor(FUNC(upd78053_device::sfr_map), this)) diff --git a/src/devices/cpu/upd78k/upd78k0.h b/src/devices/cpu/upd78k/upd78k0.h index 566dfab340f..7fb6feb8597 100644 --- a/src/devices/cpu/upd78k/upd78k0.h +++ b/src/devices/cpu/upd78k/upd78k0.h @@ -29,11 +29,11 @@ public: }; // configuration (TODO: callbacks) - void set_subclock(u32 clock) { m_subclock = clock; } + void set_subclock(const XTAL &clock) { m_subclock = clock; } void set_subclock(const XTAL &xtal) { m_subclock = xtal.value(); } protected: - upd78k0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u16 iram_size, address_map_constructor mem_map, address_map_constructor sfr_map); + upd78k0_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u16 iram_size, address_map_constructor mem_map, address_map_constructor sfr_map); // device-level overrides virtual void device_start() override; @@ -83,9 +83,9 @@ class upd78053_device : public upd78k0_device { public: // device type constructors - upd78053_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd78053_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename X> - upd78053_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, X &&subclock) + upd78053_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, X &&subclock) : upd78053_device(mconfig, tag, owner, clock) { set_subclock(std::forward<X>(subclock)); diff --git a/src/devices/cpu/upd78k/upd78k2.cpp b/src/devices/cpu/upd78k/upd78k2.cpp index b8c784e20e8..5915b057698 100644 --- a/src/devices/cpu/upd78k/upd78k2.cpp +++ b/src/devices/cpu/upd78k/upd78k2.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(UPD78213, upd78213_device, "upd78213", "NEC uPD78213") // upd78k2_device - constructor //------------------------------------------------- -upd78k2_device::upd78k2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int iram_bits, address_map_constructor mem_map, address_map_constructor sfr_map) +upd78k2_device::upd78k2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int iram_bits, address_map_constructor mem_map, address_map_constructor sfr_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 20, 0, mem_map) , m_iram_config("iram", ENDIANNESS_LITTLE, 16, iram_bits, 0, address_map_constructor(FUNC(upd78k2_device::iram_map), this)) @@ -175,7 +175,7 @@ void upd78k2_device::state_string_export(const device_state_entry &entry, std::s // upd78210_device - constructor //------------------------------------------------- -upd78210_device::upd78210_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd78210_device::upd78210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd78k2_device(mconfig, UPD78210, tag, owner, clock, 7, address_map_constructor(), address_map_constructor(FUNC(upd78210_device::sfr_map), this)) @@ -207,7 +207,7 @@ void upd78210_device::sfr_map(address_map &map) // upd78213_device - constructor //------------------------------------------------- -upd78213_device::upd78213_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd78213_device::upd78213_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd78k2_device(mconfig, UPD78213, tag, owner, clock, 8, address_map_constructor(FUNC(upd78213_device::mem_map), this), address_map_constructor(FUNC(upd78213_device::sfr_map), this)) diff --git a/src/devices/cpu/upd78k/upd78k2.h b/src/devices/cpu/upd78k/upd78k2.h index c0a8e07b825..f2391873410 100644 --- a/src/devices/cpu/upd78k/upd78k2.h +++ b/src/devices/cpu/upd78k/upd78k2.h @@ -32,7 +32,7 @@ public: // TODO: callbacks and configuration thereof protected: - upd78k2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int iram_bits, address_map_constructor mem_map, address_map_constructor sfr_map); + upd78k2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int iram_bits, address_map_constructor mem_map, address_map_constructor sfr_map); // device-level overrides virtual void device_start() override; @@ -80,7 +80,7 @@ class upd78210_device : public upd78k2_device { public: // device type constructor - upd78210_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd78210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides @@ -97,7 +97,7 @@ class upd78213_device : public upd78k2_device { public: // device type constructor - upd78213_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd78213_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides diff --git a/src/devices/cpu/upd78k/upd78k3.cpp b/src/devices/cpu/upd78k/upd78k3.cpp index e4a4a6daae5..e548bbbc010 100644 --- a/src/devices/cpu/upd78k/upd78k3.cpp +++ b/src/devices/cpu/upd78k/upd78k3.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(UPD78312, upd78312_device, "upd78312", "NEC uPD78312") // upd78k3_device - constructor //------------------------------------------------- -upd78k3_device::upd78k3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor mem_map, address_map_constructor sfr_map) +upd78k3_device::upd78k3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor mem_map, address_map_constructor sfr_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0, mem_map) , m_iram_config("iram", ENDIANNESS_LITTLE, 16, 8, 0, address_map_constructor(FUNC(upd78k3_device::iram_map), this)) @@ -264,12 +264,12 @@ void upd78k3_device::state_string_export(const device_state_entry &entry, std::s // upd78312_device - constructor //------------------------------------------------- -upd78312_device::upd78312_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd78312_device::upd78312_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd78312_device(mconfig, UPD78312, tag, owner, clock, address_map_constructor(FUNC(upd78312_device::mem_map), this)) { } -upd78312_device::upd78312_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map) +upd78312_device::upd78312_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map) : upd78k3_device(mconfig, type, tag, owner, clock, map, address_map_constructor(FUNC(upd78312_device::sfr_map), this)) { @@ -280,7 +280,7 @@ upd78312_device::upd78312_device(const machine_config &mconfig, device_type type // upd78310_device - constructor //------------------------------------------------- -upd78310_device::upd78310_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd78310_device::upd78310_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd78312_device(mconfig, UPD78310, tag, owner, clock, address_map_constructor()) { } diff --git a/src/devices/cpu/upd78k/upd78k3.h b/src/devices/cpu/upd78k/upd78k3.h index 22867376847..e8c2f8002fb 100644 --- a/src/devices/cpu/upd78k/upd78k3.h +++ b/src/devices/cpu/upd78k/upd78k3.h @@ -39,7 +39,7 @@ public: // TODO: callbacks and configuration thereof protected: - upd78k3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor mem_map, address_map_constructor sfr_map); + upd78k3_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor mem_map, address_map_constructor sfr_map); // device-level overrides virtual void device_start() override; @@ -96,10 +96,10 @@ class upd78312_device : public upd78k3_device { public: // device type constructor - upd78312_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd78312_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - upd78312_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor map); + upd78312_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor map); // device_disasm_interface overrides virtual std::unique_ptr<util::disasm_interface> create_disassembler() override; @@ -122,7 +122,7 @@ class upd78310_device : public upd78312_device { public: // device type constructor - upd78310_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd78310_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type declarations diff --git a/src/devices/cpu/upd78k/upd78k4.cpp b/src/devices/cpu/upd78k/upd78k4.cpp index 0aad7b0660a..1ef4438a76d 100644 --- a/src/devices/cpu/upd78k/upd78k4.cpp +++ b/src/devices/cpu/upd78k/upd78k4.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(UPD784031, upd784031_device, "upd784031", "NEC uPD784031") // upd78k4_device - constructor //------------------------------------------------- -upd78k4_device::upd78k4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor mem_map, address_map_constructor sfr_map) +upd78k4_device::upd78k4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor mem_map, address_map_constructor sfr_map) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 20, 0, mem_map) , m_iram_config("iram", ENDIANNESS_LITTLE, 16, 9, 0, address_map_constructor(FUNC(upd78k4_device::iram_map), this)) @@ -234,7 +234,7 @@ void upd78k4_device::state_string_export(const device_state_entry &entry, std::s // upd784031_device - constructor //------------------------------------------------- -upd784031_device::upd784031_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd784031_device::upd784031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd78k4_device(mconfig, UPD784031, tag, owner, clock, address_map_constructor(FUNC(upd784031_device::sfr_map), this), address_map_constructor(FUNC(upd784031_device::sfr_map), this)) diff --git a/src/devices/cpu/upd78k/upd78k4.h b/src/devices/cpu/upd78k/upd78k4.h index 435600b563c..1c2e12830f8 100644 --- a/src/devices/cpu/upd78k/upd78k4.h +++ b/src/devices/cpu/upd78k/upd78k4.h @@ -41,7 +41,7 @@ public: // TODO: callbacks and configuration thereof protected: - upd78k4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor mem_map, address_map_constructor sfr_map); + upd78k4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor mem_map, address_map_constructor sfr_map); // device-level overrides virtual void device_start() override; @@ -92,7 +92,7 @@ class upd784031_device : public upd78k4_device { public: // device type constructor - upd784031_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd784031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides diff --git a/src/devices/cpu/v30mz/v30mz.cpp b/src/devices/cpu/v30mz/v30mz.cpp index 93c7ad1440e..358450e9583 100644 --- a/src/devices/cpu/v30mz/v30mz.cpp +++ b/src/devices/cpu/v30mz/v30mz.cpp @@ -75,7 +75,7 @@ enum nec_irqs { DEFINE_DEVICE_TYPE(V30MZ, v30mz_cpu_device, "v30mz", "NEC V30MZ") -v30mz_cpu_device::v30mz_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v30mz_cpu_device::v30mz_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, V30MZ, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 16, 20, 0) , m_io_config("io", ENDIANNESS_LITTLE, 16, 16, 0) diff --git a/src/devices/cpu/v30mz/v30mz.h b/src/devices/cpu/v30mz/v30mz.h index f194fba269c..e352feb7833 100644 --- a/src/devices/cpu/v30mz/v30mz.h +++ b/src/devices/cpu/v30mz/v30mz.h @@ -22,7 +22,7 @@ class v30mz_cpu_device : public cpu_device, public nec_disassembler::config { public: // construction/destruction - v30mz_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v30mz_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto vector_cb() { return m_vector_func.bind(); } uint32_t pc(); diff --git a/src/devices/cpu/v60/v60.cpp b/src/devices/cpu/v60/v60.cpp index fdce71f6808..e87fc10d999 100644 --- a/src/devices/cpu/v60/v60.cpp +++ b/src/devices/cpu/v60/v60.cpp @@ -83,13 +83,13 @@ DEFINE_DEVICE_TYPE(V70, v70_device, "v70", "NEC V70") // Set m_PIR (Processor ID) for NEC m_ LSB is reserved to NEC, // so I don't know what it contains. -v60_device::v60_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v60_device::v60_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v60_device(mconfig, V60, tag, owner, clock, 16, 24, 0x00006000) { } -v60_device::v60_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int databits, int addrbits, uint32_t pir) +v60_device::v60_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int databits, int addrbits, uint32_t pir) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, databits, addrbits, 0) , m_io_config("io", ENDIANNESS_LITTLE, 16, 24, 0) @@ -100,7 +100,7 @@ v60_device::v60_device(const machine_config &mconfig, device_type type, const ch // Set m_PIR (Processor ID) for NEC v70. LSB is reserved to NEC, // so I don't know what it contains. -v70_device::v70_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v70_device::v70_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v60_device(mconfig, V70, tag, owner, clock, 32, 32, 0x00007000) { } diff --git a/src/devices/cpu/v60/v60.h b/src/devices/cpu/v60/v60.h index d617ec1bd56..4a6bc4dae9c 100644 --- a/src/devices/cpu/v60/v60.h +++ b/src/devices/cpu/v60/v60.h @@ -84,12 +84,12 @@ class v60_device : public cpu_device { public: // construction/destruction - v60_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v60_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void stall(); protected: - v60_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int databits, int addrbits, uint32_t pir); + v60_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int databits, int addrbits, uint32_t pir); // device-level overrides virtual void device_start() override; @@ -785,7 +785,7 @@ class v70_device : public v60_device { public: // construction/destruction - v70_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v70_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/v810/v810.cpp b/src/devices/cpu/v810/v810.cpp index 47a672baf69..c95ffac8262 100644 --- a/src/devices/cpu/v810/v810.cpp +++ b/src/devices/cpu/v810/v810.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(V810, v810_device, "v810", "NEC V810") -v810_device::v810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v810_device::v810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, V810, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 32, 32, 0) , m_io_config("io", ENDIANNESS_LITTLE, 32, 32, 0) diff --git a/src/devices/cpu/v810/v810.h b/src/devices/cpu/v810/v810.h index a24abe48751..7ffe02ef727 100644 --- a/src/devices/cpu/v810/v810.h +++ b/src/devices/cpu/v810/v810.h @@ -83,7 +83,7 @@ class v810_device : public cpu_device { public: // construction/destruction - v810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/vt50/vt50.cpp b/src/devices/cpu/vt50/vt50.cpp index 7a964c4be5b..ecb4c0ae936 100644 --- a/src/devices/cpu/vt50/vt50.cpp +++ b/src/devices/cpu/vt50/vt50.cpp @@ -70,7 +70,7 @@ DEFINE_DEVICE_TYPE(VT50_CPU, vt50_cpu_device, "vt50_cpu", "DEC VT50 CPU") DEFINE_DEVICE_TYPE(VT52_CPU, vt52_cpu_device, "vt52_cpu", "DEC VT52 CPU") -vt5x_cpu_device::vt5x_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int bbits, int ybits) +vt5x_cpu_device::vt5x_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int bbits, int ybits) : cpu_device(mconfig, type, tag, owner, clock) , device_video_interface(mconfig, *this) , m_rom_config("program", ENDIANNESS_LITTLE, 8, 10, 0) @@ -122,12 +122,12 @@ vt5x_cpu_device::vt5x_cpu_device(const machine_config &mconfig, device_type type m_ram_config.m_is_octal = true; } -vt50_cpu_device::vt50_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +vt50_cpu_device::vt50_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vt5x_cpu_device(mconfig, VT50_CPU, tag, owner, clock, 4, 4) { } -vt52_cpu_device::vt52_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +vt52_cpu_device::vt52_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vt5x_cpu_device(mconfig, VT52_CPU, tag, owner, clock, 7, 5) , m_graphic_callback(*this) { diff --git a/src/devices/cpu/vt50/vt50.h b/src/devices/cpu/vt50/vt50.h index e9d0b39b1bc..ac664b1f318 100644 --- a/src/devices/cpu/vt50/vt50.h +++ b/src/devices/cpu/vt50/vt50.h @@ -38,7 +38,7 @@ public: protected: // construction/destruction - vt5x_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int bbits, int ybits); + vt5x_cpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int bbits, int ybits); // device-level overrides virtual void device_config_complete() override; @@ -136,7 +136,7 @@ class vt50_cpu_device : public vt5x_cpu_device { public: // device type constructor - vt50_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + vt50_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_disasm_interface overrides @@ -149,7 +149,7 @@ class vt52_cpu_device : public vt5x_cpu_device { public: // device type constructor - vt52_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + vt52_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto graphic_callback() { return m_graphic_callback.bind(); } diff --git a/src/devices/cpu/vt61/vt61.cpp b/src/devices/cpu/vt61/vt61.cpp index 40a98cae7a8..e406c18596b 100644 --- a/src/devices/cpu/vt61/vt61.cpp +++ b/src/devices/cpu/vt61/vt61.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(VT61_CPU, vt61_cpu_device, "vt61_cpu", "DEC VT61 CPU") ALLOW_SAVE_TYPE(vt61_cpu_device::state); ALLOW_SAVE_TYPE(vt61_cpu_device::pc_mode); -vt61_cpu_device::vt61_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +vt61_cpu_device::vt61_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, VT61_CPU, tag, owner, clock) , m_program_config("microprogram", ENDIANNESS_LITTLE, 16, 10, -1) , m_memory_config("memory", ENDIANNESS_LITTLE, 8, 16, 0) diff --git a/src/devices/cpu/vt61/vt61.h b/src/devices/cpu/vt61/vt61.h index 971343fe095..42372275ad3 100644 --- a/src/devices/cpu/vt61/vt61.h +++ b/src/devices/cpu/vt61/vt61.h @@ -27,7 +27,7 @@ public: }; // construction/destruction - vt61_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + vt61_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/we32000/we32100.cpp b/src/devices/cpu/we32000/we32100.cpp index b7f166e5287..bc843eed413 100644 --- a/src/devices/cpu/we32000/we32100.cpp +++ b/src/devices/cpu/we32000/we32100.cpp @@ -15,7 +15,7 @@ // device type definitions DEFINE_DEVICE_TYPE(WE32100, we32100_device, "we32100", "AT&T WE32100") -we32100_device::we32100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +we32100_device::we32100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, WE32100, tag, owner, clock) , m_space_config("program", ENDIANNESS_BIG, 32, 32, 0) , m_r{0} diff --git a/src/devices/cpu/we32000/we32100.h b/src/devices/cpu/we32000/we32100.h index c34afc4279e..87a0de81c15 100644 --- a/src/devices/cpu/we32000/we32100.h +++ b/src/devices/cpu/we32000/we32100.h @@ -22,7 +22,7 @@ public: }; // construction/destruction - we32100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + we32100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/xavix2/xavix2.cpp b/src/devices/cpu/xavix2/xavix2.cpp index 2f1753b1523..0dc74794862 100644 --- a/src/devices/cpu/xavix2/xavix2.cpp +++ b/src/devices/cpu/xavix2/xavix2.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(XAVIX2, xavix2_device, "xavix2", "Xavix 2 CPU") const u8 xavix2_device::bpo[8] = { 4, 3, 3, 2, 2, 2, 2, 1 }; -xavix2_device::xavix2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +xavix2_device::xavix2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, XAVIX2, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 32, 32) { diff --git a/src/devices/cpu/xavix2/xavix2.h b/src/devices/cpu/xavix2/xavix2.h index 30e9ec5faea..de152204507 100644 --- a/src/devices/cpu/xavix2/xavix2.h +++ b/src/devices/cpu/xavix2/xavix2.h @@ -13,7 +13,7 @@ class xavix2_device : public cpu_device { public: - xavix2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xavix2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: enum { diff --git a/src/devices/cpu/z180/hd647180x.cpp b/src/devices/cpu/z180/hd647180x.cpp index cc70b0781a8..e568245f637 100644 --- a/src/devices/cpu/z180/hd647180x.cpp +++ b/src/devices/cpu/z180/hd647180x.cpp @@ -31,7 +31,7 @@ // device type definition DEFINE_DEVICE_TYPE(HD647180X, hd647180x_device, "hd647180x", "Hitachi HD647180X MCU") -hd647180x_device::hd647180x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd647180x_device::hd647180x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z180_device(mconfig, HD647180X, tag, owner, clock, true, address_map_constructor(FUNC(hd647180x_device::internal_map), this)) , m_port_input_cb(*this) , m_port_output_cb(*this) diff --git a/src/devices/cpu/z180/hd647180x.h b/src/devices/cpu/z180/hd647180x.h index 22d4212b4af..e5d816b2b1e 100644 --- a/src/devices/cpu/z180/hd647180x.h +++ b/src/devices/cpu/z180/hd647180x.h @@ -25,7 +25,7 @@ public: }; // construction/destruction - hd647180x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd647180x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto in_pa_callback() { return m_port_input_cb[0].bind(); } auto in_pb_callback() { return m_port_input_cb[1].bind(); } diff --git a/src/devices/cpu/z180/z180.cpp b/src/devices/cpu/z180/z180.cpp index db7b4a3026b..c70c23c3ce6 100644 --- a/src/devices/cpu/z180/z180.cpp +++ b/src/devices/cpu/z180/z180.cpp @@ -87,7 +87,7 @@ DEFINE_DEVICE_TYPE(Z8S180, z8s180_device, "z8s180", "Zilog Z8S180") // enhanced DEFINE_DEVICE_TYPE(Z80182, z80182_device, "z80182", "Zilog Z80182") // further enhanced Z8S180 -z180_device::z180_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool extended_io, address_map_constructor internal_map) +z180_device::z180_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool extended_io, address_map_constructor internal_map) : cpu_device(mconfig, type, tag, owner, clock) , z80_daisy_chain_interface(mconfig, *this) , m_program_config("program", ENDIANNESS_LITTLE, 8, 20, 0, 16, 12, internal_map) @@ -114,29 +114,29 @@ std::unique_ptr<util::disasm_interface> z180_device::create_disassembler() return std::make_unique<z180_disassembler>(); } -z80180_device::z80180_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z80180_device::z80180_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z180_device(mconfig, Z80180, tag, owner, clock, false, address_map_constructor()) { } -hd64180rp_device::hd64180rp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd64180rp_device::hd64180rp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z180_device(mconfig, HD64180RP, tag, owner, clock, false, address_map_constructor()) { // 64-pin DIP versions omit A19 set_address_width(19); } -z8s180_device::z8s180_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +z8s180_device::z8s180_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : z180_device(mconfig, type, tag, owner, clock, false, address_map_constructor()) { } -z8s180_device::z8s180_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z8s180_device::z8s180_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8s180_device(mconfig, Z8S180, tag, owner, clock) { } -z80182_device::z80182_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z80182_device::z80182_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8s180_device(mconfig, Z80182, tag, owner, clock) { } diff --git a/src/devices/cpu/z180/z180.h b/src/devices/cpu/z180/z180.h index 62213845b05..8ec6d2af297 100644 --- a/src/devices/cpu/z180/z180.h +++ b/src/devices/cpu/z180/z180.h @@ -126,7 +126,7 @@ public: protected: // construction/destruction - z180_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool extended_io, address_map_constructor internal_map); + z180_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool extended_io, address_map_constructor internal_map); // device-level overrides virtual void device_start() override; @@ -1810,24 +1810,24 @@ class z80180_device : public z180_device { public: // construction/destruction - z80180_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80180_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hd64180rp_device : public z180_device { public: // construction/destruction - hd64180rp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd64180rp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class z8s180_device : public z180_device { public: // construction/destruction - z8s180_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z8s180_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - z8s180_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + z8s180_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -1851,7 +1851,7 @@ class z80182_device : public z8s180_device { public: // construction/destruction - z80182_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80182_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(Z80180, z80180_device) diff --git a/src/devices/cpu/z180/z180asci.cpp b/src/devices/cpu/z180/z180asci.cpp index 3abf9683bc8..e4f919f01c5 100644 --- a/src/devices/cpu/z180/z180asci.cpp +++ b/src/devices/cpu/z180/z180asci.cpp @@ -65,7 +65,7 @@ static constexpr u8 Z180_ASEXT1_MASK = 0x1f; // z180asci_channel_base //************************************************************************** -z180asci_channel_base::z180asci_channel_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const int id, const bool ext) +z180asci_channel_base::z180asci_channel_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const int id, const bool ext) : device_t(mconfig, type, tag, owner, clock) , m_rcv_clock(nullptr) , m_tra_clock(nullptr) @@ -580,12 +580,12 @@ void z180asci_channel_base::output_rts(int rts) // z180asci_channel_0 //************************************************************************** -z180asci_channel_0::z180asci_channel_0(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const bool ext) +z180asci_channel_0::z180asci_channel_0(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const bool ext) : z180asci_channel_base(mconfig, type, tag, owner, clock, 0, ext) { } -z180asci_channel_0::z180asci_channel_0(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z180asci_channel_0::z180asci_channel_0(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z180asci_channel_0(mconfig, Z180ASCI_CHANNEL_0, tag, owner, clock, false) { } @@ -629,12 +629,12 @@ void z180asci_channel_0::asext_w(uint8_t data) // z180asci_channel_1 //************************************************************************** -z180asci_channel_1::z180asci_channel_1(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const bool ext) +z180asci_channel_1::z180asci_channel_1(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const bool ext) : z180asci_channel_base(mconfig, type, tag, owner, clock, 1, ext) { } -z180asci_channel_1::z180asci_channel_1(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z180asci_channel_1::z180asci_channel_1(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z180asci_channel_1(mconfig, Z180ASCI_CHANNEL_1, tag, owner, clock, false) { } @@ -677,7 +677,7 @@ void z180asci_channel_1::asext_w(uint8_t data) // z180asci_ext_channel_0 //************************************************************************** -z180asci_ext_channel_0::z180asci_ext_channel_0(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z180asci_ext_channel_0::z180asci_ext_channel_0(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z180asci_channel_0(mconfig, Z180ASCI_EXT_CHANNEL_0, tag, owner, clock, true) { } @@ -686,7 +686,7 @@ z180asci_ext_channel_0::z180asci_ext_channel_0(const machine_config &mconfig, co // z180asci_channel_1 //************************************************************************** -z180asci_ext_channel_1::z180asci_ext_channel_1(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z180asci_ext_channel_1::z180asci_ext_channel_1(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z180asci_channel_1(mconfig, Z180ASCI_EXT_CHANNEL_1, tag, owner, clock, true) { } diff --git a/src/devices/cpu/z180/z180asci.h b/src/devices/cpu/z180/z180asci.h index 3794fe635a8..975297cce8f 100644 --- a/src/devices/cpu/z180/z180asci.h +++ b/src/devices/cpu/z180/z180asci.h @@ -50,7 +50,7 @@ public: int check_interrupt() { return m_irq; } void clear_interrupt() { m_irq = 0; } protected: - z180asci_channel_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const int id, const bool ext); + z180asci_channel_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const int id, const bool ext); // device-level overrides virtual void device_start() override; @@ -136,13 +136,13 @@ class z180asci_channel_0 : public z180asci_channel_base { public: // construction/destruction - z180asci_channel_0(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z180asci_channel_0(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void stat_w(uint8_t data) override; void asext_w(uint8_t data) override; void state_add(device_state_interface &parent) override; protected: - z180asci_channel_0(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const bool ext); + z180asci_channel_0(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const bool ext); // device-level overrides virtual void device_reset() override; }; @@ -155,13 +155,13 @@ class z180asci_channel_1 : public z180asci_channel_base { public: // construction/destruction - z180asci_channel_1(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z180asci_channel_1(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void stat_w(uint8_t data) override; void asext_w(uint8_t data) override; void state_add(device_state_interface &parent) override; protected: - z180asci_channel_1(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const bool ext); + z180asci_channel_1(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const bool ext); // device-level overrides virtual void device_reset() override; }; @@ -174,7 +174,7 @@ class z180asci_ext_channel_0 : public z180asci_channel_0 { public: // construction/destruction - z180asci_ext_channel_0(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z180asci_ext_channel_0(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; //************************************************************************** @@ -185,7 +185,7 @@ class z180asci_ext_channel_1 : public z180asci_channel_1 { public: // construction/destruction - z180asci_ext_channel_1(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z180asci_ext_channel_1(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; //************************************************************************** diff --git a/src/devices/cpu/z8/z8.cpp b/src/devices/cpu/z8/z8.cpp index d59651b683b..ecadd71514a 100644 --- a/src/devices/cpu/z8/z8.cpp +++ b/src/devices/cpu/z8/z8.cpp @@ -175,7 +175,7 @@ void z8_device::register_map(address_map &map) } -z8_device::z8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t rom_size, bool preprogrammed) +z8_device::z8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t rom_size, bool preprogrammed) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 8, 16, 0, preprogrammed ? address_map_constructor(FUNC(z8_device::preprogrammed_map), this) : address_map_constructor(FUNC(z8_device::program_map), this)) , m_data_config("data", ENDIANNESS_BIG, 8, 16, 0) @@ -189,25 +189,25 @@ z8_device::z8_device(const machine_config &mconfig, device_type type, const char } -z8601_device::z8601_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z8601_device::z8601_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8_device(mconfig, Z8601, tag, owner, clock, 0x800, false) { } -ub8830d_device::ub8830d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ub8830d_device::ub8830d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8_device(mconfig, UB8830D, tag, owner, clock, 0x800, false) { } -z8611_device::z8611_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z8611_device::z8611_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8_device(mconfig, Z8611, tag, owner, clock, 0x1000, false) { } -z8671_device::z8671_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z8671_device::z8671_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8_device(mconfig, Z8671, tag, owner, clock, 0x800, true) { } @@ -223,13 +223,13 @@ const tiny_rom_entry *z8671_device::device_rom_region() const } -z8681_device::z8681_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z8681_device::z8681_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8_device(mconfig, Z8681, tag, owner, clock, 0, false) { } -z8682_device::z8682_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z8682_device::z8682_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8_device(mconfig, Z8682, tag, owner, clock, 0x800, true) { } @@ -246,7 +246,7 @@ const tiny_rom_entry *z8682_device::device_rom_region() const } -z86e02_device::z86e02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z86e02_device::z86e02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8_device(mconfig, Z86E02, tag, owner, clock, 0x200, false) { } diff --git a/src/devices/cpu/z8/z8.h b/src/devices/cpu/z8/z8.h index c092cfd4066..ad4c2dd6e7f 100644 --- a/src/devices/cpu/z8/z8.h +++ b/src/devices/cpu/z8/z8.h @@ -39,7 +39,7 @@ protected: }; // construction/destruction - z8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t rom_size, bool preprogrammed); + z8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t rom_size, bool preprogrammed); // device-level overrides virtual void device_start() override; @@ -383,28 +383,28 @@ private: class z8601_device : public z8_device { public: - z8601_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z8601_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ub8830d_device : public z8_device { public: - ub8830d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ub8830d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class z8611_device : public z8_device { public: - z8611_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z8611_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class z8671_device : public z8_device { public: - z8671_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z8671_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: const tiny_rom_entry *device_rom_region() const override; @@ -414,14 +414,14 @@ protected: class z8681_device : public z8_device { public: - z8681_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z8681_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class z8682_device : public z8_device { public: - z8682_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z8682_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: const tiny_rom_entry *device_rom_region() const override; @@ -431,7 +431,7 @@ protected: class z86e02_device : public z8_device { public: - z86e02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z86e02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/cpu/z80/ez80.cpp b/src/devices/cpu/z80/ez80.cpp index 525dc1c3b11..042a8535e4f 100644 --- a/src/devices/cpu/z80/ez80.cpp +++ b/src/devices/cpu/z80/ez80.cpp @@ -28,12 +28,12 @@ DEFINE_DEVICE_TYPE(EZ80, ez80_device, "ez80", "Zilog eZ80") // ez80_device - constructor //------------------------------------------------- -ez80_device::ez80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +ez80_device::ez80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, type, tag, owner, clock) { } -ez80_device::ez80_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ez80_device::ez80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ez80_device(mconfig, EZ80, tag, owner, clock) { } diff --git a/src/devices/cpu/z80/ez80.h b/src/devices/cpu/z80/ez80.h index 2ae563d5b80..3cc5cbec604 100644 --- a/src/devices/cpu/z80/ez80.h +++ b/src/devices/cpu/z80/ez80.h @@ -22,11 +22,11 @@ class ez80_device : public z80_device { public: // device type constructor - ez80_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ez80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // construction/destruction - ez80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + ez80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; // device type declaration diff --git a/src/devices/cpu/z80/kc82.cpp b/src/devices/cpu/z80/kc82.cpp index bf0a26290c4..0dcac14e9e2 100644 --- a/src/devices/cpu/z80/kc82.cpp +++ b/src/devices/cpu/z80/kc82.cpp @@ -17,7 +17,7 @@ // kc82_device - constructor //------------------------------------------------- -kc82_device::kc82_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor mem_map, address_map_constructor io_map) +kc82_device::kc82_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor mem_map, address_map_constructor io_map) : z80_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_LITTLE, 8, 20, 0, 16, 10, mem_map) , m_opcodes_config("opcodes", ENDIANNESS_LITTLE, 8, 20, 0, 16, 10, mem_map) diff --git a/src/devices/cpu/z80/kc82.h b/src/devices/cpu/z80/kc82.h index c78269c77fe..b9ef94c5ab2 100644 --- a/src/devices/cpu/z80/kc82.h +++ b/src/devices/cpu/z80/kc82.h @@ -29,7 +29,7 @@ public: protected: // construction/destruction - kc82_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, address_map_constructor mem_map, address_map_constructor io_map); + kc82_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor mem_map, address_map_constructor io_map); // device-level overrides virtual void device_start() override; diff --git a/src/devices/cpu/z80/kl5c80a12.cpp b/src/devices/cpu/z80/kl5c80a12.cpp index 495a0ab4afd..4a8c4e30bd5 100644 --- a/src/devices/cpu/z80/kl5c80a12.cpp +++ b/src/devices/cpu/z80/kl5c80a12.cpp @@ -35,7 +35,7 @@ static const z80_daisy_config pseudo_daisy_config[] = { { "kp69" }, { nullptr } // kl5c80a12_device - constructor //------------------------------------------------- -kl5c80a12_device::kl5c80a12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +kl5c80a12_device::kl5c80a12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc82_device(mconfig, KL5C80A12, tag, owner, clock, address_map_constructor(FUNC(kl5c80a12_device::internal_ram), this), address_map_constructor(FUNC(kl5c80a12_device::internal_io), this)) diff --git a/src/devices/cpu/z80/kl5c80a12.h b/src/devices/cpu/z80/kl5c80a12.h index 28434f8c8f6..c50fdca6297 100644 --- a/src/devices/cpu/z80/kl5c80a12.h +++ b/src/devices/cpu/z80/kl5c80a12.h @@ -28,7 +28,7 @@ public: }; // device type constructor - kl5c80a12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + kl5c80a12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto in_p0_callback() { return m_porta_in_callback[0].bind(); } diff --git a/src/devices/cpu/z80/kl5c80a16.cpp b/src/devices/cpu/z80/kl5c80a16.cpp index d92cc9142de..92cf6b56c77 100644 --- a/src/devices/cpu/z80/kl5c80a16.cpp +++ b/src/devices/cpu/z80/kl5c80a16.cpp @@ -30,7 +30,7 @@ static const z80_daisy_config pseudo_daisy_config[] = { { "kp69" }, { nullptr } // kl5c80a16_device - constructor //------------------------------------------------- -kl5c80a16_device::kl5c80a16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +kl5c80a16_device::kl5c80a16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc82_device(mconfig, KL5C80A16, tag, owner, clock, address_map_constructor(), address_map_constructor(FUNC(kl5c80a16_device::internal_io), this)) diff --git a/src/devices/cpu/z80/kl5c80a16.h b/src/devices/cpu/z80/kl5c80a16.h index d3ac8eda636..34d71bb90d9 100644 --- a/src/devices/cpu/z80/kl5c80a16.h +++ b/src/devices/cpu/z80/kl5c80a16.h @@ -28,7 +28,7 @@ public: }; // device type constructor - kl5c80a16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + kl5c80a16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto in_p0_callback() { return m_port_in_callback[0].bind(); } diff --git a/src/devices/cpu/z80/kp63.cpp b/src/devices/cpu/z80/kp63.cpp index db42ef30ecb..356fcbc17ed 100644 --- a/src/devices/cpu/z80/kp63.cpp +++ b/src/devices/cpu/z80/kp63.cpp @@ -58,7 +58,7 @@ const char *const kp63_device::s_count_modes[4] = // kp63_device - constructor //------------------------------------------------- -kp63_device::kp63_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 num_counters, u8 mode_mask) +kp63_device::kp63_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 num_counters, u8 mode_mask) : device_t(mconfig, type, tag, owner, clock) , m_out_pulse_callback(*this) , m_out_strobe_callback(*this) @@ -82,7 +82,7 @@ kp63_device::kp63_device(const machine_config &mconfig, device_type type, const // kp63_3channel_device - constructor //------------------------------------------------- -kp63_3channel_device::kp63_3channel_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +kp63_3channel_device::kp63_3channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kp63_device(mconfig, KP63_3CHANNEL, tag, owner, clock, 3, 0x1f) { } @@ -92,7 +92,7 @@ kp63_3channel_device::kp63_3channel_device(const machine_config &mconfig, const // kp63a_device - constructor //------------------------------------------------- -kp63a_device::kp63a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +kp63a_device::kp63a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kp63_device(mconfig, KP63A, tag, owner, clock, 4, 0x3f) { } diff --git a/src/devices/cpu/z80/kp63.h b/src/devices/cpu/z80/kp63.h index 73e269fb72b..ec00fbea789 100644 --- a/src/devices/cpu/z80/kp63.h +++ b/src/devices/cpu/z80/kp63.h @@ -32,7 +32,7 @@ public: protected: // construction/destruction - kp63_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 num_counters, u8 mode_mask); + kp63_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 num_counters, u8 mode_mask); // device-level overrides virtual void device_resolve_objects() override; @@ -81,14 +81,14 @@ class kp63_3channel_device : public kp63_device { public: // device type constructor - kp63_3channel_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + kp63_3channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class kp63a_device : public kp63_device { public: // device type constructor - kp63a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + kp63a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type declarations diff --git a/src/devices/cpu/z80/kp64.cpp b/src/devices/cpu/z80/kp64.cpp index 697ed65268a..52e418f35dc 100644 --- a/src/devices/cpu/z80/kp64.cpp +++ b/src/devices/cpu/z80/kp64.cpp @@ -68,7 +68,7 @@ DEFINE_DEVICE_TYPE(KP64, kp64_device, "kp64", "Kawasaki Steel KP64 Timer/Counter // kp64_device - constructor //------------------------------------------------- -kp64_device::kp64_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +kp64_device::kp64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, KP64, tag, owner, clock) , m_out_callback(*this) , m_count_timer(nullptr) diff --git a/src/devices/cpu/z80/kp64.h b/src/devices/cpu/z80/kp64.h index 954076430d0..b5d62212dfa 100644 --- a/src/devices/cpu/z80/kp64.h +++ b/src/devices/cpu/z80/kp64.h @@ -20,7 +20,7 @@ class kp64_device : public device_t { public: // device type constructor - kp64_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + kp64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto out_callback() { return m_out_callback.bind(); } diff --git a/src/devices/cpu/z80/kp69.cpp b/src/devices/cpu/z80/kp69.cpp index 0e194138b2c..a03931c3292 100644 --- a/src/devices/cpu/z80/kp69.cpp +++ b/src/devices/cpu/z80/kp69.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(KP69, kp69_device, "kp69", "Kawasaki Steel KP69 Interrupt Con // kp69_base_device - constructor //------------------------------------------------- -kp69_base_device::kp69_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +kp69_base_device::kp69_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_z80daisy_interface(mconfig, *this) , m_int_callback(*this) @@ -56,7 +56,7 @@ kp69_base_device::kp69_base_device(const machine_config &mconfig, device_type ty // kp69_device - constructor //------------------------------------------------- -kp69_device::kp69_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +kp69_device::kp69_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kp69_base_device(mconfig, KP69, tag, owner, clock) , m_ivr_written(false) { diff --git a/src/devices/cpu/z80/kp69.h b/src/devices/cpu/z80/kp69.h index f7747f795d6..dec9255f8fc 100644 --- a/src/devices/cpu/z80/kp69.h +++ b/src/devices/cpu/z80/kp69.h @@ -41,7 +41,7 @@ public: protected: // construction/destruction - kp69_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + kp69_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -82,7 +82,7 @@ class kp69_device : public kp69_base_device { public: // device type constructor - kp69_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + kp69_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // write handlers void lerl_pgrl_w(u8 data); diff --git a/src/devices/cpu/z80/ky80.cpp b/src/devices/cpu/z80/ky80.cpp index b55237efa95..067c412022d 100644 --- a/src/devices/cpu/z80/ky80.cpp +++ b/src/devices/cpu/z80/ky80.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(KY80, ky80_device, "ky80", "Taxan KY-80") // ky80_device - constructor //------------------------------------------------- -ky80_device::ky80_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ky80_device::ky80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kc82_device(mconfig, KY80, tag, owner, clock, address_map_constructor(FUNC(ky80_device::internal_ram), this), address_map_constructor(FUNC(ky80_device::internal_io), this)) diff --git a/src/devices/cpu/z80/ky80.h b/src/devices/cpu/z80/ky80.h index fce065a9c8f..0e977689db9 100644 --- a/src/devices/cpu/z80/ky80.h +++ b/src/devices/cpu/z80/ky80.h @@ -22,7 +22,7 @@ class ky80_device : public kc82_device { public: // device type constructor - ky80_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ky80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides diff --git a/src/devices/cpu/z80/lz8420m.cpp b/src/devices/cpu/z80/lz8420m.cpp index 26e41a6b248..8b6093d4d97 100644 --- a/src/devices/cpu/z80/lz8420m.cpp +++ b/src/devices/cpu/z80/lz8420m.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(LZ8420M, lz8420m_device, "lz8420m", "Sharp LZ8420M") -lz8420m_device::lz8420m_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lz8420m_device::lz8420m_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, LZ8420M, tag, owner, clock) { } diff --git a/src/devices/cpu/z80/lz8420m.h b/src/devices/cpu/z80/lz8420m.h index afa653c340d..ce1e06389aa 100644 --- a/src/devices/cpu/z80/lz8420m.h +++ b/src/devices/cpu/z80/lz8420m.h @@ -29,7 +29,7 @@ class lz8420m_device : public z80_device { public: - lz8420m_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + lz8420m_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/z80/mc8123.cpp b/src/devices/cpu/z80/mc8123.cpp index 33acc77b096..7581ea4afe8 100644 --- a/src/devices/cpu/z80/mc8123.cpp +++ b/src/devices/cpu/z80/mc8123.cpp @@ -90,7 +90,7 @@ DEFINE_DEVICE_TYPE(MC8123, mc8123_device, "mc8123", "MC-8123") // mc8123_device - constructor //------------------------------------------------- -mc8123_device::mc8123_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mc8123_device::mc8123_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, MC8123, tag, owner, clock) , m_key(*this, "key") { diff --git a/src/devices/cpu/z80/mc8123.h b/src/devices/cpu/z80/mc8123.h index 8fad72dbee7..90cbeec6ca1 100644 --- a/src/devices/cpu/z80/mc8123.h +++ b/src/devices/cpu/z80/mc8123.h @@ -17,7 +17,7 @@ class mc8123_device : public z80_device { public: // construction/destruction - mc8123_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mc8123_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // this function assumes a fixed portion of ROM at 0000-7FFF, and // an arbitrary amount of banks at 8000-BFFF. diff --git a/src/devices/cpu/z80/r800.cpp b/src/devices/cpu/z80/r800.cpp index 1748f8eca39..bef404155bf 100644 --- a/src/devices/cpu/z80/r800.cpp +++ b/src/devices/cpu/z80/r800.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(R800, r800_device, "r800", "ASCII R800") // r800_device - constructor //------------------------------------------------- -r800_device::r800_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +r800_device::r800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, R800, tag, owner, clock) { } diff --git a/src/devices/cpu/z80/r800.h b/src/devices/cpu/z80/r800.h index bad16f8cfdd..2ed0aa1672e 100644 --- a/src/devices/cpu/z80/r800.h +++ b/src/devices/cpu/z80/r800.h @@ -22,7 +22,7 @@ class r800_device : public z80_device { public: // device type constructor - r800_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + r800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides diff --git a/src/devices/cpu/z80/tmpz84c011.cpp b/src/devices/cpu/z80/tmpz84c011.cpp index c28aa2b243a..df79ffe59cc 100644 --- a/src/devices/cpu/z80/tmpz84c011.cpp +++ b/src/devices/cpu/z80/tmpz84c011.cpp @@ -32,7 +32,7 @@ void tmpz84c011_device::tmpz84c011_internal_io_map(address_map &map) } -tmpz84c011_device::tmpz84c011_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmpz84c011_device::tmpz84c011_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, TMPZ84C011, tag, owner, clock), m_io_space_config( "io", ENDIANNESS_LITTLE, 8, 16, 0, address_map_constructor(FUNC(tmpz84c011_device::tmpz84c011_internal_io_map), this)), m_ctc(*this, "tmpz84c011_ctc"), diff --git a/src/devices/cpu/z80/tmpz84c011.h b/src/devices/cpu/z80/tmpz84c011.h index 89b40a9f6aa..ab63642518e 100644 --- a/src/devices/cpu/z80/tmpz84c011.h +++ b/src/devices/cpu/z80/tmpz84c011.h @@ -30,7 +30,7 @@ class tmpz84c011_device : public z80_device { public: - tmpz84c011_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + tmpz84c011_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto zc0_callback() { return m_zc0_cb.bind(); } diff --git a/src/devices/cpu/z80/tmpz84c015.cpp b/src/devices/cpu/z80/tmpz84c015.cpp index 3df10f19c6c..ebba77d423c 100644 --- a/src/devices/cpu/z80/tmpz84c015.cpp +++ b/src/devices/cpu/z80/tmpz84c015.cpp @@ -28,7 +28,7 @@ void tmpz84c015_device::internal_io_map(address_map &map) } -tmpz84c015_device::tmpz84c015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tmpz84c015_device::tmpz84c015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, TMPZ84C015, tag, owner, clock), m_io_space_config( "io", ENDIANNESS_LITTLE, 8, 16, 0, address_map_constructor(FUNC(tmpz84c015_device::internal_io_map), this)), m_ctc(*this, "tmpz84c015_ctc"), diff --git a/src/devices/cpu/z80/tmpz84c015.h b/src/devices/cpu/z80/tmpz84c015.h index 99b6f095714..0d982496879 100644 --- a/src/devices/cpu/z80/tmpz84c015.h +++ b/src/devices/cpu/z80/tmpz84c015.h @@ -25,7 +25,7 @@ class tmpz84c015_device : public z80_device { public: - tmpz84c015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + tmpz84c015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers diff --git a/src/devices/cpu/z80/z80.cpp b/src/devices/cpu/z80/z80.cpp index 86d9d29469b..b4b9ed4fdb5 100644 --- a/src/devices/cpu/z80/z80.cpp +++ b/src/devices/cpu/z80/z80.cpp @@ -3814,12 +3814,12 @@ void z80_device::z80_set_cycle_tables(const uint8_t *op, const uint8_t *cb, cons } -z80_device::z80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +z80_device::z80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, Z80, tag, owner, clock) { } -z80_device::z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +z80_device::z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, type, tag, owner, clock), z80_daisy_chain_interface(mconfig, *this), m_program_config("program", ENDIANNESS_LITTLE, 8, 16, 0), @@ -3849,7 +3849,7 @@ device_memory_interface::space_config_vector z80_device::memory_space_config() c DEFINE_DEVICE_TYPE(Z80, z80_device, "z80", "Zilog Z80") -nsc800_device::nsc800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nsc800_device::nsc800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, NSC800, tag, owner, clock) { } diff --git a/src/devices/cpu/z80/z80.h b/src/devices/cpu/z80/z80.h index 8d3ac158325..52c0ebab583 100644 --- a/src/devices/cpu/z80/z80.h +++ b/src/devices/cpu/z80/z80.h @@ -30,7 +30,7 @@ enum class z80_device : public cpu_device, public z80_daisy_chain_interface { public: - z80_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void z80_set_cycle_tables(const uint8_t *op, const uint8_t *cb, const uint8_t *ed, const uint8_t *xy, const uint8_t *xycb, const uint8_t *ex); template <typename... T> void set_memory_map(T &&... args) { set_addrmap(AS_PROGRAM, std::forward<T>(args)...); } @@ -42,7 +42,7 @@ public: auto halt_cb() { return m_halt_cb.bind(); } protected: - z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -298,7 +298,7 @@ DECLARE_DEVICE_TYPE(Z80, z80_device) class nsc800_device : public z80_device { public: - nsc800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nsc800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/cpu/z8000/z8000.cpp b/src/devices/cpu/z8000/z8000.cpp index 8d462c7eddc..50773f5b587 100644 --- a/src/devices/cpu/z8000/z8000.cpp +++ b/src/devices/cpu/z8000/z8000.cpp @@ -23,13 +23,13 @@ DEFINE_DEVICE_TYPE(Z8001, z8001_device, "z8001", "Zilog Z8001") DEFINE_DEVICE_TYPE(Z8002, z8002_device, "z8002", "Zilog Z8002") -z8002_device::z8002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z8002_device::z8002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8002_device(mconfig, Z8002, tag, owner, clock, 16, 1) { } -z8002_device::z8002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int addrbits, int vecmult) +z8002_device::z8002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addrbits, int vecmult) : cpu_device(mconfig, type, tag, owner, clock) , m_program_config("program", ENDIANNESS_BIG, 16, addrbits, 0) , m_data_config("data", ENDIANNESS_BIG, 16, addrbits, 0) @@ -45,7 +45,7 @@ z8002_device::z8002_device(const machine_config &mconfig, device_type type, cons } -z8001_device::z8001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z8001_device::z8001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z8002_device(mconfig, Z8001, tag, owner, clock, 23, 2) { } diff --git a/src/devices/cpu/z8000/z8000.h b/src/devices/cpu/z8000/z8000.h index 921f8f4eb0f..ce96cac2f6f 100644 --- a/src/devices/cpu/z8000/z8000.h +++ b/src/devices/cpu/z8000/z8000.h @@ -76,7 +76,7 @@ public: }; // construction/destruction - z8002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z8002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~z8002_device(); auto segtack() { return m_iack_in[0].bind(); } @@ -87,7 +87,7 @@ public: DECLARE_WRITE_LINE_MEMBER(mi_w) { m_mi = state; } // XXX: this has to apply in the middle of an insn for now protected: - z8002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int addrbits, int vecmult); + z8002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addrbits, int vecmult); // device-level overrides virtual void device_start() override; @@ -706,7 +706,7 @@ class z8001_device : public z8002_device { public: // construction/destruction - z8001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z8001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // z8002_device overrides diff --git a/src/devices/imagedev/avivideo.cpp b/src/devices/imagedev/avivideo.cpp index f1a2b7e1cdc..e12a046b23e 100644 --- a/src/devices/imagedev/avivideo.cpp +++ b/src/devices/imagedev/avivideo.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(IMAGE_AVIVIDEO, avivideo_image_device, "avivideo_image", "AVI // avivideo_image_device - constructor //------------------------------------------------- -avivideo_image_device::avivideo_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +avivideo_image_device::avivideo_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IMAGE_AVIVIDEO, tag, owner, clock), device_image_interface(mconfig, *this), m_frame(nullptr), diff --git a/src/devices/imagedev/avivideo.h b/src/devices/imagedev/avivideo.h index 5af11df4187..782205250c7 100644 --- a/src/devices/imagedev/avivideo.h +++ b/src/devices/imagedev/avivideo.h @@ -26,7 +26,7 @@ class avivideo_image_device : public device_t, public device_image_interface { public: // construction/destruction - avivideo_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + avivideo_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~avivideo_image_device(); // image-level overrides diff --git a/src/devices/imagedev/bitbngr.cpp b/src/devices/imagedev/bitbngr.cpp index dc31c4ccb83..643afdc3cd7 100644 --- a/src/devices/imagedev/bitbngr.cpp +++ b/src/devices/imagedev/bitbngr.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(BITBANGER, bitbanger_device, "bitbanger", "Bitbanger") ctor -------------------------------------------------*/ -bitbanger_device::bitbanger_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bitbanger_device::bitbanger_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BITBANGER, tag, owner, clock), device_image_interface(mconfig, *this), m_interface(nullptr), diff --git a/src/devices/imagedev/bitbngr.h b/src/devices/imagedev/bitbngr.h index 5b02417cfc3..6f7eb9ce444 100644 --- a/src/devices/imagedev/bitbngr.h +++ b/src/devices/imagedev/bitbngr.h @@ -17,7 +17,7 @@ public: void set_readonly(bool is_readonly) { m_is_readonly = is_readonly; } // construction/destruction - bitbanger_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bitbanger_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // image-level overrides virtual image_init_result call_load() override; diff --git a/src/devices/imagedev/cassette.cpp b/src/devices/imagedev/cassette.cpp index 2bf7c2a4808..15e59e31f8b 100644 --- a/src/devices/imagedev/cassette.cpp +++ b/src/devices/imagedev/cassette.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(CASSETTE, cassette_image_device, "cassette_image", "Cassette" // cassette_image_device - constructor //------------------------------------------------- -cassette_image_device::cassette_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cassette_image_device::cassette_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CASSETTE, tag, owner, clock), device_image_interface(mconfig, *this), device_sound_interface(mconfig, *this), diff --git a/src/devices/imagedev/cassette.h b/src/devices/imagedev/cassette.h index ad71e062e70..4047272f43e 100644 --- a/src/devices/imagedev/cassette.h +++ b/src/devices/imagedev/cassette.h @@ -49,7 +49,7 @@ class cassette_image_device : public device_t, { public: // construction/destruction - cassette_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + cassette_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~cassette_image_device(); void set_formats(const cassette_image::Format* const *formats) { m_formats = formats; } diff --git a/src/devices/imagedev/chd_cd.cpp b/src/devices/imagedev/chd_cd.cpp index cf87d17b5ef..c9b7191384e 100644 --- a/src/devices/imagedev/chd_cd.cpp +++ b/src/devices/imagedev/chd_cd.cpp @@ -21,12 +21,12 @@ DEFINE_DEVICE_TYPE(CDROM, cdrom_image_device, "cdrom_image", "CD-ROM Image") // cdrom_image_device - constructor //------------------------------------------------- -cdrom_image_device::cdrom_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cdrom_image_device::cdrom_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cdrom_image_device(mconfig, CDROM, tag, owner, clock) { } -cdrom_image_device::cdrom_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +cdrom_image_device::cdrom_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_image_interface(mconfig, *this), m_cdrom_handle(nullptr), diff --git a/src/devices/imagedev/chd_cd.h b/src/devices/imagedev/chd_cd.h index e93b7969c62..d4b1eac0882 100644 --- a/src/devices/imagedev/chd_cd.h +++ b/src/devices/imagedev/chd_cd.h @@ -27,7 +27,7 @@ class cdrom_image_device : public device_t, { public: // construction/destruction - cdrom_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + cdrom_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~cdrom_image_device(); void set_interface(const char *interface) { m_interface = interface; } @@ -49,7 +49,7 @@ public: cdrom_file *get_cdrom_file() { return m_cdrom_handle; } protected: - cdrom_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cdrom_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_config_complete() override; diff --git a/src/devices/imagedev/diablo.cpp b/src/devices/imagedev/diablo.cpp index 5f8b45e4064..b34d0b92604 100644 --- a/src/devices/imagedev/diablo.cpp +++ b/src/devices/imagedev/diablo.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(DIABLO, diablo_image_device, "diablo_image", "Diablo") // diablo_image_device - constructor //------------------------------------------------- -diablo_image_device::diablo_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +diablo_image_device::diablo_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : harddisk_image_base_device(mconfig, DIABLO, tag, owner, clock), m_chd(nullptr), m_hard_disk_handle(nullptr), diff --git a/src/devices/imagedev/diablo.h b/src/devices/imagedev/diablo.h index 2b483bf8388..974defebc00 100644 --- a/src/devices/imagedev/diablo.h +++ b/src/devices/imagedev/diablo.h @@ -24,7 +24,7 @@ class diablo_image_device : public harddisk_image_base_device { public: // construction/destruction - diablo_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + diablo_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~diablo_image_device(); template <typename Object> void set_device_load(Object &&cb) { m_device_image_load = std::forward<Object>(cb); } diff --git a/src/devices/imagedev/flopdrv.cpp b/src/devices/imagedev/flopdrv.cpp index eba391f966e..c13820a8b7a 100644 --- a/src/devices/imagedev/flopdrv.cpp +++ b/src/devices/imagedev/flopdrv.cpp @@ -614,12 +614,12 @@ DEFINE_DEVICE_TYPE(LEGACY_FLOPPY, legacy_floppy_image_device, "legacy_floppy_ima // legacy_floppy_image_device - constructor //------------------------------------------------- -legacy_floppy_image_device::legacy_floppy_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +legacy_floppy_image_device::legacy_floppy_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : legacy_floppy_image_device(mconfig, LEGACY_FLOPPY, tag, owner, clock) { } -legacy_floppy_image_device::legacy_floppy_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +legacy_floppy_image_device::legacy_floppy_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_image_interface(mconfig, *this), m_out_idx_func(*this), diff --git a/src/devices/imagedev/flopdrv.h b/src/devices/imagedev/flopdrv.h index a3241cc4b89..da98ea1097c 100644 --- a/src/devices/imagedev/flopdrv.h +++ b/src/devices/imagedev/flopdrv.h @@ -90,13 +90,13 @@ class legacy_floppy_image_device : public device_t, { public: // construction/destruction - legacy_floppy_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, const floppy_interface *config) - : legacy_floppy_image_device(mconfig, tag, owner, clock) + legacy_floppy_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const floppy_interface *config) + : legacy_floppy_image_device(mconfig, tag, owner) { set_floppy_config(config); } - legacy_floppy_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + legacy_floppy_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); ~legacy_floppy_image_device(); void set_floppy_config(const floppy_interface *config) { m_config = config; } @@ -163,7 +163,7 @@ private: TIMER_CALLBACK_MEMBER( set_wpt ); protected: - legacy_floppy_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + legacy_floppy_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device overrides virtual void device_config_complete() override; diff --git a/src/devices/imagedev/floppy.cpp b/src/devices/imagedev/floppy.cpp index 3c00336dcd8..4d26d44171f 100644 --- a/src/devices/imagedev/floppy.cpp +++ b/src/devices/imagedev/floppy.cpp @@ -208,7 +208,7 @@ void floppy_image_device::default_pc_floppy_formats(format_registration &fr) fr.add_pc_formats(); } -floppy_connector::floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_connector::floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, FLOPPY_CONNECTOR, tag, owner, clock), device_slot_interface(mconfig, *this), formats(nullptr), @@ -248,7 +248,7 @@ floppy_image_device *floppy_connector::get_device() // floppy_image_device - constructor //------------------------------------------------- -floppy_image_device::floppy_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +floppy_image_device::floppy_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_image_interface(mconfig, *this), input_format(nullptr), @@ -1500,7 +1500,7 @@ static const char *const floppy525_sample_names[] = nullptr }; -floppy_sound_device::floppy_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +floppy_sound_device::floppy_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : samples_device(mconfig, FLOPPYSOUND, tag, owner, clock), m_sound(nullptr), m_step_base(0), @@ -1801,13 +1801,13 @@ void floppy_sound_device::sound_stream_update(sound_stream &stream, std::vector< void floppy_image_device::device_add_mconfig(machine_config &config) { SPEAKER(config, FLOPSPK).front_center(); - FLOPPYSOUND(config, FLOPSND_TAG, 44100).add_route(ALL_OUTPUTS, FLOPSPK, 0.5); + FLOPPYSOUND(config, FLOPSND_TAG, XTAL::u(44100)).add_route(ALL_OUTPUTS, FLOPSPK, 0.5); if (FLUX_SCREEN) { SCREEN(config, m_flux_screen, SCREEN_TYPE_RASTER); m_flux_screen->set_screen_update(FUNC(floppy_image_device::flux_screen_update)); - m_flux_screen->set_raw(30*(flux_screen_sx+1)*(flux_screen_sy+1), flux_screen_sx+1, 0, flux_screen_sx, flux_screen_sy+1, 0, flux_screen_sy); + m_flux_screen->set_raw(XTAL::u(30*(flux_screen_sx+1)*(flux_screen_sy+1)), flux_screen_sx+1, 0, flux_screen_sx, flux_screen_sy+1, 0, flux_screen_sy); m_flux_screen->set_physical_aspect(1, 2); } } @@ -1824,7 +1824,7 @@ DEFINE_DEVICE_TYPE(FLOPPYSOUND, floppy_sound_device, "flopsnd", "Floppy sound") // 3" single-sided double density //------------------------------------------------- -floppy_3_ssdd::floppy_3_ssdd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_3_ssdd::floppy_3_ssdd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_3_SSDD, tag, owner, clock) { } @@ -1847,7 +1847,7 @@ void floppy_3_ssdd::setup_characteristics() // 3" double-sided double density //------------------------------------------------- -floppy_3_dsdd::floppy_3_dsdd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_3_dsdd::floppy_3_dsdd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_3_DSDD, tag, owner, clock) { } @@ -1871,7 +1871,7 @@ void floppy_3_dsdd::setup_characteristics() // 3.5" single-sided double density //------------------------------------------------- -floppy_35_ssdd::floppy_35_ssdd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_35_ssdd::floppy_35_ssdd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_35_SSDD, tag, owner, clock) { } @@ -1895,7 +1895,7 @@ void floppy_35_ssdd::setup_characteristics() // 3.5" double-sided double density //------------------------------------------------- -floppy_35_dd::floppy_35_dd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_35_dd::floppy_35_dd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_35_DD, tag, owner, clock) { } @@ -1920,7 +1920,7 @@ void floppy_35_dd::setup_characteristics() // 3.5" high density //------------------------------------------------- -floppy_35_hd::floppy_35_hd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_35_hd::floppy_35_hd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_35_HD, tag, owner, clock) { } @@ -1946,7 +1946,7 @@ void floppy_35_hd::setup_characteristics() // 3.5" extended density //------------------------------------------------- -floppy_35_ed::floppy_35_ed(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_35_ed::floppy_35_ed(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_35_ED, tag, owner, clock) { } @@ -1973,7 +1973,7 @@ void floppy_35_ed::setup_characteristics() // 5.25" single-sided single density 35 tracks //------------------------------------------------- -floppy_525_sssd_35t::floppy_525_sssd_35t(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_525_sssd_35t::floppy_525_sssd_35t(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_525_SSSD_35T, tag, owner, clock) { } @@ -1996,7 +1996,7 @@ void floppy_525_sssd_35t::setup_characteristics() // 5.25" double-sided single density 35 tracks //------------------------------------------------- -floppy_525_sd_35t::floppy_525_sd_35t(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_525_sd_35t::floppy_525_sd_35t(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_525_SD_35T, tag, owner, clock) { } @@ -2020,7 +2020,7 @@ void floppy_525_sd_35t::setup_characteristics() // 5.25" single-sided single density, VTECH edition //------------------------------------------------- -floppy_525_vtech::floppy_525_vtech(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_525_vtech::floppy_525_vtech(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_525_VTECH, tag, owner, clock) { amplifier_freakout_time = attotime::from_usec(64); @@ -2044,7 +2044,7 @@ void floppy_525_vtech::setup_characteristics() // 5.25" single-sided single density //------------------------------------------------- -floppy_525_sssd::floppy_525_sssd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_525_sssd::floppy_525_sssd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_525_SSSD, tag, owner, clock) { } @@ -2067,7 +2067,7 @@ void floppy_525_sssd::setup_characteristics() // 5.25" double-sided single density //------------------------------------------------- -floppy_525_sd::floppy_525_sd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_525_sd::floppy_525_sd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_525_SD, tag, owner, clock) { } @@ -2090,7 +2090,7 @@ void floppy_525_sd::setup_characteristics() // 5.25" single-sided double density //------------------------------------------------- -floppy_525_ssdd::floppy_525_ssdd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_525_ssdd::floppy_525_ssdd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_525_SSDD, tag, owner, clock) { } @@ -2114,7 +2114,7 @@ void floppy_525_ssdd::setup_characteristics() // 5.25" double-sided double density //------------------------------------------------- -floppy_525_dd::floppy_525_dd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_525_dd::floppy_525_dd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_525_DD, tag, owner, clock) { } @@ -2139,7 +2139,7 @@ void floppy_525_dd::setup_characteristics() // 5.25" single-sided quad density //------------------------------------------------- -floppy_525_ssqd::floppy_525_ssqd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_525_ssqd::floppy_525_ssqd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_525_SSQD, tag, owner, clock) { } @@ -2164,7 +2164,7 @@ void floppy_525_ssqd::setup_characteristics() // 5.25" double-sided quad density //------------------------------------------------- -floppy_525_qd::floppy_525_qd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_525_qd::floppy_525_qd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_525_QD, tag, owner, clock) { } @@ -2192,7 +2192,7 @@ void floppy_525_qd::setup_characteristics() // 5.25" high density //------------------------------------------------- -floppy_525_hd::floppy_525_hd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_525_hd::floppy_525_hd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_525_HD, tag, owner, clock) { } @@ -2220,7 +2220,7 @@ void floppy_525_hd::setup_characteristics() // 8" single-sided single density //------------------------------------------------- -floppy_8_sssd::floppy_8_sssd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_8_sssd::floppy_8_sssd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_8_SSSD, tag, owner, clock) { } @@ -2244,7 +2244,7 @@ void floppy_8_sssd::setup_characteristics() // 8" double-sided single density //------------------------------------------------- -floppy_8_dssd::floppy_8_dssd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_8_dssd::floppy_8_dssd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_8_DSSD, tag, owner, clock) { } @@ -2269,7 +2269,7 @@ void floppy_8_dssd::setup_characteristics() // 8" single-sided double density //------------------------------------------------- -floppy_8_ssdd::floppy_8_ssdd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_8_ssdd::floppy_8_ssdd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_8_SSDD, tag, owner, clock) { } @@ -2294,7 +2294,7 @@ void floppy_8_ssdd::setup_characteristics() // 8" double-sided double density //------------------------------------------------- -floppy_8_dsdd::floppy_8_dsdd(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +floppy_8_dsdd::floppy_8_dsdd(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, FLOPPY_8_DSDD, tag, owner, clock) { } @@ -2331,7 +2331,7 @@ void floppy_8_dsdd::setup_characteristics() // //------------------------------------------------- -epson_smd_165::epson_smd_165(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +epson_smd_165::epson_smd_165(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, EPSON_SMD_165, tag, owner, clock) { } @@ -2378,7 +2378,7 @@ void epson_smd_165::setup_characteristics() // //------------------------------------------------- -epson_sd_320::epson_sd_320(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +epson_sd_320::epson_sd_320(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, EPSON_SD_320, tag, owner, clock) { } @@ -2406,7 +2406,7 @@ void epson_sd_320::setup_characteristics() // //------------------------------------------------- -epson_sd_321::epson_sd_321(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +epson_sd_321::epson_sd_321(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, EPSON_SD_321, tag, owner, clock) { } @@ -2438,7 +2438,7 @@ void epson_sd_321::setup_characteristics() // //------------------------------------------------- -pana_ju_363::pana_ju_363(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pana_ju_363::pana_ju_363(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, PANA_JU_363, tag, owner, clock) { } @@ -2470,7 +2470,7 @@ void pana_ju_363::setup_characteristics() // //------------------------------------------------- -sony_oa_d31v::sony_oa_d31v(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sony_oa_d31v::sony_oa_d31v(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, SONY_OA_D31V, tag, owner, clock) { } @@ -2502,7 +2502,7 @@ void sony_oa_d31v::setup_characteristics() // //------------------------------------------------- -sony_oa_d32w::sony_oa_d32w(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sony_oa_d32w::sony_oa_d32w(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, SONY_OA_D32W, tag, owner, clock) { } @@ -2535,7 +2535,7 @@ void sony_oa_d32w::setup_characteristics() // //------------------------------------------------- -sony_oa_d32v::sony_oa_d32v(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sony_oa_d32v::sony_oa_d32v(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, SONY_OA_D32V, tag, owner, clock) { } @@ -2566,7 +2566,7 @@ void sony_oa_d32v::setup_characteristics() // //------------------------------------------------- -teac_fd_30a::teac_fd_30a(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +teac_fd_30a::teac_fd_30a(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, TEAC_FD_30A, tag, owner, clock) { } @@ -2595,7 +2595,7 @@ void teac_fd_30a::setup_characteristics() // //------------------------------------------------- -teac_fd_55e::teac_fd_55e(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +teac_fd_55e::teac_fd_55e(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, TEAC_FD_55E, tag, owner, clock) { } @@ -2626,7 +2626,7 @@ void teac_fd_55e::setup_characteristics() // //------------------------------------------------- -teac_fd_55f::teac_fd_55f(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +teac_fd_55f::teac_fd_55f(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, TEAC_FD_55F, tag, owner, clock) { } @@ -2660,7 +2660,7 @@ void teac_fd_55f::setup_characteristics() // //------------------------------------------------- -teac_fd_55g::teac_fd_55g(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +teac_fd_55g::teac_fd_55g(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, TEAC_FD_55G, tag, owner, clock) { } @@ -2690,7 +2690,7 @@ void teac_fd_55g::setup_characteristics() // used in the Commodoere 1541 disk drive //------------------------------------------------- -alps_3255190x::alps_3255190x(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +alps_3255190x::alps_3255190x(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, ALPS_3255190X, tag, owner, clock) { } @@ -2714,7 +2714,7 @@ void alps_3255190x::setup_characteristics() // IBM 6360 -- 8" single-sided single density //------------------------------------------------- -ibm_6360::ibm_6360(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ibm_6360::ibm_6360(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, IBM_6360, tag, owner, clock) { } @@ -2740,7 +2740,7 @@ void ibm_6360::setup_characteristics() // Variable-speed Macintosh drives //------------------------------------------------- -mac_floppy_device::mac_floppy_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : floppy_image_device(mconfig, type, tag, owner, clock) +mac_floppy_device::mac_floppy_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : floppy_image_device(mconfig, type, tag, owner, clock) { m_has_mfm = false; dskchg_writable = true; @@ -2963,7 +2963,7 @@ void mac_floppy_device::tfsel_w(int state) } } -oa_d34v_device::oa_d34v_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : mac_floppy_device(mconfig, OAD34V, tag, owner, clock) +oa_d34v_device::oa_d34v_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mac_floppy_device(mconfig, OAD34V, tag, owner, clock) { } @@ -2990,7 +2990,7 @@ void oa_d34v_device::track_changed() floppy_image_device::track_changed(); } -mfd51w_device::mfd51w_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : mac_floppy_device(mconfig, MFD51W, tag, owner, clock) +mfd51w_device::mfd51w_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mac_floppy_device(mconfig, MFD51W, tag, owner, clock) { } void mfd51w_device::setup_characteristics() @@ -3009,7 +3009,7 @@ bool mfd51w_device::is_2m() const return true; } -mfd75w_device::mfd75w_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : mac_floppy_device(mconfig, MFD75W, tag, owner, clock) +mfd75w_device::mfd75w_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mac_floppy_device(mconfig, MFD75W, tag, owner, clock) { m_has_mfm = true; } diff --git a/src/devices/imagedev/floppy.h b/src/devices/imagedev/floppy.h index 3d551ee72ab..8f04c73ac31 100644 --- a/src/devices/imagedev/floppy.h +++ b/src/devices/imagedev/floppy.h @@ -164,7 +164,7 @@ protected: virtual void add_format(const floppy_image_format_t &type, u32 image_size, const char *name, const char *description) override; }; - floppy_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + floppy_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -309,7 +309,7 @@ protected: #define DECLARE_FLOPPY_IMAGE_DEVICE(Type, Name, Interface) \ class Name : public floppy_image_device { \ public: \ - Name(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); \ + Name(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); \ virtual ~Name(); \ virtual const char *image_interface() const noexcept override { return Interface; } \ protected: \ @@ -369,7 +369,7 @@ protected: bool m_strb; bool m_mfm, m_has_mfm; - mac_floppy_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mac_floppy_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -381,7 +381,7 @@ protected: // 400K GCR class oa_d34v_device : public mac_floppy_device { public: - oa_d34v_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + oa_d34v_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~oa_d34v_device() = default; protected: virtual void setup_characteristics() override; @@ -393,7 +393,7 @@ protected: // 400/800K GCR (e.g. dual-sided) class mfd51w_device : public mac_floppy_device { public: - mfd51w_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mfd51w_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~mfd51w_device() = default; protected: virtual void setup_characteristics() override; @@ -404,7 +404,7 @@ protected: // 400/800K GCR + 1.44 MFM (Superdrive) class mfd75w_device : public mac_floppy_device { public: - mfd75w_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mfd75w_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~mfd75w_device() = default; protected: @@ -425,7 +425,7 @@ DECLARE_DEVICE_TYPE(MFD75W, mfd75w_device) class floppy_sound_device : public samples_device { public: - floppy_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + floppy_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void motor(bool on, bool withdisk); void step(int track); bool samples_loaded() { return m_loaded; } @@ -463,7 +463,7 @@ class floppy_connector: public device_t, public: template <typename T> floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt, std::function<void (format_registration &fr)> formats, bool fixed = false) - : floppy_connector(mconfig, tag, owner, 0) + : floppy_connector(mconfig, tag, owner) { option_reset(); opts(*this); @@ -472,7 +472,7 @@ public: set_formats(formats); } floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, const char *option, const device_type &devtype, bool is_default, std::function<void (format_registration &fr)> formats) - : floppy_connector(mconfig, tag, owner, 0) + : floppy_connector(mconfig, tag, owner) { option_reset(); option_add(option, devtype); @@ -481,7 +481,7 @@ public: set_fixed(false); set_formats(formats); } - floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + floppy_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~floppy_connector(); void set_formats(std::function<void (format_registration &fr)> formats); diff --git a/src/devices/imagedev/harddriv.cpp b/src/devices/imagedev/harddriv.cpp index decb4e09909..fdd96bf2e81 100644 --- a/src/devices/imagedev/harddriv.cpp +++ b/src/devices/imagedev/harddriv.cpp @@ -43,7 +43,7 @@ DEFINE_DEVICE_TYPE(HARDDISK, harddisk_image_device, "harddisk_image", "Harddisk" // harddisk_image_base_device - constructor //------------------------------------------------- -harddisk_image_base_device::harddisk_image_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +harddisk_image_base_device::harddisk_image_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_image_interface(mconfig, *this) { @@ -53,7 +53,7 @@ harddisk_image_base_device::harddisk_image_base_device(const machine_config &mco // harddisk_image_device - constructor //------------------------------------------------- -harddisk_image_device::harddisk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +harddisk_image_device::harddisk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : harddisk_image_device(mconfig, HARDDISK, tag, owner, clock) { } @@ -62,7 +62,7 @@ harddisk_image_device::harddisk_image_device(const machine_config &mconfig, cons // harddisk_image_device - constructor for subclasses //------------------------------------------------- -harddisk_image_device::harddisk_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +harddisk_image_device::harddisk_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : harddisk_image_base_device(mconfig, type, tag, owner, clock), m_chd(nullptr), m_hard_disk_handle(nullptr), diff --git a/src/devices/imagedev/harddriv.h b/src/devices/imagedev/harddriv.h index 5b3b8d7dde3..0101354c67b 100644 --- a/src/devices/imagedev/harddriv.h +++ b/src/devices/imagedev/harddriv.h @@ -24,7 +24,7 @@ class harddisk_image_base_device : public device_t, public device_image_interfac { protected: // construction/destruction - harddisk_image_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + harddisk_image_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // image-level overrides virtual bool is_readable() const noexcept override { return true; } @@ -42,11 +42,11 @@ class harddisk_image_device : public harddisk_image_base_device public: // construction/destruction harddisk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intf) - : harddisk_image_device(mconfig, tag, owner, (uint32_t)0) + : harddisk_image_device(mconfig, tag, owner) { set_interface(intf); } - harddisk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + harddisk_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~harddisk_image_device(); template <typename... T> void set_device_load(T &&... args) { m_device_image_load.set(std::forward<T>(args)...); } @@ -67,7 +67,7 @@ public: hard_disk_file *get_hard_disk_file() { return m_hard_disk_handle; } protected: - harddisk_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + harddisk_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_config_complete() override; diff --git a/src/devices/imagedev/magtape.cpp b/src/devices/imagedev/magtape.cpp index dd1754ff4e3..02660b5db9c 100644 --- a/src/devices/imagedev/magtape.cpp +++ b/src/devices/imagedev/magtape.cpp @@ -18,13 +18,13 @@ #include "softlist_dev.h" -magtape_image_device::magtape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +magtape_image_device::magtape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_image_interface(mconfig, *this) { } -microtape_image_device::microtape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +microtape_image_device::microtape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : magtape_image_device(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/imagedev/magtape.h b/src/devices/imagedev/magtape.h index 5834573240c..3feb855a25a 100644 --- a/src/devices/imagedev/magtape.h +++ b/src/devices/imagedev/magtape.h @@ -33,7 +33,7 @@ public: protected: // construction/destruction - magtape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + magtape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device_image_interface implementation virtual const software_list_loader &get_software_list_loader() const override; @@ -45,7 +45,7 @@ class microtape_image_device : public magtape_image_device { protected: // construction/destruction - microtape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + microtape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // image-level overrides virtual const char *image_type_name() const noexcept override { return "microtape"; } diff --git a/src/devices/imagedev/mfmhd.cpp b/src/devices/imagedev/mfmhd.cpp index 7bbab1e97da..34a3a667836 100644 --- a/src/devices/imagedev/mfmhd.cpp +++ b/src/devices/imagedev/mfmhd.cpp @@ -304,7 +304,7 @@ enum STEP_SETTLE }; -mfm_harddisk_device::mfm_harddisk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mfm_harddisk_device::mfm_harddisk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_image_interface(mconfig, *this), m_index_timer(nullptr), @@ -938,7 +938,7 @@ int mfm_harddisk_device::get_actual_heads() /* The generic HD takes any kind of CHD HD image and magically creates enough heads and cylinders. */ -mfm_hd_generic_device::mfm_hd_generic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mfm_hd_generic_device::mfm_hd_generic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mfm_harddisk_device(mconfig, MFMHD_GENERIC, tag, owner, clock) { } @@ -948,7 +948,7 @@ DEFINE_DEVICE_TYPE(MFMHD_GENERIC, mfm_hd_generic_device, "mfm_harddisk", "Generi /* Various models. */ -mfm_hd_st213_device::mfm_hd_st213_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mfm_hd_st213_device::mfm_hd_st213_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mfm_harddisk_device(mconfig, MFMHD_ST213, tag, owner, clock) { m_phys_cylinders = 670; @@ -961,7 +961,7 @@ mfm_hd_st213_device::mfm_hd_st213_device(const machine_config &mconfig, const ch DEFINE_DEVICE_TYPE(MFMHD_ST213, mfm_hd_st213_device, "mfm_hd_st213", "Seagate ST-213 MFM hard disk") -mfm_hd_st225_device::mfm_hd_st225_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mfm_hd_st225_device::mfm_hd_st225_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mfm_harddisk_device(mconfig, MFMHD_ST225, tag, owner, clock) { m_phys_cylinders = 670; @@ -974,7 +974,7 @@ mfm_hd_st225_device::mfm_hd_st225_device(const machine_config &mconfig, const ch DEFINE_DEVICE_TYPE(MFMHD_ST225, mfm_hd_st225_device, "mfm_hd_st225", "Seagate ST-225 MFM hard disk") -mfm_hd_st251_device::mfm_hd_st251_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mfm_hd_st251_device::mfm_hd_st251_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mfm_harddisk_device(mconfig, MFMHD_ST251, tag, owner, clock) { m_phys_cylinders = 821; @@ -1182,7 +1182,7 @@ uint16_t* mfmhd_trackimage_cache::get_trackimage(int cylinder, int head) // ================================================================ -mfm_harddisk_connector::mfm_harddisk_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +mfm_harddisk_connector::mfm_harddisk_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, MFM_HD_CONNECTOR, tag, owner, clock), device_slot_interface(mconfig, *this), m_encoding(), diff --git a/src/devices/imagedev/mfmhd.h b/src/devices/imagedev/mfmhd.h index ce66a43fa3b..4ae5f23a27a 100644 --- a/src/devices/imagedev/mfmhd.h +++ b/src/devices/imagedev/mfmhd.h @@ -113,7 +113,7 @@ public: int get_actual_heads(); protected: - mfm_harddisk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mfm_harddisk_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_stop() override; @@ -188,7 +188,7 @@ private: class mfm_hd_generic_device : public mfm_harddisk_device { public: - mfm_hd_generic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mfm_hd_generic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(MFMHD_GENERIC, mfm_hd_generic_device) @@ -196,7 +196,7 @@ DECLARE_DEVICE_TYPE(MFMHD_GENERIC, mfm_hd_generic_device) class mfm_hd_st213_device : public mfm_harddisk_device { public: - mfm_hd_st213_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mfm_hd_st213_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(MFMHD_ST213, mfm_hd_st213_device) @@ -204,7 +204,7 @@ DECLARE_DEVICE_TYPE(MFMHD_ST213, mfm_hd_st213_device) class mfm_hd_st225_device : public mfm_harddisk_device { public: - mfm_hd_st225_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mfm_hd_st225_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(MFMHD_ST225, mfm_hd_st225_device) @@ -212,7 +212,7 @@ DECLARE_DEVICE_TYPE(MFMHD_ST225, mfm_hd_st225_device) class mfm_hd_st251_device : public mfm_harddisk_device { public: - mfm_hd_st251_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mfm_hd_st251_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(MFMHD_ST251, mfm_hd_st251_device) @@ -228,7 +228,7 @@ public: template <typename T> mfm_harddisk_connector(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt, mfmhd_enc_t enc, int spinup, int cache, const mfmhd_format_type format, bool fixed = false) - : mfm_harddisk_connector(mconfig, tag, owner, 0) + : mfm_harddisk_connector(mconfig, tag, owner) { option_reset(); opts(*this); @@ -237,7 +237,7 @@ public: configure(enc, spinup, cache, format); } - mfm_harddisk_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mfm_harddisk_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); ~mfm_harddisk_connector(); mfm_harddisk_device *get_device(); diff --git a/src/devices/imagedev/microdrv.cpp b/src/devices/imagedev/microdrv.cpp index 02168270523..a2c44d7de3a 100644 --- a/src/devices/imagedev/microdrv.cpp +++ b/src/devices/imagedev/microdrv.cpp @@ -45,7 +45,7 @@ DEFINE_DEVICE_TYPE(MICRODRIVE, microdrive_image_device, "microdrive_image", "Sin // microdrive_image_device - constructor //------------------------------------------------- -microdrive_image_device::microdrive_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +microdrive_image_device::microdrive_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : microtape_image_device(mconfig, MICRODRIVE, tag, owner, clock), m_write_comms_out(*this) { diff --git a/src/devices/imagedev/microdrv.h b/src/devices/imagedev/microdrv.h index 5bd7d6a37da..51cfcd6676a 100644 --- a/src/devices/imagedev/microdrv.h +++ b/src/devices/imagedev/microdrv.h @@ -34,7 +34,7 @@ class microdrive_image_device : public microtape_image_device { public: // construction/destruction - microdrive_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + microdrive_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~microdrive_image_device(); auto comms_out_wr_callback() { return m_write_comms_out.bind(); } diff --git a/src/devices/imagedev/midiin.cpp b/src/devices/imagedev/midiin.cpp index 59211d06f88..cefeb6cfb05 100644 --- a/src/devices/imagedev/midiin.cpp +++ b/src/devices/imagedev/midiin.cpp @@ -48,7 +48,7 @@ INPUT_PORTS_END ctor -------------------------------------------------*/ -midiin_device::midiin_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +midiin_device::midiin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MIDIIN, tag, owner, clock), device_image_interface(mconfig, *this), device_serial_interface(mconfig, *this), @@ -90,8 +90,8 @@ void midiin_device::device_reset() // we don't Rx, we Tx at 31250 8-N-1 set_data_frame(1, 8, PARITY_NONE, STOP_BITS_1); - set_rcv_rate(0); - set_tra_rate(31250); + set_rcv_rate(XTAL::u(0)); + set_tra_rate(XTAL::u(31250)); } /*------------------------------------------------- diff --git a/src/devices/imagedev/midiin.h b/src/devices/imagedev/midiin.h index aed7d3b15a9..02bd4e16ee7 100644 --- a/src/devices/imagedev/midiin.h +++ b/src/devices/imagedev/midiin.h @@ -26,7 +26,7 @@ class midiin_device : public device_t, { public: // construction/destruction - midiin_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + midiin_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~midiin_device(); auto input_callback() { return m_input_cb.bind(); } diff --git a/src/devices/imagedev/midiout.cpp b/src/devices/imagedev/midiout.cpp index 026b6520143..08130f5746f 100644 --- a/src/devices/imagedev/midiout.cpp +++ b/src/devices/imagedev/midiout.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(MIDIOUT, midiout_device, "midiout", "MIDI Out image device") ctor -------------------------------------------------*/ -midiout_device::midiout_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +midiout_device::midiout_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MIDIOUT, tag, owner, clock), device_image_interface(mconfig, *this), device_serial_interface(mconfig, *this), @@ -47,8 +47,8 @@ void midiout_device::device_reset() { // we don't Tx, we Rx at 31250 8-N-1 set_data_frame(1, 8, PARITY_NONE, STOP_BITS_1); - set_rcv_rate(31250); - set_tra_rate(0); + set_rcv_rate(XTAL::u(31250)); + set_tra_rate(XTAL::u(0)); } /*------------------------------------------------- diff --git a/src/devices/imagedev/midiout.h b/src/devices/imagedev/midiout.h index 7b39e4fff5e..5714d239985 100644 --- a/src/devices/imagedev/midiout.h +++ b/src/devices/imagedev/midiout.h @@ -26,7 +26,7 @@ class midiout_device : public device_t, { public: // construction/destruction - midiout_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + midiout_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~midiout_device(); // image-level overrides diff --git a/src/devices/imagedev/papertape.cpp b/src/devices/imagedev/papertape.cpp index f8cea6b2996..3522f6e4821 100644 --- a/src/devices/imagedev/papertape.cpp +++ b/src/devices/imagedev/papertape.cpp @@ -16,18 +16,18 @@ #include "softlist_dev.h" -paper_tape_image_device::paper_tape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +paper_tape_image_device::paper_tape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_image_interface(mconfig, *this) { } -paper_tape_reader_device::paper_tape_reader_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +paper_tape_reader_device::paper_tape_reader_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : paper_tape_image_device(mconfig, type, tag, owner, clock) { } -paper_tape_punch_device::paper_tape_punch_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +paper_tape_punch_device::paper_tape_punch_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : paper_tape_image_device(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/imagedev/papertape.h b/src/devices/imagedev/papertape.h index a0fa6b9cada..a90dabc45f4 100644 --- a/src/devices/imagedev/papertape.h +++ b/src/devices/imagedev/papertape.h @@ -29,7 +29,7 @@ public: protected: // construction/destruction - paper_tape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + paper_tape_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> paper_tape_reader_device @@ -45,7 +45,7 @@ public: protected: // construction/destruction - paper_tape_reader_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + paper_tape_reader_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device_image_interface implementation virtual const software_list_loader &get_software_list_loader() const override; @@ -65,7 +65,7 @@ public: protected: // construction/destruction - paper_tape_punch_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + paper_tape_punch_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; #endif // MAME_DEVICES_IMAGEDEV_PAPERTAPE_H diff --git a/src/devices/imagedev/picture.cpp b/src/devices/imagedev/picture.cpp index b617cd2eeba..ffb8c3e1899 100644 --- a/src/devices/imagedev/picture.cpp +++ b/src/devices/imagedev/picture.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(IMAGE_PICTURE, picture_image_device, "picture_image", "Still // picture_image_device - constructor //------------------------------------------------- -picture_image_device::picture_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +picture_image_device::picture_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IMAGE_PICTURE, tag, owner, clock), device_image_interface(mconfig, *this) { diff --git a/src/devices/imagedev/picture.h b/src/devices/imagedev/picture.h index b53dab22062..6f0df15986a 100644 --- a/src/devices/imagedev/picture.h +++ b/src/devices/imagedev/picture.h @@ -26,7 +26,7 @@ class picture_image_device : public device_t, { public: // construction/destruction - picture_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + picture_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~picture_image_device(); // image-level overrides diff --git a/src/devices/imagedev/printer.cpp b/src/devices/imagedev/printer.cpp index 2eb187d843a..0bcef6b9f7e 100644 --- a/src/devices/imagedev/printer.cpp +++ b/src/devices/imagedev/printer.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(PRINTER, printer_image_device, "printer_image", "Printer") // printer_image_device - constructor //------------------------------------------------- -printer_image_device::printer_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +printer_image_device::printer_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PRINTER, tag, owner, clock), device_image_interface(mconfig, *this), m_online_cb(*this) diff --git a/src/devices/imagedev/printer.h b/src/devices/imagedev/printer.h index 509ecc43ef2..0b8c16de166 100644 --- a/src/devices/imagedev/printer.h +++ b/src/devices/imagedev/printer.h @@ -25,7 +25,7 @@ class printer_image_device : public device_t, { public: // construction/destruction - printer_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + printer_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto online_callback() { return m_online_cb.bind(); } diff --git a/src/devices/imagedev/snapquik.cpp b/src/devices/imagedev/snapquik.cpp index 53c682827ea..0726a0c334a 100644 --- a/src/devices/imagedev/snapquik.cpp +++ b/src/devices/imagedev/snapquik.cpp @@ -20,12 +20,12 @@ DEFINE_DEVICE_TYPE(SNAPSHOT, snapshot_image_device, "snapsot_image", "Snapshot") // snapshot_image_device - constructor //------------------------------------------------- -snapshot_image_device::snapshot_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +snapshot_image_device::snapshot_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : snapshot_image_device(mconfig, SNAPSHOT, tag, owner, clock) { } -snapshot_image_device::snapshot_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +snapshot_image_device::snapshot_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_image_interface(mconfig, *this) , m_load(*this) @@ -90,7 +90,7 @@ DEFINE_DEVICE_TYPE(QUICKLOAD, quickload_image_device, "quickload", "Quickload") // quickload_image_device - constructor //------------------------------------------------- -quickload_image_device::quickload_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +quickload_image_device::quickload_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : snapshot_image_device(mconfig, QUICKLOAD, tag, owner, clock) { } diff --git a/src/devices/imagedev/snapquik.h b/src/devices/imagedev/snapquik.h index f312e4d4f39..489db53cb35 100644 --- a/src/devices/imagedev/snapquik.h +++ b/src/devices/imagedev/snapquik.h @@ -22,12 +22,12 @@ public: // construction/destruction snapshot_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const char* extensions, attotime delay = attotime::zero) - : snapshot_image_device(mconfig, tag, owner, 0U) + : snapshot_image_device(mconfig, tag, owner) { set_extensions(extensions); set_delay(delay); } - snapshot_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snapshot_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~snapshot_image_device(); void set_interface(const char *interface) { m_interface = interface; } @@ -49,7 +49,7 @@ public: template <typename... T> void set_load_callback(T &&... args) { m_load.set(std::forward<T>(args)...); } protected: - snapshot_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + snapshot_image_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -76,12 +76,12 @@ class quickload_image_device : public snapshot_image_device public: // construction/destruction quickload_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const char* extensions, attotime delay = attotime::zero) - : quickload_image_device(mconfig, tag, owner, 0U) + : quickload_image_device(mconfig, tag, owner) { set_extensions(extensions); set_delay(delay); } - quickload_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0U); + quickload_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual const char *image_type_name() const noexcept override { return "quickload"; } virtual const char *image_brief_type_name() const noexcept override { return "quik"; } diff --git a/src/devices/imagedev/wafadrive.cpp b/src/devices/imagedev/wafadrive.cpp index 237e809075b..1958aaee0b4 100644 --- a/src/devices/imagedev/wafadrive.cpp +++ b/src/devices/imagedev/wafadrive.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(WAFADRIVE_IMAGE, wafadrive_image_device, "wafadrive_image", " // microdrive_image_device - constructor //------------------------------------------------- -wafadrive_image_device::wafadrive_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wafadrive_image_device::wafadrive_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : microtape_image_device(mconfig, WAFADRIVE_IMAGE, tag, owner, clock) { } diff --git a/src/devices/imagedev/wafadrive.h b/src/devices/imagedev/wafadrive.h index 532288dcba9..435e27f1247 100644 --- a/src/devices/imagedev/wafadrive.h +++ b/src/devices/imagedev/wafadrive.h @@ -26,7 +26,7 @@ class wafadrive_image_device : public microtape_image_device { public: // construction/destruction - wafadrive_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + wafadrive_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~wafadrive_image_device(); // image-level overrides diff --git a/src/devices/machine/1ma6.cpp b/src/devices/machine/1ma6.cpp index 621e6aa6960..4e2b3936784 100644 --- a/src/devices/machine/1ma6.cpp +++ b/src/devices/machine/1ma6.cpp @@ -110,7 +110,7 @@ enum { HOLE_TMR_ID }; -hp_1ma6_device::hp_1ma6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp_1ma6_device::hp_1ma6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , HP_1MA6 , tag , owner , clock) , m_tape(*this , "drive") { diff --git a/src/devices/machine/1ma6.h b/src/devices/machine/1ma6.h index cb083e05c88..27f8a95ddf1 100644 --- a/src/devices/machine/1ma6.h +++ b/src/devices/machine/1ma6.h @@ -20,7 +20,7 @@ class hp_1ma6_device : public device_t { public: // construction/destruction - hp_1ma6_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_1ma6_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Register read/write void reg_w(offs_t offset, uint8_t data); diff --git a/src/devices/machine/1mb5.cpp b/src/devices/machine/1mb5.cpp index 054202b06e1..79b7e007aad 100644 --- a/src/devices/machine/1mb5.cpp +++ b/src/devices/machine/1mb5.cpp @@ -48,7 +48,7 @@ namespace { } } -hp_1mb5_device::hp_1mb5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp_1mb5_device::hp_1mb5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , HP_1MB5 , tag , owner , clock), m_irl_handler(*this), m_halt_handler(*this), diff --git a/src/devices/machine/1mb5.h b/src/devices/machine/1mb5.h index 13b1296e6cc..bd2821cf3c0 100644 --- a/src/devices/machine/1mb5.h +++ b/src/devices/machine/1mb5.h @@ -17,7 +17,7 @@ class hp_1mb5_device : public device_t { public: // construction/destruction - hp_1mb5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_1mb5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // static configuration helpers auto irl_handler() { return m_irl_handler.bind(); } diff --git a/src/devices/machine/2812fifo.cpp b/src/devices/machine/2812fifo.cpp index 3cc10965ecb..ffa019b8c3e 100644 --- a/src/devices/machine/2812fifo.cpp +++ b/src/devices/machine/2812fifo.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(FIFO2812, fifo2812_device, "fifo2812", "2812 32x8 FIFO Memory"); -fifo2812_device::fifo2812_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) : +fifo2812_device::fifo2812_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, FIFO2812, tag, owner, clock), m_q_cb(*this), m_ir_cb(*this), diff --git a/src/devices/machine/2812fifo.h b/src/devices/machine/2812fifo.h index 01c42624c09..5ed387ff80a 100644 --- a/src/devices/machine/2812fifo.h +++ b/src/devices/machine/2812fifo.h @@ -32,7 +32,7 @@ class fifo2812_device : public device_t { public: // standard constructor - fifo2812_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + fifo2812_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // callbacks auto q_cb() { return m_q_cb.bind(); } diff --git a/src/devices/machine/28fxxx.cpp b/src/devices/machine/28fxxx.cpp index 60351ee7565..f104114e433 100644 --- a/src/devices/machine/28fxxx.cpp +++ b/src/devices/machine/28fxxx.cpp @@ -48,7 +48,7 @@ DEFINE_DEVICE_TYPE(AMD_28F020, amd_28f020_device, "amd_28f020", "Am28F020 2 Mega ALLOW_SAVE_TYPE(base_28fxxx_device::state); -base_28fxxx_device::base_28fxxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 size, u8 manufacturer_code, u8 device_code) +base_28fxxx_device::base_28fxxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 size, u8 manufacturer_code, u8 device_code) : device_t(mconfig, type, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_region(*this, DEVICE_SELF) @@ -62,17 +62,17 @@ base_28fxxx_device::base_28fxxx_device(const machine_config &mconfig, device_typ throw emu_fatalerror("%s(%s): memory size must be an exact power of two", type.shortname(), tag); } -intel_28f010_device::intel_28f010_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +intel_28f010_device::intel_28f010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : base_28fxxx_device(mconfig, INTEL_28F010, tag, owner, clock, 0x20000, MFG_INTEL, 0xb4) { } -amd_28f010_device::amd_28f010_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +amd_28f010_device::amd_28f010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : base_28fxxx_device(mconfig, AMD_28F010, tag, owner, clock, 0x20000, MFG_AMD, 0xa7) { } -amd_28f020_device::amd_28f020_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +amd_28f020_device::amd_28f020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : base_28fxxx_device(mconfig, AMD_28F020, tag, owner, clock, 0x40000, MFG_AMD, 0x2a) { } diff --git a/src/devices/machine/28fxxx.h b/src/devices/machine/28fxxx.h index 9ec25a6a7d9..55bb6c5172a 100644 --- a/src/devices/machine/28fxxx.h +++ b/src/devices/machine/28fxxx.h @@ -26,7 +26,7 @@ public: void write(offs_t offset, u8 data); protected: - base_28fxxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 size, u8 manufacturer_code, u8 device_code); + base_28fxxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 size, u8 manufacturer_code, u8 device_code); virtual void device_start() override; @@ -69,19 +69,19 @@ private: class intel_28f010_device : public base_28fxxx_device { public: - intel_28f010_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + intel_28f010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class amd_28f010_device : public base_28fxxx_device { public: - amd_28f010_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + amd_28f010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class amd_28f020_device : public base_28fxxx_device { public: - amd_28f020_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + amd_28f020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(INTEL_28F010, intel_28f010_device) diff --git a/src/devices/machine/40105.cpp b/src/devices/machine/40105.cpp index ffcfab73da9..51279c61e39 100644 --- a/src/devices/machine/40105.cpp +++ b/src/devices/machine/40105.cpp @@ -43,7 +43,7 @@ DEFINE_DEVICE_TYPE(CD40105, cmos_40105_device, "cd40105", "CD40105B FIFO Registe // cmos_40105_device - constructor //------------------------------------------------- -cmos_40105_device::cmos_40105_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cmos_40105_device::cmos_40105_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CD40105, tag, owner, clock), m_write_dir(*this), m_write_dor(*this), diff --git a/src/devices/machine/40105.h b/src/devices/machine/40105.h index 5b35de12a58..82d61cbc053 100644 --- a/src/devices/machine/40105.h +++ b/src/devices/machine/40105.h @@ -35,7 +35,7 @@ class cmos_40105_device : public device_t { public: // construction/destruction - cmos_40105_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cmos_40105_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto in_ready_cb() { return m_write_dir.bind(); } auto out_ready_cb() { return m_write_dor.bind(); } diff --git a/src/devices/machine/53c7xx.cpp b/src/devices/machine/53c7xx.cpp index 754d2714909..1dacd5196bc 100644 --- a/src/devices/machine/53c7xx.cpp +++ b/src/devices/machine/53c7xx.cpp @@ -87,7 +87,7 @@ DEFINE_DEVICE_TYPE(NCR53C7XX, ncr53c7xx_device, "ncr537xx", "NCR 53C7xx SCSI") // ncr53c7xx_device - constructor/destructor //------------------------------------------------- -ncr53c7xx_device::ncr53c7xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ncr53c7xx_device::ncr53c7xx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_device(mconfig, NCR53C7XX, tag, owner, clock), nscsi_slot_card_interface(mconfig, *this, DEVICE_SELF), device_execute_interface(mconfig, *this), diff --git a/src/devices/machine/53c7xx.h b/src/devices/machine/53c7xx.h index 2d6c695acd2..f7b351b0bff 100644 --- a/src/devices/machine/53c7xx.h +++ b/src/devices/machine/53c7xx.h @@ -20,7 +20,7 @@ class ncr53c7xx_device : public nscsi_device, public nscsi_slot_card_interface, { public: // construction/destruction - ncr53c7xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ncr53c7xx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // static configuration helpers auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/machine/53c810.cpp b/src/devices/machine/53c810.cpp index 261d640b340..f9f622a98d2 100644 --- a/src/devices/machine/53c810.cpp +++ b/src/devices/machine/53c810.cpp @@ -621,7 +621,7 @@ void lsi53c810_device::add_opcode(uint8_t op, uint8_t mask, opcode_handler_deleg } } -lsi53c810_device::lsi53c810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lsi53c810_device::lsi53c810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : legacy_scsi_host_adapter(mconfig, LSI53C810, tag, owner, clock) , m_irq_cb(*this) , m_dma_cb(*this) diff --git a/src/devices/machine/53c810.h b/src/devices/machine/53c810.h index b6ecd035072..3a98c670144 100644 --- a/src/devices/machine/53c810.h +++ b/src/devices/machine/53c810.h @@ -15,7 +15,7 @@ public: typedef device_delegate<uint32_t (uint32_t dsp)> fetch_delegate; // construction/destruction - lsi53c810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + lsi53c810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename... T> void set_irq_callback(T &&... args) { diff --git a/src/devices/machine/64h156.cpp b/src/devices/machine/64h156.cpp index bf859402e55..ba190ff0341 100644 --- a/src/devices/machine/64h156.cpp +++ b/src/devices/machine/64h156.cpp @@ -55,7 +55,7 @@ DEFINE_DEVICE_TYPE(C64H156, c64h156_device, "c64h156", "Commodore 64H156") // c64h156_device - constructor //------------------------------------------------- -c64h156_device::c64h156_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +c64h156_device::c64h156_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C64H156, tag, owner, clock), m_write_atn(*this), m_write_sync(*this), diff --git a/src/devices/machine/64h156.h b/src/devices/machine/64h156.h index 0f6508caab6..ee9a1079405 100644 --- a/src/devices/machine/64h156.h +++ b/src/devices/machine/64h156.h @@ -76,7 +76,7 @@ class c64h156_device : public device_t { public: // construction/destruction - c64h156_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c64h156_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto atn_callback() { return m_write_atn.bind(); } auto sync_callback() { return m_write_sync.bind(); } diff --git a/src/devices/machine/6522via.cpp b/src/devices/machine/6522via.cpp index 5224fc4fbd5..56ef0a3e0dc 100644 --- a/src/devices/machine/6522via.cpp +++ b/src/devices/machine/6522via.cpp @@ -180,7 +180,7 @@ void via6522_device::map(address_map &map) // via6522_device - constructor //------------------------------------------------- -via6522_device::via6522_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +via6522_device::via6522_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_in_a_handler(*this), m_in_b_handler(*this), @@ -209,7 +209,7 @@ via6522_device::via6522_device(const machine_config &mconfig, device_type type, // mos6522_device - constructor //------------------------------------------------- -mos6522_device::mos6522_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6522_device::mos6522_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : via6522_device(mconfig, MOS6522, tag, owner, clock) { } @@ -219,7 +219,7 @@ mos6522_device::mos6522_device(const machine_config &mconfig, const char *tag, d // r65c22_device - constructor //------------------------------------------------- -r65c22_device::r65c22_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +r65c22_device::r65c22_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : via6522_device(mconfig, R65C22, tag, owner, clock) { } @@ -229,7 +229,7 @@ r65c22_device::r65c22_device(const machine_config &mconfig, const char *tag, dev // r65c22_device - constructor //------------------------------------------------- -r65nc22_device::r65nc22_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +r65nc22_device::r65nc22_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : via6522_device(mconfig, R65NC22, tag, owner, clock) { } @@ -239,7 +239,7 @@ r65nc22_device::r65nc22_device(const machine_config &mconfig, const char *tag, d // w65c22s_device - constructor //------------------------------------------------- -w65c22s_device::w65c22s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +w65c22s_device::w65c22s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : via6522_device(mconfig, W65C22S, tag, owner, clock) { } diff --git a/src/devices/machine/6522via.h b/src/devices/machine/6522via.h index 813a74a63d5..87ae018b31f 100644 --- a/src/devices/machine/6522via.h +++ b/src/devices/machine/6522via.h @@ -118,7 +118,7 @@ public: protected: // construction/destruction - via6522_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + via6522_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -213,7 +213,7 @@ class mos6522_device : public via6522_device { public: // construction/destruction - mos6522_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6522_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> r65c22_device @@ -222,7 +222,7 @@ class r65c22_device : public via6522_device { public: // construction/destruction - r65c22_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + r65c22_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> r65nc22_device @@ -231,7 +231,7 @@ class r65nc22_device : public via6522_device { public: // construction/destruction - r65nc22_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + r65nc22_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> w65c22s_device @@ -240,7 +240,7 @@ class w65c22s_device : public via6522_device { public: // construction/destruction - w65c22s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + w65c22s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/machine/6525tpi.cpp b/src/devices/machine/6525tpi.cpp index 83d28fc0355..2c1ee826c58 100644 --- a/src/devices/machine/6525tpi.cpp +++ b/src/devices/machine/6525tpi.cpp @@ -106,7 +106,7 @@ DEFINE_DEVICE_TYPE(TPI6525, tpi6525_device, "tpi6525", "6525 TPI") -tpi6525_device::tpi6525_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tpi6525_device::tpi6525_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TPI6525, tag, owner, clock), m_out_irq_cb(*this), m_in_pa_cb(*this), diff --git a/src/devices/machine/6525tpi.h b/src/devices/machine/6525tpi.h index 4052662d50a..f558c7ddd72 100644 --- a/src/devices/machine/6525tpi.h +++ b/src/devices/machine/6525tpi.h @@ -41,7 +41,7 @@ class tpi6525_device : public device_t { public: - tpi6525_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tpi6525_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_irq_cb() { return m_out_irq_cb.bind(); } auto in_pa_cb() { return m_in_pa_cb.bind(); } diff --git a/src/devices/machine/6532riot.cpp b/src/devices/machine/6532riot.cpp index cdeb8e673af..a4fd8ed0647 100644 --- a/src/devices/machine/6532riot.cpp +++ b/src/devices/machine/6532riot.cpp @@ -413,7 +413,7 @@ WRITE_LINE_MEMBER(riot6532_device::pb7_w) { portb_in_set(state ? 0x80 : 0x00, 0x // riot6532_device - constructor //------------------------------------------------- -riot6532_device::riot6532_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +riot6532_device::riot6532_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RIOT6532, tag, owner, clock), m_in_pa_cb(*this), m_out_pa_cb(*this), diff --git a/src/devices/machine/6532riot.h b/src/devices/machine/6532riot.h index 56156f929c3..7a04e709f9d 100644 --- a/src/devices/machine/6532riot.h +++ b/src/devices/machine/6532riot.h @@ -24,7 +24,7 @@ class riot6532_device : public device_t { public: // construction/destruction - riot6532_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + riot6532_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto in_pa_callback() { return m_in_pa_cb.bind(); } auto out_pa_callback() { return m_out_pa_cb.bind(); } diff --git a/src/devices/machine/68153bim.cpp b/src/devices/machine/68153bim.cpp index 20d63ef959e..06f8f74f13b 100644 --- a/src/devices/machine/68153bim.cpp +++ b/src/devices/machine/68153bim.cpp @@ -69,10 +69,10 @@ DEFINE_DEVICE_TYPE(EI68C153, ei68c153_device, "ei68c153", "EPIC void bim68153_device::device_add_mconfig(machine_config &config) { - MC68153_CHANNEL(config, m_chn[0], 0); - MC68153_CHANNEL(config, m_chn[1], 0); - MC68153_CHANNEL(config, m_chn[2], 0); - MC68153_CHANNEL(config, m_chn[3], 0); + MC68153_CHANNEL(config, m_chn[0]); + MC68153_CHANNEL(config, m_chn[1]); + MC68153_CHANNEL(config, m_chn[2]); + MC68153_CHANNEL(config, m_chn[3]); } //************************************************************************** @@ -82,7 +82,7 @@ void bim68153_device::device_add_mconfig(machine_config &config) //------------------------------------------------- // bim68153_device - constructor //------------------------------------------------- -bim68153_device::bim68153_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +bim68153_device::bim68153_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock) , m_chn{{*this, CHN0_TAG}, {*this, CHN1_TAG}, {*this, CHN2_TAG}, {*this, CHN3_TAG}} , m_out_int_cb(*this) @@ -96,14 +96,14 @@ bim68153_device::bim68153_device(const machine_config &mconfig, device_type type LOG("%s\n", FUNCNAME); } -bim68153_device::bim68153_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bim68153_device::bim68153_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bim68153_device(mconfig, MC68153, tag, owner, clock, TYPE_MC68153) { LOG("%s\n", FUNCNAME); } /* The EPIC EI68C153 is a CMOS implementation that is fully compatible with the bipolar MC68153 from Motorola */ -ei68c153_device::ei68c153_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ei68c153_device::ei68c153_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bim68153_device(mconfig, EI68C153, tag, owner, clock, TYPE_EI68C153) { LOG("%s\n", FUNCNAME); @@ -318,7 +318,7 @@ void bim68153_device::write(offs_t offset, uint8_t data) // BIM CHANNEL //************************************************************************** -bim68153_channel::bim68153_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bim68153_channel::bim68153_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC68153_CHANNEL, tag, owner, clock) , m_out_iack_cb(*this) , m_int_state(NONE) diff --git a/src/devices/machine/68153bim.h b/src/devices/machine/68153bim.h index 124870b8194..4bf511af7f3 100644 --- a/src/devices/machine/68153bim.h +++ b/src/devices/machine/68153bim.h @@ -45,7 +45,7 @@ class bim68153_channel : public device_t friend class bim68153_device; public: - bim68153_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bim68153_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -102,7 +102,7 @@ class bim68153_device : public device_t public: // construction/destruction - bim68153_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bim68153_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u16 iack(int irqline); int acknowledge(); @@ -133,7 +133,7 @@ public: DECLARE_WRITE_LINE_MEMBER( int3_w ) { m_chn[CHN_3]->int_w(state); } protected: - bim68153_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + bim68153_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_start() override; @@ -187,7 +187,7 @@ protected: class ei68c153_device : public bim68153_device { public : - ei68c153_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ei68c153_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/machine/6821pia.cpp b/src/devices/machine/6821pia.cpp index 2b32eb164ff..cc28a11eb52 100644 --- a/src/devices/machine/6821pia.cpp +++ b/src/devices/machine/6821pia.cpp @@ -41,7 +41,7 @@ DEFINE_DEVICE_TYPE(PIA6821, pia6821_device, "pia6821", "6821 PIA") // pia6821_device - constructor //------------------------------------------------- -pia6821_device::pia6821_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pia6821_device::pia6821_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PIA6821, tag, owner, clock), m_in_a_handler(*this), m_in_b_handler(*this), diff --git a/src/devices/machine/6821pia.h b/src/devices/machine/6821pia.h index 397b584fa3b..d152b6bcf94 100644 --- a/src/devices/machine/6821pia.h +++ b/src/devices/machine/6821pia.h @@ -34,7 +34,7 @@ class pia6821_device : public device_t { public: // construction/destruction - pia6821_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pia6821_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // TODO: REMOVE THESE auto readpa_handler() { return m_in_a_handler.bind(); } diff --git a/src/devices/machine/68230pit.cpp b/src/devices/machine/68230pit.cpp index d5aeafd4c76..91824db487f 100644 --- a/src/devices/machine/68230pit.cpp +++ b/src/devices/machine/68230pit.cpp @@ -48,7 +48,7 @@ DEFINE_DEVICE_TYPE(PIT68230, pit68230_device, "pit68230", "MC68230 PI/T") //------------------------------------------------- // pit68230_device - constructors //------------------------------------------------- -pit68230_device::pit68230_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +pit68230_device::pit68230_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock) , m_pa_out_cb(*this) , m_pa_in_cb(*this) @@ -87,7 +87,7 @@ pit68230_device::pit68230_device(const machine_config &mconfig, device_type type } -pit68230_device::pit68230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pit68230_device::pit68230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pit68230_device (mconfig, PIT68230, tag, owner, clock, 0) { } diff --git a/src/devices/machine/68230pit.h b/src/devices/machine/68230pit.h index f99c3e541ee..950614f5498 100644 --- a/src/devices/machine/68230pit.h +++ b/src/devices/machine/68230pit.h @@ -72,7 +72,7 @@ class pit68230_device : public device_t { public: // construction/destruction - pit68230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pit68230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto pa_in_callback() { return m_pa_in_cb.bind(); } auto pa_out_callback() { return m_pa_out_cb.bind(); } @@ -272,7 +272,7 @@ protected: REG_TCR_TOUT_PC7_INT = 0xe0, // 1 1 1 }; - pit68230_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + pit68230_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_start() override; diff --git a/src/devices/machine/68307.cpp b/src/devices/machine/68307.cpp index 2a16def71d9..656d673d817 100644 --- a/src/devices/machine/68307.cpp +++ b/src/devices/machine/68307.cpp @@ -56,7 +56,7 @@ void m68307_cpu_device::device_add_mconfig(machine_config &config) } -m68307_cpu_device::m68307_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m68307_cpu_device::m68307_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_device(mconfig, tag, owner, clock, M68307, 16, 24, address_map_constructor(FUNC(m68307_cpu_device::internal_map), this)), m_write_irq(*this), m_write_a_tx(*this), diff --git a/src/devices/machine/68307.h b/src/devices/machine/68307.h index cc5638b5efb..83857f5b3ae 100644 --- a/src/devices/machine/68307.h +++ b/src/devices/machine/68307.h @@ -18,7 +18,7 @@ public: typedef device_delegate<uint16_t (address_space &space, bool dedicated, uint16_t line_mask)> portb_read_delegate; typedef device_delegate<void (address_space &space, bool dedicated, uint16_t data, uint16_t line_mask)> portb_write_delegate; - m68307_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m68307_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); /* trampolines so we can specify the 68681 serial configuration when adding the CPU */ auto serial_a_tx_callback() { return m_write_a_tx.bind(); } diff --git a/src/devices/machine/68340.cpp b/src/devices/machine/68340.cpp index 81719f87a1b..0a37acf927d 100644 --- a/src/devices/machine/68340.cpp +++ b/src/devices/machine/68340.cpp @@ -221,7 +221,7 @@ void m68340_cpu_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -m68340_cpu_device::m68340_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m68340_cpu_device::m68340_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : fscpu32_device(mconfig, tag, owner, clock, M68340, address_map_constructor(FUNC(m68340_cpu_device::m68340_internal_map), this)) , m_serial(*this, "serial") , m_timer(*this, "timer%u", 1U) diff --git a/src/devices/machine/68340.h b/src/devices/machine/68340.h index ef89972a72c..052006b4ba0 100644 --- a/src/devices/machine/68340.h +++ b/src/devices/machine/68340.h @@ -20,7 +20,7 @@ class m68340_cpu_device : public fscpu32_device friend class mc68340_timer_module_device; public: - m68340_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m68340_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto pa_in_callback() { return m_pa_in_cb.bind(); } auto pa_out_callback() { return m_pa_out_cb.bind(); } diff --git a/src/devices/machine/68340ser.cpp b/src/devices/machine/68340ser.cpp index e0fc3b29fde..7f1c2d5a035 100644 --- a/src/devices/machine/68340ser.cpp +++ b/src/devices/machine/68340ser.cpp @@ -152,7 +152,7 @@ WRITE_LINE_MEMBER( mc68340_serial_module_device::irq_w ) m_cpu->update_ipl(); } -mc68340_serial_module_device::mc68340_serial_module_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68340_serial_module_device::mc68340_serial_module_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68340_duart_device(mconfig, MC68340_SERIAL_MODULE, tag, owner, clock) { } diff --git a/src/devices/machine/68340ser.h b/src/devices/machine/68340ser.h index b9775f2ad86..056bc69c30f 100644 --- a/src/devices/machine/68340ser.h +++ b/src/devices/machine/68340ser.h @@ -14,7 +14,7 @@ class mc68340_serial_module_device : public mc68340_duart_device friend class m68340_cpu_device; public: - mc68340_serial_module_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mc68340_serial_module_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // device-level overrides virtual void device_start() override; diff --git a/src/devices/machine/68340tmu.cpp b/src/devices/machine/68340tmu.cpp index 1b358e14f6c..d0e88416fff 100644 --- a/src/devices/machine/68340tmu.cpp +++ b/src/devices/machine/68340tmu.cpp @@ -516,7 +516,7 @@ void mc68340_timer_module_device::tout_clear() } } -mc68340_timer_module_device::mc68340_timer_module_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68340_timer_module_device::mc68340_timer_module_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC68340_TIMER_MODULE, tag, owner, clock) , m_tout_out_cb(*this) , m_tin_in_cb(*this) diff --git a/src/devices/machine/68340tmu.h b/src/devices/machine/68340tmu.h index 653226f8887..e4ea6dd202c 100644 --- a/src/devices/machine/68340tmu.h +++ b/src/devices/machine/68340tmu.h @@ -12,7 +12,7 @@ class mc68340_timer_module_device : public device_t friend class m68340_cpu_device; public: - mc68340_timer_module_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mc68340_timer_module_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint16_t read(offs_t offset, uint16_t mem_mask = ~0); void write(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/machine/6840ptm.cpp b/src/devices/machine/6840ptm.cpp index 4d2a146f0e9..5f42ababdec 100644 --- a/src/devices/machine/6840ptm.cpp +++ b/src/devices/machine/6840ptm.cpp @@ -76,7 +76,7 @@ DEFINE_DEVICE_TYPE(PTM6840, ptm6840_device, "ptm6840", "MC6840 PTM") // ptm6840_device - constructor //------------------------------------------------- -ptm6840_device::ptm6840_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ptm6840_device::ptm6840_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PTM6840, tag, owner, clock) , m_external_clock{ 0.0, 0.0, 0.0 } , m_out_cb(*this) diff --git a/src/devices/machine/6840ptm.h b/src/devices/machine/6840ptm.h index 614901625a4..788526df72a 100644 --- a/src/devices/machine/6840ptm.h +++ b/src/devices/machine/6840ptm.h @@ -24,9 +24,8 @@ class ptm6840_device : public device_t { public: // construction/destruction - ptm6840_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ptm6840_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); - void set_external_clocks(double clock0, double clock1, double clock2) { m_external_clock[0] = clock0; m_external_clock[1] = clock1; m_external_clock[2] = clock2; } void set_external_clocks(const XTAL &clock0, const XTAL &clock1, const XTAL &clock2) { set_external_clocks(clock0.dvalue(), clock1.dvalue(), clock2.dvalue()); } auto o1_callback() { return m_out_cb[0].bind(); } auto o2_callback() { return m_out_cb[1].bind(); } @@ -61,6 +60,7 @@ protected: virtual void device_resolve_objects() override; private: + void set_external_clocks(double clock0, double clock1, double clock2) { m_external_clock[0] = clock0; m_external_clock[1] = clock1; m_external_clock[2] = clock2; } void deduct_from_counter(int idx); void tick(int counter); TIMER_CALLBACK_MEMBER(state_changed); diff --git a/src/devices/machine/6850acia.cpp b/src/devices/machine/6850acia.cpp index 364fcfdfc92..20fde1c7870 100644 --- a/src/devices/machine/6850acia.cpp +++ b/src/devices/machine/6850acia.cpp @@ -71,12 +71,12 @@ DEFINE_DEVICE_TYPE(ACIA6850, acia6850_device, "acia6850", "MC6850 ACIA") // acia6850_device - constructor //------------------------------------------------- -acia6850_device::acia6850_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acia6850_device::acia6850_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : acia6850_device(mconfig, ACIA6850, tag, owner, clock) { } -acia6850_device::acia6850_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +acia6850_device::acia6850_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_txd_handler(*this) , m_rts_handler(*this) diff --git a/src/devices/machine/6850acia.h b/src/devices/machine/6850acia.h index 4d99209d519..89a76e0978c 100644 --- a/src/devices/machine/6850acia.h +++ b/src/devices/machine/6850acia.h @@ -18,7 +18,7 @@ class acia6850_device : public device_t { public: // construction/destruction - acia6850_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + acia6850_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto txd_handler() { return m_txd_handler.bind(); } auto rts_handler() { return m_rts_handler.bind(); } @@ -38,7 +38,7 @@ public: DECLARE_WRITE_LINE_MEMBER( write_txc ); protected: - acia6850_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + acia6850_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/machine/68561mpcc.cpp b/src/devices/machine/68561mpcc.cpp index 1a3280d7975..d748205368e 100644 --- a/src/devices/machine/68561mpcc.cpp +++ b/src/devices/machine/68561mpcc.cpp @@ -95,7 +95,7 @@ DEFINE_DEVICE_TYPE(MPCC68561A, mpcc68561a_device, "mpcc68561a", "MPCC 68561A") // LIVE DEVICE //************************************************************************** -mpcc_device::mpcc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +mpcc_device::mpcc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock), device_serial_interface(mconfig, *this), m_irq(CLEAR_LINE), @@ -139,27 +139,27 @@ mpcc_device::mpcc_device(const machine_config &mconfig, device_type type, const elem = 0; } -mpcc_device::mpcc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcc_device::mpcc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mpcc_device(mconfig, MPCC, tag, owner, clock, TYPE_MPCC) { } -mpcc68560_device::mpcc68560_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcc68560_device::mpcc68560_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mpcc_device(mconfig, MPCC68560, tag, owner, clock, TYPE_MPCC68560) { } -mpcc68560a_device::mpcc68560a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcc68560a_device::mpcc68560a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mpcc_device(mconfig, MPCC68560A, tag, owner, clock, TYPE_MPCC68560A) { } -mpcc68561_device::mpcc68561_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcc68561_device::mpcc68561_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mpcc_device(mconfig, MPCC68561, tag, owner, clock, TYPE_MPCC68561) { } -mpcc68561a_device::mpcc68561a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mpcc68561a_device::mpcc68561a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mpcc_device(mconfig, MPCC68561A, tag, owner, clock, TYPE_MPCC68561A) { } @@ -474,7 +474,7 @@ void mpcc_device::update_serial() if (m_rcr & REG_RCR_RRES) { LOGSETUP("- Rx in reset\n"); - set_rcv_rate(0); + set_rcv_rate(XTAL::u(0)); } // Rx is running else @@ -491,7 +491,7 @@ void mpcc_device::update_serial() if (m_tcr & REG_TCR_TRES) { LOGSETUP("- Tx in reset\n"); - set_tra_rate(0); + set_tra_rate(XTAL::u(0)); } // Tx is running else @@ -508,7 +508,7 @@ void mpcc_device::update_serial() else { LOGSETUP("- Tx disabled\n"); - set_tra_rate(0); + set_tra_rate(XTAL::u(0)); } } } diff --git a/src/devices/machine/68561mpcc.h b/src/devices/machine/68561mpcc.h index 9758f387976..a55fd94890e 100644 --- a/src/devices/machine/68561mpcc.h +++ b/src/devices/machine/68561mpcc.h @@ -47,7 +47,7 @@ class mpcc_device : public device_t, public device_serial_interface { public: // construction/destruction - mpcc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void configure_clocks(int rxc, int txc) { @@ -77,7 +77,7 @@ public: DECLARE_WRITE_LINE_MEMBER( txc_w ) {} // { m_chanA->txc_w(state); } protected: - mpcc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + mpcc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_start() override; @@ -407,49 +407,49 @@ protected: class mpcc68560_device : public mpcc_device { public: - mpcc68560_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, int rxc, int txc) + mpcc68560_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, int rxc, int txc) : mpcc68560_device(mconfig, tag, owner, clock) { configure_clocks(rxc, txc); } - mpcc68560_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcc68560_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mpcc68560a_device : public mpcc_device { public: - mpcc68560a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, int rxc, int txc) + mpcc68560a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, int rxc, int txc) : mpcc68560a_device(mconfig, tag, owner, clock) { configure_clocks(rxc, txc); } - mpcc68560a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcc68560a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mpcc68561_device : public mpcc_device { public: - mpcc68561_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, int rxc, int txc) + mpcc68561_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, int rxc, int txc) : mpcc68561_device(mconfig, tag, owner, clock) { configure_clocks(rxc, txc); } - mpcc68561_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcc68561_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mpcc68561a_device : public mpcc_device { public: - mpcc68561a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, int rxc, int txc) + mpcc68561a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, int rxc, int txc) : mpcc68561a_device(mconfig, tag, owner, clock) { configure_clocks(rxc, txc); } - mpcc68561a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mpcc68561a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/machine/7200fifo.cpp b/src/devices/machine/7200fifo.cpp index e9cb45f66a7..57ec29f4954 100644 --- a/src/devices/machine/7200fifo.cpp +++ b/src/devices/machine/7200fifo.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(IDT7202, idt7202_device, "idt7202", "IDT7202 FIFO (1024x9)") //------------------------------------------------- fifo7200_device::fifo7200_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, int size) - : device_t(mconfig, type, tag, owner, (uint32_t)0), + : device_t(mconfig, type, tag, owner), m_ram_size(size), m_read_ptr(0), m_write_ptr(0), m_ef(0), m_ff(0), m_hf(0), m_ef_handler(*this), @@ -37,8 +37,8 @@ fifo7200_device::fifo7200_device(const machine_config &mconfig, device_type type // idt7200_device - constructor //------------------------------------------------- -idt7200_device::idt7200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : fifo7200_device(mconfig, IDT7200, tag, owner, 0x100) +idt7200_device::idt7200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) + : fifo7200_device(mconfig, IDT7200, tag, ownerx100) { } @@ -47,8 +47,8 @@ idt7200_device::idt7200_device(const machine_config &mconfig, const char *tag, d // idt7201_device - constructor //------------------------------------------------- -idt7201_device::idt7201_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : fifo7200_device(mconfig, IDT7201, tag, owner, 0x200) +idt7201_device::idt7201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) + : fifo7200_device(mconfig, IDT7201, tag, ownerx200) { } @@ -57,8 +57,8 @@ idt7201_device::idt7201_device(const machine_config &mconfig, const char *tag, d // idt7202_device - constructor //------------------------------------------------- -idt7202_device::idt7202_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : fifo7200_device(mconfig, IDT7202, tag, owner, 0x400) +idt7202_device::idt7202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) + : fifo7200_device(mconfig, IDT7202, tag, ownerx400) { } diff --git a/src/devices/machine/7200fifo.h b/src/devices/machine/7200fifo.h index 6609d4efad6..0706b625f3f 100644 --- a/src/devices/machine/7200fifo.h +++ b/src/devices/machine/7200fifo.h @@ -110,7 +110,7 @@ private: class idt7200_device : public fifo7200_device { public: - idt7200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + idt7200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // ======================> idt7201_device @@ -118,7 +118,7 @@ public: class idt7201_device : public fifo7200_device { public: - idt7201_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + idt7201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // ======================> idt7202_device @@ -126,7 +126,7 @@ public: class idt7202_device : public fifo7200_device { public: - idt7202_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + idt7202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // device type definitions diff --git a/src/devices/machine/7400.cpp b/src/devices/machine/7400.cpp index f8ab747715d..71e63d580a4 100644 --- a/src/devices/machine/7400.cpp +++ b/src/devices/machine/7400.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(TTL7400, ttl7400_device, "7400", "7400 Quad 2-Input NAND Gate") -ttl7400_device::ttl7400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl7400_device::ttl7400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL7400, tag, owner, clock) , m_y_func(*this) , m_a(0) diff --git a/src/devices/machine/7400.h b/src/devices/machine/7400.h index 13939cda7a7..49ddd318f83 100644 --- a/src/devices/machine/7400.h +++ b/src/devices/machine/7400.h @@ -37,7 +37,7 @@ class ttl7400_device : public device_t { public: // construction/destruction - ttl7400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl7400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <std::size_t Bit> auto y_cb() { return m_y_func[Bit].bind(); } diff --git a/src/devices/machine/7404.cpp b/src/devices/machine/7404.cpp index ad3ca9e234e..103d6a288b4 100644 --- a/src/devices/machine/7404.cpp +++ b/src/devices/machine/7404.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(TTL7404, ttl7404_device, "7404", "5/7404 Hex Inverters") -ttl7404_device::ttl7404_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl7404_device::ttl7404_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL7404, tag, owner, clock) , m_y_func(*this) , m_a(0) diff --git a/src/devices/machine/7404.h b/src/devices/machine/7404.h index 9bc680997e5..4b15203748a 100644 --- a/src/devices/machine/7404.h +++ b/src/devices/machine/7404.h @@ -64,7 +64,7 @@ class ttl7404_device : public device_t { public: // construction/destruction - ttl7404_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl7404_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <std::size_t Bit> auto y_cb() { return m_y_func[Bit].bind(); } diff --git a/src/devices/machine/74123.cpp b/src/devices/machine/74123.cpp index d895a72c4e4..fb5fcc11293 100644 --- a/src/devices/machine/74123.cpp +++ b/src/devices/machine/74123.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(TTL74123, ttl74123_device, "ttl74123", "74123 TTL") // ttl74123_device - constructor //------------------------------------------------- -ttl74123_device::ttl74123_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl74123_device::ttl74123_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL74123, tag, owner, clock), m_clear_timer(nullptr), m_output_timer(nullptr), diff --git a/src/devices/machine/74123.h b/src/devices/machine/74123.h index 1aeed9d3ef7..d733fbf5313 100644 --- a/src/devices/machine/74123.h +++ b/src/devices/machine/74123.h @@ -67,9 +67,9 @@ class ttl74123_device : public device_t { public: // construction/destruction - ttl74123_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ttl74123_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); ttl74123_device(const machine_config &mconfig, const char *tag, device_t *owner, double res, double cap) - : ttl74123_device(mconfig, tag, owner, 0U) + : ttl74123_device(mconfig, tag, owner) { set_resistor_value(res); set_capacitor_value(cap); diff --git a/src/devices/machine/74145.cpp b/src/devices/machine/74145.cpp index 1ac1a41ffa6..5b556434f4e 100644 --- a/src/devices/machine/74145.cpp +++ b/src/devices/machine/74145.cpp @@ -59,7 +59,7 @@ DEFINE_DEVICE_TYPE(TTL74145, ttl74145_device, "ttl74145", "TTL74145") // ttl74145_device - constructor //------------------------------------------------- -ttl74145_device::ttl74145_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl74145_device::ttl74145_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL74145, tag, owner, clock) , m_output_line_cb(*this) , m_number(0) diff --git a/src/devices/machine/74145.h b/src/devices/machine/74145.h index f5965cea4b1..d2c735af4f6 100644 --- a/src/devices/machine/74145.h +++ b/src/devices/machine/74145.h @@ -24,7 +24,7 @@ class ttl74145_device : public device_t { public: // construction/destruction - ttl74145_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl74145_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <std::size_t Bit> auto output_line_callback() { return m_output_line_cb[Bit].bind(); } diff --git a/src/devices/machine/74148.cpp b/src/devices/machine/74148.cpp index 45ce281ed51..b81670dd63a 100644 --- a/src/devices/machine/74148.cpp +++ b/src/devices/machine/74148.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(TTL74148, ttl74148_device, "74148", "74148 TTL") -ttl74148_device::ttl74148_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl74148_device::ttl74148_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL74148, tag, owner, clock) , m_output_cb(*this) , m_enable_input(0) diff --git a/src/devices/machine/74148.h b/src/devices/machine/74148.h index b9c9ddfdb56..cb32feb5f49 100644 --- a/src/devices/machine/74148.h +++ b/src/devices/machine/74148.h @@ -48,7 +48,7 @@ class ttl74148_device : public device_t { public: - ttl74148_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ttl74148_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~ttl74148_device() {} auto out_cb() { return m_output_cb.bind(); } diff --git a/src/devices/machine/74153.cpp b/src/devices/machine/74153.cpp index 18352ff7e06..7f2c8838a73 100644 --- a/src/devices/machine/74153.cpp +++ b/src/devices/machine/74153.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(TTL153, ttl153_device, "ttl153", "SN54/74153") // ttl153_device - constructor //------------------------------------------------- -ttl153_device::ttl153_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ttl153_device::ttl153_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL153, tag, owner, clock), m_za_cb(*this), m_zb_cb(*this), diff --git a/src/devices/machine/74153.h b/src/devices/machine/74153.h index ae2f3a37353..20f09c47f4c 100644 --- a/src/devices/machine/74153.h +++ b/src/devices/machine/74153.h @@ -31,7 +31,7 @@ class ttl153_device : public device_t { public: // construction/destruction - ttl153_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl153_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration auto za_cb() { return m_za_cb.bind(); } diff --git a/src/devices/machine/74157.cpp b/src/devices/machine/74157.cpp index 1dc7eb1289b..984e6e75743 100644 --- a/src/devices/machine/74157.cpp +++ b/src/devices/machine/74157.cpp @@ -35,12 +35,12 @@ DEFINE_DEVICE_TYPE(LS157_X2, ls157_x2_device, "ls157_x2", "74LS157 Quad 2-to-1 M // ls157_device - constructor //------------------------------------------------- -ls157_device::ls157_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ls157_device::ls157_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ls157_device(mconfig, LS157, tag, owner, clock, 0x0f) { } -ls157_device::ls157_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 mask) +ls157_device::ls157_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 mask) : device_t(mconfig, type, tag, owner, clock) , m_a_in_cb(*this) , m_b_in_cb(*this) @@ -58,7 +58,7 @@ ls157_device::ls157_device(const machine_config &mconfig, device_type type, cons // ls157_x2_device - constructor //------------------------------------------------- -ls157_x2_device::ls157_x2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ls157_x2_device::ls157_x2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ls157_device(mconfig, LS157_X2, tag, owner, clock, 0xff) { } @@ -277,7 +277,7 @@ u8 ls157_device::output_r() DEFINE_DEVICE_TYPE(HC157, hc157_device, "hc157", "74HC157 Quad 2-to-1 Multiplexer") -hc157_device::hc157_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hc157_device::hc157_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ls157_device(mconfig, HC157, tag, owner, clock, 0x0f) { } @@ -289,7 +289,7 @@ hc157_device::hc157_device(const machine_config &mconfig, const char *tag, devic DEFINE_DEVICE_TYPE(HCT157, hct157_device, "hct157", "74HCT157 Quad 2-to-1 Multiplexer") -hct157_device::hct157_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hct157_device::hct157_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ls157_device(mconfig, HCT157, tag, owner, clock, 0x0f) { } diff --git a/src/devices/machine/74157.h b/src/devices/machine/74157.h index da34d879221..d34b54704a2 100644 --- a/src/devices/machine/74157.h +++ b/src/devices/machine/74157.h @@ -35,7 +35,7 @@ class ls157_device : public device_t { public: // construction/destruction - ls157_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + ls157_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto a_in_callback() { return m_a_in_cb.bind(); } auto b_in_callback() { return m_b_in_cb.bind(); } @@ -66,7 +66,7 @@ public: u8 output_r(); protected: - ls157_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 mask); + ls157_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 mask); // device-level overrides virtual void device_start() override; @@ -96,7 +96,7 @@ class ls157_x2_device : public ls157_device { public: // construction/destruction - ls157_x2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + ls157_x2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // ======================> hc157_device @@ -105,7 +105,7 @@ class hc157_device : public ls157_device { public: // construction/destruction - hc157_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + hc157_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // ======================> hct157_device @@ -114,7 +114,7 @@ class hct157_device : public ls157_device { public: // construction/destruction - hct157_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + hct157_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; diff --git a/src/devices/machine/74161.cpp b/src/devices/machine/74161.cpp index 64e935152f5..479500943bd 100644 --- a/src/devices/machine/74161.cpp +++ b/src/devices/machine/74161.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(TTL74161, ttl74161_device, "ttl74161", "54/74161 Binary Count DEFINE_DEVICE_TYPE(TTL74162, ttl74162_device, "ttl74162", "54/74162 Decade Counter") DEFINE_DEVICE_TYPE(TTL74163, ttl74163_device, "ttl74163", "54/74163 Binary Counter") -ttl7416x_device::ttl7416x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool synchronous_reset, uint8_t limit) +ttl7416x_device::ttl7416x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool synchronous_reset, uint8_t limit) : device_t(mconfig, type, tag, owner, clock) , m_qa_func(*this) , m_qb_func(*this) @@ -36,22 +36,22 @@ ttl7416x_device::ttl7416x_device(const machine_config &mconfig, device_type type { } -ttl74160_device::ttl74160_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl74160_device::ttl74160_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ttl7416x_device(mconfig, TTL74160, tag, owner, clock, false, 10) { } -ttl74161_device::ttl74161_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl74161_device::ttl74161_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ttl7416x_device(mconfig, TTL74161, tag, owner, clock, false, 16) { } -ttl74162_device::ttl74162_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl74162_device::ttl74162_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ttl7416x_device(mconfig, TTL74162, tag, owner, clock, true, 10) { } -ttl74163_device::ttl74163_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl74163_device::ttl74163_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ttl7416x_device(mconfig, TTL74163, tag, owner, clock, true, 16) { } diff --git a/src/devices/machine/74161.h b/src/devices/machine/74161.h index 0145e08a9fb..7a1cc129391 100644 --- a/src/devices/machine/74161.h +++ b/src/devices/machine/74161.h @@ -87,7 +87,7 @@ public: protected: // construction/destruction - ttl7416x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool synchronous_reset, uint8_t limit); + ttl7416x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool synchronous_reset, uint8_t limit); // device-level overrides virtual void device_start() override; @@ -128,25 +128,25 @@ private: class ttl74160_device : public ttl7416x_device { public: - ttl74160_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl74160_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ttl74161_device : public ttl7416x_device { public: - ttl74161_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl74161_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ttl74162_device : public ttl7416x_device { public: - ttl74162_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl74162_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ttl74163_device : public ttl7416x_device { public: - ttl74163_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl74163_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // device type definition diff --git a/src/devices/machine/74165.cpp b/src/devices/machine/74165.cpp index 9ba4415d56c..b7970029709 100644 --- a/src/devices/machine/74165.cpp +++ b/src/devices/machine/74165.cpp @@ -36,7 +36,7 @@ void ttl165_device::device_add_mconfig(machine_config &config) // ttl153_device - constructor //------------------------------------------------- -ttl165_device::ttl165_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ttl165_device::ttl165_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL165, tag, owner, clock), m_timer(*this, "timer"), m_data_cb(*this), m_qh_cb(*this), diff --git a/src/devices/machine/74165.h b/src/devices/machine/74165.h index 145f3195172..814871dc7a9 100644 --- a/src/devices/machine/74165.h +++ b/src/devices/machine/74165.h @@ -34,7 +34,7 @@ class ttl165_device : public device_t { public: // construction/destruction - ttl165_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl165_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto data_callback() { return m_data_cb.bind(); } auto qh_callback() { return m_qh_cb.bind(); } diff --git a/src/devices/machine/74166.cpp b/src/devices/machine/74166.cpp index 1611b526762..1946c591505 100644 --- a/src/devices/machine/74166.cpp +++ b/src/devices/machine/74166.cpp @@ -36,7 +36,7 @@ void ttl166_device::device_add_mconfig(machine_config &config) // ttl153_device - constructor //------------------------------------------------- -ttl166_device::ttl166_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ttl166_device::ttl166_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL166, tag, owner, clock), m_timer(*this, "timer"), m_data_cb(*this), m_qh_cb(*this), diff --git a/src/devices/machine/74166.h b/src/devices/machine/74166.h index e15149a50cd..4287b97ab1c 100644 --- a/src/devices/machine/74166.h +++ b/src/devices/machine/74166.h @@ -34,7 +34,7 @@ class ttl166_device : public device_t { public: // construction/destruction - ttl166_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl166_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto data_callback() { return m_data_cb.bind(); } auto qh_callback() { return m_qh_cb.bind(); } diff --git a/src/devices/machine/74175.cpp b/src/devices/machine/74175.cpp index 28d3152dbeb..967c3316fc3 100644 --- a/src/devices/machine/74175.cpp +++ b/src/devices/machine/74175.cpp @@ -12,7 +12,7 @@ DEFINE_DEVICE_TYPE(TTL74174, ttl74174_device, "ttl74174", "54/74174 Hex D Flip-Flops with Clear") DEFINE_DEVICE_TYPE(TTL74175, ttl74175_device, "ttl74175", "54/74175 Quad D Flip-Flops with Clear") -ttl741745_device::ttl741745_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ttl741745_device::ttl741745_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_q1_func(*this) , m_q2_func(*this) @@ -31,7 +31,7 @@ ttl741745_device::ttl741745_device(const machine_config &mconfig, device_type ty { } -ttl74174_device::ttl74174_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl74174_device::ttl74174_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ttl741745_device(mconfig, TTL74174, tag, owner, clock) , m_q5_func(*this) , m_q6_func(*this) @@ -42,7 +42,7 @@ ttl74174_device::ttl74174_device(const machine_config &mconfig, const char *tag, { } -ttl74175_device::ttl74175_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl74175_device::ttl74175_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ttl741745_device(mconfig, TTL74175, tag, owner, clock) , m_not_q1_func(*this) , m_not_q2_func(*this) diff --git a/src/devices/machine/74175.h b/src/devices/machine/74175.h index 2eb716d481c..cdd6ffba379 100644 --- a/src/devices/machine/74175.h +++ b/src/devices/machine/74175.h @@ -66,7 +66,7 @@ public: uint8_t q_w(); protected: - ttl741745_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ttl741745_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -96,7 +96,7 @@ protected: class ttl74174_device : public ttl741745_device { public: - ttl74174_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl74174_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto q5_cb() { return m_q5_func.bind(); } auto q6_cb() { return m_q6_func.bind(); } @@ -124,7 +124,7 @@ private: class ttl74175_device : public ttl741745_device { public: - ttl74175_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl74175_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto not_q1_cb() { return m_not_q1_func.bind(); } auto not_q2_cb() { return m_not_q2_func.bind(); } diff --git a/src/devices/machine/74181.cpp b/src/devices/machine/74181.cpp index 66901510b32..3e665f80883 100644 --- a/src/devices/machine/74181.cpp +++ b/src/devices/machine/74181.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(TTL74181, ttl74181_device, "ttl74181", "74181 TTL") // ttl74181_device - constructor //------------------------------------------------- -ttl74181_device::ttl74181_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ttl74181_device::ttl74181_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL74181, tag, owner, clock), m_a(0), m_b(0), diff --git a/src/devices/machine/74181.h b/src/devices/machine/74181.h index 40a55abc042..9b72940afe0 100644 --- a/src/devices/machine/74181.h +++ b/src/devices/machine/74181.h @@ -24,7 +24,7 @@ class ttl74181_device : public device_t { public: // construction/destruction - ttl74181_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ttl74181_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inputs void input_a_w(uint8_t data); diff --git a/src/devices/machine/74259.cpp b/src/devices/machine/74259.cpp index 806ea280eb1..ae12a7f6383 100644 --- a/src/devices/machine/74259.cpp +++ b/src/devices/machine/74259.cpp @@ -102,7 +102,7 @@ DEFINE_DEVICE_TYPE(CD4099, cd4099_device, "cd4099", "CD4099B Addressable Latch") // ADDRESSABLE LATCH DEVICE //************************************************************************** -addressable_latch_device::addressable_latch_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool clear_active) +addressable_latch_device::addressable_latch_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool clear_active) : device_t(mconfig, type, tag, owner, clock) , m_q_out_cb(*this) , m_parallel_out_cb(*this) @@ -379,7 +379,7 @@ void addressable_latch_device::clear_outputs(u8 new_q) // LS259 DEVICE //************************************************************************** -ls259_device::ls259_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ls259_device::ls259_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : addressable_latch_device(mconfig, LS259, tag, owner, clock, false) { } @@ -388,7 +388,7 @@ ls259_device::ls259_device(const machine_config &mconfig, const char *tag, devic // HC259 DEVICE //************************************************************************** -hc259_device::hc259_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hc259_device::hc259_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : addressable_latch_device(mconfig, HC259, tag, owner, clock, false) { } @@ -397,7 +397,7 @@ hc259_device::hc259_device(const machine_config &mconfig, const char *tag, devic // HCT259 DEVICE //************************************************************************** -hct259_device::hct259_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hct259_device::hct259_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : addressable_latch_device(mconfig, HCT259, tag, owner, clock, false) { } @@ -406,7 +406,7 @@ hct259_device::hct259_device(const machine_config &mconfig, const char *tag, dev // F9334 DEVICE //************************************************************************** -f9334_device::f9334_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +f9334_device::f9334_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : addressable_latch_device(mconfig, F9334, tag, owner, clock, false) { } @@ -415,7 +415,7 @@ f9334_device::f9334_device(const machine_config &mconfig, const char *tag, devic // CD4099 DEVICE //************************************************************************** -cd4099_device::cd4099_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cd4099_device::cd4099_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : addressable_latch_device(mconfig, CD4099, tag, owner, clock, true) { } diff --git a/src/devices/machine/74259.h b/src/devices/machine/74259.h index a2192701cba..87c811e0860 100644 --- a/src/devices/machine/74259.h +++ b/src/devices/machine/74259.h @@ -74,7 +74,7 @@ public: protected: // construction/destruction - addressable_latch_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool clear_active); + addressable_latch_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool clear_active); // device-level overrides virtual void device_start() override; @@ -105,7 +105,7 @@ private: class ls259_device : public addressable_latch_device { public: - ls259_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + ls259_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // ======================> hc259_device @@ -113,7 +113,7 @@ public: class hc259_device : public addressable_latch_device { public: - hc259_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + hc259_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // ======================> hct259_device @@ -121,7 +121,7 @@ public: class hct259_device : public addressable_latch_device { public: - hct259_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + hct259_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // ======================> f9334_device @@ -129,7 +129,7 @@ public: class f9334_device : public addressable_latch_device { public: - f9334_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + f9334_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // ======================> cd4099_device @@ -137,7 +137,7 @@ public: class cd4099_device : public addressable_latch_device { public: - cd4099_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + cd4099_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // device type definition diff --git a/src/devices/machine/74381.cpp b/src/devices/machine/74381.cpp index 65514a414e3..68cae17a94b 100644 --- a/src/devices/machine/74381.cpp +++ b/src/devices/machine/74381.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(SN74S381, sn74s381_device, "sn74s381", "TI SN74S381 ALU / Fun // sn74s381_device - constructor //------------------------------------------------- -sn74s381_device::sn74s381_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sn74s381_device::sn74s381_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SN74S381, tag, owner, clock) , m_a(0) , m_b(0) diff --git a/src/devices/machine/74381.h b/src/devices/machine/74381.h index 2aef6456540..0f3ff6c42f6 100644 --- a/src/devices/machine/74381.h +++ b/src/devices/machine/74381.h @@ -22,7 +22,7 @@ class sn74s381_device : public device_t { public: // construction/destruction - sn74s381_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sn74s381_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void a_w(uint8_t data); void b_w(uint8_t data); diff --git a/src/devices/machine/74543.cpp b/src/devices/machine/74543.cpp index 2abba597941..1e9fa04b49f 100644 --- a/src/devices/machine/74543.cpp +++ b/src/devices/machine/74543.cpp @@ -12,7 +12,7 @@ DEFINE_DEVICE_TYPE(TTL74543, ttl74543_device, "ttl74543", "Octal Registered Transceiver") -ttl74543_device::ttl74543_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ttl74543_device::ttl74543_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL74543, tag, owner, clock), m_output_a(*this), m_output_b(*this), diff --git a/src/devices/machine/74543.h b/src/devices/machine/74543.h index ab2c7a561d2..a8fa43346c9 100644 --- a/src/devices/machine/74543.h +++ b/src/devices/machine/74543.h @@ -66,7 +66,7 @@ class ttl74543_device : public device_t { public: - ttl74543_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + ttl74543_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto outputa_cb() { return m_output_a.bind(); } auto outputb_cb() { return m_output_b.bind(); } diff --git a/src/devices/machine/7474.cpp b/src/devices/machine/7474.cpp index 33e4e5af696..debb8a31e4e 100644 --- a/src/devices/machine/7474.cpp +++ b/src/devices/machine/7474.cpp @@ -55,7 +55,7 @@ DEFINE_DEVICE_TYPE(TTL7474, ttl7474_device, "7474", "7474 TTL") // ttl7474_device - constructor //------------------------------------------------- -ttl7474_device::ttl7474_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ttl7474_device::ttl7474_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TTL7474, tag, owner, clock), m_output_func(*this), m_comp_output_func(*this) diff --git a/src/devices/machine/7474.h b/src/devices/machine/7474.h index 4e2069d0afa..f94374bd194 100644 --- a/src/devices/machine/7474.h +++ b/src/devices/machine/7474.h @@ -55,7 +55,7 @@ class ttl7474_device : public device_t { public: // construction/destruction - ttl7474_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ttl7474_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // static configuration helpers auto output_cb() { return m_output_func.bind(); } diff --git a/src/devices/machine/8042kbdc.cpp b/src/devices/machine/8042kbdc.cpp index e054990a651..25185011afc 100644 --- a/src/devices/machine/8042kbdc.cpp +++ b/src/devices/machine/8042kbdc.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(KBDC8042, kbdc8042_device, "kbdc8042", "8042 Keyboard/Mouse C // kbdc8042_device - constructor //------------------------------------------------- -kbdc8042_device::kbdc8042_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kbdc8042_device::kbdc8042_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, KBDC8042, tag, owner, clock) , m_keyboard_dev(*this, "at_keyboard") , m_mousex_port(*this, "MOUSEX") diff --git a/src/devices/machine/8042kbdc.h b/src/devices/machine/8042kbdc.h index 64a45c8993a..b630c0d2adc 100644 --- a/src/devices/machine/8042kbdc.h +++ b/src/devices/machine/8042kbdc.h @@ -37,7 +37,7 @@ public: }; // construction/destruction - kbdc8042_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + kbdc8042_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_keyboard_type(kbdc8042_type_t keybtype) { m_keybtype = keybtype; } void set_interrupt_type(kbdc8042_interrupt_type_t interrupttype) { m_interrupttype = interrupttype; } diff --git a/src/devices/machine/82s129.cpp b/src/devices/machine/82s129.cpp index ca147f17c2f..745dbb50074 100644 --- a/src/devices/machine/82s129.cpp +++ b/src/devices/machine/82s129.cpp @@ -14,7 +14,7 @@ const uint32_t prom82s129_base_device::PROM_SIZE = 256; DEFINE_DEVICE_TYPE(PROM82S126, prom82s126_device, "82s126", "82S126 1K-bit bipolar PROM") DEFINE_DEVICE_TYPE(PROM82S129, prom82s129_device, "82s129", "82S129 1K-bit bipolar PROM") -prom82s129_base_device::prom82s129_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +prom82s129_base_device::prom82s129_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_region(*this, DEVICE_SELF) , m_out_func(*this) @@ -29,12 +29,12 @@ prom82s129_base_device::prom82s129_base_device(const machine_config &mconfig, de { } -prom82s126_device::prom82s126_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +prom82s126_device::prom82s126_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : prom82s129_base_device(mconfig, PROM82S126, tag, owner, clock) { } -prom82s129_device::prom82s129_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +prom82s129_device::prom82s129_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : prom82s129_base_device(mconfig, PROM82S129, tag, owner, clock) { } diff --git a/src/devices/machine/82s129.h b/src/devices/machine/82s129.h index 96f278c85e9..3493705ede8 100644 --- a/src/devices/machine/82s129.h +++ b/src/devices/machine/82s129.h @@ -78,7 +78,7 @@ public: protected: // construction/destruction - prom82s129_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + prom82s129_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -115,13 +115,13 @@ private: class prom82s126_device : public prom82s129_base_device { public: - prom82s126_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + prom82s126_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class prom82s129_device : public prom82s129_base_device { public: - prom82s129_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + prom82s129_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/machine/8364_paula.cpp b/src/devices/machine/8364_paula.cpp index befdb45d7b6..875a4ab4981 100644 --- a/src/devices/machine/8364_paula.cpp +++ b/src/devices/machine/8364_paula.cpp @@ -44,7 +44,7 @@ DEFINE_DEVICE_TYPE(PAULA_8364, paula_8364_device, "paula_8364", "MOS 8364 \"Paul // paula_8364_device - constructor //------------------------------------------------- -paula_8364_device::paula_8364_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +paula_8364_device::paula_8364_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PAULA_8364, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_chipmem_r(*this) diff --git a/src/devices/machine/8364_paula.h b/src/devices/machine/8364_paula.h index 873525f8e0e..b2af3e28093 100644 --- a/src/devices/machine/8364_paula.h +++ b/src/devices/machine/8364_paula.h @@ -52,7 +52,7 @@ class paula_8364_device : public device_t, public device_sound_interface { public: - paula_8364_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + paula_8364_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration auto mem_read_cb() { return m_chipmem_r.bind(); } diff --git a/src/devices/machine/8530scc.cpp b/src/devices/machine/8530scc.cpp index 7438ccce738..1ace890c22e 100644 --- a/src/devices/machine/8530scc.cpp +++ b/src/devices/machine/8530scc.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(SCC8530, scc8530_legacy_device, "scc8530l", "Zilog 8530 SCC ( IMPLEMENTATION ***************************************************************************/ -scc8530_legacy_device::scc8530_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +scc8530_legacy_device::scc8530_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SCC8530, tag, owner, clock), mode(0), reg(0), status(0), IRQV(0), MasterIRQEnable(0), lastIRQStat(0), IRQType(), intrq_cb(*this) diff --git a/src/devices/machine/8530scc.h b/src/devices/machine/8530scc.h index e4af88b3e97..cb82b923587 100644 --- a/src/devices/machine/8530scc.h +++ b/src/devices/machine/8530scc.h @@ -26,7 +26,7 @@ public: IRQ_B_EXT }; - scc8530_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc8530_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto intrq_callback() { return intrq_cb.bind(); } diff --git a/src/devices/machine/acorn_bmu.cpp b/src/devices/machine/acorn_bmu.cpp index ce3aacf8d2f..e58b5a65008 100644 --- a/src/devices/machine/acorn_bmu.cpp +++ b/src/devices/machine/acorn_bmu.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(ACORN_BMU, acorn_bmu_device, "acorn_bmu", "Acorn Battery Mana // acorn_bmu_device - constructor //------------------------------------------------- -acorn_bmu_device::acorn_bmu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_bmu_device::acorn_bmu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_BMU, tag, owner, clock) , m_slave_address(BMU_SLAVE_ADDRESS) , m_scl(0) diff --git a/src/devices/machine/acorn_bmu.h b/src/devices/machine/acorn_bmu.h index 52ff13db040..d8ad07a4d97 100644 --- a/src/devices/machine/acorn_bmu.h +++ b/src/devices/machine/acorn_bmu.h @@ -21,7 +21,7 @@ class acorn_bmu_device : public device_t { public: - acorn_bmu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_bmu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(scl_w); DECLARE_WRITE_LINE_MEMBER(sda_w); diff --git a/src/devices/machine/acorn_ioc.cpp b/src/devices/machine/acorn_ioc.cpp index 3f59b4a66d1..8799a34057a 100644 --- a/src/devices/machine/acorn_ioc.cpp +++ b/src/devices/machine/acorn_ioc.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(ACORN_IOC, acorn_ioc_device, "ioc", "Acorn IOC") // LIVE DEVICE //************************************************************************** -acorn_ioc_device::acorn_ioc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_ioc_device::acorn_ioc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_IOC, tag, owner, clock) , device_serial_interface(mconfig, *this) , m_peripherals_r(*this) @@ -74,7 +74,7 @@ void acorn_ioc_device::device_reset() // KART interface set_data_frame(1, 8, PARITY_NONE, STOP_BITS_2); - set_rate(31250); + set_rate(XTAL::u(31250)); for (int i = 0; i < 6; i++) m_giop_w[i](1); diff --git a/src/devices/machine/acorn_ioc.h b/src/devices/machine/acorn_ioc.h index 50477cf8b24..41af51e013c 100644 --- a/src/devices/machine/acorn_ioc.h +++ b/src/devices/machine/acorn_ioc.h @@ -22,7 +22,7 @@ class acorn_ioc_device : public device_t, public device_serial_interface { public: - acorn_ioc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_ioc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <unsigned N> auto peripheral_r() { static_assert(N >= 1 && N <= 7); return m_peripherals_r[N - 1].bind(); } template <unsigned N> auto peripheral_w() { static_assert(N >= 1 && N <= 7); return m_peripherals_w[N - 1].bind(); } diff --git a/src/devices/machine/acorn_lc.cpp b/src/devices/machine/acorn_lc.cpp index 71a545521cb..2e8e90b9908 100644 --- a/src/devices/machine/acorn_lc.cpp +++ b/src/devices/machine/acorn_lc.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(ACORN_LC, acorn_lc_device, "acorn_lc", "Acorn LC ASIC") // acorn_lc_device - constructor //------------------------------------------------- -acorn_lc_device::acorn_lc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +acorn_lc_device::acorn_lc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_LC, tag, owner, clock) //, device_memory_interface(mconfig, *this) //, device_palette_interface(mconfig, *this) diff --git a/src/devices/machine/acorn_lc.h b/src/devices/machine/acorn_lc.h index 8367c90fdf1..5b438a959af 100644 --- a/src/devices/machine/acorn_lc.h +++ b/src/devices/machine/acorn_lc.h @@ -24,7 +24,7 @@ class acorn_lc_device : public device_t //public device_video_interface { public: - acorn_lc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + acorn_lc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 read(offs_t offset); void write(offs_t offset, u8 data); diff --git a/src/devices/machine/acorn_memc.cpp b/src/devices/machine/acorn_memc.cpp index c8b12050478..430c7be4646 100644 --- a/src/devices/machine/acorn_memc.cpp +++ b/src/devices/machine/acorn_memc.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(ACORN_MEMC, acorn_memc_device, "memc", "Acorn MEMC") // LIVE DEVICE //************************************************************************** -acorn_memc_device::acorn_memc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +acorn_memc_device::acorn_memc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ACORN_MEMC, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_vidc(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/acorn_memc.h b/src/devices/machine/acorn_memc.h index 9664e07d7f0..a2e2ec54200 100644 --- a/src/devices/machine/acorn_memc.h +++ b/src/devices/machine/acorn_memc.h @@ -22,10 +22,10 @@ class acorn_memc_device : public device_t, public device_memory_interface { public: - acorn_memc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + acorn_memc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> - acorn_memc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&vidc_tag) + acorn_memc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&vidc_tag) : acorn_memc_device(mconfig, tag, owner, clock) { m_vidc.set_tag(std::forward<T>(vidc_tag)); diff --git a/src/devices/machine/acorn_vidc.cpp b/src/devices/machine/acorn_vidc.cpp index 9440c339711..ddf6013e3fc 100644 --- a/src/devices/machine/acorn_vidc.cpp +++ b/src/devices/machine/acorn_vidc.cpp @@ -54,7 +54,7 @@ void acorn_vidc10_device::regs_map(address_map &map) } -acorn_vidc10_device::acorn_vidc10_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int dac_type) +acorn_vidc10_device::acorn_vidc10_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int dac_type) : device_t(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , device_palette_interface(mconfig, *this) @@ -77,7 +77,7 @@ acorn_vidc10_device::acorn_vidc10_device(const machine_config &mconfig, device_t std::fill(std::begin(m_stereo_image), std::end(m_stereo_image), 0); } -acorn_vidc1_device::acorn_vidc1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +acorn_vidc1_device::acorn_vidc1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : acorn_vidc10_device(mconfig, ACORN_VIDC1, tag, owner, clock, 1) { m_space_config = address_space_config("regs_space", ENDIANNESS_LITTLE, 32, 8, 0, address_map_constructor(FUNC(acorn_vidc1_device::regs_map), this)); @@ -86,7 +86,7 @@ acorn_vidc1_device::acorn_vidc1_device(const machine_config &mconfig, const char m_pal_border_base = 0x110; } -acorn_vidc1a_device::acorn_vidc1a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +acorn_vidc1a_device::acorn_vidc1a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : acorn_vidc10_device(mconfig, ACORN_VIDC1A, tag, owner, clock, 2) { m_space_config = address_space_config("regs_space", ENDIANNESS_LITTLE, 32, 8, 0, address_map_constructor(FUNC(acorn_vidc1a_device::regs_map), this)); @@ -115,7 +115,7 @@ void acorn_vidc10_device::device_add_mconfig(machine_config &config) for (int i = 0; i < m_sound_max_channels; i++) { // custom DAC - DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_dac[i], 0).add_route(0, m_lspeaker, m_sound_input_gain).add_route(0, m_rspeaker, m_sound_input_gain); + DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_dac[i]).add_route(0, m_lspeaker, m_sound_input_gain).add_route(0, m_rspeaker, m_sound_input_gain); } } @@ -563,7 +563,7 @@ void arm_vidc20_device::regs_map(address_map &map) map(0xe0, 0xef).w(FUNC(arm_vidc20_device::vidc20_control_w)); } -arm_vidc20_device::arm_vidc20_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arm_vidc20_device::arm_vidc20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : acorn_vidc10_device(mconfig, ARM_VIDC20, tag, owner, clock, 2) , m_dac32(*this, "serial_dac_%u", 0) { @@ -589,8 +589,8 @@ void arm_vidc20_device::device_add_mconfig(machine_config &config) // For simplicity we separate DACs for 32-bit mode // TODO: how stereo image copes with this if at all? - DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_dac32[0], 0).add_route(ALL_OUTPUTS, m_lspeaker, 0.25); - DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_dac32[1], 0).add_route(ALL_OUTPUTS, m_rspeaker, 0.25); + DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_dac32[0]).add_route(ALL_OUTPUTS, m_lspeaker, 0.25); + DAC_16BIT_R2R_TWOS_COMPLEMENT(config, m_dac32[1]).add_route(ALL_OUTPUTS, m_rspeaker, 0.25); } void arm_vidc20_device::device_config_complete() diff --git a/src/devices/machine/acorn_vidc.h b/src/devices/machine/acorn_vidc.h index f2009b255b2..2affc7173cf 100644 --- a/src/devices/machine/acorn_vidc.h +++ b/src/devices/machine/acorn_vidc.h @@ -49,7 +49,7 @@ public: virtual bool get_dac_mode() { return false; } protected: - acorn_vidc10_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int dac_type); + acorn_vidc10_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int dac_type); // device-level overrides //virtual void device_validity_check(validity_checker &valid) const override; @@ -134,14 +134,14 @@ class acorn_vidc1_device : public acorn_vidc10_device { public: // construction/destruction - acorn_vidc1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + acorn_vidc1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class acorn_vidc1a_device : public acorn_vidc10_device { public: // construction/destruction - acorn_vidc1a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + acorn_vidc1a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition @@ -152,7 +152,7 @@ class arm_vidc20_device : public acorn_vidc10_device { public: // construction/destruction - arm_vidc20_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + arm_vidc20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write_dac32(u8 channel, u16 data); virtual bool get_dac_mode() override; diff --git a/src/devices/machine/adc0804.cpp b/src/devices/machine/adc0804.cpp index 12eb9e7754d..8f75a5effe6 100644 --- a/src/devices/machine/adc0804.cpp +++ b/src/devices/machine/adc0804.cpp @@ -57,7 +57,7 @@ ALLOW_SAVE_TYPE(adc0804_device::read_mode); // adc0804_device - constructor //------------------------------------------------- -adc0804_device::adc0804_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +adc0804_device::adc0804_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_vin_callback(*this) , m_intr_callback(*this) @@ -73,7 +73,7 @@ adc0804_device::adc0804_device(const machine_config &mconfig, device_type type, { } -adc0804_device::adc0804_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +adc0804_device::adc0804_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc0804_device(mconfig, ADC0804, tag, owner, clock) { } @@ -83,7 +83,7 @@ adc0804_device::adc0804_device(const machine_config &mconfig, const char *tag, d // adc0803_device - constructor //------------------------------------------------- -adc0803_device::adc0803_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +adc0803_device::adc0803_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc0804_device(mconfig, ADC0803, tag, owner, clock) { } diff --git a/src/devices/machine/adc0804.h b/src/devices/machine/adc0804.h index d8fe6ad950e..8c7ffc56b12 100644 --- a/src/devices/machine/adc0804.h +++ b/src/devices/machine/adc0804.h @@ -42,9 +42,9 @@ public: }; // device type constructors - adc0804_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + adc0804_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); adc0804_device(const machine_config &mconfig, const char *tag, device_t *owner, double r, double c) - : adc0804_device(mconfig, tag, owner, 0U) + : adc0804_device(mconfig, tag, owner) { set_rc(r, c); } @@ -70,7 +70,7 @@ public: DECLARE_READ_LINE_MEMBER(intr_r) { return m_intr_active ? 0 : 1; } protected: - adc0804_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + adc0804_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -110,9 +110,9 @@ class adc0803_device : public adc0804_device { public: // device type constructors - adc0803_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + adc0803_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); adc0803_device(const machine_config &mconfig, const char *tag, device_t *owner, double r, double c) - : adc0803_device(mconfig, tag, owner, 0U) + : adc0803_device(mconfig, tag, owner) { set_rc(r, c); } diff --git a/src/devices/machine/adc0808.cpp b/src/devices/machine/adc0808.cpp index a55c11077c7..22b59299b11 100644 --- a/src/devices/machine/adc0808.cpp +++ b/src/devices/machine/adc0808.cpp @@ -39,7 +39,7 @@ ALLOW_SAVE_TYPE(adc0808_device::state); // adc0808_device - constructor //------------------------------------------------- -adc0808_device::adc0808_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +adc0808_device::adc0808_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_eoc_cb(*this), m_eoc_ff_cb(*this), m_in_cb(*this), @@ -49,7 +49,7 @@ adc0808_device::adc0808_device(const machine_config &mconfig, device_type type, { } -adc0808_device::adc0808_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adc0808_device::adc0808_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc0808_device(mconfig, ADC0808, tag, owner, clock) { } @@ -58,7 +58,7 @@ adc0808_device::adc0808_device(const machine_config &mconfig, const char *tag, d // adc0809_device - constructor //------------------------------------------------- -adc0809_device::adc0809_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adc0809_device::adc0809_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc0808_device(mconfig, ADC0809, tag, owner, clock) { } @@ -67,7 +67,7 @@ adc0809_device::adc0809_device(const machine_config &mconfig, const char *tag, d // m58990_device - constructor //------------------------------------------------- -m58990_device::m58990_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m58990_device::m58990_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc0808_device(mconfig, M58990, tag, owner, clock) { } diff --git a/src/devices/machine/adc0808.h b/src/devices/machine/adc0808.h index 9d69c67daef..29a7d787671 100644 --- a/src/devices/machine/adc0808.h +++ b/src/devices/machine/adc0808.h @@ -45,7 +45,7 @@ class adc0808_device : public device_t { public: // construction/destruction - adc0808_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adc0808_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto eoc_callback() { return m_eoc_cb.bind(); } auto eoc_ff_callback() { return m_eoc_ff_cb.bind(); } @@ -61,7 +61,7 @@ public: void address_data_start_w(u8 data); // start and ale connected, address to the data bus protected: - adc0808_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + adc0808_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -95,13 +95,13 @@ private: class adc0809_device : public adc0808_device { public: - adc0809_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adc0809_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class m58990_device : public adc0808_device { public: - m58990_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m58990_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/machine/adc083x.cpp b/src/devices/machine/adc083x.cpp index c5c75655625..163ed9eb457 100644 --- a/src/devices/machine/adc083x.cpp +++ b/src/devices/machine/adc083x.cpp @@ -53,7 +53,7 @@ DEFINE_DEVICE_TYPE(ADC0832, adc0832_device, "adc0832", "ADC0832 A/D Converter") DEFINE_DEVICE_TYPE(ADC0834, adc0834_device, "adc0834", "ADC0834 A/D Converter") DEFINE_DEVICE_TYPE(ADC0838, adc0838_device, "adc0838", "ADC0838 A/D Converter") -adc083x_device::adc083x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t mux_bits) : +adc083x_device::adc083x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t mux_bits) : device_t(mconfig, type, tag, owner, clock), m_mux_bits(mux_bits), m_cs(0), @@ -72,22 +72,22 @@ adc083x_device::adc083x_device(const machine_config &mconfig, device_type type, { } -adc0831_device::adc0831_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adc0831_device::adc0831_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc083x_device(mconfig, ADC0831, tag, owner, clock, 0) { } -adc0832_device::adc0832_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adc0832_device::adc0832_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc083x_device(mconfig, ADC0832, tag, owner, clock, 2) { } -adc0834_device::adc0834_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adc0834_device::adc0834_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc083x_device(mconfig, ADC0834, tag, owner, clock, 3) { } -adc0838_device::adc0838_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adc0838_device::adc0838_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc083x_device(mconfig, ADC0838, tag, owner, clock, 4) { } diff --git a/src/devices/machine/adc083x.h b/src/devices/machine/adc083x.h index babde2515b1..0724ac16fdc 100644 --- a/src/devices/machine/adc083x.h +++ b/src/devices/machine/adc083x.h @@ -50,7 +50,7 @@ public: DECLARE_READ_LINE_MEMBER( do_read ); protected: - adc083x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t mux_bits); + adc083x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t mux_bits); // device-level overrides virtual void device_start() override; @@ -84,28 +84,28 @@ private: class adc0831_device : public adc083x_device { public: - adc0831_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + adc0831_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class adc0832_device : public adc083x_device { public: - adc0832_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + adc0832_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class adc0834_device : public adc083x_device { public: - adc0834_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + adc0834_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class adc0838_device : public adc083x_device { public: - adc0838_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + adc0838_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; diff --git a/src/devices/machine/adc0844.cpp b/src/devices/machine/adc0844.cpp index bbdafc68aec..20cc531ac35 100644 --- a/src/devices/machine/adc0844.cpp +++ b/src/devices/machine/adc0844.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(ADC0848, adc0848_device, "adc0848", "ADC0848 A/D Converter") // adc0844_device - constructor //------------------------------------------------- -adc0844_device::adc0844_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +adc0844_device::adc0844_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_intr_cb(*this), m_ch1_cb(*this), m_ch2_cb(*this), m_ch3_cb(*this), m_ch4_cb(*this), @@ -38,7 +38,7 @@ adc0844_device::adc0844_device(const machine_config &mconfig, device_type type, { } -adc0844_device::adc0844_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adc0844_device::adc0844_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc0844_device(mconfig, ADC0844, tag, owner, clock) { } @@ -47,7 +47,7 @@ adc0844_device::adc0844_device(const machine_config &mconfig, const char *tag, d // adc0848_device - constructor //------------------------------------------------- -adc0848_device::adc0848_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +adc0848_device::adc0848_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc0844_device(mconfig, ADC0848, tag, owner, clock), m_ch5_cb(*this), m_ch6_cb(*this), m_ch7_cb(*this), m_ch8_cb(*this) { diff --git a/src/devices/machine/adc0844.h b/src/devices/machine/adc0844.h index 98ac8b211d4..dcbdd487ad5 100644 --- a/src/devices/machine/adc0844.h +++ b/src/devices/machine/adc0844.h @@ -34,7 +34,7 @@ class adc0844_device : public device_t { public: // construction/destruction - adc0844_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + adc0844_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration auto intr_callback() { return m_intr_cb.bind(); } @@ -47,7 +47,7 @@ public: virtual void write(u8 data); protected: - adc0844_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + adc0844_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -71,7 +71,7 @@ class adc0848_device : public adc0844_device { public: // construction/destruction - adc0848_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + adc0848_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration auto ch5_callback() { return m_ch5_cb.bind(); } diff --git a/src/devices/machine/adc1038.cpp b/src/devices/machine/adc1038.cpp index 3baac1fd1be..4c26be90202 100644 --- a/src/devices/machine/adc1038.cpp +++ b/src/devices/machine/adc1038.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(ADC1038, adc1038_device, "adc1038", "ADC1038") -adc1038_device::adc1038_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adc1038_device::adc1038_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADC1038, tag, owner, clock) , m_cycle(0) , m_clk(0) diff --git a/src/devices/machine/adc1038.h b/src/devices/machine/adc1038.h index d4ee5362fd0..d11210bf3fb 100644 --- a/src/devices/machine/adc1038.h +++ b/src/devices/machine/adc1038.h @@ -29,7 +29,7 @@ class adc1038_device : public device_t public: typedef device_delegate<int (int input)> input_delegate; - adc1038_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adc1038_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename... T> void set_input_callback(T &&... args) { m_input_cb.set(std::forward<T>(args)...); } diff --git a/src/devices/machine/adc1213x.cpp b/src/devices/machine/adc1213x.cpp index 2f73575909c..2ef5c99ef93 100644 --- a/src/devices/machine/adc1213x.cpp +++ b/src/devices/machine/adc1213x.cpp @@ -39,23 +39,23 @@ DEFINE_DEVICE_TYPE(ADC12132, adc12132_device, "adc12132", "ADC12132") DEFINE_DEVICE_TYPE(ADC12138, adc12138_device, "adc12138", "ADC12138") -adc12130_device::adc12130_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adc12130_device::adc12130_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc12138_device(mconfig, ADC12130, tag, owner, clock) { } -adc12132_device::adc12132_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adc12132_device::adc12132_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc12138_device(mconfig, ADC12132, tag, owner, clock) { } -adc12138_device::adc12138_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +adc12138_device::adc12138_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : adc12138_device(mconfig, ADC12138, tag, owner, clock) { } -adc12138_device::adc12138_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +adc12138_device::adc12138_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_ipt_read_cb(*this) { diff --git a/src/devices/machine/adc1213x.h b/src/devices/machine/adc1213x.h index 7d3f69caccd..d03d704a94e 100644 --- a/src/devices/machine/adc1213x.h +++ b/src/devices/machine/adc1213x.h @@ -24,7 +24,7 @@ class adc12138_device : public device_t public: typedef device_delegate<double (uint8_t input)> ipt_convert_delegate; - adc12138_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adc12138_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename... T> void set_ipt_convert_callback(T &&... args) { m_ipt_read_cb.set(std::forward<T>(args)...); } @@ -36,7 +36,7 @@ public: u8 eoc_r(); protected: - adc12138_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + adc12138_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -65,14 +65,14 @@ private: class adc12130_device : public adc12138_device { public: - adc12130_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adc12130_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class adc12132_device : public adc12138_device { public: - adc12132_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + adc12132_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/machine/aic565.cpp b/src/devices/machine/aic565.cpp index 34da7f4fd14..64e910cc943 100644 --- a/src/devices/machine/aic565.cpp +++ b/src/devices/machine/aic565.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(AIC565, aic565_device, "aic565", "AIC-565 Bus Auxiliary Inter // aic565_device - constructor //------------------------------------------------- -aic565_device::aic565_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +aic565_device::aic565_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AIC565, tag, owner, clock) , m_hrst_callback(*this) , m_srst_callback(*this) diff --git a/src/devices/machine/aic565.h b/src/devices/machine/aic565.h index 581a595d77c..d22161cab2c 100644 --- a/src/devices/machine/aic565.h +++ b/src/devices/machine/aic565.h @@ -21,7 +21,7 @@ class aic565_device : public device_t { public: // construction/destruction - aic565_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + aic565_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // callback configuration auto hrst_callback() { return m_hrst_callback.bind(); } diff --git a/src/devices/machine/aic580.cpp b/src/devices/machine/aic580.cpp index c5bf3a51e96..f477fb19552 100644 --- a/src/devices/machine/aic580.cpp +++ b/src/devices/machine/aic580.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(AIC580, aic580_device, "aic580", "AIC-580 DMA Bus Master") // aic580_device - constructor //------------------------------------------------- -aic580_device::aic580_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +aic580_device::aic580_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AIC580, tag, owner, clock) , m_bdin_callback(*this) , m_bdout_callback(*this) diff --git a/src/devices/machine/aic580.h b/src/devices/machine/aic580.h index b764daa1710..5733f6af2e8 100644 --- a/src/devices/machine/aic580.h +++ b/src/devices/machine/aic580.h @@ -21,7 +21,7 @@ class aic580_device : public device_t { public: // construction/destruction - aic580_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + aic580_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto bdin_callback() { return m_bdin_callback.bind(); } diff --git a/src/devices/machine/aic6250.cpp b/src/devices/machine/aic6250.cpp index fb885c3b5e3..aaa7b3cc342 100644 --- a/src/devices/machine/aic6250.cpp +++ b/src/devices/machine/aic6250.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(AIC6251A, aic6251a_device, "aic6251a", "Adaptec AIC-6251A Fas static char const *const nscsi_phase[] = { "DATA OUT", "DATA IN", "COMMAND", "STATUS", "*", "*", "MESSAGE OUT", "MESSAGE IN" }; static char const *const aic6250_phase[] = { "DATA OUT", "*", "DATA IN", "*", "COMMAND", "MESSAGE OUT", "STATUS", "MESSAGE IN" }; -aic6250_device::aic6250_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +aic6250_device::aic6250_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nscsi_device(mconfig, type, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, DEVICE_SELF) , m_int_cb(*this) @@ -59,12 +59,12 @@ aic6250_device::aic6250_device(const machine_config &mconfig, device_type type, { } -aic6250_device::aic6250_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aic6250_device::aic6250_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aic6250_device(mconfig, AIC6250, tag, owner, clock) { } -aic6251a_device::aic6251a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aic6251a_device::aic6251a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : aic6250_device(mconfig, AIC6251A, tag, owner, clock) { } diff --git a/src/devices/machine/aic6250.h b/src/devices/machine/aic6250.h index 048aa6de0c8..39d26f46bd8 100644 --- a/src/devices/machine/aic6250.h +++ b/src/devices/machine/aic6250.h @@ -11,7 +11,7 @@ class aic6250_device : public nscsi_device, public nscsi_slot_card_interface { public: - aic6250_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aic6250_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void map(address_map &map); @@ -34,7 +34,7 @@ public: void dma16_w(u16 data); protected: - aic6250_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + aic6250_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // standard device_interface overrides virtual void device_start() override; @@ -282,7 +282,7 @@ private: class aic6251a_device : public aic6250_device { public: - aic6251a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aic6251a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(AIC6250, aic6250_device) diff --git a/src/devices/machine/aicartc.cpp b/src/devices/machine/aicartc.cpp index 8e58ec0bb33..9a6d1378843 100644 --- a/src/devices/machine/aicartc.cpp +++ b/src/devices/machine/aicartc.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(AICARTC, aicartc_device, "aicartc", "AICA RTC") // aicartc_device - constructor //------------------------------------------------- -aicartc_device::aicartc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +aicartc_device::aicartc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AICARTC, tag, owner, clock) , device_rtc_interface(mconfig, *this) , m_rtc_reg_lo(0), m_rtc_reg_hi(0), m_rtc_tick(0), m_we(0) diff --git a/src/devices/machine/aicartc.h b/src/devices/machine/aicartc.h index fb1955ec685..9a4ebc31f99 100644 --- a/src/devices/machine/aicartc.h +++ b/src/devices/machine/aicartc.h @@ -18,7 +18,7 @@ class aicartc_device : public device_t, public device_rtc_interface { public: // construction/destruction - aicartc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + aicartc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations void write(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/machine/akiko.cpp b/src/devices/machine/akiko.cpp index 13ae686a972..1bad05d718d 100644 --- a/src/devices/machine/akiko.cpp +++ b/src/devices/machine/akiko.cpp @@ -63,7 +63,7 @@ void akiko_device::device_add_mconfig(machine_config &config) // akiko_device - constructor //------------------------------------------------- -akiko_device::akiko_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +akiko_device::akiko_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AKIKO, tag, owner, clock) , m_c2p_input_index(0) , m_c2p_output_index(0) diff --git a/src/devices/machine/akiko.h b/src/devices/machine/akiko.h index 8a0ffec8e76..3b02ec21e51 100644 --- a/src/devices/machine/akiko.h +++ b/src/devices/machine/akiko.h @@ -31,7 +31,7 @@ class akiko_device : public device_t { public: - akiko_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + akiko_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto mem_r_callback() { return m_mem_r.bind(); } diff --git a/src/devices/machine/alpha_8921.cpp b/src/devices/machine/alpha_8921.cpp index bf57902b31e..9c70be1a8dd 100644 --- a/src/devices/machine/alpha_8921.cpp +++ b/src/devices/machine/alpha_8921.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(ALPHA_8921, alpha_8921_device, "alpha_8921", "Alpha denshi AL // alpha_8921_device - constructor //------------------------------------------------- -alpha_8921_device::alpha_8921_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +alpha_8921_device::alpha_8921_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ALPHA_8921, tag, owner, clock) { } diff --git a/src/devices/machine/alpha_8921.h b/src/devices/machine/alpha_8921.h index a6e8ccdb0ad..d41ff9ccaa5 100644 --- a/src/devices/machine/alpha_8921.h +++ b/src/devices/machine/alpha_8921.h @@ -18,7 +18,7 @@ class alpha_8921_device : public device_t { public: // construction/destruction - alpha_8921_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + alpha_8921_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inputs DECLARE_WRITE_LINE_MEMBER(clk_w); diff --git a/src/devices/machine/am25s55x.cpp b/src/devices/machine/am25s55x.cpp index b1624179463..54ff02e9ba9 100644 --- a/src/devices/machine/am25s55x.cpp +++ b/src/devices/machine/am25s55x.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(AM25S558, am25s558_device, "am25s558", "AMD Am25S558 Combinat // am25s55x_device - constructor //------------------------------------------------- -am25s55x_device::am25s55x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +am25s55x_device::am25s55x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_x_in(0) , m_y_in(0) @@ -32,13 +32,13 @@ am25s55x_device::am25s55x_device(const machine_config &mconfig, device_type type { } -am25s557_device::am25s557_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am25s557_device::am25s557_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am25s55x_device(mconfig, AM25S557, tag, owner, clock) , m_r(false) { } -am25s558_device::am25s558_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am25s558_device::am25s558_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am25s55x_device(mconfig, AM25S558, tag, owner, clock) { } diff --git a/src/devices/machine/am25s55x.h b/src/devices/machine/am25s55x.h index 1fa3cab8102..8d5e4c1e01e 100644 --- a/src/devices/machine/am25s55x.h +++ b/src/devices/machine/am25s55x.h @@ -22,7 +22,7 @@ class am25s55x_device : public device_t { public: // construction/destruction - am25s55x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock = 0); + am25s55x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void x_w(uint8_t data); void y_w(uint8_t data); @@ -74,7 +74,7 @@ class am25s557_device : public am25s55x_device { public: // construction/destruction - am25s557_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + am25s557_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual void xm_w(int state) override; virtual void ym_w(int state) override; @@ -97,7 +97,7 @@ class am25s558_device : public am25s55x_device { public: // construction/destruction - am25s558_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + am25s558_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void rs_w(int state); void ru_w(int state); diff --git a/src/devices/machine/am2847.cpp b/src/devices/machine/am2847.cpp index 7e7992a2e85..9d8181bdf2e 100644 --- a/src/devices/machine/am2847.cpp +++ b/src/devices/machine/am2847.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(AM2847, am2847_device, "am2847", "AMD Am2847 80-bit Static DEFINE_DEVICE_TYPE(AM2849, am2849_device, "am2849", "AMD Am2849 96-bit Static Shift Register") DEFINE_DEVICE_TYPE(TMS3409, tms3409_device, "tms3409", "TI TMS3409 80-bit Static Shift Register") -am2847_base_device::am2847_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, size_t size) +am2847_base_device::am2847_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, size_t size) : device_t(mconfig, type, tag, owner, clock) , m_in(0) , m_out(0) @@ -23,17 +23,17 @@ am2847_base_device::am2847_base_device(const machine_config &mconfig, device_typ { } -am2847_device::am2847_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am2847_device::am2847_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am2847_base_device(mconfig, AM2847, tag, owner, clock, 5) { } -am2849_device::am2849_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am2849_device::am2849_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am2847_base_device(mconfig, AM2849, tag, owner, clock, 6) { } -tms3409_device::tms3409_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms3409_device::tms3409_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am2847_base_device(mconfig, TMS3409, tag, owner, clock, 5) { } diff --git a/src/devices/machine/am2847.h b/src/devices/machine/am2847.h index b5d90642e32..9a21ebd54b8 100644 --- a/src/devices/machine/am2847.h +++ b/src/devices/machine/am2847.h @@ -65,7 +65,7 @@ public: uint8_t out_r() const { return m_out; } protected: - am2847_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, size_t size); + am2847_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, size_t size); virtual void device_start() override; virtual void device_reset() override; @@ -98,21 +98,21 @@ class am2847_device : public am2847_base_device { public: // construction/destruction - am2847_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + am2847_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class am2849_device : public am2847_base_device { public: // construction/destruction - am2849_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + am2849_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms3409_device : public am2847_base_device { public: // construction/destruction - tms3409_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms3409_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/machine/am2901b.cpp b/src/devices/machine/am2901b.cpp index 87b370a24b4..4ac5016b36a 100644 --- a/src/devices/machine/am2901b.cpp +++ b/src/devices/machine/am2901b.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(AM2901B, am2901b_device, "am2901b", "AMD Am2901B Bitslice Pro // am2901b_device - constructor //------------------------------------------------- -am2901b_device::am2901b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am2901b_device::am2901b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AM2901B, tag, owner, clock) , m_d(0) , m_q(0) diff --git a/src/devices/machine/am2901b.h b/src/devices/machine/am2901b.h index 4e7a25e3915..ac192c152a5 100644 --- a/src/devices/machine/am2901b.h +++ b/src/devices/machine/am2901b.h @@ -23,7 +23,7 @@ class am2901b_device : public device_t { public: // construction/destruction - am2901b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + am2901b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto y() { return m_y.bind(); } auto g() { return m_g.bind(); } diff --git a/src/devices/machine/am2910.cpp b/src/devices/machine/am2910.cpp index 158b4b83bb7..db670d76e4a 100644 --- a/src/devices/machine/am2910.cpp +++ b/src/devices/machine/am2910.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(AM2910, am2910_device, "am2910", "AMD Am2910 Microprogram Con // am2910_device - constructor //------------------------------------------------- -am2910_device::am2910_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am2910_device::am2910_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AM2910, tag, owner, clock) , m_pc(0) , m_r(0) diff --git a/src/devices/machine/am2910.h b/src/devices/machine/am2910.h index 52c075ea52a..1ae6c75a020 100644 --- a/src/devices/machine/am2910.h +++ b/src/devices/machine/am2910.h @@ -22,7 +22,7 @@ class am2910_device : public device_t { public: // construction/destruction - am2910_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + am2910_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(cc_w); // !CC DECLARE_WRITE_LINE_MEMBER(ccen_w); // !CCEN diff --git a/src/devices/machine/am53cf96.cpp b/src/devices/machine/am53cf96.cpp index 41b62e145f0..539234f8d73 100644 --- a/src/devices/machine/am53cf96.cpp +++ b/src/devices/machine/am53cf96.cpp @@ -145,7 +145,7 @@ void am53cf96_device::write(offs_t offset, uint8_t data) } } -am53cf96_device::am53cf96_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +am53cf96_device::am53cf96_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : legacy_scsi_host_adapter(mconfig, AM53CF96, tag, owner, clock), m_irq_handler(*this) { diff --git a/src/devices/machine/am53cf96.h b/src/devices/machine/am53cf96.h index 6fdd801f6df..27355472916 100644 --- a/src/devices/machine/am53cf96.h +++ b/src/devices/machine/am53cf96.h @@ -16,7 +16,7 @@ class am53cf96_device : public legacy_scsi_host_adapter { public: // construction/destruction - am53cf96_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + am53cf96_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/machine/am79c30.cpp b/src/devices/machine/am79c30.cpp index ed31a517398..43ae87797d3 100644 --- a/src/devices/machine/am79c30.cpp +++ b/src/devices/machine/am79c30.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(AM79C30A, am79c30a_device, "am79c30a", "Am79C30A DSC") // am79c30a_device - constructor //------------------------------------------------- -am79c30a_device::am79c30a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +am79c30a_device::am79c30a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AM79C30A, tag, owner, clock) , m_int_callback(*this) , m_init(0) diff --git a/src/devices/machine/am79c30.h b/src/devices/machine/am79c30.h index 0188b2c9623..d7ea33d9642 100644 --- a/src/devices/machine/am79c30.h +++ b/src/devices/machine/am79c30.h @@ -55,7 +55,7 @@ class am79c30a_device : public device_t { public: // device type constructor - am79c30a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + am79c30a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto int_callback() { return m_int_callback.bind(); } diff --git a/src/devices/machine/am79c90.cpp b/src/devices/machine/am79c90.cpp index f47457680ec..f7185c203ad 100644 --- a/src/devices/machine/am79c90.cpp +++ b/src/devices/machine/am79c90.cpp @@ -57,7 +57,7 @@ DEFINE_DEVICE_TYPE(AM7990, am7990_device, "am7990", "Am7990 LANCE Ethernet Controller") DEFINE_DEVICE_TYPE(AM79C90, am79c90_device, "am79c90", "Am79C90 C-LANCE Ethernet Controller") -am7990_device_base::am7990_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +am7990_device_base::am7990_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_network_interface(mconfig, *this, 10) , m_intr_out_cb(*this) @@ -68,12 +68,12 @@ am7990_device_base::am7990_device_base(const machine_config &mconfig, device_typ { } -am7990_device::am7990_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +am7990_device::am7990_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am7990_device_base(mconfig, AM7990, tag, owner, clock) { } -am79c90_device::am79c90_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +am79c90_device::am79c90_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am7990_device_base(mconfig, AM79C90, tag, owner, clock) { } diff --git a/src/devices/machine/am79c90.h b/src/devices/machine/am79c90.h index 80c66ff58ce..e884a949d6e 100644 --- a/src/devices/machine/am79c90.h +++ b/src/devices/machine/am79c90.h @@ -21,7 +21,7 @@ public: void reset_w(int state) { if (!state) device_reset(); } protected: - am7990_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock = 0); + am7990_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // device_t overrides virtual void device_start() override; @@ -175,7 +175,7 @@ private: class am7990_device : public am7990_device_base { public: - am7990_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + am7990_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual int get_buf_length(u16 data) const override { return (data == 0xf000) ? 4096 : -s16(0xf000 | data); } @@ -184,7 +184,7 @@ protected: class am79c90_device : public am7990_device_base { public: - am79c90_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + am79c90_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual int get_buf_length(u16 data) const override { return data ? ((data == 0xf000) ? 4096 : -s16(0xf000 | data)) : 0; } diff --git a/src/devices/machine/am9513.cpp b/src/devices/machine/am9513.cpp index 1c8c3692369..9ad6e2cf441 100644 --- a/src/devices/machine/am9513.cpp +++ b/src/devices/machine/am9513.cpp @@ -54,7 +54,7 @@ DEFINE_DEVICE_TYPE(AM9513A, am9513a_device, "am9513a", "Am9513A STC") // am9513_device - constructor //------------------------------------------------- -am9513_device::am9513_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool is_am9513a) +am9513_device::am9513_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_am9513a) : device_t(mconfig, type, tag, owner, clock) , m_out_cb(*this) , m_fout_cb(*this) @@ -62,12 +62,12 @@ am9513_device::am9513_device(const machine_config &mconfig, device_type type, co { } -am9513_device::am9513_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +am9513_device::am9513_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am9513_device(mconfig, AM9513, tag, owner, clock, false) { } -am9513a_device::am9513a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +am9513a_device::am9513a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am9513_device(mconfig, AM9513A, tag, owner, clock, true) { } diff --git a/src/devices/machine/am9513.h b/src/devices/machine/am9513.h index 34c3cc3598c..ee24c50c978 100644 --- a/src/devices/machine/am9513.h +++ b/src/devices/machine/am9513.h @@ -44,7 +44,7 @@ class am9513_device : public device_t { public: // device type constructor - am9513_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + am9513_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // static configuration auto out1_cb() { return m_out_cb[0].bind(); } @@ -88,7 +88,7 @@ public: protected: // base constructor - am9513_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool is_am9513a); + am9513_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_am9513a); // device-level overrides virtual void device_start() override; @@ -175,7 +175,7 @@ class am9513a_device : public am9513_device { public: // device type constructor - am9513a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + am9513a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type declarations diff --git a/src/devices/machine/am9517a.cpp b/src/devices/machine/am9517a.cpp index 533c617f1b5..32969680ffd 100644 --- a/src/devices/machine/am9517a.cpp +++ b/src/devices/machine/am9517a.cpp @@ -441,7 +441,7 @@ void am9517a_device::end_of_process() //------------------------------------------------- -am9517a_device::am9517a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +am9517a_device::am9517a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_execute_interface(mconfig, *this), m_icount(0), @@ -460,12 +460,12 @@ am9517a_device::am9517a_device(const machine_config &mconfig, device_type type, } -am9517a_device::am9517a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +am9517a_device::am9517a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am9517a_device(mconfig, AM9517A, tag, owner, clock) { } -v5x_dmau_device::v5x_dmau_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v5x_dmau_device::v5x_dmau_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am9517a_device(mconfig, V5X_DMAU, tag, owner, clock) , m_in_mem16r_cb(*this) , m_out_mem16w_cb(*this) @@ -475,7 +475,7 @@ v5x_dmau_device::v5x_dmau_device(const machine_config &mconfig, const char *tag, { } -pcxport_dmac_device::pcxport_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pcxport_dmac_device::pcxport_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am9517a_device(mconfig, PCXPORT_DMAC, tag, owner, clock) { } @@ -1327,7 +1327,7 @@ void pcxport_dmac_device::end_of_process() m_state = STATE_SI; } -eisa_dma_device::eisa_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +eisa_dma_device::eisa_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : am9517a_device(mconfig, EISA_DMA, tag, owner, clock) { } diff --git a/src/devices/machine/am9517a.h b/src/devices/machine/am9517a.h index e1dcec9576e..60d84c021f7 100644 --- a/src/devices/machine/am9517a.h +++ b/src/devices/machine/am9517a.h @@ -49,7 +49,7 @@ class am9517a_device : public device_t, public: // construction/destruction - am9517a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + am9517a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_hreq_callback() { return m_out_hreq_cb.bind(); } auto out_eop_callback() { return m_out_eop_cb.bind(); } @@ -79,7 +79,7 @@ public: DECLARE_WRITE_LINE_MEMBER( dreq3_w ); protected: - am9517a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + am9517a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -147,7 +147,7 @@ class v5x_dmau_device : public am9517a_device { public: // construction/destruction - v5x_dmau_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v5x_dmau_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto in_mem16r_callback() { return m_in_mem16r_cb.bind(); } auto out_mem16w_callback() { return m_out_mem16w_cb.bind(); } @@ -184,7 +184,7 @@ class pcxport_dmac_device : public am9517a_device { public: // construction/destruction - pcxport_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pcxport_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_reset() override; @@ -195,7 +195,7 @@ protected: class eisa_dma_device : public am9517a_device { public: - eisa_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + eisa_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <unsigned Channel> u8 get_address_page() { return m_channel[Channel].m_address >> 16; } template <unsigned Channel> void set_address_page(u8 data) diff --git a/src/devices/machine/am9519.cpp b/src/devices/machine/am9519.cpp index f09dd4e71cc..55789afc601 100644 --- a/src/devices/machine/am9519.cpp +++ b/src/devices/machine/am9519.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(AM9519, am9519_device, "am9519", "AMD AM9519 Universal Interrupt Controller") -am9519_device::am9519_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +am9519_device::am9519_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AM9519, tag, owner, clock) , m_out_int_func(*this) , m_irr(0) diff --git a/src/devices/machine/am9519.h b/src/devices/machine/am9519.h index bccd4534faf..fe3d55c1060 100644 --- a/src/devices/machine/am9519.h +++ b/src/devices/machine/am9519.h @@ -32,7 +32,7 @@ class am9519_device : public device_t { public: - am9519_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + am9519_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto out_int_callback() { return m_out_int_func.bind(); } diff --git a/src/devices/machine/amiga_copper.cpp b/src/devices/machine/amiga_copper.cpp index f3e0c249a75..4412570a5ef 100644 --- a/src/devices/machine/amiga_copper.cpp +++ b/src/devices/machine/amiga_copper.cpp @@ -64,7 +64,7 @@ DEFINE_DEVICE_TYPE(AMIGA_COPPER, amiga_copper_device, "amiga_copper", "Amiga Cop //------------------------------------------------- -amiga_copper_device::amiga_copper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +amiga_copper_device::amiga_copper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AMIGA_COPPER, tag, owner, clock) , m_host_cpu(*this, finder_base::DUMMY_TAG) , m_chipmem_r(*this) diff --git a/src/devices/machine/amiga_copper.h b/src/devices/machine/amiga_copper.h index 15fe5c3cd00..35fb800e0b1 100644 --- a/src/devices/machine/amiga_copper.h +++ b/src/devices/machine/amiga_copper.h @@ -19,7 +19,7 @@ class amiga_copper_device : public device_t { public: // construction/destruction - amiga_copper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + amiga_copper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // config template<class T> void set_host_cpu_tag(T &&tag) { m_host_cpu.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/machine/amigafdc.cpp b/src/devices/machine/amigafdc.cpp index 15694a95f49..cfe4c3cb718 100644 --- a/src/devices/machine/amigafdc.cpp +++ b/src/devices/machine/amigafdc.cpp @@ -52,7 +52,7 @@ void amiga_fdc_device::floppy_formats(format_registration &fr) fr.add(FLOPPY_IPF_FORMAT); } -amiga_fdc_device::amiga_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +amiga_fdc_device::amiga_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AMIGA_FDC, tag, owner, clock) , m_write_index(*this) , m_read_dma(*this) diff --git a/src/devices/machine/amigafdc.h b/src/devices/machine/amigafdc.h index 02e8c823539..9689f89c4ad 100644 --- a/src/devices/machine/amigafdc.h +++ b/src/devices/machine/amigafdc.h @@ -9,7 +9,7 @@ class amiga_fdc_device : public device_t { public: - amiga_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + amiga_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto index_callback() { return m_write_index.bind(); } auto read_dma_callback() { return m_read_dma.bind(); } diff --git a/src/devices/machine/applefdintf.cpp b/src/devices/machine/applefdintf.cpp index 68a849ba59b..0ff7cf58d28 100644 --- a/src/devices/machine/applefdintf.cpp +++ b/src/devices/machine/applefdintf.cpp @@ -50,7 +50,7 @@ void applefdintf_device::floppies_35(device_slot_interface &device) device.option_add("35hd", MFD75W); } -applefdintf_device::applefdintf_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +applefdintf_device::applefdintf_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_phases_cb(*this), m_devsel_cb(*this), diff --git a/src/devices/machine/applefdintf.h b/src/devices/machine/applefdintf.h index 97f5bc19b22..70f6aa20af5 100644 --- a/src/devices/machine/applefdintf.h +++ b/src/devices/machine/applefdintf.h @@ -105,7 +105,7 @@ protected: // Current value of the driven external phases input u8 m_phases_input; - applefdintf_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + applefdintf_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/machine/applepic.cpp b/src/devices/machine/applepic.cpp index 0383bb6817c..7f5b33f7ccc 100644 --- a/src/devices/machine/applepic.cpp +++ b/src/devices/machine/applepic.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(APPLEPIC, applepic_device, "applepic", "Apple 343S1021 PIC") const std::string_view applepic_device::s_interrupt_names[8] = { "0", "DMA 1", "DMA 2", "peripheral", "host", "timer", "6", "7" }; -applepic_device::applepic_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +applepic_device::applepic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, APPLEPIC, tag, owner, clock) , m_iopcpu(*this, "iopcpu") , m_prd_callback(*this) diff --git a/src/devices/machine/applepic.h b/src/devices/machine/applepic.h index 67d6186a963..9e03e61d3cb 100644 --- a/src/devices/machine/applepic.h +++ b/src/devices/machine/applepic.h @@ -18,7 +18,7 @@ class applepic_device : public device_t { public: // construction/destruction - applepic_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + applepic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto prd_callback() { return m_prd_callback.bind(); } diff --git a/src/devices/machine/archimedes_keyb.cpp b/src/devices/machine/archimedes_keyb.cpp index a6aa8278969..6fc27036e79 100644 --- a/src/devices/machine/archimedes_keyb.cpp +++ b/src/devices/machine/archimedes_keyb.cpp @@ -230,7 +230,7 @@ ioport_constructor archimedes_keyboard_device::device_input_ports() const // archimedes_keyboard_device - constructor //------------------------------------------------- -archimedes_keyboard_device::archimedes_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +archimedes_keyboard_device::archimedes_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARCHIMEDES_KEYBOARD, tag, owner, clock) , device_serial_interface(mconfig, *this) , m_mcu(*this, "mcu") @@ -252,7 +252,7 @@ void archimedes_keyboard_device::device_start() { // KART interface set_data_frame(1, 8, PARITY_NONE, STOP_BITS_2); - set_rate(31250); + set_rate(XTAL::u(31250)); m_mouse_timer = timer_alloc(FUNC(archimedes_keyboard_device::update_mouse), this); diff --git a/src/devices/machine/archimedes_keyb.h b/src/devices/machine/archimedes_keyb.h index 7acf6ae8d59..5c2dfc300c5 100644 --- a/src/devices/machine/archimedes_keyb.h +++ b/src/devices/machine/archimedes_keyb.h @@ -25,7 +25,7 @@ class archimedes_keyboard_device : public device_t, public device_serial_interfa { public: // construction/destruction - archimedes_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + archimedes_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto kout() { return m_kout.bind(); } diff --git a/src/devices/machine/arm_iomd.cpp b/src/devices/machine/arm_iomd.cpp index e1c32d8d3f3..c29f51d231d 100644 --- a/src/devices/machine/arm_iomd.cpp +++ b/src/devices/machine/arm_iomd.cpp @@ -136,7 +136,7 @@ void arm_iomd_device::map(address_map &map) } -arm_iomd_device::arm_iomd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +arm_iomd_device::arm_iomd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_host_cpu(*this, finder_base::DUMMY_TAG) , m_vidc(*this, finder_base::DUMMY_TAG) @@ -157,7 +157,7 @@ arm_iomd_device::arm_iomd_device(const machine_config &mconfig, device_type type { } -arm_iomd_device::arm_iomd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +arm_iomd_device::arm_iomd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm_iomd_device(mconfig, ARM_IOMD, tag, owner, clock) { m_id = 0xd4e7; @@ -204,7 +204,7 @@ void arm7500fe_iomd_device::map(address_map &map) } -arm7500fe_iomd_device::arm7500fe_iomd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +arm7500fe_iomd_device::arm7500fe_iomd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : arm_iomd_device(mconfig, ARM7500FE_IOMD, tag, owner, clock) , m_iolines_read_cb(*this) , m_iolines_write_cb(*this) diff --git a/src/devices/machine/arm_iomd.h b/src/devices/machine/arm_iomd.h index e072a7c8a31..6ac3854486f 100644 --- a/src/devices/machine/arm_iomd.h +++ b/src/devices/machine/arm_iomd.h @@ -34,8 +34,8 @@ class arm_iomd_device : public device_t { public: // construction/destruction - arm_iomd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - arm_iomd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + arm_iomd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); + arm_iomd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); template <unsigned N> auto iocr_read_od() { return m_iocr_read_od_cb[N].bind(); } template <unsigned N> auto iocr_write_od() { return m_iocr_write_od_cb[N].bind(); } @@ -167,7 +167,7 @@ class arm7500fe_iomd_device : public arm_iomd_device { public: // construction/destruction - arm7500fe_iomd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + arm7500fe_iomd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; auto iolines_read() { return m_iolines_read_cb.bind(); } diff --git a/src/devices/machine/at.cpp b/src/devices/machine/at.cpp index 75b57c8777d..cd04e6b219f 100644 --- a/src/devices/machine/at.cpp +++ b/src/devices/machine/at.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(AT_MB, at_mb_device, "at_mb", "PC/AT Motherboard") -at_mb_device::at_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +at_mb_device::at_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AT_MB, tag, owner, clock), m_maincpu(*this, ":maincpu"), m_isabus(*this, "isabus"), @@ -107,7 +107,7 @@ void at_mb_device::device_add_mconfig(machine_config &config) m_pic8259_slave->out_int_callback().set("pic8259_master", FUNC(pic8259_device::ir2_w)); m_pic8259_slave->in_sp_callback().set_constant(0); - ISA16(config, m_isabus, 0); + ISA16(config, m_isabus); m_isabus->set_memspace(":maincpu", AS_PROGRAM); m_isabus->set_iospace(":maincpu", AS_IO); m_isabus->irq2_callback().set(m_pic8259_slave, FUNC(pic8259_device::ir1_w)); // in place of irq 2 on at irq 9 is used diff --git a/src/devices/machine/at.h b/src/devices/machine/at.h index 346721ffbbd..f2f20045b01 100644 --- a/src/devices/machine/at.h +++ b/src/devices/machine/at.h @@ -15,7 +15,7 @@ class at_mb_device : public device_t { public: - at_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + at_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void map(address_map &map); diff --git a/src/devices/machine/at28c16.cpp b/src/devices/machine/at28c16.cpp index 38dbdc25117..73dbbb57760 100644 --- a/src/devices/machine/at28c16.cpp +++ b/src/devices/machine/at28c16.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(AT28C16, at28c16_device, "at28c16", "AT28C16 2Kx8 EEPROM") // at28c16_device - constructor //------------------------------------------------- -at28c16_device::at28c16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at28c16_device::at28c16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AT28C16, tag, owner, clock), device_memory_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/machine/at28c16.h b/src/devices/machine/at28c16.h index ca412d7c0af..bab4db821e8 100644 --- a/src/devices/machine/at28c16.h +++ b/src/devices/machine/at28c16.h @@ -27,7 +27,7 @@ class at28c16_device : { public: // construction/destruction - at28c16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + at28c16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint8_t data); uint8_t read(offs_t offset); diff --git a/src/devices/machine/at28c64b.cpp b/src/devices/machine/at28c64b.cpp index 7187a3cd093..88ae9613b6f 100644 --- a/src/devices/machine/at28c64b.cpp +++ b/src/devices/machine/at28c64b.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(AT28C64B, at28c64b_device, "at28c64b", "AT28C64B 8Kx8 EEPROM" // at28c64b_device - constructor //------------------------------------------------- -at28c64b_device::at28c64b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at28c64b_device::at28c64b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AT28C64B, tag, owner, clock), device_memory_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/machine/at28c64b.h b/src/devices/machine/at28c64b.h index c94ac1eec62..d07b45e3ecf 100644 --- a/src/devices/machine/at28c64b.h +++ b/src/devices/machine/at28c64b.h @@ -27,7 +27,7 @@ class at28c64b_device : { public: // construction/destruction - at28c64b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + at28c64b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, u8 data); u8 read(offs_t offset); diff --git a/src/devices/machine/at29x.cpp b/src/devices/machine/at29x.cpp index bf0544ede0f..6ad988b190a 100644 --- a/src/devices/machine/at29x.cpp +++ b/src/devices/machine/at29x.cpp @@ -56,7 +56,7 @@ Constructor for all variants */ -at29x_device::at29x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int memory_size, int device_id, int sector_size) +at29x_device::at29x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int memory_size, int device_id, int sector_size) : device_t(mconfig, type, tag, owner, clock), device_nvram_interface(mconfig, *this), m_memory_size(memory_size), // bytes @@ -72,7 +72,7 @@ at29x_device::at29x_device(const machine_config &mconfig, device_type type, cons /* Constructor for AT29C020 */ -at29c020_device::at29c020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at29c020_device::at29c020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : at29x_device(mconfig, AT29C020, tag, owner, clock, 256*1024, 0xda, 256) { } @@ -80,7 +80,7 @@ at29c020_device::at29c020_device(const machine_config &mconfig, const char *tag, /* Constructor for AT29C040 */ -at29c040_device::at29c040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at29c040_device::at29c040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : at29x_device(mconfig, AT29C040, tag, owner, clock, 512*1024, 0x5b, 512) { } @@ -88,7 +88,7 @@ at29c040_device::at29c040_device(const machine_config &mconfig, const char *tag, /* Constructor for AT29C040A */ -at29c040a_device::at29c040a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at29c040a_device::at29c040a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : at29x_device(mconfig, AT29C040A, tag, owner, clock, 512*1024, 0xa4, 256) { } diff --git a/src/devices/machine/at29x.h b/src/devices/machine/at29x.h index 5df3672877f..110f1ad3c01 100644 --- a/src/devices/machine/at29x.h +++ b/src/devices/machine/at29x.h @@ -24,7 +24,7 @@ public: void write(offs_t offset, uint8_t data); protected: - at29x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int memory_size, int device_id, int sector_size); + at29x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int memory_size, int device_id, int sector_size); virtual void device_start(void) override; virtual void device_reset(void) override; @@ -92,19 +92,19 @@ private: class at29c020_device : public at29x_device { public: - at29c020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + at29c020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class at29c040_device : public at29x_device { public: - at29c040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + at29c040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class at29c040a_device : public at29x_device { public: - at29c040a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + at29c040a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; #endif // MAME_MACHINE_AT29X_H diff --git a/src/devices/machine/at45dbxx.cpp b/src/devices/machine/at45dbxx.cpp index 890cd78ac59..a70bee5c462 100644 --- a/src/devices/machine/at45dbxx.cpp +++ b/src/devices/machine/at45dbxx.cpp @@ -46,13 +46,13 @@ DEFINE_DEVICE_TYPE(AT45DB161, at45db161_device, "at45db161", "AT45DB161") // at45db041_device - constructor //------------------------------------------------- -at45db041_device::at45db041_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at45db041_device::at45db041_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : at45db041_device(mconfig, AT45DB041, tag, owner, clock) { } -at45db041_device::at45db041_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +at45db041_device::at45db041_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_nvram_interface(mconfig, *this) , write_so(*this) @@ -60,13 +60,13 @@ at45db041_device::at45db041_device(const machine_config &mconfig, device_type ty } -at45db081_device::at45db081_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at45db081_device::at45db081_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : at45db041_device(mconfig, AT45DB081, tag, owner, clock) { } -at45db161_device::at45db161_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +at45db161_device::at45db161_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : at45db041_device(mconfig, AT45DB161, tag, owner, clock) { } diff --git a/src/devices/machine/at45dbxx.h b/src/devices/machine/at45dbxx.h index 2521ac10acc..84da1d96c1d 100644 --- a/src/devices/machine/at45dbxx.h +++ b/src/devices/machine/at45dbxx.h @@ -24,7 +24,7 @@ class at45db041_device : public device_t, public device_nvram_interface { public: - at45db041_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + at45db041_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(cs_w); DECLARE_WRITE_LINE_MEMBER(sck_w); @@ -36,7 +36,7 @@ public: auto so_callback() { return write_so.bind(); } protected: - at45db041_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + at45db041_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -101,7 +101,7 @@ protected: class at45db081_device : public at45db041_device { public: - at45db081_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + at45db081_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int num_pages() const override { return 4096; } @@ -116,7 +116,7 @@ protected: class at45db161_device : public at45db041_device { public: - at45db161_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + at45db161_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int num_pages() const override { return 4096; } diff --git a/src/devices/machine/at_keybc.cpp b/src/devices/machine/at_keybc.cpp index a166ff234cb..03cda01a664 100644 --- a/src/devices/machine/at_keybc.cpp +++ b/src/devices/machine/at_keybc.cpp @@ -282,7 +282,7 @@ WRITE_LINE_MEMBER(at_kbc_device_base::kbd_data_w) machine().scheduler().synchronize(timer_expired_delegate(FUNC(at_kbc_device_base::set_kbd_data_in), this), state); } -at_kbc_device_base::at_kbc_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) +at_kbc_device_base::at_kbc_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_mcu(*this, "mcu") , m_hot_res_cb(*this), m_gate_a20_cb(*this), m_kbd_irq_cb(*this) @@ -381,7 +381,7 @@ TIMER_CALLBACK_MEMBER(at_kbc_device_base::set_kbd_data_in) // PC/AT KEYBOARD CONTROLLER DEVICE //************************************************************************** -at_keyboard_controller_device::at_keyboard_controller_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +at_keyboard_controller_device::at_keyboard_controller_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : at_kbc_device_base(mconfig, AT_KEYBOARD_CONTROLLER, tag, owner, clock) { } @@ -452,7 +452,7 @@ WRITE_LINE_MEMBER(ps2_keyboard_controller_device::aux_data_w) machine().scheduler().synchronize(timer_expired_delegate(FUNC(ps2_keyboard_controller_device::set_aux_data_in), this), state); } -ps2_keyboard_controller_device::ps2_keyboard_controller_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +ps2_keyboard_controller_device::ps2_keyboard_controller_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : at_kbc_device_base(mconfig, PS2_KEYBOARD_CONTROLLER, tag, owner, clock) , m_aux_irq_cb(*this) , m_aux_clk_cb(*this), m_aux_data_cb(*this) diff --git a/src/devices/machine/at_keybc.h b/src/devices/machine/at_keybc.h index 9e769416cb2..afaa85b3d4e 100644 --- a/src/devices/machine/at_keybc.h +++ b/src/devices/machine/at_keybc.h @@ -41,7 +41,7 @@ public: protected: // trampoline constructor - at_kbc_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + at_kbc_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device_t implementation virtual void device_resolve_objects() override; @@ -83,7 +83,7 @@ class at_keyboard_controller_device : public at_kbc_device_base { public: // standard constructor - at_keyboard_controller_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + at_keyboard_controller_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t implementation @@ -120,7 +120,7 @@ public: DECLARE_WRITE_LINE_MEMBER(aux_data_w); // standard constructor - ps2_keyboard_controller_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + ps2_keyboard_controller_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t implementation diff --git a/src/devices/machine/ataflash.cpp b/src/devices/machine/ataflash.cpp index 892031e2052..c2c30d5e401 100644 --- a/src/devices/machine/ataflash.cpp +++ b/src/devices/machine/ataflash.cpp @@ -5,12 +5,12 @@ DEFINE_DEVICE_TYPE(ATA_FLASH_PCCARD, ata_flash_pccard_device, "ataflash", "ATA Flash PC Card") -ata_flash_pccard_device::ata_flash_pccard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ata_flash_pccard_device::ata_flash_pccard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ata_flash_pccard_device(mconfig, ATA_FLASH_PCCARD, tag, owner, clock) { } -ata_flash_pccard_device::ata_flash_pccard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ata_flash_pccard_device::ata_flash_pccard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ide_hdd_device(mconfig, type, tag, owner, clock) , device_pccard_interface(mconfig, *this) { @@ -118,7 +118,7 @@ attotime ata_flash_pccard_device::seek_time() DEFINE_DEVICE_TYPE(TAITO_PCCARD1, taito_pccard1_device, "taito_pccard1", "Taito PC Card (Type 1)") -taito_pccard1_device::taito_pccard1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +taito_pccard1_device::taito_pccard1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ata_flash_pccard_device(mconfig, TAITO_PCCARD1, tag, owner, clock), m_locked(0) { @@ -207,7 +207,7 @@ bool taito_pccard1_device::is_ready() DEFINE_DEVICE_TYPE(TAITO_PCCARD2, taito_pccard2_device, "taito_pccard2", "Taito PC Card (Type 2)") -taito_pccard2_device::taito_pccard2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +taito_pccard2_device::taito_pccard2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ata_flash_pccard_device(mconfig, TAITO_PCCARD2, tag, owner, clock), m_locked(false) { @@ -304,7 +304,7 @@ bool taito_pccard2_device::is_ready() DEFINE_DEVICE_TYPE(TAITO_COMPACT_FLASH, taito_compact_flash_device, "taito_cf", "Taito Compact Flash") -taito_compact_flash_device::taito_compact_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +taito_compact_flash_device::taito_compact_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ata_flash_pccard_device(mconfig, TAITO_COMPACT_FLASH, tag, owner, clock), m_locked(false) { diff --git a/src/devices/machine/ataflash.h b/src/devices/machine/ataflash.h index c9e3cbbf991..ad30f883b03 100644 --- a/src/devices/machine/ataflash.h +++ b/src/devices/machine/ataflash.h @@ -13,7 +13,7 @@ DECLARE_DEVICE_TYPE(ATA_FLASH_PCCARD, ata_flash_pccard_device) class ata_flash_pccard_device : public ide_hdd_device, public device_pccard_interface { public: - ata_flash_pccard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ata_flash_pccard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint16_t read_memory(offs_t offset, uint16_t mem_mask = ~0) override; virtual void write_memory(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override; @@ -21,7 +21,7 @@ public: virtual void write_reg(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override; protected: - ata_flash_pccard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ata_flash_pccard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_reset() override; @@ -41,7 +41,7 @@ DECLARE_DEVICE_TYPE(TAITO_PCCARD1, taito_pccard1_device) class taito_pccard1_device : public ata_flash_pccard_device { public: - taito_pccard1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + taito_pccard1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint16_t read_reg(offs_t offset, uint16_t mem_mask = ~0) override; virtual void write_reg(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override; @@ -62,7 +62,7 @@ DECLARE_DEVICE_TYPE(TAITO_PCCARD2, taito_pccard2_device) class taito_pccard2_device : public ata_flash_pccard_device { public: - taito_pccard2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + taito_pccard2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -84,7 +84,7 @@ DECLARE_DEVICE_TYPE(TAITO_COMPACT_FLASH, taito_compact_flash_device) class taito_compact_flash_device : public ata_flash_pccard_device { public: - taito_compact_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + taito_compact_flash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/atmel_arm_aic.h b/src/devices/machine/atmel_arm_aic.h index 72659841f3a..88308ddf87c 100644 --- a/src/devices/machine/atmel_arm_aic.h +++ b/src/devices/machine/atmel_arm_aic.h @@ -12,7 +12,7 @@ class arm_aic_device : public device_t { public: // construction/destruction - arm_aic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : + arm_aic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ARM_AIC, tag, owner, clock), m_irq_out(*this) { diff --git a/src/devices/machine/ay31015.cpp b/src/devices/machine/ay31015.cpp index a3cbbe456aa..2a5cce6e131 100644 --- a/src/devices/machine/ay31015.cpp +++ b/src/devices/machine/ay31015.cpp @@ -104,7 +104,7 @@ Start bit (low), Bit 0, Bit 1... highest bit, Parity bit (if enabled), 1-2 stop DEFINE_DEVICE_TYPE(AY31015, ay31015_device, "ay31015", "AY-3-1015 UART") DEFINE_DEVICE_TYPE(AY51013, ay51013_device, "ay51013", "AY-5-1013 UART") -ay31015_device::ay31015_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ay31015_device::ay31015_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_control_reg(0), m_status_reg(0), @@ -134,12 +134,12 @@ ay31015_device::ay31015_device(const machine_config &mconfig, device_type type, elem = 0; } -ay31015_device::ay31015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ay31015_device::ay31015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay31015_device(mconfig, AY31015, tag, owner, clock) { } -ay51013_device::ay51013_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ay51013_device::ay51013_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay31015_device(mconfig, AY51013, tag, owner, clock) { } diff --git a/src/devices/machine/ay31015.h b/src/devices/machine/ay31015.h index 4e27bc8e11f..a351522c4d8 100644 --- a/src/devices/machine/ay31015.h +++ b/src/devices/machine/ay31015.h @@ -18,7 +18,7 @@ class ay31015_device : public device_t { public: - ay31015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ay31015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_auto_rdav(bool auto_rdav) { m_auto_rdav = auto_rdav; } @@ -101,7 +101,7 @@ protected: PREP_TIME }; - ay31015_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ay31015_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -157,7 +157,7 @@ protected: class ay51013_device : public ay31015_device { public: - ay51013_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ay51013_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void internal_reset() override; diff --git a/src/devices/machine/bacta_datalogger.cpp b/src/devices/machine/bacta_datalogger.cpp index 43f9855bfd9..18ed6fcd39f 100644 --- a/src/devices/machine/bacta_datalogger.cpp +++ b/src/devices/machine/bacta_datalogger.cpp @@ -29,12 +29,12 @@ DEFINE_DEVICE_TYPE(BACTA_DATALOGGER, bacta_datalogger_device, "bacta_datalogger" // bacta_datalogger_device - constructor //------------------------------------------------- -bacta_datalogger_device::bacta_datalogger_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bacta_datalogger_device::bacta_datalogger_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bacta_datalogger_device(mconfig, BACTA_DATALOGGER, tag, owner, clock) { } -bacta_datalogger_device::bacta_datalogger_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +bacta_datalogger_device::bacta_datalogger_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BACTA_DATALOGGER, tag, owner, clock), device_serial_interface(mconfig, *this), m_rxd_handler(*this), @@ -57,9 +57,9 @@ void bacta_datalogger_device::device_reset() set_data_frame(startbits, databits, parity, stopbits); - set_tra_rate(1200); + set_tra_rate(XTAL::u(1200)); - set_rcv_rate(1200); + set_rcv_rate(XTAL::u(1200)); output_rxd(1); } @@ -70,7 +70,7 @@ void bacta_datalogger_device::tx_queue() { if (m_output_char != 255) { - set_tra_rate(1200); + set_tra_rate(XTAL::u(1200)); transmit_register_setup(m_output_char); m_output_char = 255; } diff --git a/src/devices/machine/bacta_datalogger.h b/src/devices/machine/bacta_datalogger.h index 61555d85acd..44245c8a884 100644 --- a/src/devices/machine/bacta_datalogger.h +++ b/src/devices/machine/bacta_datalogger.h @@ -9,7 +9,7 @@ class bacta_datalogger_device : public device_t, public device_serial_interface { public: - bacta_datalogger_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + bacta_datalogger_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual WRITE_LINE_MEMBER( write_txd ) {device_serial_interface::rx_w(state); } auto rxd_handler() { return m_rxd_handler.bind(); } @@ -17,7 +17,7 @@ public: DECLARE_WRITE_LINE_MEMBER( output_rxd ) { m_rxd_handler(state); } protected: - bacta_datalogger_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bacta_datalogger_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/machine/bankdev.cpp b/src/devices/machine/bankdev.cpp index e8e141ff7e6..308a116a9e9 100644 --- a/src/devices/machine/bankdev.cpp +++ b/src/devices/machine/bankdev.cpp @@ -6,7 +6,7 @@ // device type definition DEFINE_DEVICE_TYPE(ADDRESS_MAP_BANK, address_map_bank_device, "address_map_bank", "Address Map Bank") -address_map_bank_device::address_map_bank_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +address_map_bank_device::address_map_bank_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ADDRESS_MAP_BANK, tag, owner, clock), device_memory_interface(mconfig, *this), m_endianness(ENDIANNESS_NATIVE), diff --git a/src/devices/machine/bankdev.h b/src/devices/machine/bankdev.h index 05a3c2eb411..3f0cd1d3f3d 100644 --- a/src/devices/machine/bankdev.h +++ b/src/devices/machine/bankdev.h @@ -12,7 +12,7 @@ class address_map_bank_device : { public: // construction/destruction - address_map_bank_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + address_map_bank_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers template <typename... T> address_map_bank_device& set_map(T &&... args) { set_addrmap(0, std::forward<T>(args)...); return *this; } diff --git a/src/devices/machine/bcreader.cpp b/src/devices/machine/bcreader.cpp index a94c488583c..8d80e084337 100644 --- a/src/devices/machine/bcreader.cpp +++ b/src/devices/machine/bcreader.cpp @@ -59,7 +59,7 @@ DEFINE_DEVICE_TYPE(BARCODE_READER, barcode_reader_device, "bcreader", "Barcode R // barcode_reader_device - constructor //------------------------------------------------- -barcode_reader_device::barcode_reader_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +barcode_reader_device::barcode_reader_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BARCODE_READER, tag, owner, clock) , m_byte_length(0) , m_pixel_length(0) diff --git a/src/devices/machine/bcreader.h b/src/devices/machine/bcreader.h index 6fd3966bef0..3b5fe3eb86d 100644 --- a/src/devices/machine/bcreader.h +++ b/src/devices/machine/bcreader.h @@ -17,7 +17,7 @@ class barcode_reader_device : public device_t { public: // construction/destruction - barcode_reader_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + barcode_reader_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write_code(const char *barcode, int len); int get_pending_code() { return m_new_code; } diff --git a/src/devices/machine/bitmap_printer.cpp b/src/devices/machine/bitmap_printer.cpp index ca552a14694..83296b5474b 100644 --- a/src/devices/machine/bitmap_printer.cpp +++ b/src/devices/machine/bitmap_printer.cpp @@ -76,7 +76,7 @@ void bitmap_printer_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -bitmap_printer_device::bitmap_printer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +bitmap_printer_device::bitmap_printer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_cr_direction(1), m_xpos(0), @@ -108,13 +108,13 @@ bitmap_printer_device::bitmap_printer_device(const machine_config &mconfig, devi { } -bitmap_printer_device::bitmap_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bitmap_printer_device::bitmap_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bitmap_printer_device(mconfig, BITMAP_PRINTER, tag, owner, clock) { } bitmap_printer_device::bitmap_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, int paper_width, int paper_height, int hdpi, int vdpi) : - bitmap_printer_device(mconfig, tag, owner, u32(0)) + bitmap_printer_device(mconfig, tag, owner) { m_paper_width = paper_width; m_paper_height = paper_height; diff --git a/src/devices/machine/bitmap_printer.h b/src/devices/machine/bitmap_printer.h index 7b05f0e8c15..6541a2ade47 100644 --- a/src/devices/machine/bitmap_printer.h +++ b/src/devices/machine/bitmap_printer.h @@ -24,7 +24,7 @@ class bitmap_printer_device : public device_t { public: - bitmap_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bitmap_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); bitmap_printer_device(const machine_config &mconfig, const char *tag, device_t *owner, int paper_width, int paper_height, int hdpi, int vdpi); enum @@ -65,7 +65,7 @@ public: int m_ypos; protected: - bitmap_printer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bitmap_printer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/machine/bl_handhelds_menucontrol.cpp b/src/devices/machine/bl_handhelds_menucontrol.cpp index 18982731069..af101981a1f 100644 --- a/src/devices/machine/bl_handhelds_menucontrol.cpp +++ b/src/devices/machine/bl_handhelds_menucontrol.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(BL_HANDHELDS_MENUCONTROL, bl_handhelds_menucontrol_device, "blhandheldmenu", "BaoBaoLong Handhelds Menu Controller") -bl_handhelds_menucontrol_device::bl_handhelds_menucontrol_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bl_handhelds_menucontrol_device::bl_handhelds_menucontrol_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BL_HANDHELDS_MENUCONTROL, tag, owner, clock), m_is_unsp_type_hack(false) { diff --git a/src/devices/machine/bl_handhelds_menucontrol.h b/src/devices/machine/bl_handhelds_menucontrol.h index 747a60db76b..7ad8e6b772e 100644 --- a/src/devices/machine/bl_handhelds_menucontrol.h +++ b/src/devices/machine/bl_handhelds_menucontrol.h @@ -12,7 +12,7 @@ class bl_handhelds_menucontrol_device : public device_t { public: // construction/destruction - bl_handhelds_menucontrol_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bl_handhelds_menucontrol_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // the chip is the same between systems, but there's some logic not fully understood that is causing off-by-1 errors on some calcs void set_is_unsp_type_hack() { m_is_unsp_type_hack = true; } diff --git a/src/devices/machine/bq4847.cpp b/src/devices/machine/bq4847.cpp index 91fca4b8edd..db85cd16a92 100644 --- a/src/devices/machine/bq4847.cpp +++ b/src/devices/machine/bq4847.cpp @@ -74,7 +74,7 @@ enum // Constructors for basetype //------------------------------------------------- -bq4847_device::bq4847_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock) +bq4847_device::bq4847_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nvram_interface(mconfig, *this), device_rtc_interface(mconfig, *this), @@ -92,12 +92,12 @@ bq4847_device::bq4847_device(const machine_config& mconfig, device_type type, co { } -bq4847_device::bq4847_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +bq4847_device::bq4847_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : bq4847_device(mconfig, BQ4847, tag, owner, clock) { } -bq4845_device::bq4845_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) +bq4845_device::bq4845_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : bq4847_device(mconfig, BQ4845, tag, owner, clock) { } diff --git a/src/devices/machine/bq4847.h b/src/devices/machine/bq4847.h index 2658e207962..590c2b43aa6 100644 --- a/src/devices/machine/bq4847.h +++ b/src/devices/machine/bq4847.h @@ -20,7 +20,7 @@ class bq4847_device : public device_t, public device_rtc_interface { public: - bq4847_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bq4847_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto wdo_handler() { return m_wdo_handler.bind(); } auto int_handler() { return m_int_handler.bind(); } @@ -32,7 +32,7 @@ public: DECLARE_WRITE_LINE_MEMBER(write_wdi); // watchdog disabled if wdi pin is left floating protected: - bq4847_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock = 32768); + bq4847_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32768)); // device_t virtual void device_start() override; @@ -89,7 +89,7 @@ private: class bq4845_device : public bq4847_device { public: - bq4845_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + bq4845_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(BQ4845, bq4845_device) diff --git a/src/devices/machine/bq48x2.cpp b/src/devices/machine/bq48x2.cpp index 849f019ce6c..a8b8b8f2c45 100644 --- a/src/devices/machine/bq48x2.cpp +++ b/src/devices/machine/bq48x2.cpp @@ -60,7 +60,7 @@ enum //------------------------------------------------- bq48x2_device::bq48x2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, int memsize) - : device_t(mconfig, type, tag, owner, 0), + : device_t(mconfig, type, tag, owner), device_nvram_interface(mconfig, *this), device_rtc_interface(mconfig, *this), m_interrupt_cb(*this), @@ -74,13 +74,13 @@ bq48x2_device::bq48x2_device(const machine_config &mconfig, device_type type, co //------------------------------------------------- // 128 KiB memory (including clock registers) -bq4842_device::bq4842_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bq4842_device::bq4842_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bq48x2_device(mconfig, BQ4842, tag, owner, 128*1024) { } // 512 KiB memory (including clock registers) -bq4852_device::bq4852_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bq4852_device::bq4852_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bq48x2_device(mconfig, BQ4852, tag, owner, 512*1024) { } diff --git a/src/devices/machine/bq48x2.h b/src/devices/machine/bq48x2.h index f19b9778c7c..0a36a8d11f8 100644 --- a/src/devices/machine/bq48x2.h +++ b/src/devices/machine/bq48x2.h @@ -121,13 +121,13 @@ private: class bq4842_device : public bq48x2_device { public: - bq4842_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bq4842_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class bq4852_device : public bq48x2_device { public: - bq4852_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bq4852_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(BQ4842, bq4842_device) diff --git a/src/devices/machine/buffer.cpp b/src/devices/machine/buffer.cpp index b1a93df8fb7..4eb95a7a79c 100644 --- a/src/devices/machine/buffer.cpp +++ b/src/devices/machine/buffer.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(INPUT_BUFFER, input_buffer_device, "input_buffer", "Input Buffer") -input_buffer_device::input_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +input_buffer_device::input_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INPUT_BUFFER, tag, owner, clock) , m_input_data(0xff) { diff --git a/src/devices/machine/buffer.h b/src/devices/machine/buffer.h index 5df28af6c6b..b14e7a1ff1e 100644 --- a/src/devices/machine/buffer.h +++ b/src/devices/machine/buffer.h @@ -6,7 +6,7 @@ class input_buffer_device : public device_t { public: - input_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + input_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint8_t read() { return m_input_data; } diff --git a/src/devices/machine/busmouse.cpp b/src/devices/machine/busmouse.cpp index 2def623649b..bcdf237b9f3 100644 --- a/src/devices/machine/busmouse.cpp +++ b/src/devices/machine/busmouse.cpp @@ -118,7 +118,7 @@ ioport_constructor bus_mouse_device::device_input_ports() const // bus_mouse_device - constructor //------------------------------------------------- -bus_mouse_device::bus_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bus_mouse_device::bus_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BUS_MOUSE, tag, owner, clock) , m_write_extint(*this) , m_buttons(*this, "mouse_buttons") diff --git a/src/devices/machine/busmouse.h b/src/devices/machine/busmouse.h index 29c20d236ee..93718527d62 100644 --- a/src/devices/machine/busmouse.h +++ b/src/devices/machine/busmouse.h @@ -15,7 +15,7 @@ class bus_mouse_device : public device_t { public: // construction/destruction - bus_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bus_mouse_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto extint_callback() { return m_write_extint.bind(); } diff --git a/src/devices/machine/cammu.cpp b/src/devices/machine/cammu.cpp index dabc637f085..e889f00fbba 100644 --- a/src/devices/machine/cammu.cpp +++ b/src/devices/machine/cammu.cpp @@ -96,7 +96,7 @@ DEFINE_DEVICE_TYPE(CAMMU_C4T, cammu_c4t_device, "c4t", "C4E/C4T CAMMU") DEFINE_DEVICE_TYPE(CAMMU_C4I, cammu_c4i_device, "c4i", "C4I CAMMU") DEFINE_DEVICE_TYPE(CAMMU_C3, cammu_c3_device, "c3", "C1/C3 CAMMU") -cammu_c4t_device::cammu_c4t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cammu_c4t_device::cammu_c4t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cammu_c4_device(mconfig, CAMMU_C4T, tag, owner, clock) , m_ram_line(0) , m_htlb_offset(0) @@ -113,7 +113,7 @@ cammu_c4t_device::cammu_c4t_device(const machine_config &mconfig, const char *ta { } -cammu_c4i_device::cammu_c4i_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cammu_c4i_device::cammu_c4i_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cammu_c4_device(mconfig, CAMMU_C4I, tag, owner, clock) , m_reset(0) , m_clr_s_data_tlb(0) @@ -125,7 +125,7 @@ cammu_c4i_device::cammu_c4i_device(const machine_config &mconfig, const char *ta { } -cammu_c4_device::cammu_c4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +cammu_c4_device::cammu_c4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : cammu_device(mconfig, type, tag, owner, clock) , m_s_pdo(0) , m_u_pdo(0) @@ -140,7 +140,7 @@ cammu_c4_device::cammu_c4_device(const machine_config &mconfig, device_type type { } -cammu_c3_device::cammu_c3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cammu_c3_device::cammu_c3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cammu_device(mconfig, CAMMU_C3, tag, owner, clock) , m_linked{ this } , m_s_pdo(0) @@ -150,7 +150,7 @@ cammu_c3_device::cammu_c3_device(const machine_config &mconfig, const char *tag, { } -cammu_device::cammu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +cammu_device::cammu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_exception_func(*this) { diff --git a/src/devices/machine/cammu.h b/src/devices/machine/cammu.h index 83b44d4b120..64515a19a05 100644 --- a/src/devices/machine/cammu.h +++ b/src/devices/machine/cammu.h @@ -196,7 +196,7 @@ public: bool memory_translate(const u32 ssw, const int spacenum, const int intention, offs_t &address); protected: - cammu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cammu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -293,7 +293,7 @@ public: void fault_data_2_hi_w(u32 data) { m_fault_data_2_hi = data; } protected: - cammu_c4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cammu_c4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -318,7 +318,7 @@ protected: class cammu_c4t_device : public cammu_c4_device { public: - cammu_c4t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cammu_c4t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; @@ -408,7 +408,7 @@ private: class cammu_c4i_device : public cammu_c4_device { public: - cammu_c4i_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cammu_c4i_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; @@ -505,7 +505,7 @@ private: class cammu_c3_device : public cammu_device { public: - cammu_c3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cammu_c3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void add_linked(cammu_c3_device *child) { m_linked.push_back(child); } diff --git a/src/devices/machine/cdp1852.cpp b/src/devices/machine/cdp1852.cpp index b4850ac669e..7dcf4bfe536 100644 --- a/src/devices/machine/cdp1852.cpp +++ b/src/devices/machine/cdp1852.cpp @@ -39,7 +39,7 @@ enum // cdp1852_device - constructor //------------------------------------------------- -cdp1852_device::cdp1852_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +cdp1852_device::cdp1852_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDP1852, tag, owner, clock), m_read_mode(*this), m_write_sr(*this), diff --git a/src/devices/machine/cdp1852.h b/src/devices/machine/cdp1852.h index 4f4bec622f9..58317abe671 100644 --- a/src/devices/machine/cdp1852.h +++ b/src/devices/machine/cdp1852.h @@ -30,7 +30,7 @@ class cdp1852_device : public device_t { public: // construction/destruction - cdp1852_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + cdp1852_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto mode_cb() { return m_read_mode.bind(); } auto sr_cb() { return m_write_sr.bind(); } diff --git a/src/devices/machine/cdp1871.cpp b/src/devices/machine/cdp1871.cpp index 3e32512c30f..18989e6cd78 100644 --- a/src/devices/machine/cdp1871.cpp +++ b/src/devices/machine/cdp1871.cpp @@ -96,7 +96,7 @@ const uint8_t cdp1871_device::key_codes[4][11][8] = // cdp1871_device - constructor //------------------------------------------------- -cdp1871_device::cdp1871_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cdp1871_device::cdp1871_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDP1871, tag, owner, clock), m_read_d1(*this), m_read_d2(*this), diff --git a/src/devices/machine/cdp1871.h b/src/devices/machine/cdp1871.h index a359980f7fb..368cfa5b5d2 100644 --- a/src/devices/machine/cdp1871.h +++ b/src/devices/machine/cdp1871.h @@ -38,7 +38,7 @@ class cdp1871_device : public device_t { public: // construction/destruction - cdp1871_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1871_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto d1_callback() { return m_read_d1.bind(); } auto d2_callback() { return m_read_d2.bind(); } diff --git a/src/devices/machine/cdp1879.cpp b/src/devices/machine/cdp1879.cpp index f6687f73226..f680146e169 100644 --- a/src/devices/machine/cdp1879.cpp +++ b/src/devices/machine/cdp1879.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(CDP1879, cdp1879_device, "cdp1879", "RCA CDP1879 RTC") // cdp1879_device - constructor //------------------------------------------------- -cdp1879_device::cdp1879_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cdp1879_device::cdp1879_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDP1879, tag, owner, clock), device_rtc_interface(mconfig, *this), m_irq_w(*this) diff --git a/src/devices/machine/cdp1879.h b/src/devices/machine/cdp1879.h index 4dc761b5fd7..3ac6a05d1b4 100644 --- a/src/devices/machine/cdp1879.h +++ b/src/devices/machine/cdp1879.h @@ -18,7 +18,7 @@ class cdp1879_device : public device_t, { public: // construction/destruction - cdp1879_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1879_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/machine/ch376.cpp b/src/devices/machine/ch376.cpp index eeca140ec0a..8c674e297a4 100644 --- a/src/devices/machine/ch376.cpp +++ b/src/devices/machine/ch376.cpp @@ -74,7 +74,7 @@ static constexpr u8 CMD_BYTE_WR_GO = 0x3d; // ch376_device - constructor //------------------------------------------------- -ch376_device::ch376_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ch376_device::ch376_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CH376, tag, owner, clock), m_state(0), m_status(0), diff --git a/src/devices/machine/ch376.h b/src/devices/machine/ch376.h index d00586b1503..7a1e58e5bc9 100644 --- a/src/devices/machine/ch376.h +++ b/src/devices/machine/ch376.h @@ -28,7 +28,7 @@ class ch376_device : public device_t { public: // construction/destruction - ch376_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ch376_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); u8 read(offs_t offset); void write(offs_t offset, u8 data); diff --git a/src/devices/machine/chessmachine.cpp b/src/devices/machine/chessmachine.cpp index 1016cec2ec4..3b7a7a65768 100644 --- a/src/devices/machine/chessmachine.cpp +++ b/src/devices/machine/chessmachine.cpp @@ -42,7 +42,7 @@ DEFINE_DEVICE_TYPE(CHESSMACHINE, chessmachine_device, "chessmachine", "Tasc Ches // constructor //------------------------------------------------- -chessmachine_device::chessmachine_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +chessmachine_device::chessmachine_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CHESSMACHINE, tag, owner, clock), m_maincpu(*this, "maincpu"), m_bootrom(*this, "bootrom"), diff --git a/src/devices/machine/chessmachine.h b/src/devices/machine/chessmachine.h index 561e95459a7..dfbc5747a1a 100644 --- a/src/devices/machine/chessmachine.h +++ b/src/devices/machine/chessmachine.h @@ -18,7 +18,7 @@ class chessmachine_device : public device_t { public: - chessmachine_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + chessmachine_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto data_out() { return m_data_out.bind(); } // data_r diff --git a/src/devices/machine/clock.cpp b/src/devices/machine/clock.cpp index 4c2ad3afd7a..19760c789b2 100644 --- a/src/devices/machine/clock.cpp +++ b/src/devices/machine/clock.cpp @@ -19,7 +19,7 @@ Output signal at machine start is right after falling edge. DEFINE_DEVICE_TYPE(CLOCK, clock_device, "clock", "Clock") -clock_device::clock_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +clock_device::clock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CLOCK, tag, owner, clock), m_signal(0), m_output(-1), diff --git a/src/devices/machine/clock.h b/src/devices/machine/clock.h index 1dc4739ce6c..1e822985106 100644 --- a/src/devices/machine/clock.h +++ b/src/devices/machine/clock.h @@ -14,7 +14,7 @@ class clock_device : public device_t { public: - clock_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + clock_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto signal_handler() { return m_signal_handler.bind(); } auto &set_period(attotime period) { m_period = period; reinit(); return *this; } diff --git a/src/devices/machine/com52c50.cpp b/src/devices/machine/com52c50.cpp index 89b4e176f85..0488a12f088 100644 --- a/src/devices/machine/com52c50.cpp +++ b/src/devices/machine/com52c50.cpp @@ -15,7 +15,7 @@ // device type definition DEFINE_DEVICE_TYPE(COM52C50, com52c50_device, "com52c50", "SMC COM52C50 TIC") -com52c50_device::com52c50_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +com52c50_device::com52c50_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COM52C50, tag, owner, clock) , m_int1_callback(*this) , m_int2_callback(*this) diff --git a/src/devices/machine/com52c50.h b/src/devices/machine/com52c50.h index 085a3e0808a..b5c47a0e484 100644 --- a/src/devices/machine/com52c50.h +++ b/src/devices/machine/com52c50.h @@ -35,7 +35,7 @@ class com52c50_device : public device_t { public: // device type constructor - com52c50_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + com52c50_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto int1_callback() { return m_int1_callback.bind(); } diff --git a/src/devices/machine/com8116.cpp b/src/devices/machine/com8116.cpp index 38364b4b101..6645d01200d 100644 --- a/src/devices/machine/com8116.cpp +++ b/src/devices/machine/com8116.cpp @@ -88,7 +88,7 @@ const int com8116_device::divisors_16X_4_6080MHz[16] = // com8116_device - constructor //------------------------------------------------- -com8116_device::com8116_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const int *divisors) : +com8116_device::com8116_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const int *divisors) : device_t(mconfig, type, tag, owner, clock), m_fx4_handler(*this), m_fr_handler(*this), @@ -97,32 +97,32 @@ com8116_device::com8116_device(const machine_config &mconfig, device_type type, { } -com8116_device::com8116_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +com8116_device::com8116_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : com8116_device(mconfig, COM8116, tag, owner, clock, divisors_16X_5_0688MHz) { } -com8116_003_device::com8116_003_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +com8116_003_device::com8116_003_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : com8116_device(mconfig, COM8116_003, tag, owner, clock, divisors_16X_6_01835MHz) { } -com5016_5_device::com5016_5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +com5016_5_device::com5016_5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : com8116_device(mconfig, COM5016_5, tag, owner, clock, divisors_16X_4_9152MHz) { } -com5016_013_device::com5016_013_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +com5016_013_device::com5016_013_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : com8116_device(mconfig, COM5016_013, tag, owner, clock, divisors_16X_2_7648MHz) { } -com8116_020_device::com8116_020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +com8116_020_device::com8116_020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : com8116_device(mconfig, COM8116_020, tag, owner, clock, divisors_16X_1_8432MHz) { } -k1135ab_device::k1135ab_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +k1135ab_device::k1135ab_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : com8116_device(mconfig, K1135AB, tag, owner, clock, divisors_16X_5_0688MHz) { } diff --git a/src/devices/machine/com8116.h b/src/devices/machine/com8116.h index 908d7c782d2..351fb940f32 100644 --- a/src/devices/machine/com8116.h +++ b/src/devices/machine/com8116.h @@ -37,7 +37,7 @@ class com8116_device : public device_t { public: // construction/destruction - com8116_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + com8116_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto fx4_handler() { return m_fx4_handler.bind(); } auto fr_handler() { return m_fr_handler.bind(); } @@ -49,7 +49,7 @@ public: void stt_str_w(uint8_t data); protected: - com8116_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const int *divisors); + com8116_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const int *divisors); static const int divisors_16X_5_0688MHz[16]; static const int divisors_16X_6_01835MHz[16]; @@ -92,7 +92,7 @@ class com8116_003_device : public com8116_device { public: // construction/destruction - com8116_003_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + com8116_003_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -102,7 +102,7 @@ class com5016_5_device : public com8116_device { public: // construction/destruction - com5016_5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + com5016_5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -112,7 +112,7 @@ class com5016_013_device : public com8116_device { public: // construction/destruction - com5016_013_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + com5016_013_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -122,7 +122,7 @@ class com8116_020_device : public com8116_device { public: // construction/destruction - com8116_020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + com8116_020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -132,7 +132,7 @@ class k1135ab_device : public com8116_device { public: // construction/destruction - k1135ab_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + k1135ab_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/machine/cop452.cpp b/src/devices/machine/cop452.cpp index 87e2d0954d5..a547ee9c66b 100644 --- a/src/devices/machine/cop452.cpp +++ b/src/devices/machine/cop452.cpp @@ -19,7 +19,7 @@ // Device type definition DEFINE_DEVICE_TYPE(COP452, cop452_device, "cop452", "National Semiconductor COP452 frequency generator") -cop452_device::cop452_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cop452_device::cop452_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, COP452, tag, owner, clock) , m_out_handlers(*this) { diff --git a/src/devices/machine/cop452.h b/src/devices/machine/cop452.h index 238e5c8b5ca..7b0c36e30bc 100644 --- a/src/devices/machine/cop452.h +++ b/src/devices/machine/cop452.h @@ -26,7 +26,7 @@ class cop452_device : public device_t { public: - cop452_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + cop452_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // SPI I/O DECLARE_WRITE_LINE_MEMBER(cs_w); diff --git a/src/devices/machine/corvushd.cpp b/src/devices/machine/corvushd.cpp index b0c819b33f8..ce47d1a25de 100644 --- a/src/devices/machine/corvushd.cpp +++ b/src/devices/machine/corvushd.cpp @@ -227,7 +227,7 @@ DEFINE_DEVICE_TYPE(CORVUS_HDC, corvus_hdc_device, "corvus_hdc", "Corvus Flat Cable HDC") -corvus_hdc_device::corvus_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +corvus_hdc_device::corvus_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CORVUS_HDC, tag, owner, clock), m_status(0), m_prep_mode(false), diff --git a/src/devices/machine/corvushd.h b/src/devices/machine/corvushd.h index 074b761eb60..9c9f23a7b53 100644 --- a/src/devices/machine/corvushd.h +++ b/src/devices/machine/corvushd.h @@ -28,7 +28,7 @@ public: static constexpr uint8_t CONTROLLER_DIRECTION = 0x40; // Set = Controller->Host, Clear = Host->Controller // construction/destruction - corvus_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + corvus_hdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(); void write(uint8_t data); diff --git a/src/devices/machine/cr511b.cpp b/src/devices/machine/cr511b.cpp index 9eb07578de0..3b6151d671e 100644 --- a/src/devices/machine/cr511b.cpp +++ b/src/devices/machine/cr511b.cpp @@ -40,7 +40,7 @@ void cr511b_device::device_add_mconfig(machine_config &config) // cr511b_device - constructor //------------------------------------------------- -cr511b_device::cr511b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cr511b_device::cr511b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CR511B, tag, owner, clock), m_cdrom(*this, "cdrom"), m_cdda(*this, "cdda"), diff --git a/src/devices/machine/cr511b.h b/src/devices/machine/cr511b.h index aae738145fd..1b797df9c7a 100644 --- a/src/devices/machine/cr511b.h +++ b/src/devices/machine/cr511b.h @@ -42,7 +42,7 @@ class cr511b_device : public device_t { public: // construction/destruction - cr511b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cr511b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto stch_handler() { return m_stch_handler.bind(); } diff --git a/src/devices/machine/cs4031.cpp b/src/devices/machine/cs4031.cpp index 55cb0377cad..eec830ad9b7 100644 --- a/src/devices/machine/cs4031.cpp +++ b/src/devices/machine/cs4031.cpp @@ -96,7 +96,7 @@ const float cs4031_device::m_dma_clock_divider[] = void cs4031_device::device_add_mconfig(machine_config &config) { - AM9517A(config, m_dma1, 0); + AM9517A(config, m_dma1); m_dma1->out_hreq_callback().set(m_dma2, FUNC(am9517a_device::dreq0_w)); m_dma1->out_eop_callback().set(FUNC(cs4031_device::dma1_eop_w)); m_dma1->in_memr_callback().set(FUNC(cs4031_device::dma_read_byte)); @@ -114,7 +114,7 @@ void cs4031_device::device_add_mconfig(machine_config &config) m_dma1->out_dack_callback<2>().set(FUNC(cs4031_device::dma1_dack2_w)); m_dma1->out_dack_callback<3>().set(FUNC(cs4031_device::dma1_dack3_w)); - AM9517A(config, m_dma2, 0); + AM9517A(config, m_dma2); m_dma2->out_hreq_callback().set(FUNC(cs4031_device::dma2_hreq_w)); m_dma2->in_memr_callback().set(FUNC(cs4031_device::dma_read_word)); m_dma2->out_memw_callback().set(FUNC(cs4031_device::dma_write_word)); @@ -129,16 +129,16 @@ void cs4031_device::device_add_mconfig(machine_config &config) m_dma2->out_dack_callback<2>().set(FUNC(cs4031_device::dma2_dack2_w)); m_dma2->out_dack_callback<3>().set(FUNC(cs4031_device::dma2_dack3_w)); - PIC8259(config, m_intc1, 0); + PIC8259(config, m_intc1); m_intc1->out_int_callback().set(FUNC(cs4031_device::intc1_int_w)); m_intc1->in_sp_callback().set_constant(1); m_intc1->read_slave_ack_callback().set(FUNC(cs4031_device::intc1_slave_ack_r)); - PIC8259(config, m_intc2, 0); + PIC8259(config, m_intc2); m_intc2->out_int_callback().set(m_intc1, FUNC(pic8259_device::ir2_w)); m_intc2->in_sp_callback().set_constant(0); - PIT8254(config, m_ctc, 0); + PIT8254(config, m_ctc); m_ctc->set_clk<0>(XTAL(14'318'181) / 12.0); m_ctc->out_handler<0>().set(m_intc1, FUNC(pic8259_device::ir0_w)); m_ctc->set_clk<1>(XTAL(14'318'181) / 12.0); @@ -160,7 +160,7 @@ void cs4031_device::device_add_mconfig(machine_config &config) // cs4031_device - constructor //------------------------------------------------- -cs4031_device::cs4031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cs4031_device::cs4031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CS4031, tag, owner, clock), m_read_ior(*this), m_write_iow(*this), diff --git a/src/devices/machine/cs4031.h b/src/devices/machine/cs4031.h index 5e7ea81b4e0..1e7de332904 100644 --- a/src/devices/machine/cs4031.h +++ b/src/devices/machine/cs4031.h @@ -37,7 +37,7 @@ class cs4031_device : public device_t public: // construction/destruction template <typename T, typename U, typename V, typename W, typename X> - cs4031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cputag, U &&isatag, V &&biostag, W &&keybctag, X &&ramtag) + cs4031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cputag, U &&isatag, V &&biostag, W &&keybctag, X &&ramtag) : cs4031_device(mconfig, tag, owner, clock) { set_cputag(std::forward<T>(cputag)); @@ -47,7 +47,7 @@ public: set_ramtag(std::forward<X>(ramtag)); } - cs4031_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cs4031_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto ior() { return m_read_ior.bind(); } diff --git a/src/devices/machine/cs8221.cpp b/src/devices/machine/cs8221.cpp index e57f181e383..c4970e80975 100644 --- a/src/devices/machine/cs8221.cpp +++ b/src/devices/machine/cs8221.cpp @@ -61,7 +61,7 @@ static const char *const register_names[] = // cs8221_device - constructor //------------------------------------------------- -cs8221_device::cs8221_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cs8221_device::cs8221_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CS8221, tag, owner, clock), m_address(0), m_address_valid(false) diff --git a/src/devices/machine/cs8221.h b/src/devices/machine/cs8221.h index 63b3102d5e9..c6952a94a9c 100644 --- a/src/devices/machine/cs8221.h +++ b/src/devices/machine/cs8221.h @@ -24,15 +24,15 @@ class cs8221_device : public device_t { public: // construction/destruction - cs8221_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, const char *cputag, const char *isatag, const char *biostag) - : cs8221_device(mconfig, tag, owner, clock) + cs8221_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *cputag, const char *isatag, const char *biostag) + : cs8221_device(mconfig, tag, owner) { set_cputag(cputag); set_isatag(isatag); set_biostag(biostag); } - cs8221_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cs8221_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration void set_cputag(const char *tag) { m_cputag = tag; } diff --git a/src/devices/machine/cs8900a.cpp b/src/devices/machine/cs8900a.cpp index 52e0808bb01..84ee06c27d0 100644 --- a/src/devices/machine/cs8900a.cpp +++ b/src/devices/machine/cs8900a.cpp @@ -375,7 +375,7 @@ void cs8900a_device::device_start() save_item(NAME(rxevent_read_mask)); } -cs8900a_device::cs8900a_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +cs8900a_device::cs8900a_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_network_interface(mconfig, *this, 10) , cs8900_ia_mac{0, 0, 0, 0, 0, 0} @@ -400,7 +400,7 @@ cs8900a_device::cs8900a_device(const machine_config& mconfig, device_type type, , rxevent_read_mask(3) /* set if L and/or H u8 was read in RXEVENT? */ {} -cs8900a_device::cs8900a_device(machine_config const& mconfig, char const *tag, device_t *owner, u32 clock) +cs8900a_device::cs8900a_device(machine_config const& mconfig, char const *tag, device_t *owner, const XTAL &clock) : cs8900a_device(mconfig, CS8900A, tag, owner, clock) {} diff --git a/src/devices/machine/cs8900a.h b/src/devices/machine/cs8900a.h index a0a6f88dbb4..408701f7ac5 100644 --- a/src/devices/machine/cs8900a.h +++ b/src/devices/machine/cs8900a.h @@ -27,13 +27,13 @@ class cs8900a_device : public device_t, public device_network_interface { public: - cs8900a_device(machine_config const& mconfig, char const *tag, device_t *owner, u32 clock); + cs8900a_device(machine_config const& mconfig, char const *tag, device_t *owner, const XTAL &clock); u8 read(u16 address); void write(u16 address, u8 data); protected: - cs8900a_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cs8900a_device(const machine_config& mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/machine/cxd1095.cpp b/src/devices/machine/cxd1095.cpp index 1f78ca628a1..214325c7b31 100644 --- a/src/devices/machine/cxd1095.cpp +++ b/src/devices/machine/cxd1095.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(CXD1095, cxd1095_device, "cxd1095", "CXD1095 I/O Expander") // cxd1095_device - constructor //------------------------------------------------- -cxd1095_device::cxd1095_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +cxd1095_device::cxd1095_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CXD1095, tag, owner, clock) , m_input_cb(*this) , m_output_cb(*this) diff --git a/src/devices/machine/cxd1095.h b/src/devices/machine/cxd1095.h index f5decf3def7..c1c0a857f44 100644 --- a/src/devices/machine/cxd1095.h +++ b/src/devices/machine/cxd1095.h @@ -48,7 +48,7 @@ class cxd1095_device : public device_t { public: // construction/destruction - cxd1095_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + cxd1095_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration template <std::size_t Port> auto in_port_cb() { static_assert(Port >= 0 && Port < 5, "invalid port"); return m_input_cb[Port].bind(); } diff --git a/src/devices/machine/cxd1185.cpp b/src/devices/machine/cxd1185.cpp index b854884d29a..da153e3918e 100644 --- a/src/devices/machine/cxd1185.cpp +++ b/src/devices/machine/cxd1185.cpp @@ -43,7 +43,7 @@ static unsigned const SCSI_RST_HOLD = 25'000; ALLOW_SAVE_TYPE(cxd1185_device::state); -cxd1185_device::cxd1185_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +cxd1185_device::cxd1185_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : nscsi_device(mconfig, CXD1185, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, DEVICE_SELF) , m_irq_out_cb(*this) diff --git a/src/devices/machine/cxd1185.h b/src/devices/machine/cxd1185.h index f1d6732b26d..6a8b5a3236b 100644 --- a/src/devices/machine/cxd1185.h +++ b/src/devices/machine/cxd1185.h @@ -13,7 +13,7 @@ class cxd1185_device , public nscsi_slot_card_interface { public: - cxd1185_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + cxd1185_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // device configuration auto irq_out_cb() { return m_irq_out_cb.bind(); } diff --git a/src/devices/machine/dc7085.cpp b/src/devices/machine/dc7085.cpp index 264cef004c6..b6082392a49 100644 --- a/src/devices/machine/dc7085.cpp +++ b/src/devices/machine/dc7085.cpp @@ -89,7 +89,7 @@ enum tdr_mask : u16 TDR_TBUF = 0x00ff, // transmitter buffer }; -dc7085_device::dc7085_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dc7085_device::dc7085_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DC7085, tag, owner, clock) , m_chan(*this, "ch%u", 0U) , m_int_cb(*this) @@ -109,7 +109,7 @@ void dc7085_device::device_add_mconfig(machine_config &config) */ for (unsigned i = 0; i < std::size(m_chan); i++) { - DC7085_CHANNEL(config, m_chan[i], 0); + DC7085_CHANNEL(config, m_chan[i]); m_chan[i]->rx_done().set([this, i](u16 data) { rx_done((i << 8) | data); }); m_chan[i]->tx_cb().set([this, i](int state) { m_tx_cb[i](state); if (m_csr & CSR_MAINT) m_chan[i]->rx_w(state); }); @@ -297,7 +297,7 @@ void dc7085_device::tx_done(int state) recalc_irqs(); } -dc7085_channel::dc7085_channel(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +dc7085_channel::dc7085_channel(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DC7085_CHANNEL, tag, owner, clock) , device_serial_interface(mconfig, *this) , m_tx_cb(*this) @@ -321,8 +321,8 @@ void dc7085_channel::device_reset() transmit_register_reset(); set_data_frame(1, 8, PARITY_NONE, STOP_BITS_1); - set_tra_rate(0); - set_rcv_rate(0); + set_tra_rate(XTAL::u(0)); + set_rcv_rate(XTAL::u(0)); m_rx_enabled = false; } diff --git a/src/devices/machine/dc7085.h b/src/devices/machine/dc7085.h index dccb2bbefce..6f33b26a4d4 100644 --- a/src/devices/machine/dc7085.h +++ b/src/devices/machine/dc7085.h @@ -17,7 +17,7 @@ class dc7085_channel public: auto tx_cb() { return m_tx_cb.bind(); } - dc7085_channel(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + dc7085_channel(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides @@ -49,7 +49,7 @@ private: class dc7085_device : public device_t { public: - dc7085_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + dc7085_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); void map(address_map &map); diff --git a/src/devices/machine/diablo_hd.cpp b/src/devices/machine/diablo_hd.cpp index 2ce1707058c..78bcac694ea 100644 --- a/src/devices/machine/diablo_hd.cpp +++ b/src/devices/machine/diablo_hd.cpp @@ -65,7 +65,7 @@ #define LOG_DRIVE(...) do { if (DIABLO_DEBUG) logprintf(__VA_ARGS__); } while (0) -diablo_hd_device::diablo_hd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +diablo_hd_device::diablo_hd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DIABLO_HD, tag, owner, clock), m_log_level(8), m_diablo31(true), @@ -1432,7 +1432,7 @@ TIMER_CALLBACK_MEMBER(diablo_hd_device::sector_mark_tick) void diablo_hd_device::device_add_mconfig(machine_config &config) { - DIABLO(config, "drive", 0); + DIABLO(config, "drive"); } diff --git a/src/devices/machine/diablo_hd.h b/src/devices/machine/diablo_hd.h index 43524706967..7d92e793fe0 100644 --- a/src/devices/machine/diablo_hd.h +++ b/src/devices/machine/diablo_hd.h @@ -19,7 +19,7 @@ DECLARE_DEVICE_TYPE(DIABLO_HD, diablo_hd_device) class diablo_hd_device : public device_t { public: - diablo_hd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + diablo_hd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~diablo_hd_device(); static const int DIABLO_UNIT_MAX = 2; //!< max number of drive units diff --git a/src/devices/machine/dl11.cpp b/src/devices/machine/dl11.cpp index cde90816cc3..f059eab37c0 100644 --- a/src/devices/machine/dl11.cpp +++ b/src/devices/machine/dl11.cpp @@ -42,7 +42,7 @@ enum // dl11_device - constructor //------------------------------------------------- -dl11_device::dl11_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dl11_device::dl11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DL11, tag, owner, clock) , device_serial_interface(mconfig, *this) , device_z80daisy_interface(mconfig, *this) diff --git a/src/devices/machine/dl11.h b/src/devices/machine/dl11.h index 37dd3d9c614..e0b0f07a2c7 100644 --- a/src/devices/machine/dl11.h +++ b/src/devices/machine/dl11.h @@ -29,7 +29,7 @@ class dl11_device : public device_t, { public: // construction/destruction - dl11_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dl11_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_rxc(int clock) { m_rxc = clock; } void set_txc(int clock) { m_txc = clock; } diff --git a/src/devices/machine/dmac.cpp b/src/devices/machine/dmac.cpp index 0705f28c060..6564417bd99 100644 --- a/src/devices/machine/dmac.cpp +++ b/src/devices/machine/dmac.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(AMIGA_DMAC, amiga_dmac_device, "amiga_dmac", "Amiga DMAC DMA // amiga_dmac_device - constructor //------------------------------------------------- -amiga_dmac_device::amiga_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +amiga_dmac_device::amiga_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AMIGA_DMAC, tag, owner, clock), amiga_autoconfig(), m_cfgout_handler(*this), diff --git a/src/devices/machine/dmac.h b/src/devices/machine/dmac.h index 47c5f9f93d3..fd2644a7f01 100644 --- a/src/devices/machine/dmac.h +++ b/src/devices/machine/dmac.h @@ -24,7 +24,7 @@ class amiga_dmac_device : public device_t, public amiga_autoconfig { public: // construction/destruction - amiga_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + amiga_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto cfgout_handler() { return m_cfgout_handler.bind(); } diff --git a/src/devices/machine/dp8390.cpp b/src/devices/machine/dp8390.cpp index 49b98e94846..fc4e8257bf8 100644 --- a/src/devices/machine/dp8390.cpp +++ b/src/devices/machine/dp8390.cpp @@ -9,17 +9,17 @@ DEFINE_DEVICE_TYPE(DP8390D, dp8390d_device, "dp8390d", "DP8390D NIC") DEFINE_DEVICE_TYPE(RTL8019A, rtl8019a_device, "rtl8019a", "RTL8019A Ethernet Controller") -dp8390d_device::dp8390d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dp8390d_device::dp8390d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dp8390_device(mconfig, DP8390D, tag, owner, clock, TYPE::DP8390D, 10.0f) { } -rtl8019a_device::rtl8019a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rtl8019a_device::rtl8019a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dp8390_device(mconfig, RTL8019A, tag, owner, clock, TYPE::RTL8019A, 10.0f) { } -dp8390_device::dp8390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, TYPE variant, u32 bandwidth) +dp8390_device::dp8390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, TYPE variant, u32 bandwidth) : device_t(mconfig, type, tag, owner, clock) , device_network_interface(mconfig, *this, bandwidth) , m_variant(variant) diff --git a/src/devices/machine/dp8390.h b/src/devices/machine/dp8390.h index 7e87ffe44db..4b14ce9f817 100644 --- a/src/devices/machine/dp8390.h +++ b/src/devices/machine/dp8390.h @@ -32,7 +32,7 @@ protected: }; // construction/destruction - dp8390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, TYPE varian, u32 bandwidth); + dp8390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, TYPE varian, u32 bandwidth); // device-level overrides virtual void device_start() override; @@ -106,13 +106,13 @@ private: class rtl8019a_device : public dp8390_device { public: - rtl8019a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rtl8019a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class dp8390d_device : public dp8390_device { public: - dp8390d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dp8390d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/machine/dp83932c.cpp b/src/devices/machine/dp83932c.cpp index f956d8da8ea..0a818dbd619 100644 --- a/src/devices/machine/dp83932c.cpp +++ b/src/devices/machine/dp83932c.cpp @@ -64,7 +64,7 @@ static u16 const regmask[] = 0xffff, 0xffff, 0xffff, 0xffff, 0xffff, 0xffff, 0xffff, 0xf017, }; -dp83932c_device::dp83932c_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +dp83932c_device::dp83932c_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DP83932C, tag, owner, clock) , device_network_interface(mconfig, *this, 10) , m_bus(*this, finder_base::DUMMY_TAG, 0) diff --git a/src/devices/machine/dp83932c.h b/src/devices/machine/dp83932c.h index 2a7d271eb11..c1464df3f35 100644 --- a/src/devices/machine/dp83932c.h +++ b/src/devices/machine/dp83932c.h @@ -13,7 +13,7 @@ class dp83932c_device , public device_network_interface { public: - dp83932c_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + dp83932c_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // configuration template <typename T> void set_bus(T &&tag, int spacenum) { m_bus.set_tag(std::forward<T>(tag), spacenum); } diff --git a/src/devices/machine/dp8573.cpp b/src/devices/machine/dp8573.cpp index f862bec4deb..dc38bc75b70 100644 --- a/src/devices/machine/dp8573.cpp +++ b/src/devices/machine/dp8573.cpp @@ -20,7 +20,7 @@ // device type definition DEFINE_DEVICE_TYPE(DP8573, dp8573_device, "dp8573", "DP8573 Real-Time Clock") -dp8573_device::dp8573_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dp8573_device::dp8573_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DP8573, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_intr_cb(*this) diff --git a/src/devices/machine/dp8573.h b/src/devices/machine/dp8573.h index 1730884e1b4..5a04d24c9e9 100644 --- a/src/devices/machine/dp8573.h +++ b/src/devices/machine/dp8573.h @@ -19,7 +19,7 @@ public: { } - dp8573_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dp8573_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, u8 data); u8 read(offs_t offset); diff --git a/src/devices/machine/ds1204.cpp b/src/devices/machine/ds1204.cpp index 6d4fd46fc54..fff9476a244 100644 --- a/src/devices/machine/ds1204.cpp +++ b/src/devices/machine/ds1204.cpp @@ -32,7 +32,7 @@ inline void ATTR_PRINTF( 3, 4 ) ds1204_device::verboselog( int n_level, const ch // device type definition DEFINE_DEVICE_TYPE(DS1204, ds1204_device, "ds1204", "DS1204 Electronic Key") -ds1204_device::ds1204_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +ds1204_device::ds1204_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : device_t(mconfig, DS1204, tag, owner, clock), device_nvram_interface(mconfig, *this), m_region(*this, DEVICE_SELF), diff --git a/src/devices/machine/ds1204.h b/src/devices/machine/ds1204.h index 7a51463ac67..bb509e5262a 100644 --- a/src/devices/machine/ds1204.h +++ b/src/devices/machine/ds1204.h @@ -17,7 +17,7 @@ class ds1204_device : public device_t, public device_nvram_interface { public: // construction/destruction - ds1204_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0 ); + ds1204_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL() ); DECLARE_WRITE_LINE_MEMBER( write_rst ); DECLARE_WRITE_LINE_MEMBER( write_clk ); diff --git a/src/devices/machine/ds1205.cpp b/src/devices/machine/ds1205.cpp index 7bafe3b6a88..605f102dc10 100644 --- a/src/devices/machine/ds1205.cpp +++ b/src/devices/machine/ds1205.cpp @@ -32,7 +32,7 @@ inline void ATTR_PRINTF( 3, 4 ) ds1205_device::verboselog( int n_level, const ch // device type definition DEFINE_DEVICE_TYPE(DS1205, ds1205_device, "ds1205", "DS1205") -ds1205_device::ds1205_device( const machine_config &mconfig, const char *tag, device_t *owner, u32 clock ) +ds1205_device::ds1205_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : device_t(mconfig, DS1205, tag, owner, clock), device_nvram_interface(mconfig, *this), m_region(*this, DEVICE_SELF), diff --git a/src/devices/machine/ds1205.h b/src/devices/machine/ds1205.h index 0098142e65f..8c8a05852c3 100644 --- a/src/devices/machine/ds1205.h +++ b/src/devices/machine/ds1205.h @@ -17,7 +17,7 @@ class ds1205_device : public device_t, public device_nvram_interface { public: // construction/destruction - ds1205_device( const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + ds1205_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); DECLARE_WRITE_LINE_MEMBER( write_rst ); DECLARE_WRITE_LINE_MEMBER( write_clk ); diff --git a/src/devices/machine/ds128x.cpp b/src/devices/machine/ds128x.cpp index 8292e5237f2..42b32ada204 100644 --- a/src/devices/machine/ds128x.cpp +++ b/src/devices/machine/ds128x.cpp @@ -9,12 +9,12 @@ DEFINE_DEVICE_TYPE(DS12885, ds12885_device, "ds12885", "DS12885 RTC/NVRAM") // ds12885_device - constructor //------------------------------------------------- -ds12885_device::ds12885_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds12885_device::ds12885_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds12885_device(mconfig, DS12885, tag, owner, clock) { } -ds12885_device::ds12885_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ds12885_device::ds12885_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : mc146818_device(mconfig, type, tag, owner, clock) { } @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(DS12885EXT, ds12885ext_device, "ds12885ext", "DS12885 RTC/NVR // ds12885ext_device - constructor //------------------------------------------------- -ds12885ext_device::ds12885ext_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds12885ext_device::ds12885ext_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds12885_device(mconfig, DS12885EXT, tag, owner, clock) { } diff --git a/src/devices/machine/ds128x.h b/src/devices/machine/ds128x.h index 07209361041..9483449d869 100644 --- a/src/devices/machine/ds128x.h +++ b/src/devices/machine/ds128x.h @@ -12,10 +12,10 @@ class ds12885_device : public mc146818_device { public: // construction/destruction - ds12885_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 32'768); + ds12885_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32'768)); protected: - ds12885_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ds12885_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual int data_size() const override { return 128; } virtual int get_timer_bypass() const override; @@ -30,7 +30,7 @@ class ds12885ext_device : public ds12885_device { public: // construction/destruction - ds12885ext_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 32'768); + ds12885ext_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32'768)); // read/write access to extended ram uint8_t read_extended(offs_t offset); diff --git a/src/devices/machine/ds1302.cpp b/src/devices/machine/ds1302.cpp index 8d32c3fd3ff..0fa94625b46 100644 --- a/src/devices/machine/ds1302.cpp +++ b/src/devices/machine/ds1302.cpp @@ -70,7 +70,7 @@ DEFINE_DEVICE_TYPE(DS1302, ds1302_device, "ds1302", "Dallas DS1302 Trickle-Charg // ds1302_device - constructor //------------------------------------------------- -ds1302_device::ds1302_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t ram_size) +ds1302_device::ds1302_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t ram_size) : device_t(mconfig, type, tag, owner, clock), device_rtc_interface(mconfig, *this), device_nvram_interface(mconfig, *this), @@ -78,7 +78,7 @@ ds1302_device::ds1302_device(const machine_config &mconfig, device_type type, co { } -ds1302_device::ds1302_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds1302_device::ds1302_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds1302_device(mconfig, DS1302, tag, owner, clock, 0x1f) { } @@ -88,7 +88,7 @@ ds1302_device::ds1302_device(const machine_config &mconfig, const char *tag, dev // ds1202_device - constructor //------------------------------------------------- -ds1202_device::ds1202_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds1202_device::ds1202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds1302_device(mconfig, DS1202, tag, owner, clock, 0x18) { } diff --git a/src/devices/machine/ds1302.h b/src/devices/machine/ds1302.h index 9b1d09e9840..8040f37075e 100644 --- a/src/devices/machine/ds1302.h +++ b/src/devices/machine/ds1302.h @@ -34,7 +34,7 @@ class ds1302_device : public device_t, { public: // construction/destruction - ds1302_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds1302_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( ce_w ); DECLARE_WRITE_LINE_MEMBER( sclk_w ); @@ -42,7 +42,7 @@ public: DECLARE_READ_LINE_MEMBER( io_r ); protected: - ds1302_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t ram_size); + ds1302_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t ram_size); // device-level overrides virtual void device_start() override; @@ -88,7 +88,7 @@ class ds1202_device : public ds1302_device { public: // construction/destruction - ds1202_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds1202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/machine/ds1315.cpp b/src/devices/machine/ds1315.cpp index 2a574dca399..5a96c16fed8 100644 --- a/src/devices/machine/ds1315.cpp +++ b/src/devices/machine/ds1315.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(DS1315, ds1315_device, "ds1315", "Dallas DS1315 Phantom Time Chip") -ds1315_device::ds1315_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds1315_device::ds1315_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DS1315, tag, owner, clock), m_backing_read(*this), m_mode(), diff --git a/src/devices/machine/ds1315.h b/src/devices/machine/ds1315.h index 720c4a08202..fb8e5e0a0ab 100644 --- a/src/devices/machine/ds1315.h +++ b/src/devices/machine/ds1315.h @@ -18,7 +18,7 @@ class ds1315_device : public device_t { public: - ds1315_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds1315_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~ds1315_device() {} auto read_backing() { return m_backing_read.bind(); } diff --git a/src/devices/machine/ds1386.cpp b/src/devices/machine/ds1386.cpp index 6f91625bde4..78da8b618c0 100644 --- a/src/devices/machine/ds1386.cpp +++ b/src/devices/machine/ds1386.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(DS1286, ds1286_device, "ds1286", "DS1286 Watchdog DEFINE_DEVICE_TYPE(DS1386_8K, ds1386_8k_device, "ds1386_8k", "DS1386-8K RAMified Watchdog Timekeeper") DEFINE_DEVICE_TYPE(DS1386_32K, ds1386_32k_device, "ds1386_32k", "DS1386-32K RAMified Watchdog Timekeeper") -ds1386_device::ds1386_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, size_t size) +ds1386_device::ds1386_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, size_t size) : device_t(mconfig, type, tag, owner, clock) , device_nvram_interface(mconfig, *this) , device_rtc_interface(mconfig, *this) @@ -48,17 +48,17 @@ ds1386_device::ds1386_device(const machine_config &mconfig, device_type type, co { } -ds1286_device::ds1286_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds1286_device::ds1286_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds1386_device(mconfig, DS1286, tag, owner, clock, 64) { } -ds1386_8k_device::ds1386_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds1386_8k_device::ds1386_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds1386_device(mconfig, DS1386_8K, tag, owner, clock, 8*1024) { } -ds1386_32k_device::ds1386_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds1386_32k_device::ds1386_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds1386_device(mconfig, DS1386_32K, tag, owner, clock, 32*1024) { } diff --git a/src/devices/machine/ds1386.h b/src/devices/machine/ds1386.h index dd07c49c79f..cca0be92a63 100644 --- a/src/devices/machine/ds1386.h +++ b/src/devices/machine/ds1386.h @@ -121,7 +121,7 @@ protected: ALARM_PER_MINUTE = 0x7 }; - ds1386_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, size_t size); + ds1386_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, size_t size); // device-level overrides virtual void device_start() override; @@ -212,19 +212,19 @@ protected: class ds1286_device : public ds1386_device { public: - ds1286_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds1286_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ds1386_8k_device : public ds1386_device { public: - ds1386_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds1386_8k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ds1386_32k_device : public ds1386_device { public: - ds1386_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds1386_32k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(DS1286, ds1286_device) diff --git a/src/devices/machine/ds17x85.cpp b/src/devices/machine/ds17x85.cpp index af6837cf621..fba14196193 100644 --- a/src/devices/machine/ds17x85.cpp +++ b/src/devices/machine/ds17x85.cpp @@ -44,7 +44,7 @@ DEFINE_DEVICE_TYPE(DS17887, ds17887_device, "ds17887", "DS17887 RTC") // ds17x85_device - constructor //------------------------------------------------- -ds17x85_device::ds17x85_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 model, u32 extram_size) +ds17x85_device::ds17x85_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 model, u32 extram_size) : mc146818_device(mconfig, type, tag, owner, clock) , m_model(model) , m_extram_size(extram_size) @@ -57,7 +57,7 @@ ds17x85_device::ds17x85_device(const machine_config &mconfig, device_type type, // ds1685_device - constructor //------------------------------------------------- -ds1685_device::ds1685_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ds1685_device::ds1685_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds17x85_device(mconfig, DS1685, tag, owner, clock, 0x71, 128) { } @@ -66,7 +66,7 @@ ds1685_device::ds1685_device(const machine_config &mconfig, const char *tag, dev // ds1687_device - constructor //------------------------------------------------- -ds1687_device::ds1687_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ds1687_device::ds1687_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds17x85_device(mconfig, DS1687, tag, owner, clock, 0x71, 128) { } @@ -75,7 +75,7 @@ ds1687_device::ds1687_device(const machine_config &mconfig, const char *tag, dev // ds17285_device - constructor //------------------------------------------------- -ds17285_device::ds17285_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ds17285_device::ds17285_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds17x85_device(mconfig, DS17285, tag, owner, clock, 0x72, 2048) { } @@ -84,7 +84,7 @@ ds17285_device::ds17285_device(const machine_config &mconfig, const char *tag, d // ds17287_device - constructor //------------------------------------------------- -ds17287_device::ds17287_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ds17287_device::ds17287_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds17x85_device(mconfig, DS17287, tag, owner, clock, 0x72, 2048) { } @@ -93,7 +93,7 @@ ds17287_device::ds17287_device(const machine_config &mconfig, const char *tag, d // ds17485_device - constructor //------------------------------------------------- -ds17485_device::ds17485_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ds17485_device::ds17485_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds17x85_device(mconfig, DS17485, tag, owner, clock, 0x74, 4096) { } @@ -102,7 +102,7 @@ ds17485_device::ds17485_device(const machine_config &mconfig, const char *tag, d // ds17487_device - constructor //------------------------------------------------- -ds17487_device::ds17487_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ds17487_device::ds17487_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds17x85_device(mconfig, DS17487, tag, owner, clock, 0x74, 4096) { } @@ -111,7 +111,7 @@ ds17487_device::ds17487_device(const machine_config &mconfig, const char *tag, d // ds17885_device - constructor //------------------------------------------------- -ds17885_device::ds17885_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ds17885_device::ds17885_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds17x85_device(mconfig, DS17885, tag, owner, clock, 0x78, 8192) { } @@ -120,7 +120,7 @@ ds17885_device::ds17885_device(const machine_config &mconfig, const char *tag, d // ds17887_device - constructor //------------------------------------------------- -ds17887_device::ds17887_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ds17887_device::ds17887_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ds17x85_device(mconfig, DS17887, tag, owner, clock, 0x78, 8192) { } diff --git a/src/devices/machine/ds17x85.h b/src/devices/machine/ds17x85.h index 413ed5f4b8b..4c36844aa21 100644 --- a/src/devices/machine/ds17x85.h +++ b/src/devices/machine/ds17x85.h @@ -83,7 +83,7 @@ protected: REG_EXT_4B_KSE = 0x01 }; - ds17x85_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 model, u32 extram_size); + ds17x85_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 model, u32 extram_size); // device-specific overrides virtual void device_start() override; @@ -113,7 +113,7 @@ class ds1685_device : public ds17x85_device { public: // device type constructor - ds1685_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ds1685_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> ds1687_device @@ -122,7 +122,7 @@ class ds1687_device : public ds17x85_device { public: // device type constructor - ds1687_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ds1687_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> ds17285_device @@ -131,7 +131,7 @@ class ds17285_device : public ds17x85_device { public: // device type constructor - ds17285_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ds17285_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> ds17287_device @@ -140,7 +140,7 @@ class ds17287_device : public ds17x85_device { public: // device type constructor - ds17287_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ds17287_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> ds17485_device @@ -149,7 +149,7 @@ class ds17485_device : public ds17x85_device { public: // device type constructor - ds17485_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ds17485_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> ds17487_device @@ -158,7 +158,7 @@ class ds17487_device : public ds17x85_device { public: // device type constructor - ds17487_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ds17487_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> ds17885_device @@ -167,7 +167,7 @@ class ds17885_device : public ds17x85_device { public: // device type constructor - ds17885_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ds17885_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> ds17887_device @@ -176,7 +176,7 @@ class ds17887_device : public ds17x85_device { public: // device type constructor - ds17887_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ds17887_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type declarations diff --git a/src/devices/machine/ds1994.cpp b/src/devices/machine/ds1994.cpp index cff5a921c05..a4d3513c897 100644 --- a/src/devices/machine/ds1994.cpp +++ b/src/devices/machine/ds1994.cpp @@ -31,7 +31,7 @@ // device type definition DEFINE_DEVICE_TYPE(DS1994, ds1994_device, "ds1994", "DS1994 iButton 4Kb Memory Plus Time") -ds1994_device::ds1994_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds1994_device::ds1994_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DS1994, tag, owner, clock), device_nvram_interface(mconfig, *this) , m_timer_main(nullptr) , m_timer_reset(nullptr) diff --git a/src/devices/machine/ds1994.h b/src/devices/machine/ds1994.h index c6629b6fbb9..6452297650c 100644 --- a/src/devices/machine/ds1994.h +++ b/src/devices/machine/ds1994.h @@ -18,12 +18,7 @@ class ds1994_device : public device_t, public device_nvram_interface { public: // construction/destruction - ds1994_device(const machine_config &mconfig, const char *tag, device_t *owner) - : ds1994_device(mconfig, tag, owner, uint32_t(0)) - { - } - - ds1994_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds1994_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration helpers void ref_year(uint32_t year) { m_ref_year = year; } diff --git a/src/devices/machine/ds2401.cpp b/src/devices/machine/ds2401.cpp index e2236eef5d2..cd98f000f18 100644 --- a/src/devices/machine/ds2401.cpp +++ b/src/devices/machine/ds2401.cpp @@ -31,7 +31,7 @@ inline void ds2401_device::verboselog(int n_level, const char *s_fmt, ...) // device type definition DEFINE_DEVICE_TYPE(DS2401, ds2401_device, "ds2401", "DS2401 Silicon Serial Number") -ds2401_device::ds2401_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds2401_device::ds2401_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DS2401, tag, owner, clock) , m_state(0) , m_bit(0) diff --git a/src/devices/machine/ds2401.h b/src/devices/machine/ds2401.h index f29132d381e..f035e0bddce 100644 --- a/src/devices/machine/ds2401.h +++ b/src/devices/machine/ds2401.h @@ -17,12 +17,7 @@ class ds2401_device : public device_t { public: // construction/destruction - ds2401_device(const machine_config &mconfig, const char *tag, device_t *owner) - : ds2401_device(mconfig, tag, owner, uint32_t(0)) - { - } - - ds2401_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds2401_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); DECLARE_WRITE_LINE_MEMBER( write ); DECLARE_READ_LINE_MEMBER( read ); diff --git a/src/devices/machine/ds2404.cpp b/src/devices/machine/ds2404.cpp index 68845d86dc3..c4e892305d4 100644 --- a/src/devices/machine/ds2404.cpp +++ b/src/devices/machine/ds2404.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(DS2404, ds2404_device, "ds2404", "DS2404 EconoRAM Time Chip") // ds2404_device - constructor //------------------------------------------------- -ds2404_device::ds2404_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds2404_device::ds2404_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DS2404, tag, owner, clock), device_nvram_interface(mconfig, *this), m_tick_timer(nullptr), m_ref_year(0), m_ref_month(0), m_ref_day(0), m_address(0), diff --git a/src/devices/machine/ds2404.h b/src/devices/machine/ds2404.h index 1ed22887b87..3e33b2a237b 100644 --- a/src/devices/machine/ds2404.h +++ b/src/devices/machine/ds2404.h @@ -17,7 +17,7 @@ class ds2404_device : public device_t, public device_nvram_interface { public: // construction/destruction - ds2404_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds2404_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration helpers void ref_year(uint32_t year) { m_ref_year = year; } diff --git a/src/devices/machine/ds6417.cpp b/src/devices/machine/ds6417.cpp index 51ae6e7a201..af0c4cf0569 100644 --- a/src/devices/machine/ds6417.cpp +++ b/src/devices/machine/ds6417.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(DS6417, ds6417_device, "ds6417", "Dallas DS6417 CyberCard") -ds6417_device::ds6417_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds6417_device::ds6417_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DS6417, tag, owner, clock) , device_memcard_image_interface(mconfig, *this) { diff --git a/src/devices/machine/ds6417.h b/src/devices/machine/ds6417.h index 94d5e109426..c1dcb7f2257 100644 --- a/src/devices/machine/ds6417.h +++ b/src/devices/machine/ds6417.h @@ -16,7 +16,7 @@ class ds6417_device : public device_t, { public: // construction/destruction - ds6417_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds6417_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual bool is_reset_on_load() const noexcept override { return false; } virtual const char *file_extensions() const noexcept override { return "bin"; } diff --git a/src/devices/machine/ds75160a.cpp b/src/devices/machine/ds75160a.cpp index d5ad8007a61..48a7118f9c9 100644 --- a/src/devices/machine/ds75160a.cpp +++ b/src/devices/machine/ds75160a.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(DS75160A, ds75160a_device, "ds75160a", "DS75160A GPIB Transce // ds75160a_device - constructor //------------------------------------------------- -ds75160a_device::ds75160a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds75160a_device::ds75160a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DS75160A, tag, owner, clock), m_read(*this), m_write(*this), diff --git a/src/devices/machine/ds75160a.h b/src/devices/machine/ds75160a.h index 5e2498d28ad..373b00195d9 100644 --- a/src/devices/machine/ds75160a.h +++ b/src/devices/machine/ds75160a.h @@ -35,7 +35,7 @@ class ds75160a_device : public device_t { public: // construction/destruction - ds75160a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds75160a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto read_callback() { return m_read.bind(); } auto write_callback() { return m_write.bind(); } diff --git a/src/devices/machine/ds75161a.cpp b/src/devices/machine/ds75161a.cpp index 9d75d6b65a0..a2c64247d69 100644 --- a/src/devices/machine/ds75161a.cpp +++ b/src/devices/machine/ds75161a.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(DS75161A, ds75161a_device, "ds75161a", "DS75161A GPIB Transce // ds75161a_device - constructor //------------------------------------------------- -ds75161a_device::ds75161a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds75161a_device::ds75161a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DS75161A, tag, owner, clock), m_in_ren_cb(*this), m_in_ifc_cb(*this), diff --git a/src/devices/machine/ds75161a.h b/src/devices/machine/ds75161a.h index 8ea0a0b9632..8ba13029614 100644 --- a/src/devices/machine/ds75161a.h +++ b/src/devices/machine/ds75161a.h @@ -28,7 +28,7 @@ class ds75161a_device : public device_t { public: // construction/destruction - ds75161a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds75161a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto in_ren() { return m_in_ren_cb.bind(); } auto in_ifc() { return m_in_ifc_cb.bind(); } diff --git a/src/devices/machine/ds8874.cpp b/src/devices/machine/ds8874.cpp index 8b6003dcad3..bc65f40ca7e 100644 --- a/src/devices/machine/ds8874.cpp +++ b/src/devices/machine/ds8874.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(DS8874, ds8874_device, "ds8874", "DS8874 LED Driver") // constructor //------------------------------------------------- -ds8874_device::ds8874_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +ds8874_device::ds8874_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DS8874, tag, owner, clock), m_write_output(*this) { } diff --git a/src/devices/machine/ds8874.h b/src/devices/machine/ds8874.h index 444f15a020c..fcbfa736702 100644 --- a/src/devices/machine/ds8874.h +++ b/src/devices/machine/ds8874.h @@ -31,7 +31,7 @@ class ds8874_device : public device_t { public: - ds8874_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + ds8874_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers auto write_output() { return m_write_output.bind(); } // OUT pins diff --git a/src/devices/machine/e0516.cpp b/src/devices/machine/e0516.cpp index 29fe42e3f17..954f990df43 100644 --- a/src/devices/machine/e0516.cpp +++ b/src/devices/machine/e0516.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(E0516, e0516_device, "e0516", "E05-16 RTC") // e0516_device - constructor //------------------------------------------------- -e0516_device::e0516_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e0516_device::e0516_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, E0516, tag, owner, clock) , device_rtc_interface(mconfig, *this) , m_cs(0), m_clk(0), m_data_latch(0), m_reg_latch(0), m_read_write(0), m_state(0), m_bits(0), m_dio(0) diff --git a/src/devices/machine/e0516.h b/src/devices/machine/e0516.h index d3807ff5968..ca068567f7e 100644 --- a/src/devices/machine/e0516.h +++ b/src/devices/machine/e0516.h @@ -28,7 +28,7 @@ class e0516_device : public device_t, public device_rtc_interface { public: // construction/destruction - e0516_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e0516_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( cs_w ); DECLARE_WRITE_LINE_MEMBER( clk_w ); diff --git a/src/devices/machine/e05a03.cpp b/src/devices/machine/e05a03.cpp index 66a2a6785cc..28e196dab1f 100644 --- a/src/devices/machine/e05a03.cpp +++ b/src/devices/machine/e05a03.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(E05A03, e05a03_device, "e05a03", "Epson E05A03 Gate Array") -e05a03_device::e05a03_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e05a03_device::e05a03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, E05A03, tag, owner, clock), m_write_nlq_lp(*this), m_write_pe_lp(*this), diff --git a/src/devices/machine/e05a03.h b/src/devices/machine/e05a03.h index 4748bb3a84b..29681b7be7c 100644 --- a/src/devices/machine/e05a03.h +++ b/src/devices/machine/e05a03.h @@ -18,7 +18,7 @@ class e05a03_device : public device_t { public: - e05a03_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e05a03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto nlq_lp_wr_callback() { return m_write_nlq_lp.bind(); } auto pe_lp_wr_callback() { return m_write_pe_lp.bind(); } diff --git a/src/devices/machine/e05a30.cpp b/src/devices/machine/e05a30.cpp index 44d90904644..8f6eb4241a3 100644 --- a/src/devices/machine/e05a30.cpp +++ b/src/devices/machine/e05a30.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(E05A30, e05a30_device, "e05a30", "Epson E05A30 Gate Array") -e05a30_device::e05a30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +e05a30_device::e05a30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, E05A30, tag, owner, clock), m_write_printhead(*this), m_write_pf_stepper(*this), diff --git a/src/devices/machine/e05a30.h b/src/devices/machine/e05a30.h index 41bd94d999d..ebd18432ef3 100644 --- a/src/devices/machine/e05a30.h +++ b/src/devices/machine/e05a30.h @@ -13,7 +13,7 @@ class e05a30_device : public device_t { public: - e05a30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + e05a30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto printhead() { return m_write_printhead.bind(); } auto pf_stepper() { return m_write_pf_stepper.bind(); } diff --git a/src/devices/machine/edlc.cpp b/src/devices/machine/edlc.cpp index 956528aa8b7..5c544e2b443 100644 --- a/src/devices/machine/edlc.cpp +++ b/src/devices/machine/edlc.cpp @@ -37,7 +37,7 @@ DEFINE_DEVICE_TYPE(SEEQ80C03, seeq80c03_device, "seeq80c03", "SEEQ 80C03 EDLC") static const u8 ETH_BROADCAST[] = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }; -seeq8003_device::seeq8003_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) +seeq8003_device::seeq8003_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_network_interface(mconfig, *this, 10) , m_out_int(*this) @@ -46,7 +46,7 @@ seeq8003_device::seeq8003_device(machine_config const &mconfig, device_type type { } -seeq8003_device::seeq8003_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +seeq8003_device::seeq8003_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : seeq8003_device(mconfig, SEEQ8003, tag, owner, clock) { } @@ -387,7 +387,7 @@ bool seeq8003_device::address_filter(u8 *address) return false; } -seeq80c03_device::seeq80c03_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +seeq80c03_device::seeq80c03_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : seeq8003_device(mconfig, SEEQ80C03, tag, owner, clock) , m_regbank(*this, "regbank") { diff --git a/src/devices/machine/edlc.h b/src/devices/machine/edlc.h index bbcd91d2589..26c9321e83e 100644 --- a/src/devices/machine/edlc.h +++ b/src/devices/machine/edlc.h @@ -19,7 +19,7 @@ public: auto out_rxrdy_cb() { return m_out_rxrdy.bind(); } auto out_txrdy_cb() { return m_out_txrdy.bind(); } - seeq8003_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + seeq8003_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // register interface virtual void map(address_map &map); @@ -36,7 +36,7 @@ public: void fifo_w(u8 data); protected: - seeq8003_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock = 0); + seeq8003_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // device_t overrides virtual void device_start() override; @@ -143,7 +143,7 @@ protected: class seeq80c03_device : public seeq8003_device { public: - seeq80c03_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + seeq80c03_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // register interface virtual void map(address_map &map) override; diff --git a/src/devices/machine/eeprom.cpp b/src/devices/machine/eeprom.cpp index 2ee3b1697c1..20f75613874 100644 --- a/src/devices/machine/eeprom.cpp +++ b/src/devices/machine/eeprom.cpp @@ -24,7 +24,7 @@ //------------------------------------------------- eeprom_base_device::eeprom_base_device(const machine_config &mconfig, device_type devtype, const char *tag, device_t *owner) - : device_t(mconfig, devtype, tag, owner, 0), + : device_t(mconfig, devtype, tag, owner), device_nvram_interface(mconfig, *this), m_region(*this, DEVICE_SELF), m_cells(0), diff --git a/src/devices/machine/eeprompar.cpp b/src/devices/machine/eeprompar.cpp index 3393ae91a2c..1140e9fed17 100644 --- a/src/devices/machine/eeprompar.cpp +++ b/src/devices/machine/eeprompar.cpp @@ -203,7 +203,7 @@ void eeprom_parallel_28xx_device::unlock_write32(uint32_t data) { oe_w(1); } // macro for defining a new device class #define DEFINE_PARALLEL_EEPROM_DEVICE(_baseclass, _lowercase, _uppercase, _bits, _cells) \ -eeprom_parallel_##_lowercase##_device::eeprom_parallel_##_lowercase##_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) \ +eeprom_parallel_##_lowercase##_device::eeprom_parallel_##_lowercase##_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) \ : eeprom_parallel_##_baseclass##_device(mconfig, EEPROM_##_uppercase, tag, owner) \ { \ size(_cells, _bits); \ diff --git a/src/devices/machine/eeprompar.h b/src/devices/machine/eeprompar.h index 9399e32a349..ecce599a9dd 100644 --- a/src/devices/machine/eeprompar.h +++ b/src/devices/machine/eeprompar.h @@ -69,7 +69,7 @@ private: class eeprom_parallel_##_lowercase##_device : public eeprom_parallel_##_baseclass##_device \ { \ public: \ - eeprom_parallel_##_lowercase##_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); \ + eeprom_parallel_##_lowercase##_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); \ }; \ DECLARE_DEVICE_TYPE(EEPROM_##_uppercase, eeprom_parallel_##_lowercase##_device) diff --git a/src/devices/machine/eepromser.cpp b/src/devices/machine/eepromser.cpp index a8502e72fe3..8b2df6f7d68 100644 --- a/src/devices/machine/eepromser.cpp +++ b/src/devices/machine/eepromser.cpp @@ -1093,7 +1093,7 @@ eeprom_serial_##_lowercase##_##_bits##bit_device::eeprom_serial_##_lowercase##_# size(_cells, _bits); \ set_address_bits(_addrbits); \ } \ -eeprom_serial_##_lowercase##_##_bits##bit_device::eeprom_serial_##_lowercase##_##_bits##bit_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) \ +eeprom_serial_##_lowercase##_##_bits##bit_device::eeprom_serial_##_lowercase##_##_bits##bit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) \ : eeprom_serial_##_baseclass##_device(mconfig, EEPROM_##_uppercase##_##_bits##BIT, tag, owner, eeprom_serial_streaming::DISABLE) \ { \ size(_cells, _bits); \ diff --git a/src/devices/machine/eepromser.h b/src/devices/machine/eepromser.h index d3d33db19d6..cc111b3526e 100644 --- a/src/devices/machine/eepromser.h +++ b/src/devices/machine/eepromser.h @@ -216,7 +216,7 @@ class eeprom_serial_##_lowercase##_##_bits##bit_device : public eeprom_serial_## { \ public: \ eeprom_serial_##_lowercase##_##_bits##bit_device(const machine_config &mconfig, const char *tag, device_t *owner, eeprom_serial_streaming enable_streaming = eeprom_serial_streaming::DISABLE); \ - eeprom_serial_##_lowercase##_##_bits##bit_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); \ + eeprom_serial_##_lowercase##_##_bits##bit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); \ }; \ DECLARE_DEVICE_TYPE(EEPROM_##_uppercase##_##_bits##BIT, eeprom_serial_##_lowercase##_##_bits##bit_device) diff --git a/src/devices/machine/er1400.cpp b/src/devices/machine/er1400.cpp index c2375294ba5..73ff53379b7 100644 --- a/src/devices/machine/er1400.cpp +++ b/src/devices/machine/er1400.cpp @@ -39,7 +39,7 @@ DEFINE_DEVICE_TYPE(ER1400, er1400_device, "er1400", "ER1400 Serial EAROM (100x14 // er1400_device - constructor //------------------------------------------------- -er1400_device::er1400_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +er1400_device::er1400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ER1400, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_default_data(*this, DEVICE_SELF) diff --git a/src/devices/machine/er1400.h b/src/devices/machine/er1400.h index 9988edd6744..2829edce749 100644 --- a/src/devices/machine/er1400.h +++ b/src/devices/machine/er1400.h @@ -32,7 +32,7 @@ class er1400_device : public device_t, public device_nvram_interface { public: // construction/destruction - er1400_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + er1400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // line handlers DECLARE_WRITE_LINE_MEMBER(data_w); diff --git a/src/devices/machine/er2055.cpp b/src/devices/machine/er2055.cpp index 678c044122a..43303dfb2cc 100644 --- a/src/devices/machine/er2055.cpp +++ b/src/devices/machine/er2055.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(ER2055, er2055_device, "er2055", "ER2055 EAROM (64x8)") // er2055_device - constructor //------------------------------------------------- -er2055_device::er2055_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +er2055_device::er2055_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ER2055, tag, owner, clock), device_nvram_interface(mconfig, *this), m_default_data(*this, DEVICE_SELF), diff --git a/src/devices/machine/er2055.h b/src/devices/machine/er2055.h index 95517abc542..cbd6ea546ce 100644 --- a/src/devices/machine/er2055.h +++ b/src/devices/machine/er2055.h @@ -41,7 +41,7 @@ class er2055_device : public device_t, { public: // construction/destruction - er2055_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + er2055_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // I/O operations uint8_t data() const { return m_data; } diff --git a/src/devices/machine/exorterm.cpp b/src/devices/machine/exorterm.cpp index 17e0f98a662..1ba792476dc 100644 --- a/src/devices/machine/exorterm.cpp +++ b/src/devices/machine/exorterm.cpp @@ -27,7 +27,7 @@ TODO // TYPE DEFINITIONS //************************************************************************** -exorterm155_device::exorterm155_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +exorterm155_device::exorterm155_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_maincpu(*this, "maincpu") , m_irqs(*this, "irqs") @@ -65,7 +65,7 @@ exorterm155_device::exorterm155_device(const machine_config &mconfig, device_typ { } -exorterm155_device::exorterm155_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +exorterm155_device::exorterm155_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : exorterm155_device(mconfig, EXORTERM155, tag, owner, clock) { } @@ -836,7 +836,7 @@ void exorterm155_device::device_add_mconfig(machine_config &config) config.set_default_layout(layout_exorterm155); - ACIA6850(config, m_acia, 0); + ACIA6850(config, m_acia); m_acia->txd_handler().set(FUNC(exorterm155_device::acia_txd_w)); m_acia->rts_handler().set(FUNC(exorterm155_device::acia_rts_w)); m_acia->irq_handler().set(m_irqs, FUNC(input_merger_device::in_w<0>)); @@ -875,11 +875,11 @@ void exorterm155_device::device_add_mconfig(machine_config &config) m_pia_disp->irqb_handler().set(m_irqs, FUNC(input_merger_device::in_w<6>)); // Derived from the horizontal blanking, 3.4ms. - CLOCK(config, m_sys_timer_clock, 4706 / 16); + CLOCK(config, m_sys_timer_clock, XTAL::u(4706) / 16); m_sys_timer_clock->signal_handler().set(FUNC(exorterm155_device::sys_timer_w)); SPEAKER(config, "bell").front_center(); - BEEP(config, m_beeper, 2000); + BEEP(config, m_beeper, XTAL::u(2000)); m_beeper->add_route(ALL_OUTPUTS, "bell", 0.25); } diff --git a/src/devices/machine/exorterm.h b/src/devices/machine/exorterm.h index 07944bff805..c5f9552d3ed 100644 --- a/src/devices/machine/exorterm.h +++ b/src/devices/machine/exorterm.h @@ -30,7 +30,7 @@ INPUT_PORTS_EXTERN(exorterm155); class exorterm155_device : public device_t { public: - exorterm155_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + exorterm155_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Interface to a RS232 connection. auto rs232_conn_txd_handler() { return m_rs232_conn_txd_handler.bind(); } @@ -43,7 +43,7 @@ public: DECLARE_WRITE_LINE_MEMBER(rs232_conn_rxd_w); protected: - exorterm155_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + exorterm155_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_resolve_objects() override; virtual void device_start() override; diff --git a/src/devices/machine/f3853.cpp b/src/devices/machine/f3853.cpp index dbea3f30533..24b81bbea56 100644 --- a/src/devices/machine/f3853.cpp +++ b/src/devices/machine/f3853.cpp @@ -43,7 +43,7 @@ DEFINE_DEVICE_TYPE(F38T56, f38t56_device, "f38t56_psu", "Fairchild F38T56 PSU") // constructor //------------------------------------------------- -f3853_device::f3853_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +f3853_device::f3853_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_int_req_callback(*this), m_pri_out_callback(*this), @@ -54,29 +54,29 @@ f3853_device::f3853_device(const machine_config &mconfig, device_type type, cons m_external_interrupt_line(false) { } -f3853_device::f3853_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +f3853_device::f3853_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : f3853_device(mconfig, F3853, tag, owner, clock) { } -f3851_device::f3851_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +f3851_device::f3851_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : f3853_device(mconfig, type, tag, owner, clock), m_read_port(*this), m_write_port(*this) { } -f3851_device::f3851_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +f3851_device::f3851_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : f3851_device(mconfig, F3851, tag, owner, clock) { } -f3856_device::f3856_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +f3856_device::f3856_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : f3851_device(mconfig, type, tag, owner, clock) { } -f3856_device::f3856_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +f3856_device::f3856_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : f3856_device(mconfig, F3856, tag, owner, clock) { } -f38t56_device::f38t56_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +f38t56_device::f38t56_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : f3856_device(mconfig, F38T56, tag, owner, clock) { } diff --git a/src/devices/machine/f3853.h b/src/devices/machine/f3853.h index f7d6adb3b5c..22eaae40fb2 100644 --- a/src/devices/machine/f3853.h +++ b/src/devices/machine/f3853.h @@ -67,7 +67,7 @@ class f3853_device : public device_t { public: // construction/destruction - f3853_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + f3853_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto int_req_callback() { return m_int_req_callback.bind(); } auto pri_out_callback() { return m_pri_out_callback.bind(); } @@ -84,7 +84,7 @@ public: IRQ_CALLBACK_MEMBER(int_acknowledge); protected: - f3853_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + f3853_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -119,7 +119,7 @@ protected: class f3851_device : public f3853_device { public: - f3851_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + f3851_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // interrupt vector is a mask option on 3851 and 3856 void set_int_vector(u16 vector) { m_int_vector = vector; } @@ -134,7 +134,7 @@ public: virtual void write(offs_t offset, uint8_t data) override; protected: - f3851_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + f3851_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_resolve_objects() override; @@ -145,7 +145,7 @@ protected: class f3856_device : public f3851_device { public: - f3856_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + f3856_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; @@ -153,7 +153,7 @@ public: virtual TIMER_CALLBACK_MEMBER(timer_callback) override; protected: - f3856_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + f3856_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -167,7 +167,7 @@ protected: class f38t56_device : public f3856_device { public: - f38t56_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + f38t56_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/machine/f4702.cpp b/src/devices/machine/f4702.cpp index 2a6bf7218c8..c3636003ffb 100644 --- a/src/devices/machine/f4702.cpp +++ b/src/devices/machine/f4702.cpp @@ -75,7 +75,7 @@ DEFINE_DEVICE_TYPE(F4702, f4702_device, "f4702", "Fairchild 4702B Bit Rate Gener // f4702_device - constructor //------------------------------------------------- -f4702_device::f4702_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +f4702_device::f4702_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, F4702, tag, owner, clock) , device_execute_interface(mconfig, *this) , m_s_callback(*this) diff --git a/src/devices/machine/f4702.h b/src/devices/machine/f4702.h index c48601b1e3c..deedce857e5 100644 --- a/src/devices/machine/f4702.h +++ b/src/devices/machine/f4702.h @@ -28,7 +28,7 @@ class f4702_device : public device_t, public device_execute_interface { public: - f4702_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + f4702_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto s_callback() { return m_s_callback.bind(); } diff --git a/src/devices/machine/fdc37c665gt.cpp b/src/devices/machine/fdc37c665gt.cpp index c14e6437d3e..3f58fdb849d 100644 --- a/src/devices/machine/fdc37c665gt.cpp +++ b/src/devices/machine/fdc37c665gt.cpp @@ -22,7 +22,7 @@ SMSC FDC37C665GT High Performance Multi-Mode Parallel Port Super I/O Floppy Disk DEFINE_DEVICE_TYPE(FDC37C665GT, fdc37c665gt_device, "fdc37c665gt", "FDC37C665GT") -fdc37c665gt_device::fdc37c665gt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, upd765_family_device::mode_t floppy_mode) +fdc37c665gt_device::fdc37c665gt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, upd765_family_device::mode_t floppy_mode) : device_t(mconfig, FDC37C665GT, tag, owner, clock) , mode(OperatingMode::Run) , config_key_step(0) diff --git a/src/devices/machine/fdc37c665gt.h b/src/devices/machine/fdc37c665gt.h index 6b90fc8341e..bbbf62ae0af 100644 --- a/src/devices/machine/fdc37c665gt.h +++ b/src/devices/machine/fdc37c665gt.h @@ -25,11 +25,11 @@ SMSC FDC37C665GT High Performance Multi-Mode Parallel Port Super I/O Floppy Disk class fdc37c665gt_device : public device_t { public: - fdc37c665gt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + fdc37c665gt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : fdc37c665gt_device(mconfig, tag, owner, clock, upd765_family_device::mode_t::AT) { } - fdc37c665gt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, upd765_family_device::mode_t floppy_mode); + fdc37c665gt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, upd765_family_device::mode_t floppy_mode); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/machine/fdc37c93x.cpp b/src/devices/machine/fdc37c93x.cpp index 9e76e058a00..0641b1b7d35 100644 --- a/src/devices/machine/fdc37c93x.cpp +++ b/src/devices/machine/fdc37c93x.cpp @@ -15,7 +15,7 @@ SMSC FDC37C93x Plug and Play Compatible Ultra I/O Controller DEFINE_DEVICE_TYPE(FDC37C93X, fdc37c93x_device, "fdc37c93x", "SMSC FDC37C93X") -fdc37c93x_device::fdc37c93x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fdc37c93x_device::fdc37c93x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, FDC37C93X, tag, owner, clock) , device_isa16_card_interface(mconfig, *this) , mode(OperatingMode::Run) @@ -244,7 +244,7 @@ void fdc37c93x_device::floppy_formats(format_registration &fr) void fdc37c93x_device::device_add_mconfig(machine_config &config) { // floppy disc controller - smc37c78_device &fdcdev(SMC37C78(config, floppy_controller_fdcdev, 24'000'000)); + smc37c78_device &fdcdev(SMC37C78(config, floppy_controller_fdcdev, XTAL::u(24'000'000))); fdcdev.intrq_wr_callback().set(FUNC(fdc37c93x_device::irq_floppy_w)); fdcdev.drq_wr_callback().set(FUNC(fdc37c93x_device::drq_floppy_w)); FLOPPY_CONNECTOR(config, "fdc:0", pc_hd_floppies, "35hd", fdc37c93x_device::floppy_formats); diff --git a/src/devices/machine/fdc37c93x.h b/src/devices/machine/fdc37c93x.h index c4305e93b80..6a78f6b1710 100644 --- a/src/devices/machine/fdc37c93x.h +++ b/src/devices/machine/fdc37c93x.h @@ -29,7 +29,7 @@ SMSC FDC37C93x Plug and Play Compatible Ultra I/O Controller class fdc37c93x_device : public device_t, public device_isa16_card_interface { public: - fdc37c93x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fdc37c93x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~fdc37c93x_device() {} // optional information overrides diff --git a/src/devices/machine/fga002.cpp b/src/devices/machine/fga002.cpp index 14ed175fb9e..cf4610a2dd4 100644 --- a/src/devices/machine/fga002.cpp +++ b/src/devices/machine/fga002.cpp @@ -74,7 +74,7 @@ DEFINE_DEVICE_TYPE(FGA002, fga002_device, "fga002", "Force FGA-002") // fga002_device - constructor //------------------------------------------------- -fga002_device::fga002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +fga002_device::fga002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_out_int_cb(*this) , m_liack4_cb(*this) @@ -87,7 +87,7 @@ fga002_device::fga002_device(const machine_config &mconfig, device_type type, co elem = 0; } -fga002_device::fga002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fga002_device::fga002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : fga002_device(mconfig, FGA002, tag, owner, clock) { } diff --git a/src/devices/machine/fga002.h b/src/devices/machine/fga002.h index 35785189421..0457969ea16 100644 --- a/src/devices/machine/fga002.h +++ b/src/devices/machine/fga002.h @@ -10,7 +10,7 @@ class fga002_device : public device_t { public: // construction/destruction - fga002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fga002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint8_t data); uint8_t read(offs_t offset); @@ -46,7 +46,7 @@ class fga002_device : public device_t // interrupt sources in prio order if on same interrupt level. TODO: Add all sources const static fga_irq_t s_irq_sources[]; - fga002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + fga002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/machine/fm_scsi.cpp b/src/devices/machine/fm_scsi.cpp index d2b8fcd266f..5b87c8f3bee 100644 --- a/src/devices/machine/fm_scsi.cpp +++ b/src/devices/machine/fm_scsi.cpp @@ -58,7 +58,7 @@ DEFINE_DEVICE_TYPE(FMSCSI, fmscsi_device, "fmscsi", "FM-SCSI") * Device */ -fmscsi_device::fmscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fmscsi_device::fmscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : legacy_scsi_host_adapter(mconfig, FMSCSI, tag, owner, clock), m_irq_handler(*this), m_drq_handler(*this) diff --git a/src/devices/machine/fm_scsi.h b/src/devices/machine/fm_scsi.h index 9a3df8c0ba6..3aa89d69d3f 100644 --- a/src/devices/machine/fm_scsi.h +++ b/src/devices/machine/fm_scsi.h @@ -17,7 +17,7 @@ class fmscsi_device : public legacy_scsi_host_adapter { public: // construction/destruction - fmscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fmscsi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/machine/gayle.cpp b/src/devices/machine/gayle.cpp index 0e55fcd2bb6..22cc7e3fb30 100644 --- a/src/devices/machine/gayle.cpp +++ b/src/devices/machine/gayle.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(GAYLE, gayle_device, "gayle", "Amiga GAYLE") // gayle_device - constructor //------------------------------------------------- -gayle_device::gayle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gayle_device::gayle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GAYLE, tag, owner, clock), m_int2_w(*this), m_cs0_read(*this), diff --git a/src/devices/machine/gayle.h b/src/devices/machine/gayle.h index c756e6117b7..ec28f3fac25 100644 --- a/src/devices/machine/gayle.h +++ b/src/devices/machine/gayle.h @@ -24,7 +24,7 @@ class gayle_device : public device_t { public: // construction/destruction - gayle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gayle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto int2_handler() { return m_int2_w.bind(); } diff --git a/src/devices/machine/gen_fifo.cpp b/src/devices/machine/gen_fifo.cpp index 6dd2c3137d4..81a60a1d051 100644 --- a/src/devices/machine/gen_fifo.cpp +++ b/src/devices/machine/gen_fifo.cpp @@ -4,7 +4,7 @@ #include "emu.h" #include "gen_fifo.h" -template<typename T> generic_fifo_device_base<T>::generic_fifo_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +template<typename T> generic_fifo_device_base<T>::generic_fifo_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_empty_cb(*this), m_full_cb(*this), @@ -192,7 +192,7 @@ template<typename T> void generic_fifo_device_base<T>::push(T t) template class generic_fifo_device_base<u32>; -generic_fifo_u32_device::generic_fifo_u32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +generic_fifo_u32_device::generic_fifo_u32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_fifo_device_base<u32>(mconfig, GENERIC_FIFO_U32, tag, owner, clock) { } diff --git a/src/devices/machine/gen_fifo.h b/src/devices/machine/gen_fifo.h index 8e27ef73b6a..fef4b5980fe 100644 --- a/src/devices/machine/gen_fifo.h +++ b/src/devices/machine/gen_fifo.h @@ -133,7 +133,7 @@ public: } protected: - generic_fifo_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + generic_fifo_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual ~generic_fifo_device_base() = default; /* These used to build memory accessors that can be put in a @@ -205,7 +205,7 @@ private: class generic_fifo_u32_device : public generic_fifo_device_base<u32> { public: - generic_fifo_u32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_fifo_u32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~generic_fifo_u32_device() = default; u32 read() { return read_gen<u32>(); } diff --git a/src/devices/machine/gen_latch.cpp b/src/devices/machine/gen_latch.cpp index 10caccd4c7c..1e82ecc677b 100644 --- a/src/devices/machine/gen_latch.cpp +++ b/src/devices/machine/gen_latch.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(GENERIC_LATCH_16, generic_latch_16_device, "generic_latch_16" // generic_latch_base_device - constructor //------------------------------------------------- -generic_latch_base_device::generic_latch_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +generic_latch_base_device::generic_latch_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_separate_acknowledge(false), m_latch_written(false), @@ -110,7 +110,7 @@ void generic_latch_base_device::acknowledge_w(u8 data) // generic_latch_8_device - constructor //------------------------------------------------- -generic_latch_8_device::generic_latch_8_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +generic_latch_8_device::generic_latch_8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_latch_base_device(mconfig, GENERIC_LATCH_8, tag, owner, clock), m_latched_value(0) { @@ -181,7 +181,7 @@ void generic_latch_8_device::device_start() // generic_latch_16_device - constructor //------------------------------------------------- -generic_latch_16_device::generic_latch_16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +generic_latch_16_device::generic_latch_16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_latch_base_device(mconfig, GENERIC_LATCH_16, tag, owner, clock), m_latched_value(0) { diff --git a/src/devices/machine/gen_latch.h b/src/devices/machine/gen_latch.h index fc217410d06..9aa66bd45f0 100644 --- a/src/devices/machine/gen_latch.h +++ b/src/devices/machine/gen_latch.h @@ -41,7 +41,7 @@ public: protected: // construction/destruction - generic_latch_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + generic_latch_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -65,7 +65,7 @@ class generic_latch_8_device : public generic_latch_base_device { public: // construction/destruction - generic_latch_8_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + generic_latch_8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); u8 read(); void write(u8 data); @@ -91,7 +91,7 @@ class generic_latch_16_device : public generic_latch_base_device { public: // construction/destruction - generic_latch_16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + generic_latch_16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); u16 read(); void write(u16 data); diff --git a/src/devices/machine/generalplus_gpl16250soc.cpp b/src/devices/machine/generalplus_gpl16250soc.cpp index 7718c586d43..cc2fb07ee65 100644 --- a/src/devices/machine/generalplus_gpl16250soc.cpp +++ b/src/devices/machine/generalplus_gpl16250soc.cpp @@ -25,14 +25,14 @@ DEFINE_DEVICE_TYPE(GCM394, sunplus_gcm394_device, "gcm394", "GeneralPlus GPL16250 System-on-a-Chip") -sunplus_gcm394_device::sunplus_gcm394_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sunplus_gcm394_device::sunplus_gcm394_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sunplus_gcm394_base_device(mconfig, GCM394, tag, owner, clock) { } DEFINE_DEVICE_TYPE(GPAC800, generalplus_gpac800_device, "gpac800", "GeneralPlus GPL16250 System-on-a-Chip (with NAND handling)") -generalplus_gpac800_device::generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +generalplus_gpac800_device::generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sunplus_gcm394_base_device(mconfig, GPAC800, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpac800_device::gpac800_internal_map), this)) { } @@ -40,7 +40,7 @@ generalplus_gpac800_device::generalplus_gpac800_device(const machine_config &mco DEFINE_DEVICE_TYPE(GP_SPISPI, generalplus_gpspispi_device, "gpac800spi", "GeneralPlus GPL16250 (with SPI handling)") -generalplus_gpspispi_device::generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +generalplus_gpspispi_device::generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sunplus_gcm394_base_device(mconfig, GP_SPISPI, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpspispi_device::gpspispi_internal_map), this)) { } @@ -154,7 +154,7 @@ void generalplus_gpspi_direct_device::gpspi_direct_internal_map(address_map& map DEFINE_DEVICE_TYPE(GP_SPI_DIRECT, generalplus_gpspi_direct_device, "gpac800spi_direct", "GeneralPlus GPL16250 (with direct SPI handling)") -generalplus_gpspi_direct_device::generalplus_gpspi_direct_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +generalplus_gpspi_direct_device::generalplus_gpspi_direct_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sunplus_gcm394_base_device(mconfig, GP_SPI_DIRECT, tag, owner, clock, address_map_constructor(FUNC(generalplus_gpspi_direct_device::gpspi_direct_internal_map), this)) { } diff --git a/src/devices/machine/generalplus_gpl16250soc.h b/src/devices/machine/generalplus_gpl16250soc.h index 214cc7e8ace..cc31af03405 100644 --- a/src/devices/machine/generalplus_gpl16250soc.h +++ b/src/devices/machine/generalplus_gpl16250soc.h @@ -22,12 +22,12 @@ typedef device_delegate<void (uint16_t, uint16_t, uint16_t, uint16_t, uint16_t)> class sunplus_gcm394_base_device : public unsp_20_device, public device_mixer_interface { public: - sunplus_gcm394_base_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock) : + sunplus_gcm394_base_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock) : sunplus_gcm394_base_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(sunplus_gcm394_base_device::gcm394_internal_map), this)) { } - sunplus_gcm394_base_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock, address_map_constructor internal) : + sunplus_gcm394_base_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock, address_map_constructor internal) : unsp_20_device(mconfig, type, tag, owner, clock, internal), device_mixer_interface(mconfig, *this, 2), m_screen(*this, finder_base::DUMMY_TAG), @@ -377,13 +377,13 @@ class sunplus_gcm394_device : public sunplus_gcm394_base_device { public: template <typename T> - sunplus_gcm394_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : + sunplus_gcm394_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : sunplus_gcm394_device(mconfig, tag, owner, clock) { m_screen.set_tag(std::forward<T>(screen_tag)); } - sunplus_gcm394_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sunplus_gcm394_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -391,14 +391,14 @@ class generalplus_gpac800_device : public sunplus_gcm394_base_device { public: template <typename T> - generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : + generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : generalplus_gpac800_device(mconfig, tag, owner, clock) { m_screen.set_tag(std::forward<T>(screen_tag)); m_csbase = 0x30000; } - generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generalplus_gpac800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void gpac800_internal_map(address_map &map); @@ -446,14 +446,14 @@ class generalplus_gpspispi_device : public sunplus_gcm394_base_device { public: template <typename T> - generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : + generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : generalplus_gpspispi_device(mconfig, tag, owner, clock) { m_screen.set_tag(std::forward<T>(screen_tag)); m_csbase = 0x30000; } - generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generalplus_gpspispi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void gpspispi_internal_map(address_map &map); @@ -469,7 +469,7 @@ class generalplus_gpspi_direct_device : public sunplus_gcm394_base_device { public: template <typename T> - generalplus_gpspi_direct_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) : + generalplus_gpspi_direct_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : generalplus_gpspi_direct_device(mconfig, tag, owner, clock) { m_screen.set_tag(std::forward<T>(screen_tag)); @@ -478,7 +478,7 @@ public: m_csbase = 0xffffffff; } - generalplus_gpspi_direct_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generalplus_gpspi_direct_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: void gpspi_direct_internal_map(address_map &map); diff --git a/src/devices/machine/generalplus_gpl16250soc_video.cpp b/src/devices/machine/generalplus_gpl16250soc_video.cpp index 7d2b7f68385..cb23ebab314 100644 --- a/src/devices/machine/generalplus_gpl16250soc_video.cpp +++ b/src/devices/machine/generalplus_gpl16250soc_video.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(GCM394_VIDEO, gcm394_video_device, "gcm394_video", "GeneralPl #include "logmacro.h" -gcm394_base_video_device::gcm394_base_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +gcm394_base_video_device::gcm394_base_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), m_cpu(*this, finder_base::DUMMY_TAG), @@ -43,7 +43,7 @@ gcm394_base_video_device::gcm394_base_video_device(const machine_config &mconfig { } -gcm394_video_device::gcm394_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gcm394_video_device::gcm394_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gcm394_base_video_device(mconfig, GCM394_VIDEO, tag, owner, clock) { } @@ -1157,7 +1157,7 @@ void gcm394_base_video_device::device_add_mconfig(machine_config &config) PALETTE(config, m_palette).set_format(palette_device::xRGB_555, 256*0x10); GFXDECODE(config, m_gfxdecode, m_palette, gfx); - SPG_RENDERER(config, m_renderer, 0); + SPG_RENDERER(config, m_renderer); } diff --git a/src/devices/machine/generalplus_gpl16250soc_video.h b/src/devices/machine/generalplus_gpl16250soc_video.h index 22b4275a990..8a3d9046fe0 100644 --- a/src/devices/machine/generalplus_gpl16250soc_video.h +++ b/src/devices/machine/generalplus_gpl16250soc_video.h @@ -19,7 +19,7 @@ class gcm394_base_video_device : public device_t, public device_video_interface { public: - gcm394_base_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gcm394_base_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); DECLARE_WRITE_LINE_MEMBER(vblank); @@ -245,14 +245,14 @@ class gcm394_video_device : public gcm394_base_video_device { public: template <typename T, typename U> - gcm394_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, U &&screen_tag) + gcm394_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, U &&screen_tag) : gcm394_video_device(mconfig, tag, owner, clock) { m_cpu.set_tag(std::forward<T>(cpu_tag)); m_screen.set_tag(std::forward<U>(screen_tag)); } - gcm394_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gcm394_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(GCM394_VIDEO, gcm394_video_device) diff --git a/src/devices/machine/genpc.cpp b/src/devices/machine/genpc.cpp index 5c5d19cdbb3..6f98487bd9f 100644 --- a/src/devices/machine/genpc.cpp +++ b/src/devices/machine/genpc.cpp @@ -455,7 +455,7 @@ void ibm5160_mb_device::device_add_mconfig(machine_config &config) m_ppi8255->out_pb_callback().set(FUNC(ibm5160_mb_device::pc_ppi_portb_w)); m_ppi8255->in_pc_callback().set(FUNC(ibm5160_mb_device::pc_ppi_portc_r)); - ISA8(config, m_isabus, 0); + ISA8(config, m_isabus); m_isabus->set_memspace(":maincpu", AS_PROGRAM); m_isabus->set_iospace(":maincpu", AS_IO); m_isabus->irq2_callback().set(m_pic8259, FUNC(pic8259_device::ir2_w)); @@ -517,7 +517,7 @@ ioport_constructor ibm5160_mb_device::device_input_ports() const // ibm5160_mb_device - constructor //------------------------------------------------- -ibm5160_mb_device::ibm5160_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ibm5160_mb_device::ibm5160_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ibm5160_mb_device(mconfig, IBM5160_MOTHERBOARD, tag, owner, clock) { } @@ -697,12 +697,12 @@ ioport_constructor ibm5150_mb_device::device_input_ports() const // ibm5150_mb_device - constructor //------------------------------------------------- -ibm5150_mb_device::ibm5150_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ibm5150_mb_device::ibm5150_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ibm5150_mb_device(mconfig, IBM5150_MOTHERBOARD, tag, owner, clock) { } -ibm5150_mb_device::ibm5150_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ibm5150_mb_device::ibm5150_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ibm5160_mb_device(mconfig, type, tag, owner, clock) , m_cassette(*this, "cassette") { @@ -858,7 +858,7 @@ ioport_constructor ec1840_mb_device::device_input_ports() const // ec1840_mb_device - constructor //------------------------------------------------- -ec1840_mb_device::ec1840_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ec1840_mb_device::ec1840_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ec1841_mb_device(mconfig, EC1840_MOTHERBOARD, tag, owner, clock) { } @@ -970,12 +970,12 @@ ioport_constructor ec1841_mb_device::device_input_ports() const // ec1841_mb_device - constructor //------------------------------------------------- -ec1841_mb_device::ec1841_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ec1841_mb_device::ec1841_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ibm5160_mb_device(mconfig, EC1841_MOTHERBOARD, tag, owner, clock) { } -ec1841_mb_device::ec1841_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ec1841_mb_device::ec1841_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ibm5160_mb_device(mconfig, type, tag, owner, clock) { } @@ -1025,12 +1025,12 @@ uint8_t ec1841_mb_device::pc_ppi_portc_r() return data; } -pc_noppi_mb_device::pc_noppi_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pc_noppi_mb_device::pc_noppi_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc_noppi_mb_device(mconfig, PCNOPPI_MOTHERBOARD, tag, owner, clock) { } -pc_noppi_mb_device::pc_noppi_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pc_noppi_mb_device::pc_noppi_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ibm5160_mb_device(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/machine/genpc.h b/src/devices/machine/genpc.h index 8e836aae807..35d64eff0cb 100644 --- a/src/devices/machine/genpc.h +++ b/src/devices/machine/genpc.h @@ -27,7 +27,7 @@ class ibm5160_mb_device : public device_t { public: // construction/destruction - ibm5160_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ibm5160_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration template <typename T> void set_cputag(T &&tag) @@ -61,7 +61,7 @@ public: DECLARE_WRITE_LINE_MEMBER( keyboard_data_w ); protected: - ibm5160_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ibm5160_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -143,14 +143,14 @@ class ibm5150_mb_device : public ibm5160_mb_device { public: // construction/destruction - ibm5150_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ibm5150_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); DECLARE_WRITE_LINE_MEMBER( keyboard_clock_w ); virtual DECLARE_WRITE_LINE_MEMBER( pc_pit8253_out2_changed ) override; protected: - ibm5150_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ibm5150_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; @@ -173,12 +173,12 @@ class ec1841_mb_device : public ibm5160_mb_device { public: // construction/destruction - ec1841_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ec1841_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); DECLARE_WRITE_LINE_MEMBER( keyboard_clock_w ); protected: - ec1841_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ec1841_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual void device_add_mconfig(machine_config &config) override; @@ -197,7 +197,7 @@ class ec1840_mb_device : public ec1841_mb_device { public: // construction/destruction - ec1840_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ec1840_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // optional information overrides @@ -217,7 +217,7 @@ class pc_noppi_mb_device : public ibm5160_mb_device { public: // construction/destruction - pc_noppi_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pc_noppi_mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint8_t pit_out2() { return m_pit_out2; } // helper for near-clones with multifunction ics instead of 8255s @@ -226,7 +226,7 @@ public: uint8_t pc_ppi_portb_r(); protected: - pc_noppi_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pc_noppi_mb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; virtual ioport_constructor device_input_ports() const override; diff --git a/src/devices/machine/gt64xxx.cpp b/src/devices/machine/gt64xxx.cpp index ea16a9b0573..d6cb8171726 100644 --- a/src/devices/machine/gt64xxx.cpp +++ b/src/devices/machine/gt64xxx.cpp @@ -164,7 +164,7 @@ void gt64xxx_device::cpu_map(address_map &map) map(0x00000000, 0x00000cff).rw(FUNC(gt64xxx_device::cpu_if_r), FUNC(gt64xxx_device::cpu_if_w)); } -gt64xxx_device::gt64xxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gt64xxx_device::gt64xxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : pci_host_device(mconfig, type, tag, owner, clock) , m_cpu(*this, finder_base::DUMMY_TAG), m_be(0), m_autoconfig(0), m_irq_num(-1) , m_mem_config("memory_space", ENDIANNESS_LITTLE, 32, 32) diff --git a/src/devices/machine/gt64xxx.h b/src/devices/machine/gt64xxx.h index 644d101c72e..7c85f082623 100644 --- a/src/devices/machine/gt64xxx.h +++ b/src/devices/machine/gt64xxx.h @@ -69,7 +69,7 @@ public: virtual void device_post_load() override; protected: - gt64xxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gt64xxx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); address_space *m_cpu_space; virtual space_config_vector memory_space_config() const override; @@ -155,14 +155,14 @@ private: class gt64010_device : public gt64xxx_device { public: template <typename T> - gt64010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, int irq_num) + gt64010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, int irq_num) : gt64010_device(mconfig, tag, owner, clock) { set_ids_host(0x11ab0146, 0x03, 0x00000000); set_cpu_tag(std::forward<T>(cpu_tag)); set_irq_num(irq_num); } - gt64010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + gt64010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gt64xxx_device(mconfig, GT64010, tag, owner, clock) {} }; @@ -173,14 +173,14 @@ public: class gt64111_device : public gt64xxx_device { public: template <typename T> - gt64111_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, int irq_num) + gt64111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, int irq_num) : gt64111_device(mconfig, tag, owner, clock) { set_ids(0x414611ab, 0x10, 0x058000, 0x00000000); set_cpu_tag(std::forward<T>(cpu_tag)); set_irq_num(irq_num); } - gt64111_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) + gt64111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gt64xxx_device(mconfig, GT64111, tag, owner, clock) {} }; diff --git a/src/devices/machine/gt913_io.cpp b/src/devices/machine/gt913_io.cpp index d1b091fa308..feaab0c4032 100644 --- a/src/devices/machine/gt913_io.cpp +++ b/src/devices/machine/gt913_io.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(GT913_IO_HLE, gt913_io_hle_device, "gt913_io_hle", "Casio GT913F I/O (HLE)") -gt913_io_hle_device::gt913_io_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gt913_io_hle_device::gt913_io_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GT913_IO_HLE, tag, owner, clock), m_cpu(*this, DEVICE_SELF_OWNER), m_cpu_io(nullptr), m_intc(nullptr), m_intc_tag(nullptr) diff --git a/src/devices/machine/gt913_io.h b/src/devices/machine/gt913_io.h index 335c7b2719f..16f118afe48 100644 --- a/src/devices/machine/gt913_io.h +++ b/src/devices/machine/gt913_io.h @@ -21,9 +21,9 @@ class gt913_io_hle_device : public device_t { public: // construction/destruction - gt913_io_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + gt913_io_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); gt913_io_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *intc, int t0irq, int t1irq) - : gt913_io_hle_device(mconfig, tag, owner, 0) + : gt913_io_hle_device(mconfig, tag, owner) { m_intc_tag = intc; m_timer_irq[0] = t0irq; diff --git a/src/devices/machine/gt913_kbd.cpp b/src/devices/machine/gt913_kbd.cpp index ba7a2ff521c..35c73ce18a3 100644 --- a/src/devices/machine/gt913_kbd.cpp +++ b/src/devices/machine/gt913_kbd.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(GT913_KBD_HLE, gt913_kbd_hle_device, "gt913_kbd_hle", "Casio GT913F keyboard controller (HLE)") -gt913_kbd_hle_device::gt913_kbd_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +gt913_kbd_hle_device::gt913_kbd_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GT913_KBD_HLE, tag, owner, clock), device_matrix_keyboard_interface(mconfig, *this, "FI0", "FI1", "FI2", "FI3", "FI4", "FI5", "FI6", "FI7", "FI8", "FI9", "FI10", "KI0", "KI1", "KI2"), m_velocity(*this, "VELOCITY"), diff --git a/src/devices/machine/gt913_kbd.h b/src/devices/machine/gt913_kbd.h index 3bf2ced327e..0a1e64907d0 100644 --- a/src/devices/machine/gt913_kbd.h +++ b/src/devices/machine/gt913_kbd.h @@ -21,7 +21,7 @@ class gt913_kbd_hle_device : public device_t, protected device_matrix_keyboard_i { public: // construction/destruction - gt913_kbd_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + gt913_kbd_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto irq_cb() { return m_irq_cb.bind(); } diff --git a/src/devices/machine/gt913_snd.cpp b/src/devices/machine/gt913_snd.cpp index 803e6443278..9d5ecbd84e0 100644 --- a/src/devices/machine/gt913_snd.cpp +++ b/src/devices/machine/gt913_snd.cpp @@ -52,7 +52,7 @@ const u16 gt913_sound_device::volume_ramp[17] = 0x8000 }; -gt913_sound_device::gt913_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +gt913_sound_device::gt913_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GT913_SOUND, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/machine/gt913_snd.h b/src/devices/machine/gt913_snd.h index 4c5bfd4a153..0f32647f413 100644 --- a/src/devices/machine/gt913_snd.h +++ b/src/devices/machine/gt913_snd.h @@ -25,7 +25,7 @@ public: static constexpr feature_type imperfect_features() { return feature::SOUND; } // construction/destruction - gt913_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + gt913_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void data_w(offs_t offset, u16 data); u16 data_r(offs_t offset); diff --git a/src/devices/machine/hd63450.cpp b/src/devices/machine/hd63450.cpp index 5006729badf..b72cbd193fa 100644 --- a/src/devices/machine/hd63450.cpp +++ b/src/devices/machine/hd63450.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(HD63450, hd63450_device, "hd63450", "Hitachi HD63450 DMAC") -hd63450_device::hd63450_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd63450_device::hd63450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HD63450, tag, owner, clock) , m_irq_callback(*this) , m_dma_end(*this) diff --git a/src/devices/machine/hd63450.h b/src/devices/machine/hd63450.h index 33ffd8b1097..37056056e61 100644 --- a/src/devices/machine/hd63450.h +++ b/src/devices/machine/hd63450.h @@ -12,13 +12,13 @@ class hd63450_device : public device_t { public: template <typename T> - hd63450_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cputag) + hd63450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cputag) : hd63450_device(mconfig, tag, owner, clock) { set_cpu_tag(std::forward<T>(cputag)); } - hd63450_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd63450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_callback() { return m_irq_callback.bind(); } auto dma_end() { return m_dma_end.bind(); } diff --git a/src/devices/machine/hd64610.cpp b/src/devices/machine/hd64610.cpp index 2a2c3064705..876cc9ec4ea 100644 --- a/src/devices/machine/hd64610.cpp +++ b/src/devices/machine/hd64610.cpp @@ -153,7 +153,7 @@ inline void hd64610_device::check_alarm() // hd64610_device - constructor //------------------------------------------------- -hd64610_device::hd64610_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd64610_device::hd64610_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HD64610, tag, owner, clock), device_rtc_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/machine/hd64610.h b/src/devices/machine/hd64610.h index 9dda6ed03e5..877fbb0a6d6 100644 --- a/src/devices/machine/hd64610.h +++ b/src/devices/machine/hd64610.h @@ -34,7 +34,7 @@ class hd64610_device : public device_t, { public: // construction/destruction - hd64610_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd64610_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq() { return m_out_irq_cb.bind(); } auto clkout() { return m_out_1hz_cb.bind(); } diff --git a/src/devices/machine/hdc92x4.cpp b/src/devices/machine/hdc92x4.cpp index 1abdcf02abc..5394285e72b 100644 --- a/src/devices/machine/hdc92x4.cpp +++ b/src/devices/machine/hdc92x4.cpp @@ -466,7 +466,7 @@ const hdc92x4_device::cmddef hdc92x4_device::s_command[] = /* Standard constructor for the base class and the two variants */ -hdc92x4_device::hdc92x4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool is_hdc9234) +hdc92x4_device::hdc92x4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_hdc9234) : device_t(mconfig, type, tag, owner, clock), m_is_hdc9234(is_hdc9234), m_out_intrq(*this), @@ -479,12 +479,12 @@ hdc92x4_device::hdc92x4_device(const machine_config &mconfig, device_type type, { } -hdc9224_device::hdc9224_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hdc9224_device::hdc9224_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hdc92x4_device(mconfig, HDC9224, tag, owner, clock, false) { } -hdc9234_device::hdc9234_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hdc9234_device::hdc9234_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hdc92x4_device(mconfig, HDC9234, tag, owner, clock, true) { } diff --git a/src/devices/machine/hdc92x4.h b/src/devices/machine/hdc92x4.h index 4527efc6c91..790c6bf62c1 100644 --- a/src/devices/machine/hdc92x4.h +++ b/src/devices/machine/hdc92x4.h @@ -78,7 +78,7 @@ public: void connect_hard_drive(mfm_harddisk_device *harddisk); protected: - hdc92x4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool is_hdc9234); + hdc92x4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_hdc9234); virtual void device_start() override; virtual void device_reset() override; @@ -462,7 +462,7 @@ private: class hdc9224_device : public hdc92x4_device { public: - hdc9224_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hdc9224_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int step_time() override; @@ -472,7 +472,7 @@ protected: class hdc9234_device : public hdc92x4_device { public: - hdc9234_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hdc9234_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int step_time() override; diff --git a/src/devices/machine/hp_dc100_tape.cpp b/src/devices/machine/hp_dc100_tape.cpp index 2afd9d78beb..57118c24d8c 100644 --- a/src/devices/machine/hp_dc100_tape.cpp +++ b/src/devices/machine/hp_dc100_tape.cpp @@ -71,7 +71,7 @@ DEFINE_DEVICE_TYPE(HP_DC100_TAPE, hp_dc100_tape_device, "hp_dc100_tape", "HP DC1 constexpr double MOTION_MARGIN = 1e-5; // Margin to ensure motion events have passed when timer expires (10 µs) constexpr hti_format_t::tape_pos_t TAPE_INIT_POS = 80 * hti_format_t::ONE_INCH_POS; // Initial tape position: 80" from beginning (just past the punched part) -hp_dc100_tape_device::hp_dc100_tape_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp_dc100_tape_device::hp_dc100_tape_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : microtape_image_device(mconfig, HP_DC100_TAPE, tag, owner, clock) , m_cart_out_handler(*this) , m_hole_handler(*this) diff --git a/src/devices/machine/hp_dc100_tape.h b/src/devices/machine/hp_dc100_tape.h index fd8ff3b5425..5cf1c0868a8 100644 --- a/src/devices/machine/hp_dc100_tape.h +++ b/src/devices/machine/hp_dc100_tape.h @@ -21,7 +21,7 @@ class hp_dc100_tape_device : public microtape_image_device { public: // Construction - hp_dc100_tape_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_dc100_tape_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device_image_interface overrides virtual image_init_result call_load() override; diff --git a/src/devices/machine/hp_taco.cpp b/src/devices/machine/hp_taco.cpp index 8896edf0fc2..b84a7116ad9 100644 --- a/src/devices/machine/hp_taco.cpp +++ b/src/devices/machine/hp_taco.cpp @@ -274,7 +274,7 @@ enum cmd_t : uint8_t { DEFINE_DEVICE_TYPE(HP_TACO, hp_taco_device, "hp_taco", "HP TACO") // Constructors -hp_taco_device::hp_taco_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +hp_taco_device::hp_taco_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_tape(*this, "drive") , m_irq_handler(*this) @@ -283,7 +283,7 @@ hp_taco_device::hp_taco_device(const machine_config &mconfig, device_type type, { } -hp_taco_device::hp_taco_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp_taco_device::hp_taco_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hp_taco_device(mconfig, HP_TACO, tag, owner, clock) { } @@ -543,7 +543,7 @@ READ_LINE_MEMBER(hp_taco_device::wr_bit_r) void hp_taco_device::device_add_mconfig(machine_config &config) { - HP_DC100_TAPE(config, m_tape, 0); + HP_DC100_TAPE(config, m_tape); m_tape->set_acceleration(ACCELERATION); m_tape->set_set_points(SLOW_SPEED, FAST_SPEED); m_tape->set_tick_size(TACH_TICK_LEN); diff --git a/src/devices/machine/hp_taco.h b/src/devices/machine/hp_taco.h index f409946a988..4ff6eaeec6c 100644 --- a/src/devices/machine/hp_taco.h +++ b/src/devices/machine/hp_taco.h @@ -20,7 +20,7 @@ class hp_taco_device : public device_t { public: // construction/destruction - hp_taco_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp_taco_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq() { return m_irq_handler.bind(); } @@ -46,7 +46,7 @@ public: DECLARE_READ_LINE_MEMBER(wr_bit_r); protected: - hp_taco_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + hp_taco_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/machine/i2cmem.cpp b/src/devices/machine/i2cmem.cpp index 2db16de0899..102ef7f2373 100644 --- a/src/devices/machine/i2cmem.cpp +++ b/src/devices/machine/i2cmem.cpp @@ -122,68 +122,68 @@ i2cmem_device::i2cmem_device( assert(!clock); } -i2c_x24c01_device::i2c_x24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i2c_x24c01_device::i2c_x24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_X24C01, tag, owner, clock, 0, 8, 0x80) { set_devsel_address_low(true); } -i2c_24c01_device::i2c_24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i2c_24c01_device::i2c_24c01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_24C01, tag, owner, clock, 0, 8, 0x80) { } -i2c_pcf8570_device::i2c_pcf8570_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +i2c_pcf8570_device::i2c_pcf8570_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_PCF8570, tag, owner, clock, 0, 0, 0x100) { } -i2c_pcd8572_device::i2c_pcd8572_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +i2c_pcd8572_device::i2c_pcd8572_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_PCD8572, tag, owner, clock, 0, 0, 0x80) { } -i2c_pcf8582_device::i2c_pcf8582_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +i2c_pcf8582_device::i2c_pcf8582_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_PCF8582, tag, owner, clock, 0, 0, 0x100) { } -i2c_24c02_device::i2c_24c02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i2c_24c02_device::i2c_24c02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_24C02, tag, owner, clock, 0, 8, 0x100) { } -i2c_m24c02_device::i2c_m24c02_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +i2c_m24c02_device::i2c_m24c02_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_M24C02, tag, owner, clock, 0, 16, 0x100) { } -i2c_24c04_device::i2c_24c04_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +i2c_24c04_device::i2c_24c04_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_24C04, tag, owner, clock, 0, 16, 0x200) { } -i2c_x2404p_device::i2c_x2404p_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +i2c_x2404p_device::i2c_x2404p_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_X2404P, tag, owner, clock, 0x100, 8, 0x200) { } -i2c_24c08_device::i2c_24c08_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i2c_24c08_device::i2c_24c08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_24C08, tag, owner, clock, 0, 16, 0x400) { } -i2c_24c16_device::i2c_24c16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i2c_24c16_device::i2c_24c16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_24C16, tag, owner, clock, 0, 16, 0x800) { } -i2c_24c64_device::i2c_24c64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i2c_24c64_device::i2c_24c64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_24C64, tag, owner, clock, 0, 32, 0x2000) { } -i2c_24c512_device::i2c_24c512_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +i2c_24c512_device::i2c_24c512_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : i2cmem_device(mconfig, I2C_24C512, tag, owner, clock, 0, 128, 0x10000) { } diff --git a/src/devices/machine/i2cmem.h b/src/devices/machine/i2cmem.h index 9ea431faab2..f8f2faa2630 100644 --- a/src/devices/machine/i2cmem.h +++ b/src/devices/machine/i2cmem.h @@ -50,7 +50,7 @@ public: protected: // construction/destruction - i2cmem_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int read_page_size, int write_page_size, int data_size); + i2cmem_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int read_page_size, int write_page_size, int data_size); // device-level overrides virtual void device_start() override; @@ -100,7 +100,7 @@ protected: class i2c_##name##_device : public i2cmem_device \ { \ public: \ - i2c_##name##_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); \ + i2c_##name##_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); \ }; DECLARE_I2C_DEVICE(x24c01); diff --git a/src/devices/machine/i6300esb.cpp b/src/devices/machine/i6300esb.cpp index 3e9d8089b40..d2938e74e82 100644 --- a/src/devices/machine/i6300esb.cpp +++ b/src/devices/machine/i6300esb.cpp @@ -10,7 +10,7 @@ void i6300esb_watchdog_device::map(address_map &map) { } -i6300esb_watchdog_device::i6300esb_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i6300esb_watchdog_device::i6300esb_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, I6300ESB_WATCHDOG, tag, owner, clock) { } @@ -89,7 +89,7 @@ void i6300esb_lpc_device::internal_io_map(address_map &map) } -i6300esb_lpc_device::i6300esb_lpc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i6300esb_lpc_device::i6300esb_lpc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, I6300ESB_LPC, tag, owner, clock) , acpi(*this, "acpi") , rtc (*this, "rtc") diff --git a/src/devices/machine/i6300esb.h b/src/devices/machine/i6300esb.h index a126a5c1735..de9c313a30c 100644 --- a/src/devices/machine/i6300esb.h +++ b/src/devices/machine/i6300esb.h @@ -12,7 +12,7 @@ class i6300esb_lpc_device : public pci_device { public: - i6300esb_lpc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i6300esb_lpc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void reset_all_mappings() override; virtual void map_extra(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space, @@ -138,12 +138,12 @@ private: class i6300esb_watchdog_device : public pci_device { public: - i6300esb_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t subdevice_id) + i6300esb_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t subdevice_id) : i6300esb_watchdog_device(mconfig, tag, owner, clock) { set_ids(0x808625ab, 0x02, 0x088000, subdevice_id); } - i6300esb_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i6300esb_watchdog_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/i7220.cpp b/src/devices/machine/i7220.cpp index 9d9c788759f..02df85b266f 100644 --- a/src/devices/machine/i7220.cpp +++ b/src/devices/machine/i7220.cpp @@ -60,7 +60,7 @@ DEFINE_DEVICE_TYPE(I7220, i7220_device, "i7220", "Intel 7220 BMC") // i7220_device - constructor //------------------------------------------------- -i7220_device::i7220_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i7220_device::i7220_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I7220, tag, owner, clock) , device_image_interface(mconfig, *this) , intrq_cb(*this) diff --git a/src/devices/machine/i7220.h b/src/devices/machine/i7220.h index f961d64559e..6e4f47195dc 100644 --- a/src/devices/machine/i7220.h +++ b/src/devices/machine/i7220.h @@ -42,7 +42,7 @@ class i7220_device : public device_t, { public: // construction/destruction - i7220_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i7220_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_callback() { return intrq_cb.bind(); } auto drq_callback() { return drq_cb.bind(); } diff --git a/src/devices/machine/i80130.cpp b/src/devices/machine/i80130.cpp index b9b632b93e1..ce13a815010 100644 --- a/src/devices/machine/i80130.cpp +++ b/src/devices/machine/i80130.cpp @@ -102,10 +102,10 @@ void i80130_device::io_w(offs_t offset, uint16_t data, uint16_t mem_mask) void i80130_device::device_add_mconfig(machine_config &config) { - PIC8259(config, m_pic, 0); + PIC8259(config, m_pic); m_pic->out_int_callback().set(FUNC(i80130_device::irq_w)); - PIT8254(config, m_pit, 0); + PIT8254(config, m_pit); m_pit->set_clk<0>(0); m_pit->out_handler<0>().set(FUNC(i80130_device::systick_w)); m_pit->set_clk<1>(0); @@ -124,7 +124,7 @@ void i80130_device::device_add_mconfig(machine_config &config) // i80130_device - constructor //------------------------------------------------- -i80130_device::i80130_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i80130_device::i80130_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I80130, tag, owner, clock), m_pic(*this, "pic"), m_pit(*this, "pit"), diff --git a/src/devices/machine/i80130.h b/src/devices/machine/i80130.h index 0b5958ad875..d067913ad65 100644 --- a/src/devices/machine/i80130.h +++ b/src/devices/machine/i80130.h @@ -18,7 +18,7 @@ class i80130_device : public device_t { public: // construction/destruction - i80130_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i80130_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq() { return m_write_irq.bind(); } auto ack() { return m_write_ack.bind(); } diff --git a/src/devices/machine/i8087.cpp b/src/devices/machine/i8087.cpp index 4235d734d7e..2d4bd048ac5 100644 --- a/src/devices/machine/i8087.cpp +++ b/src/devices/machine/i8087.cpp @@ -167,7 +167,7 @@ static inline floatx80 double_to_fx80(double in) DEFINE_DEVICE_TYPE(I8087, i8087_device, "i8087", "Intel 8087") -i8087_device::i8087_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +i8087_device::i8087_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_space(*this, finder_base::DUMMY_TAG, -1), m_int_handler(*this), @@ -175,7 +175,7 @@ i8087_device::i8087_device(const machine_config &mconfig, device_type type, cons { } -i8087_device::i8087_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +i8087_device::i8087_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8087_device(mconfig, I8087, tag, owner, clock) { } diff --git a/src/devices/machine/i8087.h b/src/devices/machine/i8087.h index af3dea07f08..925288e188e 100644 --- a/src/devices/machine/i8087.h +++ b/src/devices/machine/i8087.h @@ -13,7 +13,7 @@ DECLARE_DEVICE_TYPE(I8087, i8087_device) class i8087_device : public device_t { public: - i8087_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + i8087_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <class Object> void set_space_88(Object &&tag, int spacenum) { m_space.set_tag(std::forward<Object>(tag), spacenum); m_space.set_data_width(8); } template <class Object> void set_space_86(Object &&tag, int spacenum) { m_space.set_tag(std::forward<Object>(tag), spacenum); m_space.set_data_width(16); } auto irq() { return m_int_handler.bind(); } @@ -23,7 +23,7 @@ public: void addr_w(uint32_t data); protected: - i8087_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + i8087_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/machine/i8155.cpp b/src/devices/machine/i8155.cpp index 810bb001e67..bf3a035c0fb 100644 --- a/src/devices/machine/i8155.cpp +++ b/src/devices/machine/i8155.cpp @@ -268,12 +268,12 @@ inline void i8155_device::write_port(int port, uint8_t data) // i8155_device - constructor //------------------------------------------------- -i8155_device::i8155_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8155_device::i8155_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8155_device(mconfig, I8155, tag, owner, clock) { } -i8155_device::i8155_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +i8155_device::i8155_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_in_pa_cb(*this), m_in_pb_cb(*this), @@ -296,7 +296,7 @@ i8155_device::i8155_device(const machine_config &mconfig, device_type type, cons // i8156_device - constructor //------------------------------------------------- -i8156_device::i8156_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8156_device::i8156_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8155_device(mconfig, I8156, tag, owner, clock) { } diff --git a/src/devices/machine/i8155.h b/src/devices/machine/i8155.h index ace27e002c9..c95d23f8159 100644 --- a/src/devices/machine/i8155.h +++ b/src/devices/machine/i8155.h @@ -45,7 +45,7 @@ class i8155_device : public device_t { public: // construction/destruction - i8155_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8155_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto in_pa_callback() { return m_in_pa_cb.bind(); } auto in_pb_callback() { return m_in_pb_cb.bind(); } @@ -66,7 +66,7 @@ public: void data_w(uint8_t data); protected: - i8155_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + i8155_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -129,7 +129,7 @@ class i8156_device : public i8155_device { public: // construction/destruction - i8156_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8156_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/machine/i8212.cpp b/src/devices/machine/i8212.cpp index c6cf46eafe5..e45ad13442d 100644 --- a/src/devices/machine/i8212.cpp +++ b/src/devices/machine/i8212.cpp @@ -57,7 +57,7 @@ DEFINE_DEVICE_TYPE(I8212, i8212_device, "i8212", "Intel 8212 I/O Port") // i8212_device - constructor //------------------------------------------------- -i8212_device::i8212_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i8212_device::i8212_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I8212, tag, owner, clock), m_write_int(*this), m_read_di(*this), diff --git a/src/devices/machine/i8212.h b/src/devices/machine/i8212.h index efd84d11813..1acd9a51f40 100644 --- a/src/devices/machine/i8212.h +++ b/src/devices/machine/i8212.h @@ -36,7 +36,7 @@ class i8212_device : public device_t public: // construction/destruction - i8212_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + i8212_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto int_wr_callback() { return m_write_int.bind(); } auto di_rd_callback() { return m_read_di.bind(); } diff --git a/src/devices/machine/i8214.cpp b/src/devices/machine/i8214.cpp index b5a8c4140be..6752f7bee1b 100644 --- a/src/devices/machine/i8214.cpp +++ b/src/devices/machine/i8214.cpp @@ -113,7 +113,7 @@ void i8214_device::check_interrupt() // i8214_device - constructor //------------------------------------------------- -i8214_device::i8214_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8214_device::i8214_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I8214, tag, owner, clock) , m_write_int(*this) , m_write_enlg(*this) diff --git a/src/devices/machine/i8214.h b/src/devices/machine/i8214.h index d8514e400ef..de17fa209bc 100644 --- a/src/devices/machine/i8214.h +++ b/src/devices/machine/i8214.h @@ -30,7 +30,7 @@ class i8214_device : public device_t { public: // construction/destruction - i8214_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8214_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_int_dis_hack(bool hack) { m_int_dis_hack = hack; } diff --git a/src/devices/machine/i82355.cpp b/src/devices/machine/i82355.cpp index 88726f7f04e..4419ee20cb4 100644 --- a/src/devices/machine/i82355.cpp +++ b/src/devices/machine/i82355.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(I82355, i82355_device, "i82355", "Intel 82355 BMIC") // i82355_device - constructor //------------------------------------------------- -i82355_device::i82355_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +i82355_device::i82355_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I82355, tag, owner, clock) , m_eint_callback(*this) , m_lint_callback(*this) diff --git a/src/devices/machine/i82355.h b/src/devices/machine/i82355.h index 25cb776d9f7..c11c459ed1b 100644 --- a/src/devices/machine/i82355.h +++ b/src/devices/machine/i82355.h @@ -21,7 +21,7 @@ class i82355_device : public device_t { public: // construction/destruction - i82355_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + i82355_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto eint_callback() { return m_eint_callback.bind(); } diff --git a/src/devices/machine/i82357.cpp b/src/devices/machine/i82357.cpp index 91de890a03d..d3bf1c1757f 100644 --- a/src/devices/machine/i82357.cpp +++ b/src/devices/machine/i82357.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(I82357, i82357_device, "i82357", "Intel 82357 Integrated System Peripheral") -i82357_device::i82357_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +i82357_device::i82357_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I82357, tag, owner, clock) , m_pic(*this, "pic%u", 0) , m_pit(*this, "pit%u", 0) @@ -43,7 +43,7 @@ i82357_device::i82357_device(const machine_config &mconfig, const char *tag, dev void i82357_device::device_add_mconfig(machine_config &config) { - PIC8259(config, m_pic[0], 0); + PIC8259(config, m_pic[0]); m_pic[0]->in_sp_callback().set_constant(1); m_pic[0]->read_slave_ack_callback().set( [this](offs_t offset) -> u8 @@ -54,12 +54,12 @@ void i82357_device::device_add_mconfig(machine_config &config) return 0; }); - PIC8259(config, m_pic[1], 0); + PIC8259(config, m_pic[1]); m_pic[1]->out_int_callback().set(m_pic[0], FUNC(pic8259_device::ir2_w)); m_pic[1]->in_sp_callback().set_constant(0); - PIT8254(config, m_pit[0], 0); - PIT8254(config, m_pit[1], 0); + PIT8254(config, m_pit[0]); + PIT8254(config, m_pit[1]); // timer 1 counter 0: system timer m_pit[0]->set_clk<0>(clock() / 12); diff --git a/src/devices/machine/i82357.h b/src/devices/machine/i82357.h index 3c5a7756061..8af682c0251 100644 --- a/src/devices/machine/i82357.h +++ b/src/devices/machine/i82357.h @@ -13,7 +13,7 @@ class i82357_device : public device_t { public: - i82357_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + i82357_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_rtc_cb() { return m_out_rtc.bind(); } auto out_int_cb() { return subdevice<pic8259_device>("pic0")->out_int_callback(); } diff --git a/src/devices/machine/i82371sb.cpp b/src/devices/machine/i82371sb.cpp index 480561bb69e..c62a9e829e8 100644 --- a/src/devices/machine/i82371sb.cpp +++ b/src/devices/machine/i82371sb.cpp @@ -108,7 +108,7 @@ void i82371sb_isa_device::device_add_mconfig(machine_config &config) SPEAKER(config, "mono").front_center(); SPEAKER_SOUND(config, m_speaker).add_route(ALL_OUTPUTS, "mono", 0.50); - ISA16(config, m_isabus, 0); + ISA16(config, m_isabus); m_isabus->set_memspace(":maincpu", AS_PROGRAM); m_isabus->set_iospace(":maincpu", AS_IO); m_isabus->irq3_callback().set(FUNC(i82371sb_isa_device::pc_irq3_w)); @@ -132,7 +132,7 @@ void i82371sb_isa_device::device_add_mconfig(machine_config &config) m_isabus->iochck_callback().set(FUNC(i82371sb_isa_device::iochck_w)); } -i82371sb_isa_device::i82371sb_isa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i82371sb_isa_device::i82371sb_isa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, I82371SB_ISA, tag, owner, clock), m_smi_callback(*this), m_nmi_callback(*this), @@ -973,7 +973,7 @@ void i82371sb_ide_device::device_add_mconfig(machine_config &config) m_ide2->set_bus_master_space(":maincpu", AS_PROGRAM); } -i82371sb_ide_device::i82371sb_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82371sb_ide_device::i82371sb_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, I82371SB_IDE, tag, owner, clock) , latency_timer(0) , bmiba(1) diff --git a/src/devices/machine/i82371sb.h b/src/devices/machine/i82371sb.h index f667132883c..fd3a28ab335 100644 --- a/src/devices/machine/i82371sb.h +++ b/src/devices/machine/i82371sb.h @@ -26,7 +26,7 @@ class i82371sb_isa_device : public pci_device { public: - i82371sb_isa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82371sb_isa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto smi() { return m_smi_callback.bind(); } auto nmi() { return m_nmi_callback.bind(); } @@ -210,7 +210,7 @@ DECLARE_DEVICE_TYPE(I82371SB_ISA, i82371sb_isa_device) class i82371sb_ide_device : public pci_device { public: - i82371sb_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82371sb_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_pri() { return m_irq_pri_callback.bind(); } auto irq_sec() { return m_irq_sec_callback.bind(); } diff --git a/src/devices/machine/i8243.cpp b/src/devices/machine/i8243.cpp index 5c6c0bfe385..116b7ca21f4 100644 --- a/src/devices/machine/i8243.cpp +++ b/src/devices/machine/i8243.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(I8243, i8243_device, "i8243", "Intel 8243 I/O Expander") // i8243_device - constructor //------------------------------------------------- -i8243_device::i8243_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8243_device::i8243_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I8243, tag, owner, clock) , m_p{0, 0, 0, 0} , m_p2out(0x0f), m_p2(0x0f), m_opcode(0), m_prog(1), m_cs(0) diff --git a/src/devices/machine/i8243.h b/src/devices/machine/i8243.h index 53c46358567..d74b53348cb 100644 --- a/src/devices/machine/i8243.h +++ b/src/devices/machine/i8243.h @@ -32,7 +32,7 @@ class i8243_device : public device_t { public: // construction/destruction - i8243_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + i8243_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers auto p4_in_cb() { return m_readhandler[0].bind(); } diff --git a/src/devices/machine/i82439hx.cpp b/src/devices/machine/i82439hx.cpp index 866963184b5..2abb004925b 100644 --- a/src/devices/machine/i82439hx.cpp +++ b/src/devices/machine/i82439hx.cpp @@ -28,7 +28,7 @@ void i82439hx_host_device::config_map(address_map &map) map(0x92, 0x92).r(FUNC(i82439hx_host_device::errsyn_r)); } -i82439hx_host_device::i82439hx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82439hx_host_device::i82439hx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_host_device(mconfig, I82439HX, tag, owner, clock) , cpu(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/machine/i82439hx.h b/src/devices/machine/i82439hx.h index e6a833c6cfb..92d497b70eb 100644 --- a/src/devices/machine/i82439hx.h +++ b/src/devices/machine/i82439hx.h @@ -12,14 +12,14 @@ class i82439hx_host_device : public pci_host_device { public: template <typename T> - i82439hx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, int ram_size) + i82439hx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, int ram_size) : i82439hx_host_device(mconfig, tag, owner, clock) { set_ids_host(0x80861250, 0x03, 0x00000000); set_cpu_tag(std::forward<T>(cpu_tag)); set_ram_size(ram_size); } - i82439hx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82439hx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_cpu_tag(T &&tag) { cpu.set_tag(std::forward<T>(tag)); } void set_ram_size(int ram_size); diff --git a/src/devices/machine/i82439tx.cpp b/src/devices/machine/i82439tx.cpp index f8c1c9a8bb3..0ac3d0ee90a 100644 --- a/src/devices/machine/i82439tx.cpp +++ b/src/devices/machine/i82439tx.cpp @@ -23,7 +23,7 @@ void i82439tx_host_device::config_map(address_map &map) map(0x92, 0x92).r(FUNC(i82439tx_host_device::errsyn_r)); } -i82439tx_host_device::i82439tx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82439tx_host_device::i82439tx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_host_device(mconfig, I82439TX, tag, owner, clock) , cpu(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/machine/i82439tx.h b/src/devices/machine/i82439tx.h index a2a9528b1dd..b925a7a4662 100644 --- a/src/devices/machine/i82439tx.h +++ b/src/devices/machine/i82439tx.h @@ -12,14 +12,14 @@ class i82439tx_host_device : public pci_host_device { public: template <typename T> - i82439tx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, int ram_size) + i82439tx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, int ram_size) : i82439tx_host_device(mconfig, tag, owner, clock) { set_ids_host(0x80867100, 0x03, 0x00000000); set_cpu_tag(std::forward<T>(cpu_tag)); set_ram_size(ram_size); } - i82439tx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82439tx_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_cpu_tag(T &&tag) { cpu.set_tag(std::forward<T>(tag)); } void set_ram_size(int ram_size); diff --git a/src/devices/machine/i8251.cpp b/src/devices/machine/i8251.cpp index b1a04cba1f6..05a7249c02b 100644 --- a/src/devices/machine/i8251.cpp +++ b/src/devices/machine/i8251.cpp @@ -73,12 +73,12 @@ i8251_device::i8251_device( { } -i8251_device::i8251_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8251_device::i8251_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8251_device(mconfig, I8251, tag, owner, clock) { } -v5x_scu_device::v5x_scu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v5x_scu_device::v5x_scu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8251_device(mconfig, V5X_SCU, tag, owner, clock) { } diff --git a/src/devices/machine/i8251.h b/src/devices/machine/i8251.h index 0cf1a7c911d..6d821f250ca 100644 --- a/src/devices/machine/i8251.h +++ b/src/devices/machine/i8251.h @@ -20,7 +20,7 @@ class i8251_device : public device_t, { public: // construction/destruction - i8251_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8251_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto txd_handler() { return m_txd_handler.bind(); } @@ -153,7 +153,7 @@ class v5x_scu_device : public i8251_device { public: // construction/destruction - v5x_scu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v5x_scu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/machine/i82541.cpp b/src/devices/machine/i82541.cpp index b727ac6e295..8e9045cdde8 100644 --- a/src/devices/machine/i82541.cpp +++ b/src/devices/machine/i82541.cpp @@ -17,7 +17,7 @@ void i82541_device::registers_io_map(address_map &map) { } -i82541_device::i82541_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82541_device::i82541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, I82541, tag, owner, clock) { } diff --git a/src/devices/machine/i82541.h b/src/devices/machine/i82541.h index 1614bf0b01c..80ae5cc4af6 100644 --- a/src/devices/machine/i82541.h +++ b/src/devices/machine/i82541.h @@ -9,12 +9,12 @@ class i82541_device : public pci_device { public: - i82541_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t subdevice_id) + i82541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t subdevice_id) : i82541_device(mconfig, tag, owner, clock) { set_ids(0x8086107c, 0x05, 0x020000, subdevice_id); } - i82541_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82541_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/i8255.cpp b/src/devices/machine/i8255.cpp index b1bae643ee9..3ae921b86f4 100644 --- a/src/devices/machine/i8255.cpp +++ b/src/devices/machine/i8255.cpp @@ -215,7 +215,7 @@ inline int i8255_device::port_c_upper_mode() // i8255_device - constructor //------------------------------------------------- -i8255_device::i8255_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool is_ams40489) +i8255_device::i8255_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_ams40489) : device_t(mconfig, type, tag, owner, clock) , m_force_portb_in(is_ams40489) , m_force_portc_out(is_ams40489) @@ -234,7 +234,7 @@ i8255_device::i8255_device(const machine_config &mconfig, device_type type, cons { } -i8255_device::i8255_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8255_device::i8255_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8255_device(mconfig, I8255, tag, owner, clock, false) { } @@ -946,7 +946,7 @@ WRITE_LINE_MEMBER( i8255_device::pc6_w ) // AMS40489 (Amstrad Plus/GX4000 ASIC PPI implementation) -ams40489_ppi_device::ams40489_ppi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ams40489_ppi_device::ams40489_ppi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8255_device(mconfig, AMS40489_PPI, tag, owner, clock, true) { } diff --git a/src/devices/machine/i8255.h b/src/devices/machine/i8255.h index bd74fe2eb6e..b9e16ccf729 100644 --- a/src/devices/machine/i8255.h +++ b/src/devices/machine/i8255.h @@ -45,7 +45,7 @@ class i8255_device : public device_t { public: // construction/destruction - i8255_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + i8255_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto in_pa_callback() { return m_in_pa_cb.bind(); } auto in_pb_callback() { return m_in_pb_cb.bind(); } @@ -73,7 +73,7 @@ public: DECLARE_WRITE_LINE_MEMBER( pc6_w ); protected: - i8255_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool is_ams40489); + i8255_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool is_ams40489); // device-level overrides virtual void device_resolve_objects() override; @@ -137,7 +137,7 @@ class ams40489_ppi_device : public i8255_device { public: // construction/destruction - ams40489_ppi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ams40489_ppi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // device type definition diff --git a/src/devices/machine/i8257.cpp b/src/devices/machine/i8257.cpp index c2fb87d203b..bfe537f0c79 100644 --- a/src/devices/machine/i8257.cpp +++ b/src/devices/machine/i8257.cpp @@ -251,7 +251,7 @@ inline void i8257_device::advance() // i8257_device - constructor //------------------------------------------------- -i8257_device::i8257_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8257_device::i8257_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I8257, tag, owner, clock) , device_execute_interface(mconfig, *this) , m_icount(0) diff --git a/src/devices/machine/i8257.h b/src/devices/machine/i8257.h index df1f74a4858..aff3b3f1829 100644 --- a/src/devices/machine/i8257.h +++ b/src/devices/machine/i8257.h @@ -38,7 +38,7 @@ class i8257_device : public device_t, public device_execute_interface { public: // construction/destruction - i8257_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8257_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/machine/i82586.cpp b/src/devices/machine/i82586.cpp index 0a97a5cf66f..bba9ab2b029 100644 --- a/src/devices/machine/i82586.cpp +++ b/src/devices/machine/i82586.cpp @@ -108,7 +108,7 @@ CFG_PARAMS[] = { "transmit on no crs", "disabled", 0, 8, 0x08, 3, false }, }; -i82586_base_device::i82586_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endian, u8 datawidth, u8 addrwidth) +i82586_base_device::i82586_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endian, u8 datawidth, u8 addrwidth) : device_t(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , device_network_interface(mconfig, *this, 10) @@ -128,32 +128,32 @@ i82586_base_device::i82586_base_device(const machine_config &mconfig, device_typ { } -i82586_device::i82586_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82586_device::i82586_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i82586_base_device(mconfig, I82586, tag, owner, clock, ENDIANNESS_LITTLE, 16, 24) { } -i82596_device::i82596_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endian, u8 datawidth) +i82596_device::i82596_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endian, u8 datawidth) : i82586_base_device(mconfig, type, tag, owner, clock, endian, datawidth, 32) { } -i82596_le16_device::i82596_le16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82596_le16_device::i82596_le16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i82596_device(mconfig, I82596_LE16, tag, owner, clock, ENDIANNESS_LITTLE, 16) { } -i82596_be16_device::i82596_be16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82596_be16_device::i82596_be16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i82596_device(mconfig, I82596_BE16, tag, owner, clock, ENDIANNESS_BIG, 16) { } -i82596_le32_device::i82596_le32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82596_le32_device::i82596_le32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i82596_device(mconfig, I82596_LE32, tag, owner, clock, ENDIANNESS_LITTLE, 32) { } -i82596_be32_device::i82596_be32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82596_be32_device::i82596_be32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i82596_device(mconfig, I82596_BE32, tag, owner, clock, ENDIANNESS_BIG, 32) { } diff --git a/src/devices/machine/i82586.h b/src/devices/machine/i82586.h index 82f48163620..14916e32b22 100644 --- a/src/devices/machine/i82586.h +++ b/src/devices/machine/i82586.h @@ -163,7 +163,7 @@ public: DECLARE_WRITE_LINE_MEMBER(reset_w); protected: - i82586_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endian, u8 datawidth, u8 addrwidth); + i82586_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endian, u8 datawidth, u8 addrwidth); // standard device_* overrides virtual void device_start() override; @@ -261,7 +261,7 @@ protected: class i82586_device : public i82586_base_device { public: - i82586_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82586_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static const int CFG_SIZE = 12; static const int DUMP_SIZE = 170; @@ -324,7 +324,7 @@ public: void port(u32 data); // cpu access interface protected: - i82596_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, endianness_t endian, u8 datawidth); + i82596_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, endianness_t endian, u8 datawidth); // standard device_* overrides virtual void device_start() override; @@ -372,25 +372,25 @@ private: class i82596_le16_device : public i82596_device { public: - i82596_le16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82596_le16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i82596_be16_device : public i82596_device { public: - i82596_be16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82596_be16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i82596_le32_device : public i82596_device { public: - i82596_le32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82596_le32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class i82596_be32_device : public i82596_device { public: - i82596_be32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82596_be32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(I82586, i82586_device) diff --git a/src/devices/machine/i8271.cpp b/src/devices/machine/i8271.cpp index 48d734288f4..0ac06a8db9d 100644 --- a/src/devices/machine/i8271.cpp +++ b/src/devices/machine/i8271.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(I8271, i8271_device, "i8271", "Intel 8271 FDC") -i8271_device::i8271_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8271_device::i8271_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I8271, tag, owner, clock), ready_connected(false), mode(0), main_phase(0), intrq_cb(*this), drq_cb(*this), @@ -171,9 +171,9 @@ uint8_t i8271_device::rr_r() return rr; } -void i8271_device::set_rate(int rate) +void i8271_device::set_rate(const XTAL &rate) { - cur_rate = rate; + cur_rate = rate.value(); } uint8_t i8271_device::read(offs_t offset) diff --git a/src/devices/machine/i8271.h b/src/devices/machine/i8271.h index 92880af57d4..7a828296967 100644 --- a/src/devices/machine/i8271.h +++ b/src/devices/machine/i8271.h @@ -18,7 +18,7 @@ class floppy_image_device; class i8271_device : public device_t { public: - i8271_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8271_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto intrq_wr_callback() { return intrq_cb.bind(); } auto drq_wr_callback() { return drq_cb.bind(); } @@ -32,7 +32,7 @@ public: void ready_w(bool val); - void set_rate(int rate); // rate in bps, to be used when the fdc is externally frequency-controlled + void set_rate(const XTAL &rate); // rate in bps, to be used when the fdc is externally frequency-controlled void set_ready_line_connected(bool ready); void set_select_lines_connected(bool select); diff --git a/src/devices/machine/i8279.cpp b/src/devices/machine/i8279.cpp index 9de96d806e0..7be9360d04d 100644 --- a/src/devices/machine/i8279.cpp +++ b/src/devices/machine/i8279.cpp @@ -93,7 +93,7 @@ DEFINE_DEVICE_TYPE(I8279, i8279_device, "i8279", "Intel 8279 KDC") // i8279_device - constructor //------------------------------------------------- -i8279_device::i8279_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +i8279_device::i8279_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I8279, tag, owner, clock), m_out_irq_cb(*this), m_out_sl_cb(*this), diff --git a/src/devices/machine/i8279.h b/src/devices/machine/i8279.h index 56c111a2797..2264ee7dd89 100644 --- a/src/devices/machine/i8279.h +++ b/src/devices/machine/i8279.h @@ -39,7 +39,7 @@ class i8279_device : public device_t { public: // construction/destruction - i8279_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + i8279_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_irq_callback() { return m_out_irq_cb.bind(); } auto out_sl_callback() { return m_out_sl_cb.bind(); } diff --git a/src/devices/machine/i82875p.cpp b/src/devices/machine/i82875p.cpp index 37d95112359..513df703059 100644 --- a/src/devices/machine/i82875p.cpp +++ b/src/devices/machine/i82875p.cpp @@ -43,7 +43,7 @@ void i82875p_host_device::config_map(address_map &map) map(0xe8, 0xe8).r(FUNC(i82875p_host_device::capreg2_r)); } -i82875p_host_device::i82875p_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82875p_host_device::i82875p_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_host_device(mconfig, I82875P_HOST, tag, owner, clock) , cpu(*this, finder_base::DUMMY_TAG) { @@ -423,7 +423,7 @@ void i82875p_host_device::map_extra(uint64_t memory_window_start, uint64_t memor } -i82875p_agp_device::i82875p_agp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82875p_agp_device::i82875p_agp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : agp_bridge_device(mconfig, I82875P_AGP, tag, owner, clock) { set_ids_bridge(0x80862579, 0x02); @@ -448,7 +448,7 @@ void i82875p_overflow_device::overflow_map(address_map &map) } -i82875p_overflow_device::i82875p_overflow_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i82875p_overflow_device::i82875p_overflow_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, I82875P_OVERFLOW, tag, owner, clock) { } diff --git a/src/devices/machine/i82875p.h b/src/devices/machine/i82875p.h index ecd252b35ef..d7f8d4c9143 100644 --- a/src/devices/machine/i82875p.h +++ b/src/devices/machine/i82875p.h @@ -12,7 +12,7 @@ class i82875p_host_device : public pci_host_device { public: template <typename T> - i82875p_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t subdevice_id, T &&cpu_tag, int ram_size) + i82875p_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t subdevice_id, T &&cpu_tag, int ram_size) : i82875p_host_device(mconfig, tag, owner, clock) { set_ids_host(0x80862578, 0x02, subdevice_id); @@ -20,7 +20,7 @@ public: set_ram_size(ram_size); } - i82875p_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82875p_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_cpu_tag(T &&tag) { cpu.set_tag(std::forward<T>(tag)); } void set_ram_size(int ram_size); @@ -97,7 +97,7 @@ private: class i82875p_agp_device : public agp_bridge_device { public: - i82875p_agp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82875p_agp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -106,12 +106,12 @@ protected: class i82875p_overflow_device : public pci_device { public: - i82875p_overflow_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t subdevice_id) + i82875p_overflow_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t subdevice_id) : i82875p_overflow_device(mconfig, tag, owner, clock) { set_ids(0x8086257e, 0x02, 0x088000, subdevice_id); } - i82875p_overflow_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82875p_overflow_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: uint8_t dram_row_boundary_r(offs_t offset); diff --git a/src/devices/machine/i8291a.cpp b/src/devices/machine/i8291a.cpp index 3692ba95a28..cd3750205b0 100644 --- a/src/devices/machine/i8291a.cpp +++ b/src/devices/machine/i8291a.cpp @@ -37,7 +37,7 @@ ALLOW_SAVE_TYPE(i8291a_device::source_handshake_state); ALLOW_SAVE_TYPE(i8291a_device::acceptor_handshake_state); i8291a_device::i8291a_device(const machine_config &mconfig, const char *tag, - device_t *owner, uint32_t clock) : + device_t *owner, const XTAL &clock) : device_t{mconfig, I8291A, tag, owner, clock}, m_int_write_func{*this}, m_dreq_write_func{*this}, diff --git a/src/devices/machine/i8291a.h b/src/devices/machine/i8291a.h index 2d048d806aa..b0a3458223f 100644 --- a/src/devices/machine/i8291a.h +++ b/src/devices/machine/i8291a.h @@ -17,7 +17,7 @@ class i8291a_device : public device_t { public: // construction/destruction - i8291a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8291a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto int_write() { return m_int_write_func.bind(); } auto dreq_write() { return m_dreq_write_func.bind(); } diff --git a/src/devices/machine/i8355.cpp b/src/devices/machine/i8355.cpp index caa31eb7e1a..14e5e81f8ac 100644 --- a/src/devices/machine/i8355.cpp +++ b/src/devices/machine/i8355.cpp @@ -87,7 +87,7 @@ inline void i8355_device::write_port(int port, u8 data) // i8355_device - constructor //------------------------------------------------- -i8355_device::i8355_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +i8355_device::i8355_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I8355, tag, owner, clock), m_in_pa_cb(*this), m_out_pa_cb(*this), diff --git a/src/devices/machine/i8355.h b/src/devices/machine/i8355.h index e9205a86a9d..76680c9af44 100644 --- a/src/devices/machine/i8355.h +++ b/src/devices/machine/i8355.h @@ -38,7 +38,7 @@ class i8355_device : public device_t { public: // construction/destruction - i8355_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8355_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto in_pa() { return m_in_pa_cb.bind(); } auto out_pa() { return m_out_pa_cb.bind(); } diff --git a/src/devices/machine/ibm21s850.cpp b/src/devices/machine/ibm21s850.cpp index c58622cace6..6d5445b92ed 100644 --- a/src/devices/machine/ibm21s850.cpp +++ b/src/devices/machine/ibm21s850.cpp @@ -23,18 +23,18 @@ DEFINE_DEVICE_TYPE(IBM21S850, ibm21s850_device, "ibm21s850", "IBM 21S850 IEEE-1394 1-Port PHY") DEFINE_DEVICE_TYPE(IBM21S851, ibm21s851_device, "ibm21s851", "IBM 21S850 IEEE-1394 3-Port PHY") -ibm21s85x_base_device::ibm21s85x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ibm21s85x_base_device::ibm21s85x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_reset_cb(*this) { } -ibm21s850_device::ibm21s850_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ibm21s850_device::ibm21s850_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ibm21s85x_base_device(mconfig, IBM21S850, tag, owner, clock) { } -ibm21s851_device::ibm21s851_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ibm21s851_device::ibm21s851_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ibm21s85x_base_device(mconfig, IBM21S851, tag, owner, clock) { } diff --git a/src/devices/machine/ibm21s850.h b/src/devices/machine/ibm21s850.h index dde6cf59a4d..c4c1f4dc39f 100644 --- a/src/devices/machine/ibm21s850.h +++ b/src/devices/machine/ibm21s850.h @@ -25,7 +25,7 @@ public: static constexpr feature_type unemulated_features() { return feature::COMMS; } protected: - ibm21s85x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ibm21s85x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -143,7 +143,7 @@ protected: class ibm21s850_device : public ibm21s85x_base_device { public: - ibm21s850_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ibm21s850_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: virtual void device_reset() override; @@ -161,7 +161,7 @@ private: class ibm21s851_device : public ibm21s85x_base_device { public: - ibm21s851_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ibm21s851_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: virtual void device_reset() override; diff --git a/src/devices/machine/icm7170.cpp b/src/devices/machine/icm7170.cpp index 3abcf04ea38..d0ed12fb392 100644 --- a/src/devices/machine/icm7170.cpp +++ b/src/devices/machine/icm7170.cpp @@ -68,7 +68,7 @@ enum // icm7170_device - constructor //------------------------------------------------- -icm7170_device::icm7170_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +icm7170_device::icm7170_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ICM7170, tag, owner, clock), device_rtc_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/machine/icm7170.h b/src/devices/machine/icm7170.h index 2fef930fa04..a2306fae33e 100644 --- a/src/devices/machine/icm7170.h +++ b/src/devices/machine/icm7170.h @@ -50,7 +50,7 @@ class icm7170_device : public device_t, { public: // construction/destruction - icm7170_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + icm7170_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq() { return m_out_irq_cb.bind(); } diff --git a/src/devices/machine/idectrl.cpp b/src/devices/machine/idectrl.cpp index c8f79c3fd91..9c0d4e08183 100644 --- a/src/devices/machine/idectrl.cpp +++ b/src/devices/machine/idectrl.cpp @@ -26,12 +26,12 @@ DEFINE_DEVICE_TYPE(IDE_CONTROLLER, ide_controller_device, "idectrl", "IDE Controller (16-bit)") -ide_controller_device::ide_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ide_controller_device::ide_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ide_controller_device(mconfig, IDE_CONTROLLER, tag, owner, clock) { } -ide_controller_device::ide_controller_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +ide_controller_device::ide_controller_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : abstract_ata_interface_device(mconfig, type, tag, owner, clock) { } @@ -88,12 +88,12 @@ void ide_controller_device::write_cs1(offs_t offset, uint16_t data, uint16_t mem DEFINE_DEVICE_TYPE(IDE_CONTROLLER_32, ide_controller_32_device, "idectrl32", "IDE Controller (32-bit)") -ide_controller_32_device::ide_controller_32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ide_controller_32_device::ide_controller_32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ide_controller_32_device(mconfig, IDE_CONTROLLER_32, tag, owner, clock) { } -ide_controller_32_device::ide_controller_32_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +ide_controller_32_device::ide_controller_32_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : abstract_ata_interface_device(mconfig, type, tag, owner, clock) { } @@ -220,7 +220,7 @@ void ide_controller_32_device::write_cs1(offs_t offset, uint32_t data, uint32_t DEFINE_DEVICE_TYPE(BUS_MASTER_IDE_CONTROLLER, bus_master_ide_controller_device, "idectrl32bm", "Bus Master IDE Controller") -bus_master_ide_controller_device::bus_master_ide_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +bus_master_ide_controller_device::bus_master_ide_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ide_controller_32_device(mconfig, BUS_MASTER_IDE_CONTROLLER, tag, owner, clock), m_dma_space(*this, finder_base::DUMMY_TAG, -1, 32), m_dma_address(0), diff --git a/src/devices/machine/idectrl.h b/src/devices/machine/idectrl.h index e0b10b05d08..28b0adfb974 100644 --- a/src/devices/machine/idectrl.h +++ b/src/devices/machine/idectrl.h @@ -18,7 +18,7 @@ class ide_controller_device : public abstract_ata_interface_device { public: - ide_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ide_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> ide_controller_device &master(T &&opts, const char *dflt = nullptr, bool fixed = false) { @@ -52,7 +52,7 @@ public: void cs1_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) { write_cs1(offset, data, mem_mask); } protected: - ide_controller_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ide_controller_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(IDE_CONTROLLER, ide_controller_device) @@ -61,7 +61,7 @@ DECLARE_DEVICE_TYPE(IDE_CONTROLLER, ide_controller_device) class ide_controller_32_device : public abstract_ata_interface_device { public: - ide_controller_32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ide_controller_32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> ide_controller_32_device &master(T &&opts, const char *dflt = nullptr, bool fixed = false) { @@ -95,7 +95,7 @@ public: void cs1_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0) { write_cs1(offset, data, mem_mask); } protected: - ide_controller_32_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ide_controller_32_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(IDE_CONTROLLER_32, ide_controller_32_device) @@ -104,7 +104,7 @@ DECLARE_DEVICE_TYPE(IDE_CONTROLLER_32, ide_controller_32_device) class bus_master_ide_controller_device : public ide_controller_32_device { public: - bus_master_ide_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + bus_master_ide_controller_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> void set_bus_master_space(T &&bmtag, int bmspace) { m_dma_space.set_tag(std::forward<T>(bmtag), bmspace); } template <bool R> void set_bus_master_space(const address_space_finder<R> &finder) { m_dma_space.set_tag(finder); } diff --git a/src/devices/machine/ie15.cpp b/src/devices/machine/ie15.cpp index 603c6034ca9..daacce72812 100644 --- a/src/devices/machine/ie15.cpp +++ b/src/devices/machine/ie15.cpp @@ -39,7 +39,7 @@ #define _PRINT(ch) (std::isprint(ch & 127)?(ch & 127):' ') -ie15_device::ie15_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ie15_device::ie15_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_serial_interface(mconfig, *this) , m_maincpu(*this, "maincpu") @@ -69,7 +69,7 @@ ie15_device::ie15_device(const machine_config &mconfig, device_type type, const { } -ie15_device::ie15_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ie15_device::ie15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ie15_device(mconfig, IE15, tag, owner, clock) { } @@ -517,7 +517,7 @@ void ie15_device::device_reset() m_serial_tx_ready = m_serial_rx_ready = IE_TRUE; set_data_frame(1 /* start bits */, 8 /* data bits */, PARITY_NONE, STOP_BITS_1); // device supports rates from 150 to 9600 baud but null_modem has hardcoded 9600 - set_rate(9600); + set_rate(XTAL::u(9600)); } /* @@ -680,12 +680,12 @@ void ie15_device::ie15core(machine_config &config) config.set_default_layout(layout_ie15); /* Devices */ - IE15_KEYBOARD(config, m_keyboard, 0); + IE15_KEYBOARD(config, m_keyboard); m_keyboard->keyboard_cb().set(FUNC(ie15_device::kbd_put)); m_keyboard->sdv_cb().set(FUNC(ie15_device::kbd_sdv)); SPEAKER(config, "mono").front_center(); - BEEP(config, m_beeper, 2400); + BEEP(config, m_beeper, XTAL::u(2400)); m_beeper->add_route(ALL_OUTPUTS, "mono", 0.15); } diff --git a/src/devices/machine/ie15.h b/src/devices/machine/ie15.h index 89eaf0cfd8b..3687300fbda 100644 --- a/src/devices/machine/ie15.h +++ b/src/devices/machine/ie15.h @@ -36,7 +36,7 @@ INPUT_PORTS_EXTERN(ie15); class ie15_device : public device_t, public device_serial_interface { public: - ie15_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ie15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Interface to a RS232 connection. auto rs232_conn_txd_handler() { return m_rs232_conn_txd_handler.bind(); } @@ -51,7 +51,7 @@ public: DECLARE_WRITE_LINE_MEMBER(update_serial); protected: - ie15_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ie15_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_resolve_objects() override; virtual void device_start() override; diff --git a/src/devices/machine/ie15_kbd.cpp b/src/devices/machine/ie15_kbd.cpp index 169f4be18aa..015633d7dcc 100644 --- a/src/devices/machine/ie15_kbd.cpp +++ b/src/devices/machine/ie15_kbd.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(IE15_KEYBOARD, ie15_keyboard_device, "ie15kbd", "15WWW-97-006 Keyboard") -ie15_keyboard_device::ie15_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ie15_keyboard_device::ie15_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_matrix_keyboard_interface(mconfig, *this, "TERM_LINE0", "TERM_LINE1", "TERM_LINE2", "TERM_LINE3") , m_io_kbdc(*this, "TERM_LINEC") @@ -27,7 +27,7 @@ ie15_keyboard_device::ie15_keyboard_device(const machine_config &mconfig, device { } -ie15_keyboard_device::ie15_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ie15_keyboard_device::ie15_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ie15_keyboard_device(mconfig, IE15_KEYBOARD, tag, owner, clock) { } diff --git a/src/devices/machine/ie15_kbd.h b/src/devices/machine/ie15_kbd.h index 3302bbda8a2..89baf4eccc6 100644 --- a/src/devices/machine/ie15_kbd.h +++ b/src/devices/machine/ie15_kbd.h @@ -31,7 +31,7 @@ public: IE_KB_NR_BIT = 7, }; - ie15_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ie15_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto keyboard_cb() { return m_keyboard_cb.bind(); } auto sdv_cb() { return m_sdv_cb.bind(); } @@ -41,7 +41,7 @@ public: DECLARE_INPUT_CHANGED_MEMBER(dip_changed); protected: - ie15_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ie15_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/machine/im6402.cpp b/src/devices/machine/im6402.cpp index 6a52867bdbd..119d5ff111e 100644 --- a/src/devices/machine/im6402.cpp +++ b/src/devices/machine/im6402.cpp @@ -70,7 +70,7 @@ inline void im6402_device::set_tre(int state) // im6402_device - constructor //------------------------------------------------- -im6402_device::im6402_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +im6402_device::im6402_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IM6402, tag, owner, clock), device_serial_interface(mconfig, *this), m_write_tro(*this), diff --git a/src/devices/machine/im6402.h b/src/devices/machine/im6402.h index d36853353c2..4455e17d993 100644 --- a/src/devices/machine/im6402.h +++ b/src/devices/machine/im6402.h @@ -48,13 +48,13 @@ class im6402_device : public device_t, public device_serial_interface public: // construction/destruction im6402_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t rrc, uint32_t trc) - : im6402_device(mconfig, tag, owner, 0) + : im6402_device(mconfig, tag, owner) { set_rrc(rrc); set_trc(trc); } - im6402_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + im6402_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_rrc(int rrc) { m_rrc = rrc; } void set_trc(int trc) { m_trc = trc; } diff --git a/src/devices/machine/input_merger.cpp b/src/devices/machine/input_merger.cpp index 7424bd6e8fa..a8b9f96e456 100644 --- a/src/devices/machine/input_merger.cpp +++ b/src/devices/machine/input_merger.cpp @@ -110,22 +110,22 @@ TIMER_CALLBACK_MEMBER(input_merger_device::update_state) // SPECIALISATIONS //************************************************************************** -input_merger_any_high_device::input_merger_any_high_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +input_merger_any_high_device::input_merger_any_high_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : input_merger_device(mconfig, INPUT_MERGER_ANY_HIGH, tag, owner, clock, u32(0), u32(0), 1) { } -input_merger_all_high_device::input_merger_all_high_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +input_merger_all_high_device::input_merger_all_high_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : input_merger_device(mconfig, INPUT_MERGER_ALL_HIGH, tag, owner, clock, ~u32(0), ~u32(0), 0) { } -input_merger_any_low_device::input_merger_any_low_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +input_merger_any_low_device::input_merger_any_low_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : input_merger_device(mconfig, INPUT_MERGER_ANY_LOW, tag, owner, clock, ~u32(0), ~u32(0), 1) { } -input_merger_all_low_device::input_merger_all_low_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock) +input_merger_all_low_device::input_merger_all_low_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : input_merger_device(mconfig, INPUT_MERGER_ALL_LOW, tag, owner, clock, u32(0), u32(0), 0) { } diff --git a/src/devices/machine/input_merger.h b/src/devices/machine/input_merger.h index aacffeab4ee..b8098d8d901 100644 --- a/src/devices/machine/input_merger.h +++ b/src/devices/machine/input_merger.h @@ -57,28 +57,28 @@ protected: class input_merger_any_high_device : public input_merger_device { public: - input_merger_any_high_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + input_merger_any_high_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class input_merger_all_high_device : public input_merger_device { public: - input_merger_all_high_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + input_merger_all_high_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class input_merger_any_low_device : public input_merger_device { public: - input_merger_any_low_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + input_merger_any_low_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class input_merger_all_low_device : public input_merger_device { public: - input_merger_all_low_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + input_merger_all_low_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; diff --git a/src/devices/machine/ins8154.cpp b/src/devices/machine/ins8154.cpp index 0ce0dbd11d8..e4d67b1bfbf 100644 --- a/src/devices/machine/ins8154.cpp +++ b/src/devices/machine/ins8154.cpp @@ -46,7 +46,7 @@ DEFINE_DEVICE_TYPE(INS8154, ins8154_device, "ins8154", "INS8154 RAM I/O") // ins8154_device - constructor //------------------------------------------------- -ins8154_device::ins8154_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ins8154_device::ins8154_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, INS8154, tag, owner, clock) , m_in_a_cb(*this) , m_out_a_cb(*this) diff --git a/src/devices/machine/ins8154.h b/src/devices/machine/ins8154.h index b4013c0876d..4e996177a5a 100644 --- a/src/devices/machine/ins8154.h +++ b/src/devices/machine/ins8154.h @@ -39,7 +39,7 @@ class ins8154_device : public device_t { public: // construction/destruction - ins8154_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ins8154_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto in_a() { return m_in_a_cb.bind(); } auto out_a() { return m_out_a_cb.bind(); } diff --git a/src/devices/machine/ins8250.cpp b/src/devices/machine/ins8250.cpp index 63a68550e2d..b17574e710b 100644 --- a/src/devices/machine/ins8250.cpp +++ b/src/devices/machine/ins8250.cpp @@ -107,7 +107,7 @@ DEFINE_DEVICE_TYPE(NS16450, ns16450_device, "ns16450", "National Semiconductor DEFINE_DEVICE_TYPE(NS16550, ns16550_device, "ns16550", "National Semiconductor NS16550 UART") DEFINE_DEVICE_TYPE(PC16552D, pc16552_device, "pc16552d", "National Semiconductor PC16552D UART") -ins8250_uart_device::ins8250_uart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, dev_type device_type) +ins8250_uart_device::ins8250_uart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, dev_type device_type) : device_t(mconfig, type, tag, owner, clock) , device_serial_interface(mconfig, *this) , m_device_type(device_type) @@ -127,22 +127,22 @@ ins8250_uart_device::ins8250_uart_device(const machine_config &mconfig, device_t m_regs.ier = 0; } -ins8250_device::ins8250_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ins8250_device::ins8250_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ins8250_uart_device(mconfig, INS8250, tag, owner, clock, dev_type::INS8250) { } -ns16450_device::ns16450_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ns16450_device::ns16450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ins8250_uart_device(mconfig, NS16450, tag, owner, clock, dev_type::NS16450) { } -ns16550_device::ns16550_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ns16550_device::ns16550_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ins8250_uart_device(mconfig, NS16550, tag, owner, clock, dev_type::NS16550) { } -pc16552_device::pc16552_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pc16552_device::pc16552_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC16552D, tag, owner, clock) { } @@ -643,8 +643,8 @@ void ins8250_uart_device::device_start() m_out_int_cb.resolve_safe(); m_out_out1_cb.resolve_safe(); m_out_out2_cb.resolve_safe(); - set_tra_rate(0); - set_rcv_rate(0); + set_tra_rate(XTAL::u(0)); + set_rcv_rate(XTAL::u(0)); save_item(NAME(m_regs.thr)); save_item(NAME(m_regs.rbr)); diff --git a/src/devices/machine/ins8250.h b/src/devices/machine/ins8250.h index f79715decc3..a6f0f06ce1c 100644 --- a/src/devices/machine/ins8250.h +++ b/src/devices/machine/ins8250.h @@ -46,7 +46,7 @@ protected: NS16550A }; - ins8250_uart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, dev_type device_type); + ins8250_uart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, dev_type device_type); virtual void device_start() override; virtual void device_reset() override; @@ -101,19 +101,19 @@ private: class ins8250_device : public ins8250_uart_device { public: - ins8250_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ins8250_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ns16450_device : public ins8250_uart_device { public: - ns16450_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ns16450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class ns16550_device : public ins8250_uart_device { public: - ns16550_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ns16550_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; virtual void device_reset() override; @@ -139,7 +139,7 @@ private: class pc16552_device : public device_t { public: - pc16552_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pc16552_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 read(offs_t offset) { return ((offset & 8) ? m_chan1 : m_chan0)->ins8250_r(offset & 7); } void write(offs_t offset, u8 data) { ((offset & 8) ? m_chan1 : m_chan0)->ins8250_w(offset & 7, data); } diff --git a/src/devices/machine/intelfsh.cpp b/src/devices/machine/intelfsh.cpp index b4e9c5acde0..068e513ae30 100644 --- a/src/devices/machine/intelfsh.cpp +++ b/src/devices/machine/intelfsh.cpp @@ -133,7 +133,7 @@ DEFINE_DEVICE_TYPE(CAT28F020, cat28f020_device, "cat28f0 // intelfsh_device - constructor //------------------------------------------------- -intelfsh_device::intelfsh_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +intelfsh_device::intelfsh_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock), device_nvram_interface(mconfig, *this), m_region(*this, DEVICE_SELF), @@ -409,130 +409,130 @@ intelfsh_device::intelfsh_device(const machine_config &mconfig, device_type type break; } -intelfsh8_device::intelfsh8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +intelfsh8_device::intelfsh8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : intelfsh_device(mconfig, type, tag, owner, clock, variant) { } -intelfsh16_device::intelfsh16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +intelfsh16_device::intelfsh16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : intelfsh_device(mconfig, type, tag, owner, clock, variant) { } -intel_28f016s5_device::intel_28f016s5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intel_28f016s5_device::intel_28f016s5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, INTEL_28F016S5, tag, owner, clock, FLASH_INTEL_28F016S5) { } -fujitsu_29f160te_device::fujitsu_29f160te_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fujitsu_29f160te_device::fujitsu_29f160te_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, FUJITSU_29F160TE, tag, owner, clock, FLASH_FUJITSU_29F160TE) { } -fujitsu_29f016a_device::fujitsu_29f016a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fujitsu_29f016a_device::fujitsu_29f016a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, FUJITSU_29F016A, tag, owner, clock, FLASH_FUJITSU_29F016A) { } -fujitsu_29dl164bd_device::fujitsu_29dl164bd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fujitsu_29dl164bd_device::fujitsu_29dl164bd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, FUJITSU_29DL164BD, tag, owner, clock, FLASH_FUJITSU_29DL164BD) { } -fujitsu_29lv002tc_device::fujitsu_29lv002tc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fujitsu_29lv002tc_device::fujitsu_29lv002tc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, FUJITSU_29LV002TC, tag, owner, clock, FLASH_FUJITSU_29LV002TC) { } -fujitsu_29lv800b_device::fujitsu_29lv800b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +fujitsu_29lv800b_device::fujitsu_29lv800b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, FUJITSU_29LV800B, tag, owner, clock, FLASH_FUJITSU_29LV800B) { } -sharp_lh28f016s_device::sharp_lh28f016s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sharp_lh28f016s_device::sharp_lh28f016s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, SHARP_LH28F016S, tag, owner, clock, FLASH_SHARP_LH28F016S) { } -sharp_lh28f016s_16bit_device::sharp_lh28f016s_16bit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sharp_lh28f016s_16bit_device::sharp_lh28f016s_16bit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, SHARP_LH28F016S_16BIT, tag, owner, clock, FLASH_SHARP_LH28F016S_16BIT) { } -atmel_29c010_device::atmel_29c010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atmel_29c010_device::atmel_29c010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, ATMEL_29C010, tag, owner, clock, FLASH_ATMEL_29C010) { } -atmel_49f4096_device::atmel_49f4096_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +atmel_49f4096_device::atmel_49f4096_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, ATMEL_49F4096, tag, owner, clock, FLASH_ATMEL_49F4096) { } -amd_29f010_device::amd_29f010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +amd_29f010_device::amd_29f010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, AMD_29F010, tag, owner, clock, FLASH_AMD_29F010) { } -amd_29f040_device::amd_29f040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +amd_29f040_device::amd_29f040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, AMD_29F040, tag, owner, clock, FLASH_AMD_29F040) { } -amd_29f080_device::amd_29f080_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +amd_29f080_device::amd_29f080_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, AMD_29F080, tag, owner, clock, FLASH_AMD_29F080) { } -amd_29f400t_device::amd_29f400t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +amd_29f400t_device::amd_29f400t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, AMD_29F400T, tag, owner, clock, FLASH_AMD_29F400T) { } -amd_29f800t_device::amd_29f800t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +amd_29f800t_device::amd_29f800t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, AMD_29F800T, tag, owner, clock, FLASH_AMD_29F800T) { } -amd_29f800b_16bit_device::amd_29f800b_16bit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +amd_29f800b_16bit_device::amd_29f800b_16bit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, AMD_29F800B_16BIT, tag, owner, clock, FLASH_AMD_29F800B_16BIT) { } -amd_29lv200t_device::amd_29lv200t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +amd_29lv200t_device::amd_29lv200t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, AMD_29LV200T, tag, owner, clock, FLASH_AMD_29LV200T) { } -cat28f020_device::cat28f020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cat28f020_device::cat28f020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, CAT28F020, tag, owner, clock, FLASH_CAT28F020) { } -intel_e28f008sa_device::intel_e28f008sa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intel_e28f008sa_device::intel_e28f008sa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, INTEL_E28F008SA, tag, owner, clock, FLASH_INTEL_E28F008SA) { } -macronix_29f008tc_device::macronix_29f008tc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +macronix_29f008tc_device::macronix_29f008tc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, MACRONIX_29F008TC, tag, owner, clock, FLASH_MACRONIX_29F008TC) { } -macronix_29l001mc_device::macronix_29l001mc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +macronix_29l001mc_device::macronix_29l001mc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, MACRONIX_29L001MC, tag, owner, clock, FLASH_MACRONIX_29L001MC) { } -macronix_29lv160tmc_device::macronix_29lv160tmc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +macronix_29lv160tmc_device::macronix_29lv160tmc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, MACRONIX_29LV160TMC, tag, owner, clock, FLASH_MACRONIX_29LV160TMC) { } -panasonic_mn63f805mnp_device::panasonic_mn63f805mnp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +panasonic_mn63f805mnp_device::panasonic_mn63f805mnp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, PANASONIC_MN63F805MNP, tag, owner, clock, FLASH_PANASONIC_MN63F805MNP) { } -sanyo_le26fv10n1ts_device::sanyo_le26fv10n1ts_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sanyo_le26fv10n1ts_device::sanyo_le26fv10n1ts_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, SANYO_LE26FV10N1TS, tag, owner, clock, FLASH_SANYO_LE26FV10N1TS) { } -sst_28sf040_device::sst_28sf040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sst_28sf040_device::sst_28sf040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, SST_28SF040, tag, owner, clock, FLASH_SST_28SF040) { } -sst_39sf040_device::sst_39sf040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sst_39sf040_device::sst_39sf040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, SST_39SF040, tag, owner, clock, FLASH_SST_39SF040) { } -sst_39vf020_device::sst_39vf020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sst_39vf020_device::sst_39vf020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, SST_39VF020, tag, owner, clock, FLASH_SST_39VF020) { } -sst_49lf020_device::sst_49lf020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sst_49lf020_device::sst_49lf020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, SST_49LF020, tag, owner, clock, FLASH_SST_49LF020) { } -sharp_lh28f400_device::sharp_lh28f400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sharp_lh28f400_device::sharp_lh28f400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, SHARP_LH28F400, tag, owner, clock, FLASH_SHARP_LH28F400) { } -intel_te28f160_device::intel_te28f160_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intel_te28f160_device::intel_te28f160_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, INTEL_TE28F160, tag, owner, clock, FLASH_INTEL_TE28F160) { } -sharp_lh28f160s3_device::sharp_lh28f160s3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sharp_lh28f160s3_device::sharp_lh28f160s3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, SHARP_LH28F160S3, tag, owner, clock, FLASH_SHARP_LH28F160S3) { } -intel_te28f320_device::intel_te28f320_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intel_te28f320_device::intel_te28f320_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, INTEL_TE28F320, tag, owner, clock, FLASH_INTEL_TE28F320) { } -spansion_s29gl064s_device::spansion_s29gl064s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spansion_s29gl064s_device::spansion_s29gl064s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, SPANSION_S29GL064S, tag, owner, clock, FLASH_SPANSION_S29GL064S) { } -intel_e28f400b_device::intel_e28f400b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intel_e28f400b_device::intel_e28f400b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, INTEL_E28F400B, tag, owner, clock, FLASH_INTEL_E28F400B) { } -sharp_lh28f320bf_device::sharp_lh28f320bf_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sharp_lh28f320bf_device::sharp_lh28f320bf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, SHARP_LH28F320BF, tag, owner, clock, FLASH_SHARP_LH28F320BF) { } -intel_28f320j3d_device::intel_28f320j3d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intel_28f320j3d_device::intel_28f320j3d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, INTEL_28F320J3D, tag, owner, clock, FLASH_INTEL_28F320J3D) { } -intel_28f320j5_device::intel_28f320j5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +intel_28f320j5_device::intel_28f320j5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, INTEL_28F320J5, tag, owner, clock, FLASH_INTEL_28F320J5) { } -sst_39vf400a_device::sst_39vf400a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sst_39vf400a_device::sst_39vf400a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh16_device(mconfig, SST_39VF400A, tag, owner, clock, FLASH_SST_39VF400A) { } -tms_29f040_device::tms_29f040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms_29f040_device::tms_29f040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : intelfsh8_device(mconfig, TMS_29F040, tag, owner, clock, FLASH_TMS_29F040) { } //------------------------------------------------- diff --git a/src/devices/machine/intelfsh.h b/src/devices/machine/intelfsh.h index 189d9349d42..1612c0d88e8 100644 --- a/src/devices/machine/intelfsh.h +++ b/src/devices/machine/intelfsh.h @@ -63,7 +63,7 @@ public: protected: // construction/destruction - intelfsh_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + intelfsh_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_start() override; @@ -120,7 +120,7 @@ public: protected: // construction/destruction - intelfsh8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + intelfsh8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); }; @@ -138,7 +138,7 @@ public: protected: // construction/destruction - intelfsh16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + intelfsh16_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); }; @@ -148,103 +148,103 @@ protected: class intel_28f016s5_device : public intelfsh8_device { public: - intel_28f016s5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + intel_28f016s5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class fujitsu_29f160te_device : public intelfsh8_device { public: - fujitsu_29f160te_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + fujitsu_29f160te_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class fujitsu_29f016a_device : public intelfsh8_device { public: - fujitsu_29f016a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + fujitsu_29f016a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class fujitsu_29dl164bd_device : public intelfsh8_device { public: - fujitsu_29dl164bd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + fujitsu_29dl164bd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class fujitsu_29lv002tc_device : public intelfsh8_device { public: - fujitsu_29lv002tc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + fujitsu_29lv002tc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class fujitsu_29lv800b_device : public intelfsh16_device { public: - fujitsu_29lv800b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + fujitsu_29lv800b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class atmel_29c010_device : public intelfsh8_device { public: - atmel_29c010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + atmel_29c010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class amd_29f010_device : public intelfsh8_device { public: - amd_29f010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + amd_29f010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class amd_29f040_device : public intelfsh8_device { public: - amd_29f040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + amd_29f040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class amd_29f080_device : public intelfsh8_device { public: - amd_29f080_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + amd_29f080_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class amd_29f400t_device : public intelfsh8_device { public: - amd_29f400t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + amd_29f400t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class amd_29f800t_device : public intelfsh8_device { public: - amd_29f800t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + amd_29f800t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class amd_29f800b_16bit_device : public intelfsh16_device { public: - amd_29f800b_16bit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + amd_29f800b_16bit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class amd_29lv200t_device : public intelfsh8_device { public: - amd_29lv200t_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + amd_29lv200t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class sharp_lh28f016s_device : public intelfsh8_device { public: - sharp_lh28f016s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sharp_lh28f016s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class sharp_lh28f016s_16bit_device : public intelfsh16_device { public: - sharp_lh28f016s_16bit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sharp_lh28f016s_16bit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class intel_e28f008sa_device : public intelfsh8_device { public: - intel_e28f008sa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + intel_e28f008sa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class macronix_29f008tc_device : public intelfsh8_device @@ -256,128 +256,128 @@ public: class macronix_29l001mc_device : public intelfsh8_device { public: - macronix_29l001mc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + macronix_29l001mc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class macronix_29lv160tmc_device : public intelfsh8_device { public: - macronix_29lv160tmc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + macronix_29lv160tmc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class panasonic_mn63f805mnp_device : public intelfsh8_device { public: - panasonic_mn63f805mnp_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + panasonic_mn63f805mnp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class sanyo_le26fv10n1ts_device : public intelfsh8_device { public: - sanyo_le26fv10n1ts_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sanyo_le26fv10n1ts_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class sst_28sf040_device : public intelfsh8_device { public: - sst_28sf040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sst_28sf040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class sst_39sf040_device : public intelfsh8_device { public: - sst_39sf040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sst_39sf040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class sst_39vf020_device : public intelfsh8_device { public: - sst_39vf020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sst_39vf020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class sst_49lf020_device : public intelfsh8_device { public: - sst_49lf020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sst_49lf020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class tms_29f040_device : public intelfsh8_device { public: - tms_29f040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + tms_29f040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // 16-bit variants class sharp_lh28f400_device : public intelfsh16_device { public: - sharp_lh28f400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sharp_lh28f400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class intel_te28f160_device : public intelfsh16_device { public: - intel_te28f160_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + intel_te28f160_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class sharp_lh28f160s3_device : public intelfsh16_device { public: - sharp_lh28f160s3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sharp_lh28f160s3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class intel_te28f320_device : public intelfsh16_device { public: - intel_te28f320_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + intel_te28f320_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class spansion_s29gl064s_device : public intelfsh16_device { public: - spansion_s29gl064s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + spansion_s29gl064s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class intel_e28f400b_device : public intelfsh16_device { public: - intel_e28f400b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + intel_e28f400b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class sharp_lh28f320bf_device : public intelfsh16_device { public: - sharp_lh28f320bf_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sharp_lh28f320bf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class intel_28f320j3d_device : public intelfsh16_device { public: - intel_28f320j3d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + intel_28f320j3d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class intel_28f320j5_device : public intelfsh16_device { public: - intel_28f320j5_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + intel_28f320j5_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class sst_39vf400a_device : public intelfsh16_device { public: - sst_39vf400a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sst_39vf400a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class atmel_49f4096_device : public intelfsh16_device { public: - atmel_49f4096_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + atmel_49f4096_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class cat28f020_device : public intelfsh8_device { public: - cat28f020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + cat28f020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; diff --git a/src/devices/machine/iopcdvd.cpp b/src/devices/machine/iopcdvd.cpp index a2938c4be35..3ab5d8dee52 100644 --- a/src/devices/machine/iopcdvd.cpp +++ b/src/devices/machine/iopcdvd.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(SONYIOP_CDVD, iop_cdvd_device, "iopcdvd", "PlayStation 2 disc /*static*/ const size_t iop_cdvd_device::BUFFER_SIZE = 16; // Total guess -iop_cdvd_device::iop_cdvd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iop_cdvd_device::iop_cdvd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYIOP_CDVD, tag, owner, clock) , m_intc(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/machine/iopcdvd.h b/src/devices/machine/iopcdvd.h index 194933eb3d9..15717da7612 100644 --- a/src/devices/machine/iopcdvd.h +++ b/src/devices/machine/iopcdvd.h @@ -21,12 +21,12 @@ class iop_cdvd_device : public device_t public: template <typename T> iop_cdvd_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&intc_tag) - : iop_cdvd_device(mconfig, tag, owner, (uint32_t)0) + : iop_cdvd_device(mconfig, tag, owner) { m_intc.set_tag(std::forward<T>(intc_tag)); } - iop_cdvd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iop_cdvd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~iop_cdvd_device() override; uint8_t read(offs_t offset); diff --git a/src/devices/machine/iopdma.cpp b/src/devices/machine/iopdma.cpp index 784bc16b515..cc9d0ad9603 100644 --- a/src/devices/machine/iopdma.cpp +++ b/src/devices/machine/iopdma.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(SONYIOP_DMA, iop_dma_device, "iopdma", "PlayStation 2 IOP DMAC") -iop_dma_device::iop_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iop_dma_device::iop_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYIOP_DMA, tag, owner, clock) , device_execute_interface(mconfig, *this) , m_intc(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/iopdma.h b/src/devices/machine/iopdma.h index 2e84ec44aaa..7bc7252c1de 100644 --- a/src/devices/machine/iopdma.h +++ b/src/devices/machine/iopdma.h @@ -23,7 +23,7 @@ class iop_dma_device : public device_t, public device_execute_interface { public: template <typename T, typename U, typename V, typename W, typename X> - iop_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&intc_tag, U &&ram_tag, V &&sif_tag, W &&spu_tag, X &&sio2_tag) + iop_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&intc_tag, U &&ram_tag, V &&sif_tag, W &&spu_tag, X &&sio2_tag) : iop_dma_device(mconfig, tag, owner, clock) { m_intc.set_tag(std::forward<T>(intc_tag)); @@ -33,7 +33,7 @@ public: m_sio2.set_tag(std::forward<X>(sio2_tag)); } - iop_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iop_dma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~iop_dma_device() override; uint32_t bank0_r(offs_t offset, uint32_t mem_mask = ~0); diff --git a/src/devices/machine/iopintc.cpp b/src/devices/machine/iopintc.cpp index 15e57e00608..373b6a3e774 100644 --- a/src/devices/machine/iopintc.cpp +++ b/src/devices/machine/iopintc.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(SONYIOP_INTC, iop_intc_device, "iopintc", "PlayStation 2 IOP INTC") -iop_intc_device::iop_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iop_intc_device::iop_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYIOP_INTC, tag, owner, clock) , m_iop(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/machine/iopintc.h b/src/devices/machine/iopintc.h index 5ead2c505fe..c41c61ff6fd 100644 --- a/src/devices/machine/iopintc.h +++ b/src/devices/machine/iopintc.h @@ -21,12 +21,12 @@ class iop_intc_device : public device_t public: template <typename T> iop_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&iop_tag) - : iop_intc_device(mconfig, tag, owner, (uint32_t)0) + : iop_intc_device(mconfig, tag, owner) { m_iop.set_tag(std::forward<T>(iop_tag)); } - iop_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iop_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~iop_intc_device() override; uint32_t read(offs_t offset, uint32_t mem_mask = ~0); diff --git a/src/devices/machine/iopsio2.cpp b/src/devices/machine/iopsio2.cpp index c5b6de09546..84a60623e57 100644 --- a/src/devices/machine/iopsio2.cpp +++ b/src/devices/machine/iopsio2.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(SONYIOP_SIO2, iop_sio2_device, "iopsio2", "PlayStation 2 IOP /*static*/ const size_t iop_sio2_device::BUFFER_SIZE = 512; // total guess based on memcard block size -iop_sio2_device::iop_sio2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iop_sio2_device::iop_sio2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYIOP_SIO2, tag, owner, clock) , m_intc(*this, finder_base::DUMMY_TAG) , m_pad0(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/iopsio2.h b/src/devices/machine/iopsio2.h index 67fc395b6f3..7192b7efe2a 100644 --- a/src/devices/machine/iopsio2.h +++ b/src/devices/machine/iopsio2.h @@ -23,7 +23,7 @@ class iop_sio2_device : public device_t public: template <typename T, typename U, typename V, typename W> iop_sio2_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&intc_tag, U &&pad0_tag, V &&pad1_tag, W &&mc0_tag) - : iop_sio2_device(mconfig, tag, owner, (uint32_t)0) + : iop_sio2_device(mconfig, tag, owner) { m_intc.set_tag(std::forward<T>(intc_tag)); m_pad0.set_tag(std::forward<U>(pad0_tag)); @@ -31,7 +31,7 @@ public: m_mc0.set_tag(std::forward<W>(mc0_tag)); } - iop_sio2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iop_sio2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~iop_sio2_device() override; uint32_t read(offs_t offset, uint32_t mem_mask = ~0); diff --git a/src/devices/machine/ioptimer.cpp b/src/devices/machine/ioptimer.cpp index 54864a00901..292922132f1 100644 --- a/src/devices/machine/ioptimer.cpp +++ b/src/devices/machine/ioptimer.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(SONYIOP_TIMER, iop_timer_device, "ioptimer", "PlayStation 2 IOP timer") -iop_timer_device::iop_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iop_timer_device::iop_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYIOP_TIMER, tag, owner, clock) , m_compare_timer(nullptr) , m_overflow_timer(nullptr) diff --git a/src/devices/machine/ioptimer.h b/src/devices/machine/ioptimer.h index a7c4891b9dc..2cf4ca928e5 100644 --- a/src/devices/machine/ioptimer.h +++ b/src/devices/machine/ioptimer.h @@ -17,7 +17,7 @@ class iop_timer_device : public device_t { public: - iop_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iop_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq() { return m_int_cb.bind(); } diff --git a/src/devices/machine/iwm.cpp b/src/devices/machine/iwm.cpp index b52c01eec83..1db70c91ecb 100644 --- a/src/devices/machine/iwm.cpp +++ b/src/devices/machine/iwm.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(IWM, iwm_device, "iwm", "Apple IWM floppy controller") -iwm_device::iwm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t q3_clock) : +iwm_device::iwm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t q3_clock) : applefdintf_device(mconfig, IWM, tag, owner, clock), m_floppy(nullptr), m_q3_clock(q3_clock) diff --git a/src/devices/machine/iwm.h b/src/devices/machine/iwm.h index 73045890d0d..c24d2677c06 100644 --- a/src/devices/machine/iwm.h +++ b/src/devices/machine/iwm.h @@ -22,8 +22,8 @@ class iwm_device: public applefdintf_device { public: // construction/destruction - iwm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t q3_clock = 0); - iwm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, XTAL q3_clock) : + iwm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t q3_clock = 0); + iwm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, XTAL q3_clock) : iwm_device(mconfig, tag, owner, clock, q3_clock.value()) {} virtual u8 read(offs_t offset) override; diff --git a/src/devices/machine/jvsdev.cpp b/src/devices/machine/jvsdev.cpp index f55a836cd01..650c98e279e 100644 --- a/src/devices/machine/jvsdev.cpp +++ b/src/devices/machine/jvsdev.cpp @@ -3,7 +3,7 @@ #include "emu.h" #include "jvsdev.h" -jvs_device::jvs_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +jvs_device::jvs_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), jvs_outputs(0), host(*this, finder_base::DUMMY_TAG), jvs_address(0), jvs_reset_counter(0) { next_device = nullptr; diff --git a/src/devices/machine/jvsdev.h b/src/devices/machine/jvsdev.h index f7dba299c97..768cd30ef40 100644 --- a/src/devices/machine/jvsdev.h +++ b/src/devices/machine/jvsdev.h @@ -19,7 +19,7 @@ protected: void handle_output(ioport_port *port, uint8_t id, uint8_t val); - jvs_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + jvs_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/machine/jvshost.cpp b/src/devices/machine/jvshost.cpp index 1f720b4fa00..75e4f49a8d1 100644 --- a/src/devices/machine/jvshost.cpp +++ b/src/devices/machine/jvshost.cpp @@ -29,7 +29,7 @@ void jvs_host::device_reset() memset(recv_buffer, 0, sizeof(recv_buffer)); } -jvs_host::jvs_host(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +jvs_host::jvs_host(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), send_size(0), recv_size(0), recv_is_encoded(false) { first_device = nullptr; diff --git a/src/devices/machine/jvshost.h b/src/devices/machine/jvshost.h index c0f8429a1a3..674bdb0afbc 100644 --- a/src/devices/machine/jvshost.h +++ b/src/devices/machine/jvshost.h @@ -13,7 +13,7 @@ public: void add_device(jvs_device *dev); protected: - jvs_host(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + jvs_host(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/machine/k033906.cpp b/src/devices/machine/k033906.cpp index 5ffad3b74eb..d0afff12b2d 100644 --- a/src/devices/machine/k033906.cpp +++ b/src/devices/machine/k033906.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(K033906, k033906_device, "k033906", "K033906 PCI bridge") // k033906_device - constructor //------------------------------------------------- -k033906_device::k033906_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +k033906_device::k033906_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K033906, tag, owner, clock) , m_reg_set(0) , m_voodoo(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/k033906.h b/src/devices/machine/k033906.h index 21187ad0541..8cae9f3c46e 100644 --- a/src/devices/machine/k033906.h +++ b/src/devices/machine/k033906.h @@ -18,13 +18,13 @@ class k033906_device : public device_t public: // construction/destruction template <typename T> - k033906_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&voodoo_tag) - : k033906_device(mconfig, tag, owner, clock) + k033906_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&voodoo_tag) + : k033906_device(mconfig, tag, owner) { m_voodoo.set_tag(std::forward<T>(voodoo_tag)); } - k033906_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + k033906_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); u32 read(offs_t offset); void write(offs_t offset, u32 data); diff --git a/src/devices/machine/k053252.cpp b/src/devices/machine/k053252.cpp index 6972d0f5c96..f08dc1f71d8 100644 --- a/src/devices/machine/k053252.cpp +++ b/src/devices/machine/k053252.cpp @@ -65,7 +65,7 @@ TODO: DEFINE_DEVICE_TYPE(K053252, k053252_device, "k053252", "K053252 Timing/Interrupt Controller") -k053252_device::k053252_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +k053252_device::k053252_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K053252, tag, owner, clock) , device_video_interface(mconfig, *this) , m_int1_en_cb(*this) diff --git a/src/devices/machine/k053252.h b/src/devices/machine/k053252.h index fec683df1da..f40442682d4 100644 --- a/src/devices/machine/k053252.h +++ b/src/devices/machine/k053252.h @@ -12,7 +12,7 @@ class k053252_device : public device_t, public device_video_interface { public: - k053252_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + k053252_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto int1_en() { return m_int1_en_cb.bind(); } auto int2_en() { return m_int2_en_cb.bind(); } diff --git a/src/devices/machine/k054321.cpp b/src/devices/machine/k054321.cpp index 6a362f655b2..b9404d056b2 100644 --- a/src/devices/machine/k054321.cpp +++ b/src/devices/machine/k054321.cpp @@ -57,7 +57,7 @@ void k054321_device::sound_map(address_map &map) map(0x3, 0x3).r(m_soundlatch[1], FUNC(generic_latch_8_device::read)); } -k054321_device::k054321_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +k054321_device::k054321_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K054321, tag, owner, clock), m_left(*this, finder_base::DUMMY_TAG), m_right(*this, finder_base::DUMMY_TAG), diff --git a/src/devices/machine/k054321.h b/src/devices/machine/k054321.h index 6c66659372d..450001659bc 100644 --- a/src/devices/machine/k054321.h +++ b/src/devices/machine/k054321.h @@ -13,13 +13,13 @@ class k054321_device : public device_t public: template<typename T, typename U> k054321_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&left, U &&right) : - k054321_device(mconfig, tag, owner, 0) + k054321_device(mconfig, tag, owner) { m_left.set_tag(std::forward<T>(left)); m_right.set_tag(std::forward<U>(right)); } - k054321_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + k054321_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void main_map(address_map &map); void sound_map(address_map &map); diff --git a/src/devices/machine/k056230.cpp b/src/devices/machine/k056230.cpp index 7a401c83def..176667e7680 100644 --- a/src/devices/machine/k056230.cpp +++ b/src/devices/machine/k056230.cpp @@ -33,7 +33,7 @@ TODO: nearly everything DEFINE_DEVICE_TYPE(K056230, k056230_device, "k056230", "K056230 LANC") -k056230_device::k056230_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +k056230_device::k056230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K056230, tag, owner, clock) , m_ram(*this, "lanc_ram", 0x800U * 4, ENDIANNESS_BIG) , m_irq_cb(*this) diff --git a/src/devices/machine/k056230.h b/src/devices/machine/k056230.h index 7df76c26e53..18cc46ec3fc 100644 --- a/src/devices/machine/k056230.h +++ b/src/devices/machine/k056230.h @@ -15,7 +15,7 @@ class k056230_device : public device_t { public: // construction/destruction - k056230_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + k056230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto irq_cb() { return m_irq_cb.bind(); } diff --git a/src/devices/machine/kb3600.cpp b/src/devices/machine/kb3600.cpp index 9be5846e0c8..290b98e758b 100644 --- a/src/devices/machine/kb3600.cpp +++ b/src/devices/machine/kb3600.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(AY3600, ay3600_device, "ay3600", "AY-5-3600 Keyboard Encoder" // ay3600_device - constructor //------------------------------------------------- -ay3600_device::ay3600_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ay3600_device::ay3600_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AY3600, tag, owner, clock), m_read_x0(*this), m_read_x1(*this), diff --git a/src/devices/machine/kb3600.h b/src/devices/machine/kb3600.h index c65bbea3a6f..c1a663c2f5c 100644 --- a/src/devices/machine/kb3600.h +++ b/src/devices/machine/kb3600.h @@ -60,7 +60,7 @@ class ay3600_device : public device_t { public: // construction/destruction - ay3600_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ay3600_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // public interface uint16_t b_r(); diff --git a/src/devices/machine/keyboard.cpp b/src/devices/machine/keyboard.cpp index eac7263c82c..b11e6c6f6cd 100644 --- a/src/devices/machine/keyboard.cpp +++ b/src/devices/machine/keyboard.cpp @@ -11,7 +11,7 @@ Example of usage in a driver. In the machine config function: - generic_keyboard_device &kbd(GENERIC_KEYBOARD(config, KEYBOARD_TAG, 0)); + generic_keyboard_device &kbd(GENERIC_KEYBOARD(config, KEYBOARD_TAG)); kbd.set_keyboard_callback(FUNC(xxx_state::kbd_put)); In the code: @@ -251,7 +251,7 @@ generic_keyboard_device::generic_keyboard_device( device_type type, char const *tag, device_t *owner, - u32 clock) + const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_matrix_keyboard_interface(mconfig, *this, "GENKBD_ROW0", "GENKBD_ROW1", "GENKBD_ROW2", "GENKBD_ROW3") , m_config(*this, "GENKBD_CFG") @@ -262,7 +262,7 @@ generic_keyboard_device::generic_keyboard_device( } -generic_keyboard_device::generic_keyboard_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +generic_keyboard_device::generic_keyboard_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : generic_keyboard_device(mconfig, GENERIC_KEYBOARD, tag, owner, clock) { } diff --git a/src/devices/machine/keyboard.h b/src/devices/machine/keyboard.h index 2b4f32e856f..e2364eef3a6 100644 --- a/src/devices/machine/keyboard.h +++ b/src/devices/machine/keyboard.h @@ -77,7 +77,7 @@ public: const machine_config &mconfig, const char *tag, device_t *owner, - u32 clock); + const XTAL &clock); template <typename... T> void set_keyboard_callback(T &&... args) @@ -93,7 +93,7 @@ protected: device_type type, char const *tag, device_t *owner, - u32 clock); + const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; virtual void key_make(u8 row, u8 column) override; diff --git a/src/devices/machine/kr1601rr1.cpp b/src/devices/machine/kr1601rr1.cpp index 561d3f212db..a88a73eab91 100644 --- a/src/devices/machine/kr1601rr1.cpp +++ b/src/devices/machine/kr1601rr1.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(KR1601RR1, kr1601rr1_device, "kr1601rr1", "KR1601RR1 EAROM") // ctor //------------------------------------------------- -kr1601rr1_device::kr1601rr1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kr1601rr1_device::kr1601rr1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, KR1601RR1, tag, owner, clock) , device_nvram_interface(mconfig, *this) { diff --git a/src/devices/machine/kr1601rr1.h b/src/devices/machine/kr1601rr1.h index 49837e42c32..41b71e2201c 100644 --- a/src/devices/machine/kr1601rr1.h +++ b/src/devices/machine/kr1601rr1.h @@ -43,7 +43,7 @@ class kr1601rr1_device : public device_t, public device_nvram_interface { public: // construction/destruction - kr1601rr1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kr1601rr1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/machine/kr2376.cpp b/src/devices/machine/kr2376.cpp index af0abb4169d..f3bf0b860b5 100644 --- a/src/devices/machine/kr2376.cpp +++ b/src/devices/machine/kr2376.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(KR2376_ST, kr2376_st_device, "kr2376_st", "SMC KR2376-ST Keyboard Encoder") DEFINE_DEVICE_TYPE(KR2376_12, kr2376_12_device, "kr2376_12", "SMC KR2376-12 Keyboard Encoder") -kr2376_device::kr2376_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +kr2376_device::kr2376_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_read_x(*this), m_read_shift(*this), @@ -22,7 +22,7 @@ kr2376_device::kr2376_device(const machine_config &mconfig, device_type type, co { } -kr2376_st_device::kr2376_st_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kr2376_st_device::kr2376_st_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kr2376_device(mconfig, KR2376_ST, tag, owner, clock) { } @@ -85,7 +85,7 @@ uint8_t kr2376_st_device::key_codes(int mode, int x, int y) return KEY_CODES[mode][x][y]; } -kr2376_12_device::kr2376_12_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +kr2376_12_device::kr2376_12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : kr2376_device(mconfig, KR2376_12, tag, owner, clock) { } diff --git a/src/devices/machine/kr2376.h b/src/devices/machine/kr2376.h index 2345ade8c5e..4f7fc9cc739 100644 --- a/src/devices/machine/kr2376.h +++ b/src/devices/machine/kr2376.h @@ -52,7 +52,7 @@ public: KR2376_PO=7 /* PO - Pin 7 - Parity Output */ }; - kr2376_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + kr2376_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); template <unsigned N> auto x() { return m_read_x[N].bind(); } auto shift() { return m_read_shift.bind(); } @@ -101,7 +101,7 @@ private: class kr2376_st_device : public kr2376_device { public: - kr2376_st_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kr2376_st_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual uint8_t key_codes(int mode, int x, int y) override; }; @@ -109,7 +109,7 @@ protected: class kr2376_12_device : public kr2376_device { public: - kr2376_12_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kr2376_12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual uint8_t key_codes(int mode, int x, int y) override; }; diff --git a/src/devices/machine/laserdsc.cpp b/src/devices/machine/laserdsc.cpp index 4184e3e7677..2d572b162ce 100644 --- a/src/devices/machine/laserdsc.cpp +++ b/src/devices/machine/laserdsc.cpp @@ -62,7 +62,7 @@ ALLOW_SAVE_TYPE(laserdisc_device::slider_position); // laserdisc_device - constructor //------------------------------------------------- -laserdisc_device::laserdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +laserdisc_device::laserdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_sound_interface(mconfig, *this), device_video_interface(mconfig, *this), @@ -332,7 +332,7 @@ void laserdisc_device::device_stop() void laserdisc_device::device_reset() { // attempt to wire up the audio - m_stream->set_sample_rate(m_samplerate); + m_stream->set_sample_rate(XTAL::u(m_samplerate)); // set up the general ld m_audiosquelch = 3; @@ -856,7 +856,7 @@ void laserdisc_device::init_audio() m_audio_callback.resolve(); // allocate a stream - m_stream = stream_alloc(0, 2, 48000); + m_stream = stream_alloc(0, 2, XTAL::u(48000)); // allocate audio buffers m_audiomaxsamples = ((uint64_t)m_samplerate * 1000000 + m_fps_times_1million - 1) / m_fps_times_1million; diff --git a/src/devices/machine/laserdsc.h b/src/devices/machine/laserdsc.h index abc536a3be0..eaaeb8f1de1 100644 --- a/src/devices/machine/laserdsc.h +++ b/src/devices/machine/laserdsc.h @@ -101,7 +101,7 @@ public: typedef device_delegate<chd_file *(void)> get_disc_delegate; typedef device_delegate<void (int samplerate, int samples, const int16_t *ch0, const int16_t *ch1)> audio_delegate; - laserdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + laserdisc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // use these to add laserdisc screens with proper video update parameters // TODO: actually move these SCREEN_RAW_PARAMS to a common screen info header diff --git a/src/devices/machine/latch8.cpp b/src/devices/machine/latch8.cpp index bfccdc48a30..4c91c81ec64 100644 --- a/src/devices/machine/latch8.cpp +++ b/src/devices/machine/latch8.cpp @@ -99,7 +99,7 @@ void latch8_device::bit7_w(offs_t offset, uint8_t data) { bitx_w<7>(offset, data DEFINE_DEVICE_TYPE(LATCH8, latch8_device, "latch8", "8-bit latch") -latch8_device::latch8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +latch8_device::latch8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LATCH8, tag, owner, clock) , m_write_cb(*this) , m_read_cb(*this) diff --git a/src/devices/machine/latch8.h b/src/devices/machine/latch8.h index 0609d3949ff..0fb58c14d5e 100644 --- a/src/devices/machine/latch8.h +++ b/src/devices/machine/latch8.h @@ -22,7 +22,7 @@ class latch8_device : public device_t { public: - latch8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + latch8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // Write bit to discrete node template <unsigned N> auto write_cb() { return m_write_cb[N].bind(); } diff --git a/src/devices/machine/lc89510.cpp b/src/devices/machine/lc89510.cpp index 649dc01ea8d..7b24e58dc1e 100644 --- a/src/devices/machine/lc89510.cpp +++ b/src/devices/machine/lc89510.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(LC89510, lc89510_device, "lc89510", "LC89510 CD Controller") -lc89510_device::lc89510_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lc89510_device::lc89510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LC89510, tag, owner, clock) { } diff --git a/src/devices/machine/lc89510.h b/src/devices/machine/lc89510.h index 4282654136c..956d55c65a9 100644 --- a/src/devices/machine/lc89510.h +++ b/src/devices/machine/lc89510.h @@ -8,7 +8,7 @@ class lc89510_device : public device_t { public: - lc89510_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + lc89510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/ldp1000.cpp b/src/devices/machine/ldp1000.cpp index 42f8cb796fe..04aa4e23bcf 100644 --- a/src/devices/machine/ldp1000.cpp +++ b/src/devices/machine/ldp1000.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(SONY_LDP1000, sony_ldp1000_device, "ldp1000", "Sony LDP-1000" // sony_ldp1000_device - constructor //------------------------------------------------- -sony_ldp1000_device::sony_ldp1000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sony_ldp1000_device::sony_ldp1000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : laserdisc_device(mconfig, SONY_LDP1000, tag, owner, clock) { } diff --git a/src/devices/machine/ldp1000.h b/src/devices/machine/ldp1000.h index 2fd79a6a6fc..c112d6cd9c2 100644 --- a/src/devices/machine/ldp1000.h +++ b/src/devices/machine/ldp1000.h @@ -27,7 +27,7 @@ class sony_ldp1000_device : public laserdisc_device { public: // construction/destruction - sony_ldp1000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sony_ldp1000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations TODO: both actually protected void command_w(uint8_t data); diff --git a/src/devices/machine/ldp1450.cpp b/src/devices/machine/ldp1450.cpp index 2b4d037cab4..2069ec78b92 100644 --- a/src/devices/machine/ldp1450.cpp +++ b/src/devices/machine/ldp1450.cpp @@ -46,7 +46,7 @@ DEFINE_DEVICE_TYPE(SONY_LDP1450, sony_ldp1450_device, "ldp1450", "Sony LDP-1450" // sony_ldp1450_device - constructor //------------------------------------------------- -sony_ldp1450_device::sony_ldp1450_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sony_ldp1450_device::sony_ldp1450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : laserdisc_device(mconfig, SONY_LDP1450, tag, owner, clock) { } diff --git a/src/devices/machine/ldp1450.h b/src/devices/machine/ldp1450.h index 67a429845e1..e57f34096a3 100644 --- a/src/devices/machine/ldp1450.h +++ b/src/devices/machine/ldp1450.h @@ -27,7 +27,7 @@ class sony_ldp1450_device : public laserdisc_device { public: // construction/destruction - sony_ldp1450_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sony_ldp1450_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations TODO: both actually protected void command_w(uint8_t data); diff --git a/src/devices/machine/ldpr8210.cpp b/src/devices/machine/ldpr8210.cpp index a51d84b19ea..df6c3bb4661 100644 --- a/src/devices/machine/ldpr8210.cpp +++ b/src/devices/machine/ldpr8210.cpp @@ -168,12 +168,12 @@ ROM_END // pioneer_pr8210_device - constructor //------------------------------------------------- -pioneer_pr8210_device::pioneer_pr8210_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pioneer_pr8210_device::pioneer_pr8210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pioneer_pr8210_device(mconfig, PIONEER_PR8210, tag, owner, clock) { } -pioneer_pr8210_device::pioneer_pr8210_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pioneer_pr8210_device::pioneer_pr8210_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : laserdisc_device(mconfig, type, tag, owner, clock), m_audio1(*this, "pr8210_audio1"), m_audio2(*this, "pr8210_audio2"), @@ -884,7 +884,7 @@ ROM_END // simutrek_special_device - constructor //------------------------------------------------- -simutrek_special_device::simutrek_special_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +simutrek_special_device::simutrek_special_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pioneer_pr8210_device(mconfig, SIMUTREK_SPECIAL, tag, owner, clock), m_i8748_cpu(*this, "simutrek"), m_audio_squelch(0), diff --git a/src/devices/machine/ldpr8210.h b/src/devices/machine/ldpr8210.h index 4bc4615c03c..822ca332830 100644 --- a/src/devices/machine/ldpr8210.h +++ b/src/devices/machine/ldpr8210.h @@ -38,13 +38,13 @@ class pioneer_pr8210_device : public laserdisc_device { public: // construction/destruction - pioneer_pr8210_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pioneer_pr8210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // input and output void control_w(uint8_t data); protected: - pioneer_pr8210_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pioneer_pr8210_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -139,7 +139,7 @@ class simutrek_special_device : public pioneer_pr8210_device { public: // construction/destruction - simutrek_special_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + simutrek_special_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // input and output void data_w(uint8_t data); diff --git a/src/devices/machine/ldstub.cpp b/src/devices/machine/ldstub.cpp index c0c9a7ac05a..38d5560d67a 100644 --- a/src/devices/machine/ldstub.cpp +++ b/src/devices/machine/ldstub.cpp @@ -21,13 +21,13 @@ DEFINE_DEVICE_TYPE(PIONEER_PR7820, pioneer_pr7820_device, "pr7820", "Pioneer DEFINE_DEVICE_TYPE(PHILIPS_22VP932, philips_22vp932_device, "22vp932", "Philips 22VP932") -pioneer_pr7820_device::pioneer_pr7820_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pioneer_pr7820_device::pioneer_pr7820_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : laserdisc_device(mconfig, PIONEER_PR7820, tag, owner, clock) { } -philips_22vp932_device::philips_22vp932_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +philips_22vp932_device::philips_22vp932_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : laserdisc_device(mconfig, PHILIPS_22VP932, tag, owner, clock) { } diff --git a/src/devices/machine/ldstub.h b/src/devices/machine/ldstub.h index 9fbc756b240..931ee29d600 100644 --- a/src/devices/machine/ldstub.h +++ b/src/devices/machine/ldstub.h @@ -35,7 +35,7 @@ class pioneer_pr7820_device : public laserdisc_device { public: // construction/destruction - pioneer_pr7820_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pioneer_pr7820_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // input/output uint8_t data_available_r() { return CLEAR_LINE; } @@ -58,7 +58,7 @@ class philips_22vp932_device : public laserdisc_device { public: // construction/destruction - philips_22vp932_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + philips_22vp932_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // input/output uint8_t data_r() { return 0; } diff --git a/src/devices/machine/ldv1000.cpp b/src/devices/machine/ldv1000.cpp index 2f382271aaf..82fd1663439 100644 --- a/src/devices/machine/ldv1000.cpp +++ b/src/devices/machine/ldv1000.cpp @@ -101,7 +101,7 @@ ROM_END // pioneer_ldv1000_device - constructor //------------------------------------------------- -pioneer_ldv1000_device::pioneer_ldv1000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pioneer_ldv1000_device::pioneer_ldv1000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : laserdisc_device(mconfig, PIONEER_LDV1000, tag, owner, clock), m_z80_cpu(*this, "ldv1000"), m_z80_ctc(*this, "ldvctc"), diff --git a/src/devices/machine/ldv1000.h b/src/devices/machine/ldv1000.h index a4ffa12f5b2..7402a68f7b9 100644 --- a/src/devices/machine/ldv1000.h +++ b/src/devices/machine/ldv1000.h @@ -39,7 +39,7 @@ class pioneer_ldv1000_device : public laserdisc_device { public: // construction/destruction - pioneer_ldv1000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pioneer_ldv1000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto command_strobe_callback() { return m_command_strobe_cb.bind(); } diff --git a/src/devices/machine/ldv4200hle.cpp b/src/devices/machine/ldv4200hle.cpp index 577e236fa63..5df5f6965b5 100644 --- a/src/devices/machine/ldv4200hle.cpp +++ b/src/devices/machine/ldv4200hle.cpp @@ -65,7 +65,7 @@ DEFINE_DEVICE_TYPE(PIONEER_LDV4200HLE, pioneer_ldv4200hle_device, "ldv4200hle", // pioneer_ldv4200hle_device - constructor //------------------------------------------------- -pioneer_ldv4200hle_device::pioneer_ldv4200hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pioneer_ldv4200hle_device::pioneer_ldv4200hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : laserdisc_device(mconfig, PIONEER_LDV4200HLE, tag, owner, clock) , device_serial_interface(mconfig, *this) , m_serial_tx(*this) diff --git a/src/devices/machine/ldv4200hle.h b/src/devices/machine/ldv4200hle.h index c7ee5738e2a..cf0f77989b8 100644 --- a/src/devices/machine/ldv4200hle.h +++ b/src/devices/machine/ldv4200hle.h @@ -46,7 +46,7 @@ class pioneer_ldv4200hle_device : public laserdisc_device, public device_serial_ { public: // construction/destruction - pioneer_ldv4200hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pioneer_ldv4200hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto serial_tx() { return m_serial_tx.bind(); } diff --git a/src/devices/machine/ldvp931.cpp b/src/devices/machine/ldvp931.cpp index 012d23591fb..3a6ee4f2709 100644 --- a/src/devices/machine/ldvp931.cpp +++ b/src/devices/machine/ldvp931.cpp @@ -77,7 +77,7 @@ ROM_END // philips_22vp931_device - constructor //------------------------------------------------- -philips_22vp931_device::philips_22vp931_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +philips_22vp931_device::philips_22vp931_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : laserdisc_device(mconfig, PHILIPS_22VP931, tag, owner, clock), m_i8049_cpu(*this, "vp931"), m_process_vbi_timer(nullptr), diff --git a/src/devices/machine/ldvp931.h b/src/devices/machine/ldvp931.h index cffc81cc9dc..7a7aea09875 100644 --- a/src/devices/machine/ldvp931.h +++ b/src/devices/machine/ldvp931.h @@ -40,7 +40,7 @@ public: typedef delegate<void (philips_22vp931_device &, int)> data_ready_delegate; // construction/destruction - philips_22vp931_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + philips_22vp931_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // input and output void data_w(uint8_t data) { machine().scheduler().synchronize(timer_expired_delegate(FUNC(philips_22vp931_device::process_deferred_data), this), data); } diff --git a/src/devices/machine/legscsi.cpp b/src/devices/machine/legscsi.cpp index c379c797f73..1807fc684c0 100644 --- a/src/devices/machine/legscsi.cpp +++ b/src/devices/machine/legscsi.cpp @@ -3,7 +3,7 @@ #include "emu.h" #include "legscsi.h" -legacy_scsi_host_adapter::legacy_scsi_host_adapter(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +legacy_scsi_host_adapter::legacy_scsi_host_adapter(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_selected(0) , m_scsi_port(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/legscsi.h b/src/devices/machine/legscsi.h index 229580bc0bf..ad9459fb6a2 100644 --- a/src/devices/machine/legscsi.h +++ b/src/devices/machine/legscsi.h @@ -14,7 +14,7 @@ public: template <typename T> void set_scsi_port(T && tag) { m_scsi_port.set_tag(std::forward<T>(tag)); } protected: - legacy_scsi_host_adapter(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + legacy_scsi_host_adapter(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; diff --git a/src/devices/machine/lh5810.cpp b/src/devices/machine/lh5810.cpp index 054a532dff0..a37bc10cbda 100644 --- a/src/devices/machine/lh5810.cpp +++ b/src/devices/machine/lh5810.cpp @@ -48,7 +48,7 @@ DEFINE_DEVICE_TYPE(LH5810, lh5810_device, "lh5810", "LH5810 I/O Port") // lh5810_device - constructor //------------------------------------------------- -lh5810_device::lh5810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lh5810_device::lh5810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LH5810, tag, owner, clock) , m_porta_r_cb(*this) , m_porta_w_cb(*this) diff --git a/src/devices/machine/lh5810.h b/src/devices/machine/lh5810.h index a383d0047eb..16e3a573506 100644 --- a/src/devices/machine/lh5810.h +++ b/src/devices/machine/lh5810.h @@ -15,7 +15,7 @@ class lh5810_device : public device_t { public: // construction/destruction - lh5810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + lh5810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto porta_r() { return m_porta_r_cb.bind(); } auto porta_w() { return m_porta_w_cb.bind(); } diff --git a/src/devices/machine/linflash.cpp b/src/devices/machine/linflash.cpp index 25b5257dd0b..149ad07e3a0 100644 --- a/src/devices/machine/linflash.cpp +++ b/src/devices/machine/linflash.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(LINEAR_FLASH_PCCARD_32MB, linear_flash_pccard_32mb_device, "l DEFINE_DEVICE_TYPE(LINEAR_FLASH_PCCARD_64MB, linear_flash_pccard_64mb_device, "linearflash64mb", "Linear Flash PC Card (64MB)") -linear_flash_pccard_device::linear_flash_pccard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +linear_flash_pccard_device::linear_flash_pccard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_pccard_interface(mconfig, *this), device_memory_interface(mconfig, *this), @@ -53,7 +53,7 @@ void linear_flash_pccard_16mb_device::linear_flash_pccard_16mb(address_map &map) map(0x00c00000, 0x00ffffff).rw("4u", FUNC(intelfsh8_device::read), FUNC(intelfsh8_device::write)).umask16(0xff00); } -linear_flash_pccard_16mb_device::linear_flash_pccard_16mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +linear_flash_pccard_16mb_device::linear_flash_pccard_16mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : linear_flash_pccard_device(mconfig, LINEAR_FLASH_PCCARD_16MB, tag, owner, clock) { m_space_config = address_space_config("memory", ENDIANNESS_LITTLE, 16, 26, 0, address_map_constructor(FUNC(linear_flash_pccard_16mb_device::linear_flash_pccard_16mb), this)); @@ -93,7 +93,7 @@ void linear_flash_pccard_32mb_device::linear_flash_pccard_32mb(address_map &map) map(0x01c00000, 0x01ffffff).rw("8u", FUNC(intelfsh8_device::read), FUNC(intelfsh8_device::write)).umask16(0xff00); } -linear_flash_pccard_32mb_device::linear_flash_pccard_32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +linear_flash_pccard_32mb_device::linear_flash_pccard_32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : linear_flash_pccard_device(mconfig, LINEAR_FLASH_PCCARD_32MB, tag, owner, clock) { m_space_config = address_space_config("memory", ENDIANNESS_LITTLE, 16, 26, 0, address_map_constructor(FUNC(linear_flash_pccard_32mb_device::linear_flash_pccard_32mb), this)); @@ -157,7 +157,7 @@ void linear_flash_pccard_64mb_device::linear_flash_pccard_64mb(address_map &map) map(0x03c00000, 0x03ffffff).rw("16u", FUNC(intelfsh8_device::read), FUNC(intelfsh8_device::write)).umask16(0xff00); } -linear_flash_pccard_64mb_device::linear_flash_pccard_64mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +linear_flash_pccard_64mb_device::linear_flash_pccard_64mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : linear_flash_pccard_device(mconfig, LINEAR_FLASH_PCCARD_64MB, tag, owner, clock) { m_space_config = address_space_config("memory", ENDIANNESS_LITTLE, 16, 26, 0, address_map_constructor(FUNC(linear_flash_pccard_64mb_device::linear_flash_pccard_64mb), this)); diff --git a/src/devices/machine/linflash.h b/src/devices/machine/linflash.h index 20f4559e98d..bbb1d6fc821 100644 --- a/src/devices/machine/linflash.h +++ b/src/devices/machine/linflash.h @@ -17,7 +17,7 @@ public: virtual void write_memory(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) override; protected: - linear_flash_pccard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + linear_flash_pccard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -33,7 +33,7 @@ protected: class linear_flash_pccard_16mb_device : public linear_flash_pccard_device { public: - linear_flash_pccard_16mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + linear_flash_pccard_16mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -47,7 +47,7 @@ private: class linear_flash_pccard_32mb_device : public linear_flash_pccard_device { public: - linear_flash_pccard_32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + linear_flash_pccard_32mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -61,7 +61,7 @@ private: class linear_flash_pccard_64mb_device : public linear_flash_pccard_device { public: - linear_flash_pccard_64mb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + linear_flash_pccard_64mb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/machine/locomo.cpp b/src/devices/machine/locomo.cpp index 01cae8787ce..f888e1c1c70 100644 --- a/src/devices/machine/locomo.cpp +++ b/src/devices/machine/locomo.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(LOCOMO, locomo_device, "locomo", "Sharp LoCoMo Peripheral") -locomo_device::locomo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +locomo_device::locomo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LOCOMO, tag, owner, clock) { } diff --git a/src/devices/machine/locomo.h b/src/devices/machine/locomo.h index ac240959d9f..d143a2e06ea 100644 --- a/src/devices/machine/locomo.h +++ b/src/devices/machine/locomo.h @@ -14,7 +14,7 @@ class locomo_device : public device_t { public: - locomo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + locomo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint32_t read(offs_t offset, uint32_t mem_mask = ~0U); void write(offs_t offset, uint32_t data, uint32_t mem_mask = ~0U); diff --git a/src/devices/machine/lpc-acpi.cpp b/src/devices/machine/lpc-acpi.cpp index b252ffd2c3b..0ee555ce1ae 100644 --- a/src/devices/machine/lpc-acpi.cpp +++ b/src/devices/machine/lpc-acpi.cpp @@ -38,7 +38,7 @@ void lpc_acpi_device::map(address_map &map) map(0x70, 0x70).rw(FUNC(lpc_acpi_device::sw_irq_gen_r), FUNC(lpc_acpi_device::sw_irq_gen_w)); } -lpc_acpi_device::lpc_acpi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lpc_acpi_device::lpc_acpi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : lpc_device(mconfig, LPC_ACPI, tag, owner, clock) { } diff --git a/src/devices/machine/lpc-acpi.h b/src/devices/machine/lpc-acpi.h index 1cd64636a10..2e21c7d1ad0 100644 --- a/src/devices/machine/lpc-acpi.h +++ b/src/devices/machine/lpc-acpi.h @@ -9,7 +9,7 @@ class lpc_acpi_device : public lpc_device { public: - lpc_acpi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + lpc_acpi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map_device(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space, uint64_t io_window_start, uint64_t io_window_end, uint64_t io_offset, address_space *io_space) override; diff --git a/src/devices/machine/lpc-pit.cpp b/src/devices/machine/lpc-pit.cpp index e15f1893045..3c18f762be7 100644 --- a/src/devices/machine/lpc-pit.cpp +++ b/src/devices/machine/lpc-pit.cpp @@ -13,7 +13,7 @@ void lpc_pit_device::map(address_map &map) map(0x53, 0x53).w(FUNC(lpc_pit_device::control_w)); } -lpc_pit_device::lpc_pit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lpc_pit_device::lpc_pit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : lpc_device(mconfig, LPC_PIT, tag, owner, clock) { } diff --git a/src/devices/machine/lpc-pit.h b/src/devices/machine/lpc-pit.h index aa83b6af5ce..cbba7788a1e 100644 --- a/src/devices/machine/lpc-pit.h +++ b/src/devices/machine/lpc-pit.h @@ -9,7 +9,7 @@ class lpc_pit_device : public lpc_device { public: - lpc_pit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + lpc_pit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map_device(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space, uint64_t io_window_start, uint64_t io_window_end, uint64_t io_offset, address_space *io_space) override; diff --git a/src/devices/machine/lpc-rtc.cpp b/src/devices/machine/lpc-rtc.cpp index e584d96cd6c..3c65efb66c2 100644 --- a/src/devices/machine/lpc-rtc.cpp +++ b/src/devices/machine/lpc-rtc.cpp @@ -17,7 +17,7 @@ void lpc_rtc_device::extmap(address_map &map) map(0x70, 0x77).rw(FUNC(lpc_rtc_device::exttarget_r), FUNC(lpc_rtc_device::exttarget_w)).umask32(0xff000000); } -lpc_rtc_device::lpc_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lpc_rtc_device::lpc_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : lpc_device(mconfig, LPC_RTC, tag, owner, clock), cur_index(0), cur_extindex(0) { } diff --git a/src/devices/machine/lpc-rtc.h b/src/devices/machine/lpc-rtc.h index 5243bcf7f8a..c59ac5827a5 100644 --- a/src/devices/machine/lpc-rtc.h +++ b/src/devices/machine/lpc-rtc.h @@ -9,7 +9,7 @@ class lpc_rtc_device : public lpc_device { public: - lpc_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + lpc_rtc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map_device(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space, uint64_t io_window_start, uint64_t io_window_end, uint64_t io_offset, address_space *io_space) override; diff --git a/src/devices/machine/lpci.cpp b/src/devices/machine/lpci.cpp index 44b8b84bf3d..836915a776f 100644 --- a/src/devices/machine/lpci.cpp +++ b/src/devices/machine/lpci.cpp @@ -91,7 +91,7 @@ DEFINE_DEVICE_TYPE(PCI_BUS_LEGACY, pci_bus_legacy_device, "pci_bus_legacy", "PCI //------------------------------------------------- // pci_bus_legacy_device - constructor //------------------------------------------------- -pci_bus_legacy_device::pci_bus_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pci_bus_legacy_device::pci_bus_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCI_BUS_LEGACY, tag, owner, clock), m_read_callback(*this), m_write_callback(*this), diff --git a/src/devices/machine/lpci.h b/src/devices/machine/lpci.h index fb289d5538f..e0d1e99ac08 100644 --- a/src/devices/machine/lpci.h +++ b/src/devices/machine/lpci.h @@ -26,12 +26,12 @@ public: typedef device_delegate<void (int function, int reg, uint32_t data, uint32_t mem_mask)> pci_bus_legacy_write_delegate; // construction/destruction - pci_bus_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint8_t busnum) - : pci_bus_legacy_device(mconfig, tag, owner, clock) + pci_bus_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint8_t busnum) + : pci_bus_legacy_device(mconfig, tag, owner) { set_busnum(busnum); } - pci_bus_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pci_bus_legacy_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint32_t read(offs_t offset, uint32_t mem_mask = ~0); void write(offs_t offset, uint32_t data, uint32_t mem_mask = ~0); diff --git a/src/devices/machine/m3002.cpp b/src/devices/machine/m3002.cpp index 1e021571896..ccc3c2e8922 100644 --- a/src/devices/machine/m3002.cpp +++ b/src/devices/machine/m3002.cpp @@ -34,7 +34,7 @@ ALLOW_SAVE_TYPE(m3002_device::mux_state); // m3002_device - constructor //------------------------------------------------- -m3002_device::m3002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +m3002_device::m3002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_nvram_interface(mconfig, *this) , device_rtc_interface(mconfig, *this) @@ -48,7 +48,7 @@ m3002_device::m3002_device(const machine_config &mconfig, device_type type, cons std::fill_n(&m_ram[0], 0x10, 0); } -m3002_device::m3002_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m3002_device::m3002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m3002_device(mconfig, M3002, tag, owner, clock) { } @@ -58,7 +58,7 @@ m3002_device::m3002_device(const machine_config &mconfig, const char *tag, devic // m3000_device - constructor //------------------------------------------------- -m3000_device::m3000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m3000_device::m3000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m3002_device(mconfig, M3000, tag, owner, clock) { } diff --git a/src/devices/machine/m3002.h b/src/devices/machine/m3002.h index b02d13429eb..04ed31b8c74 100644 --- a/src/devices/machine/m3002.h +++ b/src/devices/machine/m3002.h @@ -35,7 +35,7 @@ class m3002_device : public device_t, public device_nvram_interface, public devi { public: // device type constructor - m3002_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m3002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_out() { return m_irq_callback.bind(); } @@ -48,7 +48,7 @@ public: DECLARE_READ_LINE_MEMBER(irq_r) { return m_irq_active ? 0 : 1; } protected: - m3002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + m3002_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -105,7 +105,7 @@ class m3000_device : public m3002_device { public: // device type constructor - m3000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m3000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type declarations diff --git a/src/devices/machine/m68sfdc.cpp b/src/devices/machine/m68sfdc.cpp index 99a0b3b4580..922e0fe100a 100644 --- a/src/devices/machine/m68sfdc.cpp +++ b/src/devices/machine/m68sfdc.cpp @@ -14,7 +14,7 @@ #include "emu.h" #include "m68sfdc.h" -m68sfdc_device::m68sfdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +m68sfdc_device::m68sfdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, M68SFDC, tag, owner, clock), m_pia(*this, "pia"), m_ssda(*this, "ssda"), @@ -835,7 +835,7 @@ bool m68sfdc_device::pll_write_next_bit(bool bit, attotime &tm, floppy_image_dev void m68sfdc_device::device_add_mconfig(machine_config &config) { - PIA6821(config, m_pia, 0); + PIA6821(config, m_pia); m_pia->readpa_handler().set(FUNC(m68sfdc_device::pia_pa_r)); m_pia->writepa_handler().set(FUNC(m68sfdc_device::pia_pa_w)); m_pia->ca1_w(0); @@ -847,7 +847,7 @@ void m68sfdc_device::device_add_mconfig(machine_config &config) m_pia->irqa_handler().set(FUNC(m68sfdc_device::handle_nmi)); m_pia->irqb_handler().set(FUNC(m68sfdc_device::handle_irq)); - MC6852(config, m_ssda, 0); + MC6852(config, m_ssda); } DEFINE_DEVICE_TYPE(M68SFDC, m68sfdc_device, "m68sfdc", "M68SFDC") diff --git a/src/devices/machine/m68sfdc.h b/src/devices/machine/m68sfdc.h index 605ac628583..d4d5d10608b 100644 --- a/src/devices/machine/m68sfdc.h +++ b/src/devices/machine/m68sfdc.h @@ -19,7 +19,7 @@ INPUT_PORTS_EXTERN(m68sfdc); class m68sfdc_device : public device_t { public: - m68sfdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m68sfdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t reg, uint8_t val); uint8_t read(offs_t reg); diff --git a/src/devices/machine/m6m80011ap.cpp b/src/devices/machine/m6m80011ap.cpp index 937f9e815e1..f4f06d398df 100644 --- a/src/devices/machine/m6m80011ap.cpp +++ b/src/devices/machine/m6m80011ap.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(M6M80011AP, m6m80011ap_device, "m6m80011ap", "M6M80011AP EEPR // m6m80011ap_device - constructor //------------------------------------------------- -m6m80011ap_device::m6m80011ap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m6m80011ap_device::m6m80011ap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, M6M80011AP, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_latch(0), m_reset_line(0), m_cmd_stream_pos(0), m_current_cmd(0), m_read_latch(0), m_current_addr(0), m_eeprom_we(0), m_eeprom_state() diff --git a/src/devices/machine/m6m80011ap.h b/src/devices/machine/m6m80011ap.h index c288b9da633..b8eddb4cc61 100644 --- a/src/devices/machine/m6m80011ap.h +++ b/src/devices/machine/m6m80011ap.h @@ -10,7 +10,7 @@ class m6m80011ap_device : public device_t, { public: // construction/destruction - m6m80011ap_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 32'768); /* TODO: frequency */ + m6m80011ap_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = 32'768); /* TODO: frequency */ // I/O operations DECLARE_READ_LINE_MEMBER( read_bit ); diff --git a/src/devices/machine/m950x0.cpp b/src/devices/machine/m950x0.cpp index 9d42166804c..2f8bd3e2aad 100644 --- a/src/devices/machine/m950x0.cpp +++ b/src/devices/machine/m950x0.cpp @@ -43,18 +43,18 @@ m950x0_device::m950x0_device(const machine_config &mconfig, device_type type, co size(capacity, 8); } -m95010_device::m95010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : m950x0_device(mconfig, M95010, tag, owner, 0x80) +m95010_device::m95010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) + : m950x0_device(mconfig, M95010, tag, ownerx80) { } -m95020_device::m95020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : m950x0_device(mconfig, M95020, tag, owner, 0x100) +m95020_device::m95020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) + : m950x0_device(mconfig, M95020, tag, ownerx100) { } -m95040_device::m95040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : m950x0_device(mconfig, M95040, tag, owner, 0x200) +m95040_device::m95040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) + : m950x0_device(mconfig, M95040, tag, ownerx200) { } diff --git a/src/devices/machine/m950x0.h b/src/devices/machine/m950x0.h index 0eceb6fab21..e045ad8f7c1 100644 --- a/src/devices/machine/m950x0.h +++ b/src/devices/machine/m950x0.h @@ -75,19 +75,19 @@ protected: class m95010_device : public m950x0_device { public: - m95010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + m95010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class m95020_device : public m950x0_device { public: - m95020_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + m95020_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class m95040_device : public m950x0_device { public: - m95040_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + m95040_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(M95010, m95010_device) diff --git a/src/devices/machine/mb14241.cpp b/src/devices/machine/mb14241.cpp index c9d08eb503e..0cdd87a7b57 100644 --- a/src/devices/machine/mb14241.cpp +++ b/src/devices/machine/mb14241.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(MB14241, mb14241_device, "mb14241", "MB14241 Data Shifter") -mb14241_device::mb14241_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mb14241_device::mb14241_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MB14241, tag, owner, clock), m_shift_data(0), m_shift_count(0) { } diff --git a/src/devices/machine/mb14241.h b/src/devices/machine/mb14241.h index 00bc2a55949..673c787bafa 100644 --- a/src/devices/machine/mb14241.h +++ b/src/devices/machine/mb14241.h @@ -14,7 +14,7 @@ class mb14241_device : public device_t { public: - mb14241_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + mb14241_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void shift_count_w(u8 data); void shift_data_w(u8 data); diff --git a/src/devices/machine/mb3773.cpp b/src/devices/machine/mb3773.cpp index e5ce23e13e6..39c51959fe8 100644 --- a/src/devices/machine/mb3773.cpp +++ b/src/devices/machine/mb3773.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(MB3773, mb3773_device, "mb3773", "MB3773 Power Supply Monitor // mb3773_device - constructor //------------------------------------------------- -mb3773_device::mb3773_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +mb3773_device::mb3773_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : device_t(mconfig, MB3773, tag, owner, clock), m_watchdog_timer(nullptr), m_ck(0) { } diff --git a/src/devices/machine/mb3773.h b/src/devices/machine/mb3773.h index 5955c1fa372..8f641bfc2c6 100644 --- a/src/devices/machine/mb3773.h +++ b/src/devices/machine/mb3773.h @@ -17,7 +17,7 @@ class mb3773_device : public device_t { public: // construction/destruction - mb3773_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mb3773_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // I/O operations WRITE_LINE_MEMBER( write_line_ck ); diff --git a/src/devices/machine/mb8421.h b/src/devices/machine/mb8421.h index f112f1e1484..c7bd387c7d0 100644 --- a/src/devices/machine/mb8421.h +++ b/src/devices/machine/mb8421.h @@ -150,7 +150,7 @@ public: DECLARE_READ_LINE_MEMBER(busy_r) { return 0; } // _BUSY pin - not emulated protected: - dual_port_mailbox_ram_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) + dual_port_mailbox_ram_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_intl_callback(*this) , m_intr_callback(*this) @@ -229,7 +229,7 @@ private: class cy7c131_device : public dual_port_mailbox_ram_base<u8, 10, 8> { public: - cy7c131_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + cy7c131_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : dual_port_mailbox_ram_base<u8, 10, 8>(mconfig, CY7C131, tag, owner, clock) // 1kx8 { } @@ -240,7 +240,7 @@ public: class idt7130_device : public dual_port_mailbox_ram_base<u8, 10, 8> { public: - idt7130_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + idt7130_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : dual_port_mailbox_ram_base<u8, 10, 8>(mconfig, IDT7130, tag, owner, clock) // 1kx8 { } @@ -251,7 +251,7 @@ public: class idt71321_device : public dual_port_mailbox_ram_base<u8, 11, 8> { public: - idt71321_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + idt71321_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : dual_port_mailbox_ram_base<u8, 11, 8>(mconfig, IDT71321, tag, owner, clock) // 2kx8 { } @@ -262,7 +262,7 @@ public: class mb8421_device : public dual_port_mailbox_ram_base<u8, 11, 8> { public: - mb8421_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + mb8421_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : dual_port_mailbox_ram_base<u8, 11, 8>(mconfig, MB8421, tag, owner, clock) // 2kx8 { } @@ -273,7 +273,7 @@ public: class mb8421_mb8431_16_device : public dual_port_mailbox_ram_base<u16, 11, 16> { public: - mb8421_mb8431_16_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + mb8421_mb8431_16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : dual_port_mailbox_ram_base<u16, 11, 16>(mconfig, MB8421_MB8431_16BIT, tag, owner, clock) // 2kx16 { } diff --git a/src/devices/machine/mb87030.cpp b/src/devices/machine/mb87030.cpp index 1898f69ec67..13ce1eeff68 100644 --- a/src/devices/machine/mb87030.cpp +++ b/src/devices/machine/mb87030.cpp @@ -10,13 +10,13 @@ DEFINE_DEVICE_TYPE(MB87030, mb87030_device, "mb87030", "Fujitsu MB87030 SCSI controller") -mb87030_device::mb87030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mb87030_device::mb87030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mb87030_device(mconfig, MB87030, tag, owner, clock) { } -mb87030_device::mb87030_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +mb87030_device::mb87030_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nscsi_device(mconfig, type, tag, owner, clock), nscsi_slot_card_interface(mconfig, *this, DEVICE_SELF), m_irq_handler(*this), diff --git a/src/devices/machine/mb87030.h b/src/devices/machine/mb87030.h index d2e90a506f4..e7a1684a405 100644 --- a/src/devices/machine/mb87030.h +++ b/src/devices/machine/mb87030.h @@ -11,7 +11,7 @@ class mb87030_device : public nscsi_device, public nscsi_slot_card_interface { public: - mb87030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb87030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map); @@ -58,7 +58,7 @@ public: void ctrl_write(uint32_t value, uint32_t mask) { scsi_bus->ctrl_w(scsi_refid, value, mask); scsi_ctrl_changed(); } uint32_t data_read() { return scsi_bus->data_r(); } protected: - mb87030_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mb87030_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/machine/mb87078.cpp b/src/devices/machine/mb87078.cpp index eed6f53297a..9be63b8a552 100644 --- a/src/devices/machine/mb87078.cpp +++ b/src/devices/machine/mb87078.cpp @@ -79,7 +79,7 @@ DEFINE_DEVICE_TYPE(MB87078, mb87078_device, "mb87078", "MB87078 Volume Controller") -mb87078_device::mb87078_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mb87078_device::mb87078_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MB87078, tag, owner, clock), m_gain_changed_cb(*this) { diff --git a/src/devices/machine/mb87078.h b/src/devices/machine/mb87078.h index 500a53b02a6..975a1139878 100644 --- a/src/devices/machine/mb87078.h +++ b/src/devices/machine/mb87078.h @@ -14,7 +14,7 @@ class mb87078_device : public device_t { public: - mb87078_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mb87078_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto gain_changed() { return m_gain_changed_cb.bind(); } diff --git a/src/devices/machine/mb8795.cpp b/src/devices/machine/mb8795.cpp index 957b53a2655..04288290256 100644 --- a/src/devices/machine/mb8795.cpp +++ b/src/devices/machine/mb8795.cpp @@ -19,7 +19,7 @@ void mb8795_device::map(address_map &map) map(0x8, 0xf).rw(FUNC(mb8795_device::mac_r), FUNC(mb8795_device::mac_w)); // Mapping limitation, real is up to 0xd } -mb8795_device::mb8795_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mb8795_device::mb8795_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MB8795, tag, owner, clock), device_network_interface(mconfig, *this, 10), txstat(0), txmask(0), rxstat(0), rxmask(0), txmode(0), rxmode(0), txlen(0), rxlen(0), txcount(0), diff --git a/src/devices/machine/mb8795.h b/src/devices/machine/mb8795.h index 57daf378f66..638363a3450 100644 --- a/src/devices/machine/mb8795.h +++ b/src/devices/machine/mb8795.h @@ -9,7 +9,7 @@ class mb8795_device : public device_t, public device_network_interface { public: - mb8795_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb8795_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto tx_irq() { return irq_tx_cb.bind(); } auto rx_irq() { return irq_rx_cb.bind(); } diff --git a/src/devices/machine/mb89352.cpp b/src/devices/machine/mb89352.cpp index 24777cd0289..921c451f398 100644 --- a/src/devices/machine/mb89352.cpp +++ b/src/devices/machine/mb89352.cpp @@ -155,7 +155,7 @@ DEFINE_DEVICE_TYPE(MB89352A, mb89352_device, "mb89352", "Fujitsu MB89352A") * Device */ -mb89352_device::mb89352_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mb89352_device::mb89352_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : legacy_scsi_host_adapter(mconfig, MB89352A, tag, owner, clock), m_irq_cb(*this), m_drq_cb(*this) diff --git a/src/devices/machine/mb89352.h b/src/devices/machine/mb89352.h index 1032dd547d7..43cb6d4a023 100644 --- a/src/devices/machine/mb89352.h +++ b/src/devices/machine/mb89352.h @@ -15,7 +15,7 @@ class mb89352_device : public legacy_scsi_host_adapter { public: // construction/destruction - mb89352_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mb89352_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto irq_cb() { return m_irq_cb.bind(); } auto drq_cb() { return m_drq_cb.bind(); } diff --git a/src/devices/machine/mb89363b.cpp b/src/devices/machine/mb89363b.cpp index dae0d4a3372..3cf04bbe40d 100644 --- a/src/devices/machine/mb89363b.cpp +++ b/src/devices/machine/mb89363b.cpp @@ -83,7 +83,7 @@ DEFINE_DEVICE_TYPE(MB89363B, mb89363b_device, "mb89363b", "Fujitsu MB89363B I/O") -mb89363b_device::mb89363b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb89363b_device::mb89363b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MB89363B, tag, owner, clock), m_i8255_a(*this, "i8255_a"), m_i8255_b(*this, "i8255_b"), diff --git a/src/devices/machine/mb89363b.h b/src/devices/machine/mb89363b.h index 273642f96f5..71efc26d4cf 100644 --- a/src/devices/machine/mb89363b.h +++ b/src/devices/machine/mb89363b.h @@ -21,7 +21,7 @@ class mb89363b_device : public device_t { public: // construction/destruction - mb89363b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mb89363b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/machine/mb89371.cpp b/src/devices/machine/mb89371.cpp index 7393bd7d529..deffdfa8108 100644 --- a/src/devices/machine/mb89371.cpp +++ b/src/devices/machine/mb89371.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(MB89371, mb89371_device, "mb89371", "MB89371 Dual Serial UART") -mb89371_device::mb89371_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +mb89371_device::mb89371_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : device_t(mconfig, MB89371, tag, owner, clock) { } diff --git a/src/devices/machine/mb89371.h b/src/devices/machine/mb89371.h index 4fe1c8158d2..79d05d787fa 100644 --- a/src/devices/machine/mb89371.h +++ b/src/devices/machine/mb89371.h @@ -18,7 +18,7 @@ class mb89371_device : public device_t { public: // construction/destruction - mb89371_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb89371_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint8_t data, uint8_t mem_mask = ~0); uint8_t read(offs_t offset, uint8_t mem_mask = ~0); diff --git a/src/devices/machine/mb89374.cpp b/src/devices/machine/mb89374.cpp index 7cad4c899d6..74ac6c08910 100644 --- a/src/devices/machine/mb89374.cpp +++ b/src/devices/machine/mb89374.cpp @@ -99,7 +99,7 @@ enum // mb89374_device - constructor //------------------------------------------------- -mb89374_device::mb89374_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) : +mb89374_device::mb89374_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : device_t(mconfig, MB89374, tag, owner, clock), device_execute_interface(mconfig, *this), m_icount(0), diff --git a/src/devices/machine/mb89374.h b/src/devices/machine/mb89374.h index 4ea6878641f..1229e0bb181 100644 --- a/src/devices/machine/mb89374.h +++ b/src/devices/machine/mb89374.h @@ -43,7 +43,7 @@ class mb89374_device : public device_t, { public: // construction/destruction - mb89374_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb89374_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_irq_callback() { return m_out_irq_cb.bind(); } template <unsigned N> auto out_po_callback() { return m_out_po_cb[N].bind(); } diff --git a/src/devices/machine/mc14411.cpp b/src/devices/machine/mc14411.cpp index 722de11b35e..f7fab924077 100644 --- a/src/devices/machine/mc14411.cpp +++ b/src/devices/machine/mc14411.cpp @@ -89,12 +89,12 @@ DEFINE_DEVICE_TYPE(MC14411, mc14411_device, "mc14411", "MC14411 Bit Rate Generat // LIVE DEVICE //************************************************************************** -mc14411_device::mc14411_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc14411_device::mc14411_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc14411_device(mconfig, MC14411, tag, owner, clock) { } -mc14411_device::mc14411_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mc14411_device::mc14411_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_out_fx_cbs(*this) , m_divider(0) diff --git a/src/devices/machine/mc14411.h b/src/devices/machine/mc14411.h index 422e381bcb2..e9b25e89585 100644 --- a/src/devices/machine/mc14411.h +++ b/src/devices/machine/mc14411.h @@ -58,7 +58,7 @@ public: }; // construction/destruction - mc14411_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc14411_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <std::size_t Line> auto out_f() { return m_out_fx_cbs[Line-1].bind(); } @@ -71,7 +71,7 @@ public: void timer_disable_all(); protected: - mc14411_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mc14411_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/machine/mc146818.cpp b/src/devices/machine/mc146818.cpp index c5cabdfd528..f89261875e5 100644 --- a/src/devices/machine/mc146818.cpp +++ b/src/devices/machine/mc146818.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(DS1287, ds1287_device, "ds1287", "DS1287 RTC") // mc146818_device - constructor //------------------------------------------------- -mc146818_device::mc146818_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc146818_device::mc146818_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc146818_device(mconfig, MC146818, tag, owner, clock) { switch (clock) @@ -44,12 +44,12 @@ mc146818_device::mc146818_device(const machine_config &mconfig, const char *tag, } } -ds1287_device::ds1287_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ds1287_device::ds1287_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc146818_device(mconfig, DS1287, tag, owner, clock) { } -mc146818_device::mc146818_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mc146818_device::mc146818_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_nvram_interface(mconfig, *this), m_region(*this, DEVICE_SELF), diff --git a/src/devices/machine/mc146818.h b/src/devices/machine/mc146818.h index 44eb0a54337..bb566919077 100644 --- a/src/devices/machine/mc146818.h +++ b/src/devices/machine/mc146818.h @@ -22,7 +22,7 @@ class mc146818_device : public device_t, { public: // construction/destruction - mc146818_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc146818_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto irq() { return m_write_irq.bind(); } @@ -48,7 +48,7 @@ public: void write_direct(offs_t offset, uint8_t data); protected: - mc146818_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mc146818_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -175,7 +175,7 @@ protected: class ds1287_device : public mc146818_device { public: - ds1287_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds1287_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/machine/mc68328.cpp b/src/devices/machine/mc68328.cpp index e1753110d56..e58e8055ac6 100644 --- a/src/devices/machine/mc68328.cpp +++ b/src/devices/machine/mc68328.cpp @@ -210,7 +210,7 @@ void mc68328_device::cpu_space_map(address_map &map) } -mc68328_device::mc68328_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68328_device::mc68328_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_device(mconfig, tag, owner, clock, MC68328, 16, 24, address_map_constructor(FUNC(mc68328_device::internal_map), this)) , m_rtc(nullptr), m_pwm(nullptr) , m_out_port_a_cb(*this) diff --git a/src/devices/machine/mc68328.h b/src/devices/machine/mc68328.h index da28189db18..4ece2accddb 100644 --- a/src/devices/machine/mc68328.h +++ b/src/devices/machine/mc68328.h @@ -93,7 +93,7 @@ class mc68328_device : public m68000_device { public: - mc68328_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc68328_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_port_a() { return m_out_port_a_cb.bind(); } auto out_port_b() { return m_out_port_b_cb.bind(); } diff --git a/src/devices/machine/mc6843.cpp b/src/devices/machine/mc6843.cpp index 0987b494a27..7c9a0df5839 100644 --- a/src/devices/machine/mc6843.cpp +++ b/src/devices/machine/mc6843.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(MC6843, mc6843_device, "mc6843", "Motorola MC6843 FDC") -mc6843_device::mc6843_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6843_device::mc6843_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC6843, tag, owner, clock), m_irq(*this), m_force_ready(false) diff --git a/src/devices/machine/mc6843.h b/src/devices/machine/mc6843.h index 86a92757279..a2522d9bc0e 100644 --- a/src/devices/machine/mc6843.h +++ b/src/devices/machine/mc6843.h @@ -16,7 +16,7 @@ class mc6843_device : public device_t { public: - mc6843_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6843_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void force_ready() { m_force_ready = true; } diff --git a/src/devices/machine/mc6844.cpp b/src/devices/machine/mc6844.cpp index a88b497a271..96a8a5b9ed6 100644 --- a/src/devices/machine/mc6844.cpp +++ b/src/devices/machine/mc6844.cpp @@ -77,7 +77,7 @@ DEFINE_DEVICE_TYPE(MC6844, mc6844_device, "mc6844", "MC6844 DMA") //------------------------------------------------- // mc6844_device - constructor //------------------------------------------------- -mc6844_device::mc6844_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6844_device::mc6844_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC6844, tag, owner, clock) , device_execute_interface(mconfig, *this) , m_out_int_cb(*this) diff --git a/src/devices/machine/mc6844.h b/src/devices/machine/mc6844.h index 242528454a6..16561b73bbc 100644 --- a/src/devices/machine/mc6844.h +++ b/src/devices/machine/mc6844.h @@ -48,7 +48,7 @@ class mc6844_device : public device_t, public device_execute_interface { public: // construction/destruction - mc6844_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6844_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_int_callback() { return m_out_int_cb.bind(); } auto out_txak_callback() { return m_out_txak_cb.bind(); } diff --git a/src/devices/machine/mc6846.cpp b/src/devices/machine/mc6846.cpp index 7cacedc9656..5fcd5f7c9e7 100644 --- a/src/devices/machine/mc6846.cpp +++ b/src/devices/machine/mc6846.cpp @@ -46,7 +46,7 @@ DEFINE_DEVICE_TYPE(MC6846, mc6846_device, "mc6846", "MC6846 Programmable Timer") -mc6846_device::mc6846_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6846_device::mc6846_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC6846, tag, owner, clock), m_out_port_cb(*this), m_out_cp2_cb(*this), diff --git a/src/devices/machine/mc6846.h b/src/devices/machine/mc6846.h index 3569e78bb98..c4601dec045 100644 --- a/src/devices/machine/mc6846.h +++ b/src/devices/machine/mc6846.h @@ -17,7 +17,7 @@ class mc6846_device : public device_t { public: - mc6846_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6846_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_port() { return m_out_port_cb.bind(); } auto in_port() { return m_in_port_cb.bind(); } diff --git a/src/devices/machine/mc6852.cpp b/src/devices/machine/mc6852.cpp index 714e093aed3..996b31eca2b 100644 --- a/src/devices/machine/mc6852.cpp +++ b/src/devices/machine/mc6852.cpp @@ -44,7 +44,7 @@ DEFINE_DEVICE_TYPE(MC6852, mc6852_device, "mc6852", "Motorola MC6852 SSDA") // mc6852_device - constructor //------------------------------------------------- -mc6852_device::mc6852_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mc6852_device::mc6852_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC6852, tag, owner, clock), device_serial_interface(mconfig, *this), m_write_tx_data(*this), diff --git a/src/devices/machine/mc6852.h b/src/devices/machine/mc6852.h index 27e7ec9f962..8d954d2e507 100644 --- a/src/devices/machine/mc6852.h +++ b/src/devices/machine/mc6852.h @@ -42,7 +42,7 @@ class mc6852_device : public device_t, { public: // construction/destruction - mc6852_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6852_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_rx_clock(int clock) { m_rx_clock = clock; } void set_tx_clock(int clock) { m_tx_clock = clock; } diff --git a/src/devices/machine/mc6854.cpp b/src/devices/machine/mc6854.cpp index 55418ee0d23..569d3dfd813 100644 --- a/src/devices/machine/mc6854.cpp +++ b/src/devices/machine/mc6854.cpp @@ -139,7 +139,7 @@ static const int word_length[4] = { 5, 6, 7, 8 }; /* transmit / receive word len DEFINE_DEVICE_TYPE(MC6854, mc6854_device, "mc6854", "Motorola MC6854 ADLC") -mc6854_device::mc6854_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mc6854_device::mc6854_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC6854, tag, owner, clock), m_out_irq_cb(*this), m_out_rdsr_cb(*this), diff --git a/src/devices/machine/mc6854.h b/src/devices/machine/mc6854.h index 2e2fe6fa663..bc68e4137ae 100644 --- a/src/devices/machine/mc6854.h +++ b/src/devices/machine/mc6854.h @@ -21,7 +21,7 @@ public: typedef device_delegate<void (uint8_t *data, int length)> out_frame_delegate; - mc6854_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mc6854_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto out_irq_cb() { return m_out_irq_cb.bind(); } auto out_rdsr_cb() { return m_out_rdsr_cb.bind(); } diff --git a/src/devices/machine/mc68681.cpp b/src/devices/machine/mc68681.cpp index 8e647f4c2ab..ce33d8fbc79 100644 --- a/src/devices/machine/mc68681.cpp +++ b/src/devices/machine/mc68681.cpp @@ -112,7 +112,7 @@ DEFINE_DEVICE_TYPE(DUART_CHANNEL, duart_channel, "duart_channel", "DUART channel // LIVE DEVICE //************************************************************************** -duart_base_device::duart_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +duart_base_device::duart_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_chanA(*this, CHANA_TAG), m_chanB(*this, CHANB_TAG), @@ -134,23 +134,23 @@ duart_base_device::duart_base_device(const machine_config &mconfig, device_type { } -scn2681_device::scn2681_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scn2681_device::scn2681_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : duart_base_device(mconfig, SCN2681, tag, owner, clock) { } -mc68681_device::mc68681_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mc68681_device::mc68681_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : duart_base_device(mconfig, type, tag, owner, clock), m_read_vector(false) { } -mc68681_device::mc68681_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68681_device::mc68681_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68681_device(mconfig, MC68681, tag, owner, clock) { } -sc28c94_device::sc28c94_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sc28c94_device::sc28c94_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : duart_base_device(mconfig, SC28C94, tag, owner, clock) { } @@ -162,17 +162,17 @@ sc28c94_device::sc28c94_device(const machine_config &mconfig, const char *tag, d // that the code knows all of this and will not warn if those registers are accessed as it could be ported code. // TODO: A lot of subtle differences and also detect misuse of unavailable registers as they should be ignored //-------------------------------------------------------------------------------------------------------------------- -mc68340_duart_device::mc68340_duart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mc68340_duart_device::mc68340_duart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : duart_base_device(mconfig, type, tag, owner, clock) { } -mc68340_duart_device::mc68340_duart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc68340_duart_device::mc68340_duart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68340_duart_device(mconfig, MC68340_DUART, tag, owner, clock) { } -xr68c681_device::xr68c681_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +xr68c681_device::xr68c681_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc68681_device(mconfig, XR68C681, tag, owner, clock), m_XTXA(false), m_XRXA(false), @@ -277,22 +277,22 @@ void xr68c681_device::device_reset() void duart_base_device::device_add_mconfig(machine_config &config) { - DUART_CHANNEL(config, CHANA_TAG, 0); - DUART_CHANNEL(config, CHANB_TAG, 0); + DUART_CHANNEL(config, CHANA_TAG); + DUART_CHANNEL(config, CHANB_TAG); } void sc28c94_device::device_add_mconfig(machine_config &config) { - DUART_CHANNEL(config, CHANA_TAG, 0); - DUART_CHANNEL(config, CHANB_TAG, 0); - DUART_CHANNEL(config, CHANC_TAG, 0); - DUART_CHANNEL(config, CHAND_TAG, 0); + DUART_CHANNEL(config, CHANA_TAG); + DUART_CHANNEL(config, CHANB_TAG); + DUART_CHANNEL(config, CHANC_TAG); + DUART_CHANNEL(config, CHAND_TAG); } void mc68340_duart_device::device_add_mconfig(machine_config &config) { - DUART_CHANNEL(config, CHANA_TAG, 0); - DUART_CHANNEL(config, CHANB_TAG, 0); + DUART_CHANNEL(config, CHANA_TAG); + DUART_CHANNEL(config, CHANB_TAG); } void duart_base_device::update_interrupts() @@ -1160,7 +1160,7 @@ void duart_base_device::set_ISR_bits(int mask) // DUART channel class stuff -duart_channel::duart_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +duart_channel::duart_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DUART_CHANNEL, tag, owner, clock) , device_serial_interface(mconfig, *this) , MR1(0) diff --git a/src/devices/machine/mc68681.h b/src/devices/machine/mc68681.h index b47e7276cd8..30d7f1c9b6d 100644 --- a/src/devices/machine/mc68681.h +++ b/src/devices/machine/mc68681.h @@ -16,7 +16,7 @@ class duart_base_device; class duart_channel : public device_t, public device_serial_interface { public: - duart_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + duart_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -98,7 +98,6 @@ public: optional_device<duart_channel> m_chanD; // inline configuration helpers - void set_clocks(int clk3, int clk4, int clk5, int clk6); void set_clocks(const XTAL &clk3, const XTAL &clk4, const XTAL &clk5, const XTAL &clk6) { set_clocks(clk3.value(), clk4.value(), clk5.value(), clk6.value()); } @@ -128,7 +127,7 @@ public: bool irq_pending() const { return (ISR & IMR) != 0; } protected: - duart_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + duart_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -167,6 +166,7 @@ private: bool m_irq_state; + void set_clocks(int clk3, int clk4, int clk5, int clk6); uint32_t get_ct_rate(); uint16_t get_ct_count(); void start_ct(int count); @@ -198,13 +198,13 @@ private: class scn2681_device : public duart_base_device { public: - scn2681_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scn2681_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mc68681_device : public duart_base_device { public: - mc68681_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc68681_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; @@ -214,7 +214,7 @@ protected: virtual void device_start() override; virtual void device_reset() override; virtual void update_interrupts() override; - mc68681_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mc68681_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); private: bool m_read_vector; // if this is read and IRQ is active, it counts as pulling IACK @@ -225,7 +225,7 @@ private: class sc28c94_device : public duart_base_device { public: - sc28c94_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sc28c94_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto c_tx_cb() { return write_c_tx.bind(); } auto d_tx_cb() { return write_d_tx.bind(); } @@ -245,14 +245,14 @@ private: class mc68340_duart_device : public duart_base_device { public: - mc68340_duart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc68340_duart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; protected: virtual void device_add_mconfig(machine_config &config) override; - mc68340_duart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mc68340_duart_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); private: virtual int calc_baud(int ch, bool rx, uint8_t data) override; @@ -261,7 +261,7 @@ private: class xr68c681_device : public mc68681_device { public: - xr68c681_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xr68c681_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/machine/mc68901.cpp b/src/devices/machine/mc68901.cpp index ed0282770e9..cf235cb43a7 100644 --- a/src/devices/machine/mc68901.cpp +++ b/src/devices/machine/mc68901.cpp @@ -345,7 +345,7 @@ void mc68901_device::gpio_output() // mc68901_device - constructor //------------------------------------------------- -mc68901_device::mc68901_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mc68901_device::mc68901_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MC68901, tag, owner, clock), m_timer_clock(0), m_out_irq_cb(*this), diff --git a/src/devices/machine/mc68901.h b/src/devices/machine/mc68901.h index 0e992c78941..2291f046559 100644 --- a/src/devices/machine/mc68901.h +++ b/src/devices/machine/mc68901.h @@ -50,7 +50,7 @@ class mc68901_device : public device_t { public: // construction/destruction - mc68901_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mc68901_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_timer_clock(int timer_clock) { m_timer_clock = timer_clock; } void set_timer_clock(const XTAL &xtal) { set_timer_clock(xtal.value()); } diff --git a/src/devices/machine/mccs1850.cpp b/src/devices/machine/mccs1850.cpp index 367b58af135..7072b09729f 100644 --- a/src/devices/machine/mccs1850.cpp +++ b/src/devices/machine/mccs1850.cpp @@ -280,7 +280,7 @@ TIMER_CALLBACK_MEMBER(mccs1850_device::advance_seconds) // mccs1850_device - constructor //------------------------------------------------- -mccs1850_device::mccs1850_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mccs1850_device::mccs1850_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MCCS1850, tag, owner, clock), device_rtc_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/machine/mccs1850.h b/src/devices/machine/mccs1850.h index cdd3b2853bc..48c9941d7c0 100644 --- a/src/devices/machine/mccs1850.h +++ b/src/devices/machine/mccs1850.h @@ -37,7 +37,7 @@ class mccs1850_device : public device_t, { public: // construction/destruction - mccs1850_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mccs1850_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto int_wr_callback() { return int_cb.bind(); } auto pse_wr_callback() { return pse_cb.bind(); } diff --git a/src/devices/machine/mcf5206e.cpp b/src/devices/machine/mcf5206e.cpp index eb4695be03a..6ef44232748 100644 --- a/src/devices/machine/mcf5206e.cpp +++ b/src/devices/machine/mcf5206e.cpp @@ -823,7 +823,7 @@ DEFINE_DEVICE_TYPE(MCF5206E_PERIPHERAL, mcf5206e_peripheral_device, "mcf5206e_pe // mcf5206e_peripheral_device - constructor //------------------------------------------------- -mcf5206e_peripheral_device::mcf5206e_peripheral_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mcf5206e_peripheral_device::mcf5206e_peripheral_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MCF5206E_PERIPHERAL, tag, owner, clock), device_memory_interface(mconfig, *this), m_maincpu(*this, finder_base::DUMMY_TAG), diff --git a/src/devices/machine/mcf5206e.h b/src/devices/machine/mcf5206e.h index d4ec0dd7980..f2799e16a5c 100644 --- a/src/devices/machine/mcf5206e.h +++ b/src/devices/machine/mcf5206e.h @@ -24,13 +24,13 @@ class mcf5206e_peripheral_device : public device_t, public: // construction/destruction template <typename T> - mcf5206e_peripheral_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag) - : mcf5206e_peripheral_device(mconfig, tag, owner, clock) + mcf5206e_peripheral_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag) + : mcf5206e_peripheral_device(mconfig, tag, owner) { m_maincpu.set_tag(std::forward<T>(cpu_tag)); } - mcf5206e_peripheral_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mcf5206e_peripheral_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint32_t dev_r(offs_t offset, uint32_t mem_mask = ~0); void dev_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0); diff --git a/src/devices/machine/meters.cpp b/src/devices/machine/meters.cpp index 93ab6fd7fdc..28bc542cdf3 100644 --- a/src/devices/machine/meters.cpp +++ b/src/devices/machine/meters.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(METERS, meters_device, "meters", "Electromechanical meters") -meters_device::meters_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +meters_device::meters_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, METERS, tag, owner, clock) , m_number_mtr(0) { diff --git a/src/devices/machine/meters.h b/src/devices/machine/meters.h index c8dc68a5800..681e32de009 100644 --- a/src/devices/machine/meters.h +++ b/src/devices/machine/meters.h @@ -15,7 +15,7 @@ class meters_device : public device_t { public: - meters_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + meters_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_number(int number) { m_number_mtr = number; } diff --git a/src/devices/machine/microtch.cpp b/src/devices/machine/microtch.cpp index 7f4562f02f1..2d25a36fa4e 100644 --- a/src/devices/machine/microtch.cpp +++ b/src/devices/machine/microtch.cpp @@ -63,7 +63,7 @@ COM8 3F0-3F7 ON : ON : : ON DEFINE_DEVICE_TYPE(MICROTOUCH, microtouch_device, "microtouch", "Microtouch Touchscreen") -microtouch_device::microtouch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +microtouch_device::microtouch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MICROTOUCH, tag, owner, clock), device_serial_interface(mconfig, *this), m_rx_buffer_ptr(0), m_tx_buffer_num(0), m_tx_buffer_ptr(0), m_reset_done(0), m_format(0), m_mode(0), m_last_touch_state(0), diff --git a/src/devices/machine/microtch.h b/src/devices/machine/microtch.h index b7242f4cca3..929ee3c585c 100644 --- a/src/devices/machine/microtch.h +++ b/src/devices/machine/microtch.h @@ -14,7 +14,7 @@ class microtouch_device : public: typedef device_delegate<int (int *, int *)> touch_cb; - microtouch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + microtouch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto stx() { return m_out_stx_func.bind(); } DECLARE_WRITE_LINE_MEMBER(rx) { device_serial_interface::rx_w(state); } diff --git a/src/devices/machine/mm5307.cpp b/src/devices/machine/mm5307.cpp index 30032913ad0..c7614089a80 100644 --- a/src/devices/machine/mm5307.cpp +++ b/src/devices/machine/mm5307.cpp @@ -88,7 +88,7 @@ const std::array<u16, 16> mm5307ab_device::s_divisors_x2 = { // mm5307_device - constructor //------------------------------------------------- -mm5307_device::mm5307_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, const std::array<u16, 16> &divisors_x2) +mm5307_device::mm5307_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const std::array<u16, 16> &divisors_x2) : device_t(mconfig, type, tag, owner, clock) , m_divisors_x2(divisors_x2) , m_output_cb(*this) @@ -104,7 +104,7 @@ mm5307_device::mm5307_device(const machine_config &mconfig, device_type type, co // mm5307aa_device - constructor //------------------------------------------------- -mm5307aa_device::mm5307aa_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mm5307aa_device::mm5307aa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm5307_device(mconfig, MM5307AA, tag, owner, clock, s_divisors_x2) { } @@ -114,7 +114,7 @@ mm5307aa_device::mm5307aa_device(const machine_config &mconfig, const char *tag, // mm5307ab_device - constructor //------------------------------------------------- -mm5307ab_device::mm5307ab_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mm5307ab_device::mm5307ab_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm5307_device(mconfig, MM5307AB, tag, owner, clock, s_divisors_x2) { } diff --git a/src/devices/machine/mm5307.h b/src/devices/machine/mm5307.h index c1e6dad8f89..75dfb171080 100644 --- a/src/devices/machine/mm5307.h +++ b/src/devices/machine/mm5307.h @@ -40,7 +40,7 @@ public: protected: // base class constructor - mm5307_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, const std::array<u16, 16> &divisors_x2); + mm5307_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const std::array<u16, 16> &divisors_x2); // device-specific overrides virtual void device_resolve_objects() override; @@ -74,7 +74,7 @@ class mm5307aa_device : public mm5307_device { public: // construction/destruction - mm5307aa_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm5307aa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: static const std::array<u16, 16> s_divisors_x2; @@ -86,7 +86,7 @@ class mm5307ab_device : public mm5307_device { public: // construction/destruction - mm5307ab_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm5307ab_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); private: static const std::array<u16, 16> s_divisors_x2; diff --git a/src/devices/machine/mm5740.cpp b/src/devices/machine/mm5740.cpp index feabf787fe0..5d6cb821f27 100644 --- a/src/devices/machine/mm5740.cpp +++ b/src/devices/machine/mm5740.cpp @@ -43,7 +43,7 @@ const tiny_rom_entry *mm5740_device::device_rom_region() const // mm5740_device - constructor //------------------------------------------------- -mm5740_device::mm5740_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mm5740_device::mm5740_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MM5740, tag, owner, clock), m_read_x(*this), m_read_shift(*this), diff --git a/src/devices/machine/mm5740.h b/src/devices/machine/mm5740.h index c1e4eb81f70..4c352f7371b 100644 --- a/src/devices/machine/mm5740.h +++ b/src/devices/machine/mm5740.h @@ -89,7 +89,7 @@ class mm5740_device : public device_t { public: // construction/destruction - mm5740_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mm5740_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // public interface uint16_t b_r(); diff --git a/src/devices/machine/mm58167.cpp b/src/devices/machine/mm58167.cpp index 9363a80c6f4..ae30c51ff09 100644 --- a/src/devices/machine/mm58167.cpp +++ b/src/devices/machine/mm58167.cpp @@ -52,7 +52,7 @@ typedef enum // mm58167_device - constructor //------------------------------------------------- -mm58167_device::mm58167_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mm58167_device::mm58167_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MM58167, tag, owner, clock), device_rtc_interface(mconfig, *this), m_irq_w(*this) diff --git a/src/devices/machine/mm58167.h b/src/devices/machine/mm58167.h index 82cf173ca95..8fcd6776945 100644 --- a/src/devices/machine/mm58167.h +++ b/src/devices/machine/mm58167.h @@ -25,7 +25,7 @@ class mm58167_device : public device_t, { public: // construction/destruction - mm58167_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mm58167_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/machine/mm58174.cpp b/src/devices/machine/mm58174.cpp index 3d15060666a..4b0e0bb1f88 100644 --- a/src/devices/machine/mm58174.cpp +++ b/src/devices/machine/mm58174.cpp @@ -34,7 +34,7 @@ enum DEFINE_DEVICE_TYPE(MM58174, mm58174_device, "mm58174", "National Semiconductor MM58174 RTC") -mm58174_device::mm58174_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mm58174_device::mm58174_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MM58174, tag, owner, clock) , device_rtc_interface(mconfig, *this) , m_control(0) diff --git a/src/devices/machine/mm58174.h b/src/devices/machine/mm58174.h index 72fbfc85502..a084ca4bbb8 100644 --- a/src/devices/machine/mm58174.h +++ b/src/devices/machine/mm58174.h @@ -15,7 +15,7 @@ class mm58174_device : public device_t, public device_rtc_interface { public: - mm58174_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mm58174_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/machine/mm58274c.cpp b/src/devices/machine/mm58274c.cpp index cfc50472653..66b7b4c49c6 100644 --- a/src/devices/machine/mm58274c.cpp +++ b/src/devices/machine/mm58274c.cpp @@ -47,7 +47,7 @@ enum DEFINE_DEVICE_TYPE(MM58274C, mm58274c_device, "mm58274c", "National Semiconductor MM58274C RTC") -mm58274c_device::mm58274c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mm58274c_device::mm58274c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MM58274C, tag, owner, clock) , m_mode24(0) , m_day1(0) diff --git a/src/devices/machine/mm58274c.h b/src/devices/machine/mm58274c.h index c6fcbee3c46..2d838b221c3 100644 --- a/src/devices/machine/mm58274c.h +++ b/src/devices/machine/mm58274c.h @@ -10,7 +10,7 @@ class mm58274c_device : public device_t { public: - mm58274c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mm58274c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_mode24(int mode) { m_mode24 = mode; } void set_day1(int day) { m_day1 = day; } diff --git a/src/devices/machine/mm74c922.cpp b/src/devices/machine/mm74c922.cpp index add765a1b1e..42cb30146ae 100644 --- a/src/devices/machine/mm74c922.cpp +++ b/src/devices/machine/mm74c922.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(MM74C923, mm74c923_device, "mm74c923", "MM74C923 20-Key Encod // mm74c922_device - constructor //------------------------------------------------- -mm74c922_device::mm74c922_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int max_y) : +mm74c922_device::mm74c922_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int max_y) : device_t(mconfig, type, tag, owner, clock), m_write_da(*this), m_read_x(*this), m_tristate_data(*this), m_cap_osc(0), m_cap_debounce(0), @@ -46,12 +46,12 @@ mm74c922_device::mm74c922_device(const machine_config &mconfig, device_type type { } -mm74c922_device::mm74c922_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mm74c922_device::mm74c922_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm74c922_device(mconfig, MM74C922, tag, owner, clock, 4) { } -mm74c923_device::mm74c923_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mm74c923_device::mm74c923_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm74c922_device(mconfig, MM74C923, tag, owner, clock, 5) { } diff --git a/src/devices/machine/mm74c922.h b/src/devices/machine/mm74c922.h index 43c958bb4b7..74ecc1c68e5 100644 --- a/src/devices/machine/mm74c922.h +++ b/src/devices/machine/mm74c922.h @@ -46,7 +46,7 @@ class mm74c922_device : public device_t { public: // construction/destruction - mm74c922_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mm74c922_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_cap_osc(double value) { m_cap_osc = value; } void set_cap_debounce(double value) { m_cap_debounce = value; } @@ -63,7 +63,7 @@ public: DECLARE_READ_LINE_MEMBER(da_r) { return m_da; } protected: - mm74c922_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int max_y); + mm74c922_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int max_y); // device-level overrides virtual void device_start() override; @@ -104,7 +104,7 @@ class mm74c923_device : public mm74c922_device { public: // construction/destruction - mm74c923_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mm74c923_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/machine/mos6526.cpp b/src/devices/machine/mos6526.cpp index a35d9a9c573..c743ec440d1 100644 --- a/src/devices/machine/mos6526.cpp +++ b/src/devices/machine/mos6526.cpp @@ -587,7 +587,7 @@ void mos6526_device::synchronize() // mos6526_device - constructor //------------------------------------------------- -mos6526_device::mos6526_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +mos6526_device::mos6526_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock), device_execute_interface(mconfig, *this), m_icount(0), @@ -604,17 +604,17 @@ mos6526_device::mos6526_device(const machine_config &mconfig, device_type type, { } -mos6526_device::mos6526_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6526_device::mos6526_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6526_device(mconfig, MOS6526, tag, owner, clock, TYPE_6526) { } -mos6526a_device::mos6526a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6526a_device::mos6526a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6526_device(mconfig, MOS6526A, tag, owner, clock, TYPE_6526A) { } -mos8520_device::mos8520_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8520_device::mos8520_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6526_device(mconfig, MOS8520, tag, owner, clock, TYPE_8520) { } -mos5710_device::mos5710_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos5710_device::mos5710_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6526_device(mconfig, MOS5710, tag, owner, clock, TYPE_5710) { } diff --git a/src/devices/machine/mos6526.h b/src/devices/machine/mos6526.h index 1f515271537..17fb72a4a49 100644 --- a/src/devices/machine/mos6526.h +++ b/src/devices/machine/mos6526.h @@ -72,7 +72,7 @@ class mos6526_device : public device_t, { public: // construction/destruction - mos6526_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6526_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_tod_clock(int clock) { m_tod_clock = clock; } @@ -108,7 +108,7 @@ protected: TYPE_5710 }; - mos6526_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + mos6526_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_start() override; @@ -218,7 +218,7 @@ protected: class mos6526a_device : public mos6526_device { public: - mos6526a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6526a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -227,7 +227,7 @@ public: class mos8520_device : public mos6526_device { public: - mos8520_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8520_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); @@ -242,7 +242,7 @@ protected: class mos5710_device : public mos6526_device { public: - mos5710_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos5710_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); //uint8_t read(offs_t offset); //void write(offs_t offset, uint8_t data); diff --git a/src/devices/machine/mos6529.cpp b/src/devices/machine/mos6529.cpp index 46bbf3bc0b8..3fbdd2dce5e 100644 --- a/src/devices/machine/mos6529.cpp +++ b/src/devices/machine/mos6529.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(MOS6529, mos6529_device, "mos6529", "MOS 6529") // mos6529_device - constructor //------------------------------------------------- -mos6529_device::mos6529_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mos6529_device::mos6529_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MOS6529, tag, owner, clock), m_input(0), m_p_handler(*this) diff --git a/src/devices/machine/mos6529.h b/src/devices/machine/mos6529.h index 67806441d57..780e69db95c 100644 --- a/src/devices/machine/mos6529.h +++ b/src/devices/machine/mos6529.h @@ -37,7 +37,7 @@ class mos6529_device : public device_t { public: // construction/destruction - mos6529_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6529_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <std::size_t Bit> auto p_handler() { return m_p_handler[Bit].bind(); } diff --git a/src/devices/machine/mos6530.cpp b/src/devices/machine/mos6530.cpp index 3862b0699e8..4efa3b915c7 100644 --- a/src/devices/machine/mos6530.cpp +++ b/src/devices/machine/mos6530.cpp @@ -41,7 +41,7 @@ enum DEFINE_DEVICE_TYPE(MOS6530, mos6530_device, "mos6530", "MOS 6530 MIOT") -mos6530_device::mos6530_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6530_device::mos6530_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MOS6530, tag, owner, clock), m_in_pa_cb(*this), m_out_pa_cb(*this), diff --git a/src/devices/machine/mos6530.h b/src/devices/machine/mos6530.h index 25e11a38f97..88015ee878d 100644 --- a/src/devices/machine/mos6530.h +++ b/src/devices/machine/mos6530.h @@ -46,7 +46,7 @@ class mos6530_device : public device_t { public: - mos6530_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6530_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto in_pa_callback() { return m_in_pa_cb.bind(); } auto out_pa_callback() { return m_out_pa_cb.bind(); } diff --git a/src/devices/machine/mos6530n.cpp b/src/devices/machine/mos6530n.cpp index fab3833e387..e91868babd8 100644 --- a/src/devices/machine/mos6530n.cpp +++ b/src/devices/machine/mos6530n.cpp @@ -84,7 +84,7 @@ void mos6532_new_device::io_map(address_map &map) // mos6530_device_base - constructor //------------------------------------------------- -mos6530_device_base::mos6530_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, u32 rsize) : +mos6530_device_base::mos6530_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 rsize) : device_t(mconfig, type, tag, owner, clock), m_ram(*this, finder_base::DUMMY_TAG, rsize, ENDIANNESS_LITTLE), m_rom(*this, DEVICE_SELF), @@ -120,7 +120,7 @@ mos6530_device_base::mos6530_device_base(const machine_config &mconfig, device_t // mos6530_new_device - constructor //------------------------------------------------- -mos6530_new_device::mos6530_new_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6530_new_device::mos6530_new_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6530_device_base(mconfig, MOS6530_NEW, tag, owner, clock, 0x40) { } @@ -128,7 +128,7 @@ mos6530_new_device::mos6530_new_device(const machine_config &mconfig, const char // mos6532_new_device - constructor //------------------------------------------------- -mos6532_new_device::mos6532_new_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6532_new_device::mos6532_new_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6530_device_base(mconfig, MOS6532_NEW, tag, owner, clock, 0x80) { } diff --git a/src/devices/machine/mos6530n.h b/src/devices/machine/mos6530n.h index 164a07031b0..d1c6476b5d6 100644 --- a/src/devices/machine/mos6530n.h +++ b/src/devices/machine/mos6530n.h @@ -96,7 +96,7 @@ public: protected: // construction/destruction - mos6530_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, u32 rsize); + mos6530_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 rsize); // device-level overrides virtual void device_start() override; @@ -200,7 +200,7 @@ class mos6530_new_device : public mos6530_device_base { public: // construction/destruction - mos6530_new_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6530_new_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void rom_map(address_map &map); virtual void ram_map(address_map &map); @@ -218,7 +218,7 @@ class mos6532_new_device : public mos6530_device_base { public: // construction/destruction - mos6532_new_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6532_new_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void ram_map(address_map &map); virtual void io_map(address_map &map); diff --git a/src/devices/machine/mos6551.cpp b/src/devices/machine/mos6551.cpp index 56302c75050..528646f1a5a 100644 --- a/src/devices/machine/mos6551.cpp +++ b/src/devices/machine/mos6551.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(MOS6551, mos6551_device, "mos6551", "MOS 6551 ACIA") -mos6551_device::mos6551_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mos6551_device::mos6551_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MOS6551, tag, owner, clock), m_internal_clock(*this, "clock"), m_irq_handler(*this), @@ -65,7 +65,7 @@ const int mos6551_device::transmitter_controls[4][3] = void mos6551_device::device_add_mconfig(machine_config &config) { - CLOCK(config, m_internal_clock, 0); + CLOCK(config, m_internal_clock); m_internal_clock->signal_handler().set(FUNC(mos6551_device::internal_clock)); } diff --git a/src/devices/machine/mos6551.h b/src/devices/machine/mos6551.h index b7afabfa603..8a893346eed 100644 --- a/src/devices/machine/mos6551.h +++ b/src/devices/machine/mos6551.h @@ -33,7 +33,7 @@ class mos6551_device : public device_t { public: - mos6551_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mos6551_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto irq_handler() { return m_irq_handler.bind(); } auto txd_handler() { return m_txd_handler.bind(); } diff --git a/src/devices/machine/mos6702.cpp b/src/devices/machine/mos6702.cpp index 1b552054cb4..5960bf7359f 100644 --- a/src/devices/machine/mos6702.cpp +++ b/src/devices/machine/mos6702.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(MOS6702, mos6702_device, "mos6702", "MOS 6702") // mos6702_device - constructor //------------------------------------------------- -mos6702_device::mos6702_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6702_device::mos6702_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MOS6702, tag, owner, clock) { } diff --git a/src/devices/machine/mos6702.h b/src/devices/machine/mos6702.h index ab1ea945e6e..fa5fa39c29f 100644 --- a/src/devices/machine/mos6702.h +++ b/src/devices/machine/mos6702.h @@ -35,7 +35,7 @@ class mos6702_device : public device_t { public: // construction/destruction - mos6702_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6702_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/machine/mos8706.cpp b/src/devices/machine/mos8706.cpp index 3ac0a976310..e8db0974bd9 100644 --- a/src/devices/machine/mos8706.cpp +++ b/src/devices/machine/mos8706.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(MOS8706, mos8706_device, "mos8706", "MOS 8706") // mos8706_device - constructor //------------------------------------------------- -mos8706_device::mos8706_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8706_device::mos8706_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MOS8706, tag, owner, clock) { } diff --git a/src/devices/machine/mos8706.h b/src/devices/machine/mos8706.h index a1d1a225e0e..ce9320b37cc 100644 --- a/src/devices/machine/mos8706.h +++ b/src/devices/machine/mos8706.h @@ -38,7 +38,7 @@ class mos8706_device : public device_t { public: - mos8706_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8706_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/machine/mos8722.cpp b/src/devices/machine/mos8722.cpp index 0364460b63e..d766e385492 100644 --- a/src/devices/machine/mos8722.cpp +++ b/src/devices/machine/mos8722.cpp @@ -69,7 +69,7 @@ static const offs_t RCR_TOP_ADDRESS[4] = { 0xf000, 0xf000, 0xe000, 0xc000 }; // mos8722_device - constructor //------------------------------------------------- -mos8722_device::mos8722_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mos8722_device::mos8722_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MOS8722, tag, owner, clock), m_write_z80en(*this), m_write_fsdir(*this), diff --git a/src/devices/machine/mos8722.h b/src/devices/machine/mos8722.h index 2b80aa846c2..18c44e047c6 100644 --- a/src/devices/machine/mos8722.h +++ b/src/devices/machine/mos8722.h @@ -48,7 +48,7 @@ class mos8722_device : public device_t { public: // construction/destruction - mos8722_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8722_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto z80en() { return m_write_z80en.bind(); } auto fsdir() { return m_write_fsdir.bind(); } diff --git a/src/devices/machine/mos8726.cpp b/src/devices/machine/mos8726.cpp index e1f167d70d3..70f83b32a1a 100644 --- a/src/devices/machine/mos8726.cpp +++ b/src/devices/machine/mos8726.cpp @@ -41,7 +41,7 @@ DEFINE_DEVICE_TYPE(MOS8726, mos8726_device, "mos8726", "MOS 8726 DMA Controller" // mos8726_device - constructor //------------------------------------------------- -mos8726_device::mos8726_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8726_device::mos8726_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MOS8726, tag, owner, clock) , device_execute_interface(mconfig, *this) , m_icount(0) diff --git a/src/devices/machine/mos8726.h b/src/devices/machine/mos8726.h index 90b78ec8412..1773a051c45 100644 --- a/src/devices/machine/mos8726.h +++ b/src/devices/machine/mos8726.h @@ -58,7 +58,7 @@ class mos8726_device : public device_t, { public: // construction/destruction - mos8726_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8726_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); diff --git a/src/devices/machine/mpu401.cpp b/src/devices/machine/mpu401.cpp index e2959a432a9..11c735dbfba 100644 --- a/src/devices/machine/mpu401.cpp +++ b/src/devices/machine/mpu401.cpp @@ -83,7 +83,7 @@ DEFINE_DEVICE_TYPE(MPU401, mpu401_device, "mpu401", "Roland MPU-401 I/O box") void mpu401_device::device_add_mconfig(machine_config &config) { - M6801(config, m_ourcpu, 4000000); /* 4 MHz as per schematics */ + M6801(config, m_ourcpu, XTAL::u(4000000)); /* 4 MHz as per schematics */ m_ourcpu->set_addrmap(AS_PROGRAM, &mpu401_device::mpu401_map); m_ourcpu->in_p1_cb().set(FUNC(mpu401_device::port1_r)); m_ourcpu->out_p1_cb().set(FUNC(mpu401_device::port1_w)); @@ -113,7 +113,7 @@ const tiny_rom_entry *mpu401_device::device_rom_region() const // mpu401_device - constructor //------------------------------------------------- -mpu401_device::mpu401_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mpu401_device::mpu401_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MPU401, tag, owner, clock), m_ourcpu(*this, M6801_TAG), write_irq(*this) diff --git a/src/devices/machine/mpu401.h b/src/devices/machine/mpu401.h index a76cc53dcdd..c84dc3469fc 100644 --- a/src/devices/machine/mpu401.h +++ b/src/devices/machine/mpu401.h @@ -15,7 +15,7 @@ class mpu401_device : public device_t { public: // construction/destruction - mpu401_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mpu401_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto irq_cb() { return write_irq.bind(); } diff --git a/src/devices/machine/msm5832.cpp b/src/devices/machine/msm5832.cpp index 65db2dda469..477a0beb730 100644 --- a/src/devices/machine/msm5832.cpp +++ b/src/devices/machine/msm5832.cpp @@ -88,7 +88,7 @@ inline void msm5832_device::write_counter(int counter, int value) // msm5832_device - constructor //------------------------------------------------- -msm5832_device::msm5832_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msm5832_device::msm5832_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSM5832, tag, owner, clock), device_rtc_interface(mconfig, *this), m_hold(0), diff --git a/src/devices/machine/msm5832.h b/src/devices/machine/msm5832.h index 2e55dc21b97..6f33e904049 100644 --- a/src/devices/machine/msm5832.h +++ b/src/devices/machine/msm5832.h @@ -38,7 +38,7 @@ class msm5832_device : public device_t, { public: // construction/destruction - msm5832_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msm5832_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t data_r(); void data_w(uint8_t data); diff --git a/src/devices/machine/msm58321.cpp b/src/devices/machine/msm58321.cpp index 72aa2b09d33..bc8b8e13c8c 100644 --- a/src/devices/machine/msm58321.cpp +++ b/src/devices/machine/msm58321.cpp @@ -161,7 +161,7 @@ inline void msm58321_device::write_counter(int address, int data) // msm58321_device - constructor //------------------------------------------------- -msm58321_device::msm58321_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +msm58321_device::msm58321_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSM58321, tag, owner, clock), device_rtc_interface(mconfig, *this), device_nvram_interface(mconfig, *this), diff --git a/src/devices/machine/msm58321.h b/src/devices/machine/msm58321.h index 6f28b05eecf..cb0cec53db1 100644 --- a/src/devices/machine/msm58321.h +++ b/src/devices/machine/msm58321.h @@ -47,7 +47,7 @@ class msm58321_device : public device_t, { public: // construction/destruction - msm58321_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msm58321_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto d0_handler() { return m_d0_handler.bind(); } diff --git a/src/devices/machine/msm6242.cpp b/src/devices/machine/msm6242.cpp index a4f566c3cd2..31e758e4ce8 100644 --- a/src/devices/machine/msm6242.cpp +++ b/src/devices/machine/msm6242.cpp @@ -76,12 +76,12 @@ DEFINE_DEVICE_TYPE(RTC72423, rtc72423_device, "rtc72423", "Epson RTC-72423 RTC") // msm6242_device - constructor //------------------------------------------------- -msm6242_device::msm6242_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +msm6242_device::msm6242_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msm6242_device(mconfig, MSM6242, tag, owner, clock) { } -msm6242_device::msm6242_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +msm6242_device::msm6242_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_rtc_interface(mconfig, *this) , m_out_int_handler(*this) @@ -592,7 +592,7 @@ void msm6242_device::write(offs_t offset, u8 data) // rtc62421_device - constructor //------------------------------------------------- -rtc62421_device::rtc62421_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rtc62421_device::rtc62421_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msm6242_device(mconfig, RTC62421, tag, owner, clock) { } @@ -602,7 +602,7 @@ rtc62421_device::rtc62421_device(const machine_config &mconfig, const char *tag, // rtc62423_device - constructor //------------------------------------------------- -rtc62423_device::rtc62423_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rtc62423_device::rtc62423_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msm6242_device(mconfig, RTC62423, tag, owner, clock) { } @@ -612,7 +612,7 @@ rtc62423_device::rtc62423_device(const machine_config &mconfig, const char *tag, // rtc72421_device - constructor //------------------------------------------------- -rtc72421_device::rtc72421_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rtc72421_device::rtc72421_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msm6242_device(mconfig, RTC72421, tag, owner, clock) { } @@ -622,7 +622,7 @@ rtc72421_device::rtc72421_device(const machine_config &mconfig, const char *tag, // rtc72423_device - constructor //------------------------------------------------- -rtc72423_device::rtc72423_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rtc72423_device::rtc72423_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msm6242_device(mconfig, RTC72423, tag, owner, clock) { } diff --git a/src/devices/machine/msm6242.h b/src/devices/machine/msm6242.h index 216c66fc5b5..e67300bfa85 100644 --- a/src/devices/machine/msm6242.h +++ b/src/devices/machine/msm6242.h @@ -46,7 +46,7 @@ class msm6242_device : public device_t, public device_rtc_interface { public: // construction/destruction - msm6242_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + msm6242_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_int_handler() { return m_out_int_handler.bind(); } @@ -55,7 +55,7 @@ public: u8 read(offs_t offset); protected: - msm6242_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + msm6242_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -105,7 +105,7 @@ class rtc62421_device : public msm6242_device { public: // construction/destruction - rtc62421_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rtc62421_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> rtc62423_device @@ -114,7 +114,7 @@ class rtc62423_device : public msm6242_device { public: // construction/destruction - rtc62423_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rtc62423_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> rtc72421_device @@ -123,7 +123,7 @@ class rtc72421_device : public msm6242_device { public: // construction/destruction - rtc72421_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rtc72421_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> rtc72423_device @@ -132,7 +132,7 @@ class rtc72423_device : public msm6242_device { public: // construction/destruction - rtc72423_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rtc72423_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/machine/msm6253.cpp b/src/devices/machine/msm6253.cpp index 53a47b2152e..9a2fbe523f2 100644 --- a/src/devices/machine/msm6253.cpp +++ b/src/devices/machine/msm6253.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(MSM6253, msm6253_device, "msm6253", "OKI MSM6253 A/D Converte // msm6253_device - constructor //------------------------------------------------- -msm6253_device::msm6253_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +msm6253_device::msm6253_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSM6253, tag, owner, clock) , m_analog_ports(*this, {finder_base::DUMMY_TAG, finder_base::DUMMY_TAG, finder_base::DUMMY_TAG, finder_base::DUMMY_TAG}) , m_analog_input_cb(*this) diff --git a/src/devices/machine/msm6253.h b/src/devices/machine/msm6253.h index b784bb9aec3..e9c7c262bd6 100644 --- a/src/devices/machine/msm6253.h +++ b/src/devices/machine/msm6253.h @@ -35,7 +35,7 @@ public: typedef device_delegate<ioport_value ()> port_read_delegate; // construction/destruction - msm6253_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + msm6253_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration template <unsigned P> void set_input_tag(const char *tag) { m_analog_ports[P].set_tag(tag); } diff --git a/src/devices/machine/mv_sonora.cpp b/src/devices/machine/mv_sonora.cpp index bab95cccb0f..87399ff98b3 100644 --- a/src/devices/machine/mv_sonora.cpp +++ b/src/devices/machine/mv_sonora.cpp @@ -20,7 +20,7 @@ const mac_video_sonora_device::modeline mac_video_sonora_device::modelines[5] = { 0x0b, "640x480 VGA", 25175000, 800, 16, 96, 48, 525, 10, 2, 33, false }, }; -mac_video_sonora_device::mac_video_sonora_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mac_video_sonora_device::mac_video_sonora_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MAC_VIDEO_SONORA, tag, owner, clock), m_screen(*this, "screen"), m_palette(*this, "palette"), @@ -57,7 +57,7 @@ void mac_video_sonora_device::device_add_mconfig(machine_config &config) { SCREEN(config, m_screen, SCREEN_TYPE_RASTER); // dot clock, htotal, hstart, hend, vtotal, vstart, vend - m_screen->set_raw(31334400, 896, 0, 640, 525, 0, 480); + m_screen->set_raw(XTAL::u(31334400), 896, 0, 640, 525, 0, 480); m_screen->set_screen_update(FUNC(mac_video_sonora_device::screen_update)); m_screen->screen_vblank().set([this](int state) { m_screen_vblank(state && (m_modeline_id != -1)); }); diff --git a/src/devices/machine/mv_sonora.h b/src/devices/machine/mv_sonora.h index 5d3e2c87cb9..9bc8d92ad0f 100644 --- a/src/devices/machine/mv_sonora.h +++ b/src/devices/machine/mv_sonora.h @@ -17,7 +17,7 @@ class mac_video_sonora_device : public device_t { public: - mac_video_sonora_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mac_video_sonora_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~mac_video_sonora_device() = default; uint8_t vctrl_r(offs_t offset); diff --git a/src/devices/machine/myb3k_kbd.cpp b/src/devices/machine/myb3k_kbd.cpp index 768ae3bda91..a2fc2919fc8 100644 --- a/src/devices/machine/myb3k_kbd.cpp +++ b/src/devices/machine/myb3k_kbd.cpp @@ -342,7 +342,7 @@ myb3k_keyboard_device::myb3k_keyboard_device( { } -myb3k_keyboard_device::myb3k_keyboard_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +myb3k_keyboard_device::myb3k_keyboard_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : myb3k_keyboard_device(mconfig, MYB3K_KEYBOARD, tag, owner, clock) { } diff --git a/src/devices/machine/ncr5380.cpp b/src/devices/machine/ncr5380.cpp index 56fefc4f97f..54ad053e0eb 100644 --- a/src/devices/machine/ncr5380.cpp +++ b/src/devices/machine/ncr5380.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(CXD1180, cxd1180_device, "cxd1180", "Sony CXD1180") ALLOW_SAVE_TYPE(ncr5380_device::state); -ncr5380_device::ncr5380_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, bool has_lbs) +ncr5380_device::ncr5380_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, bool has_lbs) : nscsi_device(mconfig, type, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, DEVICE_SELF) , m_irq_handler(*this) @@ -40,17 +40,17 @@ ncr5380_device::ncr5380_device(machine_config const &mconfig, device_type type, { } -ncr5380_device::ncr5380_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +ncr5380_device::ncr5380_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : ncr5380_device(mconfig, NCR5380, tag, owner, clock) { } -ncr53c80_device::ncr53c80_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +ncr53c80_device::ncr53c80_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : ncr5380_device(mconfig, NCR53C80, tag, owner, clock, true) { } -cxd1180_device::cxd1180_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +cxd1180_device::cxd1180_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : ncr5380_device(mconfig, CXD1180, tag, owner, clock, true) { } diff --git a/src/devices/machine/ncr5380.h b/src/devices/machine/ncr5380.h index e7107ae285e..406b820e3da 100644 --- a/src/devices/machine/ncr5380.h +++ b/src/devices/machine/ncr5380.h @@ -13,7 +13,7 @@ class ncr5380_device , public nscsi_slot_card_interface { public: - ncr5380_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + ncr5380_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // device configuration auto irq_handler() { return m_irq_handler.bind(); } @@ -30,7 +30,7 @@ public: void dma_w(u8 val); protected: - ncr5380_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, bool has_lbs = false); + ncr5380_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, bool has_lbs = false); // device_t overrides virtual void device_start() override; @@ -170,13 +170,13 @@ private: class ncr53c80_device : public ncr5380_device { public: - ncr53c80_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + ncr53c80_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); }; class cxd1180_device : public ncr5380_device { public: - cxd1180_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + cxd1180_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(NCR5380, ncr5380_device) diff --git a/src/devices/machine/ncr5385.cpp b/src/devices/machine/ncr5385.cpp index 6c1f4a3bb4e..c759d7f434b 100644 --- a/src/devices/machine/ncr5385.cpp +++ b/src/devices/machine/ncr5385.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(NCR5385, ncr5385_device, "ncr5385", "NCR 5385E SCSI Controller") -ncr5385_device::ncr5385_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ncr5385_device::ncr5385_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NCR5385, tag, owner, clock) , m_int(*this) { diff --git a/src/devices/machine/ncr5385.h b/src/devices/machine/ncr5385.h index a1dec052045..ec4ab1c44e2 100644 --- a/src/devices/machine/ncr5385.h +++ b/src/devices/machine/ncr5385.h @@ -54,7 +54,7 @@ class ncr5385_device : public device_t { public: // construction/destruction - ncr5385_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ncr5385_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq() { return m_int.bind(); } diff --git a/src/devices/machine/ncr5390.cpp b/src/devices/machine/ncr5390.cpp index 7a52d237982..4eb82715677 100644 --- a/src/devices/machine/ncr5390.cpp +++ b/src/devices/machine/ncr5390.cpp @@ -122,7 +122,7 @@ void ncr53c94_device::write(offs_t offset, uint8_t data) ncr53c90a_device::write(offset, data); } -ncr5390_device::ncr5390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ncr5390_device::ncr5390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nscsi_device(mconfig, type, tag, owner, clock) , nscsi_slot_card_interface(mconfig, *this, DEVICE_SELF) , tm(nullptr), config(0), status(0), istatus(0), clock_conv(0), sync_offset(0), sync_period(0), bus_id(0) @@ -132,35 +132,35 @@ ncr5390_device::ncr5390_device(const machine_config &mconfig, device_type type, { } -ncr53c90a_device::ncr53c90a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ncr53c90a_device::ncr53c90a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ncr5390_device(mconfig, type, tag, owner, clock) , config2(0) { } -ncr5390_device::ncr5390_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ncr5390_device::ncr5390_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ncr5390_device(mconfig, NCR5390, tag, owner, clock) { } -ncr53c90a_device::ncr53c90a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ncr53c90a_device::ncr53c90a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ncr53c90a_device(mconfig, NCR53C90A, tag, owner, clock) { } -ncr53c94_device::ncr53c94_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ncr53c94_device::ncr53c94_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ncr53c94_device(mconfig, NCR53C94, tag, owner, clock) { } -ncr53c94_device::ncr53c94_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ncr53c94_device::ncr53c94_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ncr53c90a_device(mconfig, type, tag, owner, clock) , config3(0) , m_busmd(BUSMD_0) { } -ncr53cf94_device::ncr53cf94_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ncr53cf94_device::ncr53cf94_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ncr53c94_device(mconfig, NCR53CF94, tag, owner, clock) { } diff --git a/src/devices/machine/ncr5390.h b/src/devices/machine/ncr5390.h index ba38e1b52cf..a50cd560756 100644 --- a/src/devices/machine/ncr5390.h +++ b/src/devices/machine/ncr5390.h @@ -10,7 +10,7 @@ class ncr5390_device : public nscsi_device, public nscsi_slot_card_interface { public: - ncr5390_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ncr5390_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq_handler_cb() { return m_irq_handler.bind(); } @@ -48,7 +48,7 @@ public: void dma_w(uint8_t val); protected: - ncr5390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ncr5390_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -240,7 +240,7 @@ protected: class ncr53c90a_device : public ncr5390_device { public: - ncr53c90a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ncr53c90a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; @@ -253,7 +253,7 @@ public: virtual void write(offs_t offset, uint8_t data) override; protected: - ncr53c90a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ncr53c90a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -284,7 +284,7 @@ private: class ncr53c94_device : public ncr53c90a_device { public: - ncr53c94_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ncr53c94_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); enum busmd_t : u8 { @@ -308,7 +308,7 @@ public: void dma16_w(u16 data); protected: - ncr53c94_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ncr53c94_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); enum conf3_mask : u8 { @@ -330,7 +330,7 @@ private: class ncr53cf94_device : public ncr53c94_device { public: - ncr53cf94_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ncr53cf94_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(NCR5390, ncr5390_device) diff --git a/src/devices/machine/ncr539x.cpp b/src/devices/machine/ncr539x.cpp index 67cfdadae76..2a962059927 100644 --- a/src/devices/machine/ncr539x.cpp +++ b/src/devices/machine/ncr539x.cpp @@ -118,7 +118,7 @@ DEFINE_DEVICE_TYPE(NCR539X, ncr539x_device, "ncr539x", "NCR/AMD 5394/5396 SCSI") // ncr539x_device - constructor/destructor //------------------------------------------------- -ncr539x_device::ncr539x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ncr539x_device::ncr539x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : legacy_scsi_host_adapter(mconfig, NCR539X, tag, owner, clock), m_out_irq_cb(*this), m_out_drq_cb(*this) diff --git a/src/devices/machine/ncr539x.h b/src/devices/machine/ncr539x.h index 9ba24b3ba47..040e9ff9013 100644 --- a/src/devices/machine/ncr539x.h +++ b/src/devices/machine/ncr539x.h @@ -19,7 +19,7 @@ class ncr539x_device : public legacy_scsi_host_adapter { public: // construction/destruction - ncr539x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ncr539x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_callback() { return m_out_irq_cb.bind(); } auto drq_callback() { return m_out_drq_cb.bind(); } diff --git a/src/devices/machine/netlist.cpp b/src/devices/machine/netlist.cpp index 48d81cacbdb..99e2537017c 100644 --- a/src/devices/machine/netlist.cpp +++ b/src/devices/machine/netlist.cpp @@ -424,7 +424,7 @@ void netlist_mame_sub_interface::set_mult_offset(const double mult, const double netlist_mame_analog_input_device::netlist_mame_analog_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *param_name) - : device_t(mconfig, NETLIST_ANALOG_INPUT, tag, owner, 0) + : device_t(mconfig, NETLIST_ANALOG_INPUT, tag, owner) , netlist_mame_sub_interface(*owner) , m_param(nullptr) , m_auto_port(true) @@ -433,7 +433,7 @@ netlist_mame_analog_input_device::netlist_mame_analog_input_device(const machine { } -netlist_mame_analog_input_device::netlist_mame_analog_input_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_analog_input_device::netlist_mame_analog_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NETLIST_ANALOG_INPUT, tag, owner, clock) , netlist_mame_sub_interface(*owner) , m_param(nullptr) @@ -475,7 +475,7 @@ void netlist_mame_analog_input_device::validity_helper(validity_checker &valid, // netlist_mame_analog_output_device // ---------------------------------------------------------------------------------------- -netlist_mame_analog_output_device::netlist_mame_analog_output_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_analog_output_device::netlist_mame_analog_output_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NETLIST_ANALOG_OUTPUT, tag, owner, clock) , netlist_mame_sub_interface(*owner) , m_in("") @@ -527,7 +527,7 @@ void netlist_mame_analog_output_device::device_start() // netlist_mame_logic_output_device // ---------------------------------------------------------------------------------------- -netlist_mame_logic_output_device::netlist_mame_logic_output_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_logic_output_device::netlist_mame_logic_output_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NETLIST_LOGIC_OUTPUT, tag, owner, clock) , netlist_mame_sub_interface(*owner) , m_in("") @@ -578,7 +578,7 @@ void netlist_mame_logic_output_device::device_start() // netlist_mame_int_input_device // ---------------------------------------------------------------------------------------- -netlist_mame_int_input_device::netlist_mame_int_input_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_int_input_device::netlist_mame_int_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NETLIST_INT_INPUT, tag, owner, clock) , netlist_mame_sub_interface(*owner) , m_param(nullptr) @@ -622,7 +622,7 @@ void netlist_mame_int_input_device::validity_helper(validity_checker &valid, // netlist_mame_logic_input_device // ---------------------------------------------------------------------------------------- -netlist_mame_logic_input_device::netlist_mame_logic_input_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_logic_input_device::netlist_mame_logic_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NETLIST_LOGIC_INPUT, tag, owner, clock) , netlist_mame_sub_interface(*owner) , m_param(nullptr) @@ -665,7 +665,7 @@ void netlist_mame_logic_input_device::validity_helper(validity_checker &valid, // netlist_mame_ram_pointer_device // ---------------------------------------------------------------------------------------- -netlist_mame_ram_pointer_device::netlist_mame_ram_pointer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_ram_pointer_device::netlist_mame_ram_pointer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NETLIST_RAM_POINTER, tag, owner, clock) , netlist_mame_sub_interface(*owner) , m_param(nullptr) @@ -675,7 +675,7 @@ netlist_mame_ram_pointer_device::netlist_mame_ram_pointer_device(const machine_c } netlist_mame_ram_pointer_device::netlist_mame_ram_pointer_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *pname) - : device_t(mconfig, NETLIST_RAM_POINTER, tag, owner, 0) + : device_t(mconfig, NETLIST_RAM_POINTER, tag, owner) , netlist_mame_sub_interface(*owner) , m_param(nullptr) , m_param_name(pname) @@ -717,7 +717,7 @@ void netlist_mame_ram_pointer_device::validity_helper(validity_checker &valid, // netlist_mame_stream_input_device // ---------------------------------------------------------------------------------------- -netlist_mame_stream_input_device::netlist_mame_stream_input_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_stream_input_device::netlist_mame_stream_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NETLIST_STREAM_INPUT, tag, owner, clock) , netlist_mame_sub_interface(*owner) , m_channel(0) @@ -752,7 +752,7 @@ void netlist_mame_stream_input_device::custom_netlist_additions(netlist::nlparse // netlist_mame_stream_output_device // ---------------------------------------------------------------------------------------- -netlist_mame_stream_output_device::netlist_mame_stream_output_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_stream_output_device::netlist_mame_stream_output_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NETLIST_STREAM_OUTPUT, tag, owner, clock) , netlist_mame_sub_interface(*owner) , m_channel(0) @@ -872,12 +872,12 @@ void netlist_mame_stream_output_device::process(netlist::netlist_time_ext tim, n // netlist_mame_device // ---------------------------------------------------------------------------------------- -netlist_mame_device::netlist_mame_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_device::netlist_mame_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : netlist_mame_device(mconfig, NETLIST_CORE, tag, owner, clock) { } -netlist_mame_device::netlist_mame_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_device::netlist_mame_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_setup_func(nullptr) , m_device_reset_called(false) @@ -1167,7 +1167,7 @@ void netlist_mame_device::save_state() // netlist_mame_cpu_device // ---------------------------------------------------------------------------------------- -netlist_mame_cpu_device::netlist_mame_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +netlist_mame_cpu_device::netlist_mame_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : netlist_mame_device(mconfig, NETLIST_CPU, tag, owner, clock) , device_execute_interface(mconfig, *this) , device_state_interface(mconfig, *this) @@ -1313,8 +1313,8 @@ offs_t netlist_disassembler::disassemble(std::ostream &stream, offs_t pc, const // netlist_mame_sound_device // ---------------------------------------------------------------------------------------- -netlist_mame_sound_device::netlist_mame_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) - : netlist_mame_device(mconfig, NETLIST_SOUND, tag, owner, 0) +netlist_mame_sound_device::netlist_mame_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) + : netlist_mame_device(mconfig, NETLIST_SOUND, tag, owner) , device_sound_interface(mconfig, *this) , m_stream(nullptr) , m_cur_time(attotime::zero) diff --git a/src/devices/machine/netlist.h b/src/devices/machine/netlist.h index ff9adf7d332..ce2ce4c4c08 100644 --- a/src/devices/machine/netlist.h +++ b/src/devices/machine/netlist.h @@ -112,7 +112,7 @@ public: using func_type = std::function<void(netlist::nlparse_t &)>; // construction/destruction - netlist_mame_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + netlist_mame_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~netlist_mame_device(); @@ -126,7 +126,7 @@ public: auto &log_csv() { return m_log_csv; } protected: - netlist_mame_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + netlist_mame_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // Custom to netlist ... virtual void nl_register_devices(netlist::nlparse_t &parser) const { } @@ -168,7 +168,7 @@ public: static constexpr const unsigned MDIV_SHIFT = 16; // construction/destruction - netlist_mame_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + netlist_mame_cpu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(1'000'000'000)); ~netlist_mame_cpu_device() { @@ -273,7 +273,7 @@ class netlist_mame_sound_device : public netlist_mame_device, { public: // construction/destruction - netlist_mame_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + netlist_mame_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); netlist_mame_sound_device & set_source(void (*setup_func)(netlist::nlparse_t &)) { @@ -378,7 +378,7 @@ public: // construction/destruction netlist_mame_analog_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *param_name); - netlist_mame_analog_input_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + netlist_mame_analog_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_name(const char *param_name) { m_param_name = param_name; } @@ -422,7 +422,7 @@ public: typedef device_delegate<void (const double, const attotime &)> output_delegate; // construction/destruction - netlist_mame_analog_output_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + netlist_mame_analog_output_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename... T> void set_params(const char *in_name, T &&... args) @@ -452,7 +452,7 @@ public: typedef device_delegate<void(const int, const attotime &)> output_delegate; // construction/destruction - netlist_mame_logic_output_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + netlist_mame_logic_output_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename... T> void set_params(const char *in_name, T &&... args) { @@ -481,11 +481,11 @@ public: // construction/destruction netlist_mame_int_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *param_name, const uint32_t shift, const uint32_t mask) - : netlist_mame_int_input_device(mconfig, tag, owner, (uint32_t)0) + : netlist_mame_int_input_device(mconfig, tag, owner) { set_params(param_name, mask, shift); } - netlist_mame_int_input_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + netlist_mame_int_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_params(const char *param_name, const uint32_t mask, const uint32_t shift); @@ -523,11 +523,11 @@ class netlist_mame_logic_input_device : public device_t, public netlist_mame_sub public: // construction/destruction netlist_mame_logic_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *param_name, const uint32_t shift) - : netlist_mame_logic_input_device(mconfig, tag, owner, (uint32_t)0) + : netlist_mame_logic_input_device(mconfig, tag, owner) { set_params(param_name, shift); } - netlist_mame_logic_input_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + netlist_mame_logic_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_params(const char *param_name, const uint32_t shift); @@ -562,7 +562,7 @@ class netlist_mame_ram_pointer_device : public device_t, public netlist_mame_sub { public: // construction/destruction - netlist_mame_ram_pointer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + netlist_mame_ram_pointer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); netlist_mame_ram_pointer_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *pname); uint8_t* ptr() const { return m_data; } @@ -592,11 +592,11 @@ class netlist_mame_stream_input_device : public device_t, public netlist_mame_su public: // construction/destruction netlist_mame_stream_input_device(const machine_config &mconfig, const char *tag, device_t *owner, int channel, const char *param_name) - : netlist_mame_stream_input_device(mconfig, tag, owner, (uint32_t)0) + : netlist_mame_stream_input_device(mconfig, tag, owner) { set_params(channel, param_name); } - netlist_mame_stream_input_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + netlist_mame_stream_input_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_params(int channel, const char *param_name); @@ -618,11 +618,11 @@ class netlist_mame_stream_output_device : public device_t, public netlist_mame_s public: // construction/destruction netlist_mame_stream_output_device(const machine_config &mconfig, const char *tag, device_t *owner, int channel, const char *out_name) - : netlist_mame_stream_output_device(mconfig, tag, owner, (uint32_t)0) + : netlist_mame_stream_output_device(mconfig, tag, owner) { set_params(channel, out_name); } - netlist_mame_stream_output_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + netlist_mame_stream_output_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_params(int channel, const char *out_name); diff --git a/src/devices/machine/nmc9306.cpp b/src/devices/machine/nmc9306.cpp index b2fd50626f9..b85e13a860b 100644 --- a/src/devices/machine/nmc9306.cpp +++ b/src/devices/machine/nmc9306.cpp @@ -104,7 +104,7 @@ inline void nmc9306_device::erase(offs_t offset) // nmc9306_device - constructor //------------------------------------------------- -nmc9306_device::nmc9306_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nmc9306_device::nmc9306_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NMC9306, tag, owner, clock), device_nvram_interface(mconfig, *this), m_state(STATE_IDLE), diff --git a/src/devices/machine/nmc9306.h b/src/devices/machine/nmc9306.h index 98566a9ab82..06c9ca9b82a 100644 --- a/src/devices/machine/nmc9306.h +++ b/src/devices/machine/nmc9306.h @@ -31,7 +31,7 @@ class nmc9306_device : public device_t, { public: // construction/destruction - nmc9306_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nmc9306_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( cs_w ); DECLARE_WRITE_LINE_MEMBER( sk_w ); diff --git a/src/devices/machine/nmk112.cpp b/src/devices/machine/nmk112.cpp index 4de5062ac14..31d03399b26 100644 --- a/src/devices/machine/nmk112.cpp +++ b/src/devices/machine/nmk112.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(NMK112, nmk112_device, "nmk112", "NMK112") -nmk112_device::nmk112_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nmk112_device::nmk112_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NMK112, tag, owner, clock) , m_page_mask(0xff) , m_rom0(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/nmk112.h b/src/devices/machine/nmk112.h index 5535d94899b..72cea1c841b 100644 --- a/src/devices/machine/nmk112.h +++ b/src/devices/machine/nmk112.h @@ -18,7 +18,7 @@ class nmk112_device : public device_t { public: - nmk112_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nmk112_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration template <typename T> nmk112_device &set_rom0_tag(T &&tag) { m_rom0.set_tag(std::forward<T>(tag)); return *this; } diff --git a/src/devices/machine/ns32081.cpp b/src/devices/machine/ns32081.cpp index a436a823582..2face6ef7c4 100644 --- a/src/devices/machine/ns32081.cpp +++ b/src/devices/machine/ns32081.cpp @@ -81,7 +81,7 @@ enum size_code : unsigned SIZE_D = 3, }; -ns32081_device::ns32081_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +ns32081_device::ns32081_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NS32081, tag, owner, clock) , ns32000_slow_slave_interface(mconfig, *this) { diff --git a/src/devices/machine/ns32081.h b/src/devices/machine/ns32081.h index e73fa8013f6..6dfa03fca24 100644 --- a/src/devices/machine/ns32081.h +++ b/src/devices/machine/ns32081.h @@ -13,7 +13,7 @@ class ns32081_device , public ns32000_slow_slave_interface { public: - ns32081_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + ns32081_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual void state_add(device_state_interface &parent, int &index) override; diff --git a/src/devices/machine/ns32082.cpp b/src/devices/machine/ns32082.cpp index fa70331b584..b0f7f41181e 100644 --- a/src/devices/machine/ns32082.cpp +++ b/src/devices/machine/ns32082.cpp @@ -145,7 +145,7 @@ enum st_mask : unsigned ST_SID = 0xf, // slave ID }; -ns32082_device::ns32082_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +ns32082_device::ns32082_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NS32082, tag, owner, clock) , ns32000_slow_slave_interface(mconfig, *this) , ns32000_mmu_interface(mconfig, *this) diff --git a/src/devices/machine/ns32082.h b/src/devices/machine/ns32082.h index 83238529e6b..b6ebe06dad3 100644 --- a/src/devices/machine/ns32082.h +++ b/src/devices/machine/ns32082.h @@ -14,7 +14,7 @@ class ns32082_device , public ns32000_mmu_interface { public: - ns32082_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + ns32082_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual void state_add(device_state_interface &parent, int &index) override; diff --git a/src/devices/machine/ns32202.cpp b/src/devices/machine/ns32202.cpp index ba97c22ab06..27603886eac 100644 --- a/src/devices/machine/ns32202.cpp +++ b/src/devices/machine/ns32202.cpp @@ -61,7 +61,7 @@ enum cictl_mask : u8 CICTL_CERH = 0x80, // h-counter error flag }; -ns32202_device::ns32202_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +ns32202_device::ns32202_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NS32202, tag, owner, clock) , m_out_int(*this) , m_out_cout(*this) diff --git a/src/devices/machine/ns32202.h b/src/devices/machine/ns32202.h index 7795b205e91..b0e0abe3ffe 100644 --- a/src/devices/machine/ns32202.h +++ b/src/devices/machine/ns32202.h @@ -16,7 +16,7 @@ public: template <unsigned Number> void ir_w(int state); template <unsigned ST1> void map(address_map &map); - ns32202_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + ns32202_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: // device_t overrides diff --git a/src/devices/machine/ns32382.cpp b/src/devices/machine/ns32382.cpp index 132c37c7b3f..218dce0634f 100644 --- a/src/devices/machine/ns32382.cpp +++ b/src/devices/machine/ns32382.cpp @@ -143,7 +143,7 @@ enum st_mask : unsigned ST_SID = 0xf, // slave ID }; -ns32382_device::ns32382_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +ns32382_device::ns32382_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NS32382, tag, owner, clock) , ns32000_fast_slave_interface(mconfig, *this) , ns32000_mmu_interface(mconfig, *this) diff --git a/src/devices/machine/ns32382.h b/src/devices/machine/ns32382.h index d7730a70d68..e0083295b92 100644 --- a/src/devices/machine/ns32382.h +++ b/src/devices/machine/ns32382.h @@ -14,7 +14,7 @@ class ns32382_device , public ns32000_mmu_interface { public: - ns32382_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + ns32382_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // ns32000_slave_interface overrides virtual void state_add(device_state_interface &parent, int &index) override; diff --git a/src/devices/machine/nsc810.cpp b/src/devices/machine/nsc810.cpp index a416e6ccca4..dcbf5cc2ff6 100644 --- a/src/devices/machine/nsc810.cpp +++ b/src/devices/machine/nsc810.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(NSC810, nsc810_device, "nsc810", "National Semiconductor NSC810 RAM-I/O-Timer") -nsc810_device::nsc810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nsc810_device::nsc810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NSC810, tag, owner, clock), m_portA_latch(0), m_portB_latch(0), m_portC_latch(0), m_ddrA(0), m_ddrB(0), m_ddrC(0), diff --git a/src/devices/machine/nsc810.h b/src/devices/machine/nsc810.h index 08a35465cc4..f039d5ccffc 100644 --- a/src/devices/machine/nsc810.h +++ b/src/devices/machine/nsc810.h @@ -16,21 +16,14 @@ class nsc810_device : public device_t { public: // construction/destruction - nsc810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t clk0, uint32_t clk1) - : nsc810_device(mconfig, tag, owner, clock) - { - set_timer0_clock(clk0); - set_timer1_clock(clk1); - } - - nsc810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, const XTAL &clk0, const XTAL &clk1) - : nsc810_device(mconfig, tag, owner, clock) + nsc810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clk0, const XTAL &clk1) + : nsc810_device(mconfig, tag, owner) { set_timer0_clock(clk0.value()); set_timer1_clock(clk1.value()); } - nsc810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nsc810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto portA_read_callback() { return m_portA_r.bind(); } auto portB_read_callback() { return m_portB_r.bind(); } diff --git a/src/devices/machine/nscsi_bus.cpp b/src/devices/machine/nscsi_bus.cpp index eeaf2c2722a..a9596d6b52a 100644 --- a/src/devices/machine/nscsi_bus.cpp +++ b/src/devices/machine/nscsi_bus.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(NSCSI_BUS, nscsi_bus_device, "nscsi_bus", "SCSI B DEFINE_DEVICE_TYPE(NSCSI_CONNECTOR, nscsi_connector, "nscsi_connector", "SCSI Connector Abstraction (new)") -nscsi_bus_device::nscsi_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_bus_device::nscsi_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NSCSI_BUS, tag, owner, clock), data(0), ctrl(0) { devcnt = 0; @@ -139,7 +139,7 @@ void nscsi_bus_device::device_resolve_objects() } -nscsi_connector::nscsi_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nscsi_connector::nscsi_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NSCSI_CONNECTOR, tag, owner, clock), device_single_card_slot_interface<nscsi_slot_card_interface>(mconfig, *this) { @@ -168,7 +168,7 @@ nscsi_slot_card_interface::nscsi_slot_card_interface(const machine_config &mconf { } -nscsi_device::nscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nscsi_device::nscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) { scsi_id = scsi_refid = -1; @@ -192,7 +192,7 @@ void nscsi_device::device_start() } -nscsi_full_device::nscsi_full_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nscsi_full_device::nscsi_full_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nscsi_device(mconfig, type, tag, owner, clock), nscsi_slot_card_interface(mconfig, *this, DEVICE_SELF) { diff --git a/src/devices/machine/nscsi_bus.h b/src/devices/machine/nscsi_bus.h index 6cd99732bf9..62a6394b6e7 100644 --- a/src/devices/machine/nscsi_bus.h +++ b/src/devices/machine/nscsi_bus.h @@ -12,7 +12,7 @@ class nscsi_slot_card_interface; class nscsi_bus_device : public device_t { public: - nscsi_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_bus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void ctrl_w(int refid, uint32_t lines, uint32_t mask); void data_w(int refid, uint32_t lines); @@ -48,14 +48,14 @@ class nscsi_connector: public device_t, public: template <typename T> nscsi_connector(const machine_config &mconfig, const char *tag, device_t *owner, T &&opts, const char *dflt, bool fixed = false) - : nscsi_connector(mconfig, tag, owner, 0) + : nscsi_connector(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(fixed); } - nscsi_connector(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nscsi_connector(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~nscsi_connector(); nscsi_device *get_device(); @@ -131,7 +131,7 @@ public: virtual void scsi_ctrl_changed(); protected: - nscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nscsi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -311,7 +311,7 @@ protected: SBUF_SENSE }; - nscsi_full_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nscsi_full_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/machine/nscsi_cb.cpp b/src/devices/machine/nscsi_cb.cpp index 5d42caf8265..afd54b4465d 100644 --- a/src/devices/machine/nscsi_cb.cpp +++ b/src/devices/machine/nscsi_cb.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(NSCSI_CB, nscsi_callback_device, "nscsi_cb", "SCSI callback (new)") -nscsi_callback_device::nscsi_callback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nscsi_callback_device::nscsi_callback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nscsi_device(mconfig, NSCSI_CB, tag, owner, clock), nscsi_slot_card_interface(mconfig, *this, DEVICE_SELF), m_write_rst(*this), diff --git a/src/devices/machine/nscsi_cb.h b/src/devices/machine/nscsi_cb.h index 5cc96b83862..551174e8a8f 100644 --- a/src/devices/machine/nscsi_cb.h +++ b/src/devices/machine/nscsi_cb.h @@ -11,7 +11,7 @@ class nscsi_callback_device : public nscsi_device, public nscsi_slot_card_interface { public: - nscsi_callback_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nscsi_callback_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto rst_callback() { return m_write_rst.bind(); } auto atn_callback() { return m_write_atn.bind(); } diff --git a/src/devices/machine/nvram.cpp b/src/devices/machine/nvram.cpp index 84c07477e9a..49f4875e375 100644 --- a/src/devices/machine/nvram.cpp +++ b/src/devices/machine/nvram.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(NVRAM, nvram_device, "nvram", "NVRAM") // nvram_device - constructor //------------------------------------------------- -nvram_device::nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nvram_device::nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NVRAM, tag, owner, clock), device_nvram_interface(mconfig, *this), m_region(*this, DEVICE_SELF), diff --git a/src/devices/machine/nvram.h b/src/devices/machine/nvram.h index 58bde56bece..d6ba521c699 100644 --- a/src/devices/machine/nvram.h +++ b/src/devices/machine/nvram.h @@ -32,11 +32,11 @@ public: // construction/destruction nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, default_value value) - : nvram_device(mconfig, tag, owner, 0) + : nvram_device(mconfig, tag, owner) { set_default_value(value); } - nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nvram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration helpers void set_default_value(default_value value) { m_default_value = value; } diff --git a/src/devices/machine/output_latch.cpp b/src/devices/machine/output_latch.cpp index 7ed407d68f8..58b90b19018 100644 --- a/src/devices/machine/output_latch.cpp +++ b/src/devices/machine/output_latch.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(OUTPUT_LATCH, output_latch_device, "output_latch", "Output Latch") -output_latch_device::output_latch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +output_latch_device::output_latch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, OUTPUT_LATCH, tag, owner, clock) , m_bit_handlers(*this) , m_bits{ -1, -1, -1, -1, -1, -1, -1, -1 } diff --git a/src/devices/machine/output_latch.h b/src/devices/machine/output_latch.h index 0e6a87ff6dc..5339af1df2f 100644 --- a/src/devices/machine/output_latch.h +++ b/src/devices/machine/output_latch.h @@ -9,7 +9,7 @@ class output_latch_device : public device_t { public: - output_latch_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + output_latch_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <unsigned Bit> auto bit_handler() { return m_bit_handlers[Bit].bind(); } diff --git a/src/devices/machine/pc_fdc.cpp b/src/devices/machine/pc_fdc.cpp index d1668f2381d..8ed951aebdb 100644 --- a/src/devices/machine/pc_fdc.cpp +++ b/src/devices/machine/pc_fdc.cpp @@ -38,7 +38,7 @@ void pc_fdc_xt_device::map(address_map &map) } -pc_fdc_family_device::pc_fdc_family_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +pc_fdc_family_device::pc_fdc_family_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), fdc(*this, "upd765"), intrq_cb(*this), drq_cb(*this) @@ -62,7 +62,7 @@ void pc_fdc_family_device::dma_w(uint8_t data) void pc_fdc_family_device::device_add_mconfig(machine_config &config) { - UPD765A(config, fdc, 8'000'000, false, false); + UPD765A(config, fdc, XTAL::u(8'000'000), false, false); fdc->intrq_wr_callback().set(FUNC(pc_fdc_family_device::irq_w)); fdc->drq_wr_callback().set(FUNC(pc_fdc_family_device::drq_w)); } @@ -166,6 +166,6 @@ void pc_fdc_family_device::check_drq() drq_cb(drq); } -pc_fdc_xt_device::pc_fdc_xt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : pc_fdc_family_device(mconfig, PC_FDC_XT, tag, owner, clock) +pc_fdc_xt_device::pc_fdc_xt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc_fdc_family_device(mconfig, PC_FDC_XT, tag, owner, clock) { } diff --git a/src/devices/machine/pc_fdc.h b/src/devices/machine/pc_fdc.h index bbb2f0a9068..da2898e7dba 100644 --- a/src/devices/machine/pc_fdc.h +++ b/src/devices/machine/pc_fdc.h @@ -32,7 +32,7 @@ public: required_device<upd765a_device> fdc; protected: - pc_fdc_family_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pc_fdc_family_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -54,7 +54,7 @@ private: class pc_fdc_xt_device : public pc_fdc_family_device { public: - pc_fdc_xt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc_fdc_xt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; void dor_fifo_w(uint8_t data); diff --git a/src/devices/machine/pc_lpt.cpp b/src/devices/machine/pc_lpt.cpp index 26d2357a72b..f8a20439670 100644 --- a/src/devices/machine/pc_lpt.cpp +++ b/src/devices/machine/pc_lpt.cpp @@ -12,7 +12,7 @@ DEFINE_DEVICE_TYPE(PC_LPT, pc_lpt_device, "pc_lpt", "PC LPT") -pc_lpt_device::pc_lpt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pc_lpt_device::pc_lpt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PC_LPT, tag, owner, clock), m_irq(1), m_data(0xff), m_control(0), diff --git a/src/devices/machine/pc_lpt.h b/src/devices/machine/pc_lpt.h index 911c657baa4..d72545a13df 100644 --- a/src/devices/machine/pc_lpt.h +++ b/src/devices/machine/pc_lpt.h @@ -21,7 +21,7 @@ class pc_lpt_device : public device_t { public: - pc_lpt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pc_lpt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/machine/pccard.cpp b/src/devices/machine/pccard.cpp index 83a05b99421..d095712b3b9 100644 --- a/src/devices/machine/pccard.cpp +++ b/src/devices/machine/pccard.cpp @@ -40,7 +40,7 @@ void device_pccard_interface::write_reg(offs_t offset, uint16_t data, uint16_t m DEFINE_DEVICE_TYPE(PCCARD_SLOT, pccard_slot_device, "pccard", "PC Card Slot") -pccard_slot_device::pccard_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pccard_slot_device::pccard_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCCARD_SLOT, tag, owner, clock), device_single_card_slot_interface<device_pccard_interface>(mconfig, *this), m_pccard(nullptr) diff --git a/src/devices/machine/pccard.h b/src/devices/machine/pccard.h index 9e06018f005..294d9c27403 100644 --- a/src/devices/machine/pccard.h +++ b/src/devices/machine/pccard.h @@ -27,14 +27,14 @@ class pccard_slot_device : public device_t, public device_single_card_slot_inter public: template <typename T> pccard_slot_device(machine_config const &mconfig, char const *tag, device_t *owner, T &&opts, char const *dflt) - : pccard_slot_device(mconfig, tag, owner, (uint32_t)0) + : pccard_slot_device(mconfig, tag, owner) { option_reset(); opts(*this); set_default_option(dflt); set_fixed(false); } - pccard_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pccard_slot_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); DECLARE_READ_LINE_MEMBER(read_line_inserted); uint16_t read_memory(offs_t offset, uint16_t mem_mask = ~0); diff --git a/src/devices/machine/pcf8573.cpp b/src/devices/machine/pcf8573.cpp index 791336b4bf5..2b4e630c790 100644 --- a/src/devices/machine/pcf8573.cpp +++ b/src/devices/machine/pcf8573.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(PCF8573, pcf8573_device, "pcf8573", "PCF8573 RTC with Power F // pcf8573_device - constructor //------------------------------------------------- -pcf8573_device::pcf8573_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pcf8573_device::pcf8573_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCF8573, tag, owner, clock) , device_rtc_interface(mconfig, *this) , m_comp_cb(*this) diff --git a/src/devices/machine/pcf8573.h b/src/devices/machine/pcf8573.h index a6b31e83ed7..00e7211c809 100644 --- a/src/devices/machine/pcf8573.h +++ b/src/devices/machine/pcf8573.h @@ -46,7 +46,7 @@ class pcf8573_device : public device_rtc_interface { public: - pcf8573_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pcf8573_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto comp_cb() { return m_comp_cb.bind(); } auto min_cb() { return m_min_cb.bind(); } diff --git a/src/devices/machine/pcf8583.cpp b/src/devices/machine/pcf8583.cpp index c09a6fce138..a543714eb7c 100644 --- a/src/devices/machine/pcf8583.cpp +++ b/src/devices/machine/pcf8583.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(PCF8583, pcf8583_device, "pcf8583", "PCF8583 RTC with 240x8 R // pcf8583_device - constructor //------------------------------------------------- -pcf8583_device::pcf8583_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pcf8583_device::pcf8583_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCF8583, tag, owner, clock) , device_rtc_interface(mconfig, *this) , device_nvram_interface(mconfig, *this) diff --git a/src/devices/machine/pcf8583.h b/src/devices/machine/pcf8583.h index d5018160788..6f128a0d1e6 100644 --- a/src/devices/machine/pcf8583.h +++ b/src/devices/machine/pcf8583.h @@ -74,7 +74,7 @@ class pcf8583_device : public device_nvram_interface { public: - pcf8583_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pcf8583_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq() { return m_irq_cb.bind(); } diff --git a/src/devices/machine/pcf8584.cpp b/src/devices/machine/pcf8584.cpp index 31d78e73008..f4b4de45f1a 100644 --- a/src/devices/machine/pcf8584.cpp +++ b/src/devices/machine/pcf8584.cpp @@ -52,7 +52,7 @@ const char *const pcf8584_device::s_bus_function[4] = { "NOP", "stop", "start", // pcf8584_device - constructor //------------------------------------------------- -pcf8584_device::pcf8584_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +pcf8584_device::pcf8584_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCF8584, tag, owner, clock) , m_sda_callback(*this) , m_sda_out_callback(*this) diff --git a/src/devices/machine/pcf8584.h b/src/devices/machine/pcf8584.h index 68886a7affc..3f59e856b59 100644 --- a/src/devices/machine/pcf8584.h +++ b/src/devices/machine/pcf8584.h @@ -39,7 +39,7 @@ class pcf8584_device : public device_t public: // device type constructor - pcf8584_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pcf8584_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto sda_cb() { return m_sda_callback.bind(); } diff --git a/src/devices/machine/pcf8593.cpp b/src/devices/machine/pcf8593.cpp index 3ba4f1af89b..0e052492d2f 100644 --- a/src/devices/machine/pcf8593.cpp +++ b/src/devices/machine/pcf8593.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(PCF8593, pcf8593_device, "pcf8593", "PCF8593 RTC") // pcf8593_device - constructor //------------------------------------------------- -pcf8593_device::pcf8593_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pcf8593_device::pcf8593_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCF8593, tag, owner, clock) , device_rtc_interface(mconfig, *this) , device_nvram_interface(mconfig, *this) diff --git a/src/devices/machine/pcf8593.h b/src/devices/machine/pcf8593.h index 3720ac1bb53..ca9302594fb 100644 --- a/src/devices/machine/pcf8593.h +++ b/src/devices/machine/pcf8593.h @@ -22,7 +22,7 @@ class pcf8593_device : public device_t, public device_nvram_interface { public: - pcf8593_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pcf8593_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); DECLARE_WRITE_LINE_MEMBER(scl_w); DECLARE_WRITE_LINE_MEMBER(sda_w); diff --git a/src/devices/machine/pci-apic.cpp b/src/devices/machine/pci-apic.cpp index 2a7c1a26261..b4818b12607 100644 --- a/src/devices/machine/pci-apic.cpp +++ b/src/devices/machine/pci-apic.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(APIC, apic_device, "apic", "I/O Advanced Programmable Interrupt Controller") -apic_device::apic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +apic_device::apic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, APIC, tag, owner, clock) { } diff --git a/src/devices/machine/pci-apic.h b/src/devices/machine/pci-apic.h index ede3d80baf3..8d0056bb53d 100644 --- a/src/devices/machine/pci-apic.h +++ b/src/devices/machine/pci-apic.h @@ -9,12 +9,12 @@ class apic_device : public pci_device { public: - apic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) + apic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) : apic_device(mconfig, tag, owner, clock) { set_ids(main_id, revision, 0x080010, subdevice_id); } - apic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + apic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/pci-ide.cpp b/src/devices/machine/pci-ide.cpp index b24a944eb3b..6e37acfc321 100644 --- a/src/devices/machine/pci-ide.cpp +++ b/src/devices/machine/pci-ide.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(IDE_PCI, ide_pci_device, "ide_pci", "PCI IDE interface") -ide_pci_device::ide_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ide_pci_device::ide_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, IDE_PCI, tag, owner, clock), m_ide(*this, "ide"), m_ide2(*this, "ide2"), diff --git a/src/devices/machine/pci-ide.h b/src/devices/machine/pci-ide.h index af3d7ae0a4d..1cad2df5bff 100644 --- a/src/devices/machine/pci-ide.h +++ b/src/devices/machine/pci-ide.h @@ -21,14 +21,14 @@ TODO: class ide_pci_device : public pci_device { public: - ide_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id + ide_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t main_id, uint32_t revision, uint32_t subdevice_id , const char *bmtag = ":pci:00.0", uint32_t bmspace = AS_DATA) - : ide_pci_device(mconfig, tag, owner, clock) + : ide_pci_device(mconfig, tag, owner) { set_ids(main_id, revision, 0x01018a, subdevice_id); m_bus_master_space.set_tag(bmtag, bmspace); } - ide_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ide_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/machine/pci-sata.cpp b/src/devices/machine/pci-sata.cpp index 1332fea71d5..78ef30f631a 100644 --- a/src/devices/machine/pci-sata.cpp +++ b/src/devices/machine/pci-sata.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(SATA, sata_device, "sata", "SATA AHCI interface") -sata_device::sata_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sata_device::sata_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, SATA, tag, owner, clock) { } diff --git a/src/devices/machine/pci-sata.h b/src/devices/machine/pci-sata.h index edf3545c1d7..803e034cdc4 100644 --- a/src/devices/machine/pci-sata.h +++ b/src/devices/machine/pci-sata.h @@ -9,12 +9,12 @@ class sata_device : public pci_device { public: - sata_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) + sata_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) : sata_device(mconfig, tag, owner, clock) { set_ids(main_id, revision, 0x01018a, subdevice_id); } - sata_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sata_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/pci-smbus.cpp b/src/devices/machine/pci-smbus.cpp index 62a4f99cbb7..15f218ae8cb 100644 --- a/src/devices/machine/pci-smbus.cpp +++ b/src/devices/machine/pci-smbus.cpp @@ -28,7 +28,7 @@ void smbus_device::map(address_map &map) map(0x17, 0x17).r(FUNC(smbus_device::notify_dhigh_r)); } -smbus_device::smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +smbus_device::smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, SMBUS, tag, owner, clock) { } diff --git a/src/devices/machine/pci-smbus.h b/src/devices/machine/pci-smbus.h index 9c7cd79aa74..fa834666b46 100644 --- a/src/devices/machine/pci-smbus.h +++ b/src/devices/machine/pci-smbus.h @@ -7,12 +7,12 @@ class smbus_device : public pci_device { public: - smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) + smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) : smbus_device(mconfig, tag, owner, clock) { set_ids(main_id, revision, 0x0c0500, subdevice_id); } - smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/pci-usb.cpp b/src/devices/machine/pci-usb.cpp index 0b45c1bd9ee..28523013576 100644 --- a/src/devices/machine/pci-usb.cpp +++ b/src/devices/machine/pci-usb.cpp @@ -11,7 +11,7 @@ void usb_ohci_device::map(address_map &map) { } -usb_ohci_device::usb_ohci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +usb_ohci_device::usb_ohci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, USB_OHCI, tag, owner, clock) { } @@ -31,7 +31,7 @@ void usb_uhci_device::map(address_map &map) { } -usb_uhci_device::usb_uhci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +usb_uhci_device::usb_uhci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, USB_UHCI, tag, owner, clock) { } @@ -51,7 +51,7 @@ void usb_ehci_device::map(address_map &map) { } -usb_ehci_device::usb_ehci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +usb_ehci_device::usb_ehci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, USB_EHCI, tag, owner, clock) { } diff --git a/src/devices/machine/pci-usb.h b/src/devices/machine/pci-usb.h index 388fa28b24d..d5dca213873 100644 --- a/src/devices/machine/pci-usb.h +++ b/src/devices/machine/pci-usb.h @@ -9,12 +9,12 @@ class usb_ohci_device : public pci_device { public: - usb_ohci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) + usb_ohci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) : usb_ohci_device(mconfig, tag, owner, clock) { set_ids(main_id, revision, 0x0c0310, subdevice_id); } - usb_ohci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + usb_ohci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -26,12 +26,12 @@ private: class usb_uhci_device : public pci_device { public: - usb_uhci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) + usb_uhci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) : usb_uhci_device(mconfig, tag, owner, clock) { set_ids(main_id, revision, 0x0c0300, subdevice_id); } - usb_uhci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + usb_uhci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -43,12 +43,12 @@ private: class usb_ehci_device : public pci_device { public: - usb_ehci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) + usb_ehci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) : usb_ehci_device(mconfig, tag, owner, clock) { set_ids(main_id, revision, 0x0c0320, subdevice_id); } - usb_ehci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + usb_ehci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/pci.cpp b/src/devices/machine/pci.cpp index c0f2676ca56..3016307ee19 100644 --- a/src/devices/machine/pci.cpp +++ b/src/devices/machine/pci.cpp @@ -69,7 +69,7 @@ void pci_bridge_device::config_map(address_map &map) map(0x3e, 0x3f).rw(FUNC(pci_bridge_device::bridge_control_r), FUNC(pci_bridge_device::bridge_control_w)); } -pci_device::pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pci_device::pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_region(*this, DEVICE_SELF) { @@ -446,7 +446,7 @@ void pci_device::set_map_flags(int id, int flags) remap_cb(); } -agp_device::agp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +agp_device::agp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, type, tag, owner, clock) { } @@ -463,12 +463,12 @@ void agp_device::device_reset() -pci_bridge_device::pci_bridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pci_bridge_device::pci_bridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_bridge_device(mconfig, PCI_BRIDGE, tag, owner, clock) { } -pci_bridge_device::pci_bridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pci_bridge_device::pci_bridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , configure_space_config("configuration_space", ENDIANNESS_LITTLE, 32, 20) @@ -844,7 +844,7 @@ void pci_bridge_device::bridge_control_w(offs_t offset, uint16_t data, uint16_t } -agp_bridge_device::agp_bridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +agp_bridge_device::agp_bridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : pci_bridge_device(mconfig, type, tag, owner, clock) { } @@ -868,7 +868,7 @@ void pci_host_device::io_configuration_access_map(address_map &map) } -pci_host_device::pci_host_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pci_host_device::pci_host_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : pci_bridge_device(mconfig, type, tag, owner, clock) { } @@ -956,7 +956,7 @@ void pci_host_device::root_config_write(uint8_t bus, uint8_t device, uint16_t re } -pci_root_device::pci_root_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pci_root_device::pci_root_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCI_ROOT, tag, owner, clock) { } diff --git a/src/devices/machine/pci.h b/src/devices/machine/pci.h index 53e1a6be3d1..7f14ef1df84 100644 --- a/src/devices/machine/pci.h +++ b/src/devices/machine/pci.h @@ -72,7 +72,7 @@ public: void interrupt_pin_w(offs_t offset, uint8_t data, uint8_t mem_mask = ~0); protected: - pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); optional_memory_region m_region; @@ -136,7 +136,7 @@ protected: class agp_device : public pci_device { protected: - agp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + agp_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -144,12 +144,12 @@ protected: class pci_bridge_device : public pci_device, public device_memory_interface { public: - pci_bridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t main_id, uint32_t revision) + pci_bridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t main_id, uint32_t revision) : pci_bridge_device(mconfig, tag, owner, clock) { set_ids_bridge(main_id, revision); } - pci_bridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pci_bridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void set_remap_cb(mapper_cb _remap_cb) override; virtual void map_device(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space, @@ -201,7 +201,7 @@ protected: AS_PCI_CONFIG = 0 }; - pci_bridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pci_bridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -232,7 +232,7 @@ private: class agp_bridge_device : public pci_bridge_device { protected: - agp_bridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + agp_bridge_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -243,7 +243,7 @@ public: void io_configuration_access_map(address_map &map); protected: - pci_host_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pci_host_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); uint32_t config_address_r(); void config_address_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0); @@ -271,7 +271,7 @@ protected: class pci_root_device : public device_t { public: - pci_root_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pci_root_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/pci9050.cpp b/src/devices/machine/pci9050.cpp index 9f5c63c621e..280a7559a52 100644 --- a/src/devices/machine/pci9050.cpp +++ b/src/devices/machine/pci9050.cpp @@ -39,7 +39,7 @@ void pci9050_device::map(address_map &map) map(0x50, 0x53).rw(FUNC(pci9050_device::cntrl_r), FUNC(pci9050_device::cntrl_w)); } -pci9050_device::pci9050_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pci9050_device::pci9050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, PCI9050, tag, owner, clock) , m_user_input_handler(*this), m_user_output_handler(*this) { diff --git a/src/devices/machine/pckeybrd.cpp b/src/devices/machine/pckeybrd.cpp index c2b46fbe4b7..76a77753799 100644 --- a/src/devices/machine/pckeybrd.cpp +++ b/src/devices/machine/pckeybrd.cpp @@ -278,20 +278,20 @@ const at_keyboard_device::extended_keyboard_code at_keyboard_device::m_extended_ DEFINE_DEVICE_TYPE(PC_KEYB, pc_keyboard_device, "pc_keyb", "PC Keyboard") DEFINE_DEVICE_TYPE(AT_KEYB, at_keyboard_device, "at_keyb", "AT Keyboard") -pc_keyboard_device::pc_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pc_keyboard_device::pc_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc_keyboard_device(mconfig, PC_KEYB, tag, owner, clock) { m_type = KEYBOARD_TYPE::PC; } -pc_keyboard_device::pc_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +pc_keyboard_device::pc_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_ioport(*this, "pc_keyboard_%u", 0), m_out_keypress_func(*this) { } -at_keyboard_device::at_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +at_keyboard_device::at_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pc_keyboard_device(mconfig, AT_KEYB, tag, owner, clock), m_leds(*this, "led%u", 0U), m_scan_code_set(1) diff --git a/src/devices/machine/pckeybrd.h b/src/devices/machine/pckeybrd.h index e52981b10c4..a3a2ee77d70 100644 --- a/src/devices/machine/pckeybrd.h +++ b/src/devices/machine/pckeybrd.h @@ -20,7 +20,7 @@ class pc_keyboard_device : public device_t { public: - pc_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pc_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint8_t read(); void enable(int state); @@ -35,7 +35,7 @@ public: }; protected: - pc_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pc_keyboard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual ioport_constructor device_input_ports() const override; virtual void device_start() override; @@ -80,12 +80,12 @@ class at_keyboard_device : public pc_keyboard_device { public: at_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, KEYBOARD_TYPE type, int default_set) - : at_keyboard_device(mconfig, tag, owner, 0) + : at_keyboard_device(mconfig, tag, owner) { set_type(type, default_set); } - at_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + at_keyboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void write(uint8_t data); diff --git a/src/devices/machine/pdc.cpp b/src/devices/machine/pdc.cpp index 2a482d8a236..6e2fd04a001 100644 --- a/src/devices/machine/pdc.cpp +++ b/src/devices/machine/pdc.cpp @@ -256,7 +256,7 @@ void pdc_device::device_add_mconfig(machine_config &config) //config.m_perfect_cpu_quantum = subtag(M6502_TAG); /* Floppy Disk Controller - uPD765a - NEC D765AC-2 */ - UPD765A(config, m_fdc, 4'000'000, true, true); + UPD765A(config, m_fdc, XTAL::u(4'000'000), true, true); m_fdc->intrq_wr_callback().set(FUNC(pdc_device::fdc_irq)); m_fdc->drq_wr_callback().set(m_dma8237, FUNC(am9517a_device::dreq0_w)); //.invert(); @@ -279,7 +279,7 @@ void pdc_device::device_add_mconfig(machine_config &config) /* Hard Disk Controller - HDC9224 */ // TODO: connect the HDC lines - HDC9224(config, HDC_TAG, 0); + HDC9224(config, HDC_TAG); MFM_HD_CONNECTOR(config, "h1", pdc_harddisks, nullptr, MFM_BYTE, 3000, 20, MFMHD_GEN_FORMAT); } @@ -297,7 +297,7 @@ ioport_constructor pdc_device::device_input_ports() const // pdc_device - constructor //------------------------------------------------- -pdc_device::pdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pdc_device::pdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PDC, tag, owner, clock), m_pdccpu(*this, Z80_TAG), m_dma8237(*this, FDCDMA_TAG), @@ -347,7 +347,7 @@ void pdc_device::device_reset() /* Reset CPU */ m_pdccpu->reset(); - m_fdc->set_rate(500000) ; + m_fdc->set_rate(XTAL::u(500000)) ; } //------------------------------------------------- diff --git a/src/devices/machine/pdc.h b/src/devices/machine/pdc.h index 416354b9c48..b301ad1aa13 100644 --- a/src/devices/machine/pdc.h +++ b/src/devices/machine/pdc.h @@ -34,7 +34,7 @@ class pdc_device : public device_t { public: /* Constructor and Destructor */ - pdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); /* Callbacks */ auto m68k_r_callback() { return m_m68k_r_cb.bind(); } diff --git a/src/devices/machine/phi.cpp b/src/devices/machine/phi.cpp index 7659a0359a1..38aafef40f9 100644 --- a/src/devices/machine/phi.cpp +++ b/src/devices/machine/phi.cpp @@ -187,7 +187,7 @@ constexpr uint8_t CONTROLLER_ADDR = 0x1e; // PHI always has this address when DEFINE_DEVICE_TYPE(PHI, phi_device, "hp_phi", "HP Processor-to-HPIB Interface") // Constructors -phi_device::phi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +phi_device::phi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_dio_read_func(*this), m_dio_write_func(*this), @@ -198,7 +198,7 @@ phi_device::phi_device(const machine_config &mconfig, device_type type, const ch { } -phi_device::phi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +phi_device::phi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : phi_device(mconfig, PHI, tag, owner, clock) { } diff --git a/src/devices/machine/phi.h b/src/devices/machine/phi.h index 4eb74b6bbca..bdb73bc5ed6 100644 --- a/src/devices/machine/phi.h +++ b/src/devices/machine/phi.h @@ -16,7 +16,7 @@ class phi_device : public device_t { public: // construction/destruction - phi_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + phi_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // See ieee488.h enum phi_488_signal_t @@ -90,7 +90,7 @@ public: uint8_t reg8_r(offs_t offset); protected: - phi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + phi_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/machine/pic8259.cpp b/src/devices/machine/pic8259.cpp index 385f38cfbdb..8abb6271055 100644 --- a/src/devices/machine/pic8259.cpp +++ b/src/devices/machine/pic8259.cpp @@ -468,7 +468,7 @@ DEFINE_DEVICE_TYPE(PIC8259, pic8259_device, "pic8259", "Intel 8259 PIC") DEFINE_DEVICE_TYPE(V5X_ICU, v5x_icu_device, "v5x_icu", "NEC V5X ICU") DEFINE_DEVICE_TYPE(MK98PIC, mk98pic_device, "mk98pic", "Elektronika MK-98 PIC") -pic8259_device::pic8259_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pic8259_device::pic8259_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_out_int_func(*this) , m_in_sp_func(*this) @@ -479,17 +479,17 @@ pic8259_device::pic8259_device(const machine_config &mconfig, device_type type, { } -pic8259_device::pic8259_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pic8259_device::pic8259_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic8259_device(mconfig, PIC8259, tag, owner, clock) { } -v5x_icu_device::v5x_icu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v5x_icu_device::v5x_icu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic8259_device(mconfig, V5X_ICU, tag, owner, clock) { } -mk98pic_device::mk98pic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mk98pic_device::mk98pic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pic8259_device(mconfig, MK98PIC, tag, owner, clock) { } diff --git a/src/devices/machine/pic8259.h b/src/devices/machine/pic8259.h index 333cadced09..02bfd57935f 100644 --- a/src/devices/machine/pic8259.h +++ b/src/devices/machine/pic8259.h @@ -31,7 +31,7 @@ class pic8259_device : public device_t { public: - pic8259_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pic8259_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto out_int_callback() { return m_out_int_func.bind(); } // Interrupt request output to CPU or master 8259 (active high) auto in_sp_callback() { return m_in_sp_func.bind(); } // Slave program select (VCC = master; GND = slave; pin becomes EN output in buffered mode) @@ -53,7 +53,7 @@ public: IRQ_CALLBACK_MEMBER(inta_cb); protected: - pic8259_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pic8259_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -119,7 +119,7 @@ private: class v5x_icu_device : public pic8259_device { public: - v5x_icu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + v5x_icu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual bool is_x86() const override { return true; } @@ -128,7 +128,7 @@ protected: class mk98pic_device : public pic8259_device { public: - mk98pic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mk98pic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual bool is_x86() const override { return true; } diff --git a/src/devices/machine/pit8253.cpp b/src/devices/machine/pit8253.cpp index fc7c79cc289..8778a6b9f1a 100644 --- a/src/devices/machine/pit8253.cpp +++ b/src/devices/machine/pit8253.cpp @@ -46,17 +46,17 @@ DEFINE_DEVICE_TYPE(PIT8253, pit8253_device, "pit8253", "Intel 8253 PIT") DEFINE_DEVICE_TYPE(PIT8254, pit8254_device, "pit8254", "Intel 8254 PIT") DEFINE_DEVICE_TYPE(FE2010_PIT, fe2010_pit_device, "fe2010_pit", "Faraday FE2010 PIT") -pit_counter_device::pit_counter_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pit_counter_device::pit_counter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PIT_COUNTER, tag, owner, clock) { } -pit8253_device::pit8253_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pit8253_device::pit8253_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pit8253_device(mconfig, PIT8253, tag, owner, clock, pit_type::I8253) { } -pit8253_device::pit8253_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, pit_type chip_type) : +pit8253_device::pit8253_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, pit_type chip_type) : device_t(mconfig, type, tag, owner, clock), m_clk{0, 0, 0}, m_out_handler(*this), @@ -66,12 +66,12 @@ pit8253_device::pit8253_device(const machine_config &mconfig, device_type type, } -pit8254_device::pit8254_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pit8254_device::pit8254_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pit8253_device(mconfig, PIT8254, tag, owner, clock, pit_type::I8254) { } -fe2010_pit_device::fe2010_pit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +fe2010_pit_device::fe2010_pit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pit8253_device(mconfig, FE2010_PIT, tag, owner, clock, pit_type::FE2010) { } @@ -82,9 +82,9 @@ fe2010_pit_device::fe2010_pit_device(const machine_config &mconfig, const char * void pit8253_device::device_add_mconfig(machine_config &config) { - PIT_COUNTER(config, "counter0", 0); - PIT_COUNTER(config, "counter1", 0); - PIT_COUNTER(config, "counter2", 0); + PIT_COUNTER(config, "counter0"); + PIT_COUNTER(config, "counter1"); + PIT_COUNTER(config, "counter2"); } diff --git a/src/devices/machine/pit8253.h b/src/devices/machine/pit8253.h index 0c069a217d8..64b164ff851 100644 --- a/src/devices/machine/pit8253.h +++ b/src/devices/machine/pit8253.h @@ -44,7 +44,7 @@ class pit_counter_device : public device_t public: // construction/destruction - pit_counter_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pit_counter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -109,7 +109,7 @@ class pit8253_device : public device_t public: // construction/destruction - pit8253_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pit8253_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers template <unsigned N> void set_clk(double clk) { m_clk[N] = clk; } @@ -140,7 +140,7 @@ public: void set_clockin(int timer, double new_clockin) { m_counter[timer]->set_clockin(new_clockin); } protected: - pit8253_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, pit_type chip_type); + pit8253_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, pit_type chip_type); // device-level overrides virtual void device_add_mconfig(machine_config &config) override; @@ -162,7 +162,7 @@ DECLARE_DEVICE_TYPE(PIT8253, pit8253_device) class pit8254_device : public pit8253_device { public: - pit8254_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pit8254_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void readback_command(uint8_t data) override; @@ -173,7 +173,7 @@ DECLARE_DEVICE_TYPE(PIT8254, pit8254_device) class fe2010_pit_device : public pit8253_device { public: - fe2010_pit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + fe2010_pit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(FE2010_PIT, fe2010_pit_device) diff --git a/src/devices/machine/pla.cpp b/src/devices/machine/pla.cpp index fe72d5b12c8..a0f395c2d7c 100644 --- a/src/devices/machine/pla.cpp +++ b/src/devices/machine/pla.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(MOS8721, mos8721_device, "mos8721", "MOS 8721 PLA") // pla_device - constructor //------------------------------------------------- -pla_device::pla_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +pla_device::pla_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_region(*this, DEVICE_SELF) , m_format(FMT::JEDBIN) @@ -37,12 +37,12 @@ pla_device::pla_device(const machine_config &mconfig, device_type type, const ch { } -pla_device::pla_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pla_device::pla_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pla_device(mconfig, PLA, tag, owner, clock) { } -pls100_device::pls100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pls100_device::pls100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pla_device(mconfig, PLS100, tag, owner, clock) { set_num_inputs(16); @@ -50,7 +50,7 @@ pls100_device::pls100_device(const machine_config &mconfig, const char *tag, dev set_num_terms(48); } -mos8721_device::mos8721_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8721_device::mos8721_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pla_device(mconfig, MOS8721, tag, owner, clock) { // TODO: actual number of terms is unknown diff --git a/src/devices/machine/pla.h b/src/devices/machine/pla.h index 548ab4bf16b..0c201b28e73 100644 --- a/src/devices/machine/pla.h +++ b/src/devices/machine/pla.h @@ -48,10 +48,10 @@ public: }; // construction/destruction - pla_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - pla_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + pla_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); + pla_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); pla_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t inputs, uint32_t outputs, uint32_t terms) - : pla_device(mconfig, tag, owner, (uint32_t)0) + : pla_device(mconfig, tag, owner) { set_num_inputs(inputs); set_num_outputs(outputs); @@ -107,13 +107,13 @@ private: class pls100_device : public pla_device { public: - pls100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + pls100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class mos8721_device : public pla_device { public: - mos8721_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mos8721_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(PLA, pla_device) diff --git a/src/devices/machine/ps2dma.cpp b/src/devices/machine/ps2dma.cpp index 6e143123fb0..0c7db188a48 100644 --- a/src/devices/machine/ps2dma.cpp +++ b/src/devices/machine/ps2dma.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(SONYPS2_DMAC, ps2_dmac_device, "ps2dmac", "PlayStation 2 EE DMAC") -ps2_dmac_device::ps2_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ps2_dmac_device::ps2_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYPS2_DMAC, tag, owner, clock) , device_execute_interface(mconfig, *this) , m_ee(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/ps2dma.h b/src/devices/machine/ps2dma.h index b602999de28..8b40bad7975 100644 --- a/src/devices/machine/ps2dma.h +++ b/src/devices/machine/ps2dma.h @@ -22,7 +22,7 @@ class ps2_dmac_device : public device_t, public device_execute_interface { public: template <typename T, typename U, typename V, typename W, typename X> - ps2_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&ee_tag, U &&ram_tag, V &&sif_tag, W &&gs_tag, X &&vu1_tag) + ps2_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&ee_tag, U &&ram_tag, V &&sif_tag, W &&gs_tag, X &&vu1_tag) : ps2_dmac_device(mconfig, tag, owner, clock) { m_ee.set_tag(std::forward<T>(ee_tag)); @@ -32,7 +32,7 @@ public: m_vu1.set_tag(std::forward<X>(vu1_tag)); } - ps2_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ps2_dmac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~ps2_dmac_device() override; enum channel_type : uint32_t diff --git a/src/devices/machine/ps2intc.cpp b/src/devices/machine/ps2intc.cpp index 10b6602606e..0ea4d1b414c 100644 --- a/src/devices/machine/ps2intc.cpp +++ b/src/devices/machine/ps2intc.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(SONYPS2_INTC, ps2_intc_device, "ps2intc", "PlayStation 2 EE INTC") -ps2_intc_device::ps2_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ps2_intc_device::ps2_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYPS2_INTC, tag, owner, clock) , m_ee(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/machine/ps2intc.h b/src/devices/machine/ps2intc.h index 111c343372f..fa97d6a5693 100644 --- a/src/devices/machine/ps2intc.h +++ b/src/devices/machine/ps2intc.h @@ -23,12 +23,12 @@ class ps2_intc_device : public device_t public: template <typename T> ps2_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&ee_tag) - : ps2_intc_device(mconfig, tag, owner, (uint32_t)0) + : ps2_intc_device(mconfig, tag, owner) { m_ee.set_tag(std::forward<T>(ee_tag)); } - ps2_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ps2_intc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~ps2_intc_device() override; uint32_t read(offs_t offset, uint32_t mem_mask = ~0); diff --git a/src/devices/machine/ps2mc.cpp b/src/devices/machine/ps2mc.cpp index b253f6153b7..5c80c1da8a4 100644 --- a/src/devices/machine/ps2mc.cpp +++ b/src/devices/machine/ps2mc.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(SONYPS2_MC, ps2_mc_device, "ps2mc", "PlayStation 2 Memory Car /*static*/ const size_t ps2_mc_device::BUFFER_SIZE = 512; // Total guess /*static*/ const uint8_t ps2_mc_device::DEFAULT_TERMINATOR = 0x55; -ps2_mc_device::ps2_mc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ps2_mc_device::ps2_mc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYPS2_MC, tag, owner, clock) { } diff --git a/src/devices/machine/ps2mc.h b/src/devices/machine/ps2mc.h index ef38dea72c2..fe79fb0baaa 100644 --- a/src/devices/machine/ps2mc.h +++ b/src/devices/machine/ps2mc.h @@ -17,12 +17,7 @@ class ps2_mc_device : public device_t { public: - ps2_mc_device(const machine_config &mconfig, const char *tag, device_t *owner) - : ps2_mc_device(mconfig, tag, owner, (uint32_t)0) - { - } - - ps2_mc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ps2_mc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~ps2_mc_device() override; void recv_fifo_push(uint8_t data); // TODO: Turn me into a bus interface! diff --git a/src/devices/machine/ps2pad.cpp b/src/devices/machine/ps2pad.cpp index 64e1009a331..17afcca7e4d 100644 --- a/src/devices/machine/ps2pad.cpp +++ b/src/devices/machine/ps2pad.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(SONYPS2_PAD, ps2_pad_device, "ps2pad", "Sony DualShock 2") /*static*/ const size_t ps2_pad_device::BUFFER_SIZE = 64; // Total guess -ps2_pad_device::ps2_pad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ps2_pad_device::ps2_pad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYPS2_PAD, tag, owner, clock) { } diff --git a/src/devices/machine/ps2pad.h b/src/devices/machine/ps2pad.h index 2b384fd0818..7e3962727dc 100644 --- a/src/devices/machine/ps2pad.h +++ b/src/devices/machine/ps2pad.h @@ -17,12 +17,7 @@ class ps2_pad_device : public device_t { public: - ps2_pad_device(const machine_config &mconfig, const char *tag, device_t *owner) - : ps2_pad_device(mconfig, tag, owner, (uint32_t)0) - { - } - - ps2_pad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ps2_pad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~ps2_pad_device() override; void recv_fifo_push(uint8_t data); // TODO: Turn me into a bus interface! diff --git a/src/devices/machine/ps2sif.cpp b/src/devices/machine/ps2sif.cpp index b6fd6d5cfe7..a5ab0b46949 100644 --- a/src/devices/machine/ps2sif.cpp +++ b/src/devices/machine/ps2sif.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(SONYPS2_SIF, ps2_sif_device, "ps2sif", "PlayStation 2 SIF") /*static*/ const size_t ps2_sif_device::MAX_FIFO_DEPTH = 0x20; -ps2_sif_device::ps2_sif_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ps2_sif_device::ps2_sif_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYPS2_SIF, tag, owner, clock) , m_intc(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/machine/ps2sif.h b/src/devices/machine/ps2sif.h index 83fe5f4a076..63686bd9714 100644 --- a/src/devices/machine/ps2sif.h +++ b/src/devices/machine/ps2sif.h @@ -21,12 +21,12 @@ class ps2_sif_device : public device_t public: template <typename T> ps2_sif_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&intc_tag) - : ps2_sif_device(mconfig, tag, owner, (uint32_t)0) + : ps2_sif_device(mconfig, tag, owner) { m_intc.set_tag(std::forward<T>(intc_tag)); } - ps2_sif_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ps2_sif_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~ps2_sif_device() override; uint32_t ee_r(offs_t offset, uint32_t mem_mask = ~0); diff --git a/src/devices/machine/ps2timer.cpp b/src/devices/machine/ps2timer.cpp index 667fed7622c..f2c44c274a0 100644 --- a/src/devices/machine/ps2timer.cpp +++ b/src/devices/machine/ps2timer.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(SONYPS2_TIMER, ps2_timer_device, "ps2timer", "PlayStation 2 EE Core Timer") -ps2_timer_device::ps2_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ps2_timer_device::ps2_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYPS2_TIMER, tag, owner, clock) , m_compare_timer(nullptr) , m_overflow_timer(nullptr) diff --git a/src/devices/machine/ps2timer.h b/src/devices/machine/ps2timer.h index f7cd398f938..5761467ca62 100644 --- a/src/devices/machine/ps2timer.h +++ b/src/devices/machine/ps2timer.h @@ -17,13 +17,13 @@ class ps2_timer_device : public device_t { public: - ps2_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, bool can_hold) + ps2_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool can_hold) : ps2_timer_device(mconfig, tag, owner, clock) { m_can_hold = can_hold; } - ps2_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ps2_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t read(offs_t offset, uint32_t mem_mask = ~0); void write(offs_t offset, uint32_t data, uint32_t mem_mask = ~0); diff --git a/src/devices/machine/pxa255.cpp b/src/devices/machine/pxa255.cpp index d387347dd98..e86ea8d607c 100644 --- a/src/devices/machine/pxa255.cpp +++ b/src/devices/machine/pxa255.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(PXA255_PERIPHERALS, pxa255_periphs_device, "pxa255_periphs", "Intel XScale PXA255 Peripherals") -pxa255_periphs_device::pxa255_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pxa255_periphs_device::pxa255_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PXA255_PERIPHERALS, tag, owner, clock) , m_gpio0_w(*this) , m_gpio1_w(*this) diff --git a/src/devices/machine/pxa255.h b/src/devices/machine/pxa255.h index 75eadbac2c5..4c4d5c8b742 100644 --- a/src/devices/machine/pxa255.h +++ b/src/devices/machine/pxa255.h @@ -26,13 +26,13 @@ class pxa255_periphs_device : public device_t { public: template <typename T> - pxa255_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag) + pxa255_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag) : pxa255_periphs_device(mconfig, tag, owner, clock) { m_maincpu.set_tag(std::forward<T>(cpu_tag)); } - pxa255_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pxa255_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto gpio0_write() { return m_gpio0_w.bind(); } auto gpio0_read() { return m_gpio0_r.bind(); } diff --git a/src/devices/machine/r10696.cpp b/src/devices/machine/r10696.cpp index ce9140ef7d5..8f9c6a20ce6 100644 --- a/src/devices/machine/r10696.cpp +++ b/src/devices/machine/r10696.cpp @@ -44,7 +44,7 @@ DEFINE_DEVICE_TYPE(R10696, r10696_device, "r10696", "Rockwell 10696 GPIO") -r10696_device::r10696_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +r10696_device::r10696_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, R10696, tag, owner, clock) , m_io_a(0), m_io_b(0), m_io_c(0) , m_iord(*this), m_iowr(*this) diff --git a/src/devices/machine/r10696.h b/src/devices/machine/r10696.h index dc33c4519f3..394fab6d36b 100644 --- a/src/devices/machine/r10696.h +++ b/src/devices/machine/r10696.h @@ -22,7 +22,7 @@ class r10696_device : public device_t { public: - r10696_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + r10696_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t io_r(offs_t offset); void io_w(offs_t offset, uint8_t data); diff --git a/src/devices/machine/r10788.cpp b/src/devices/machine/r10788.cpp index 4a8a8161ad5..2244098c4cc 100644 --- a/src/devices/machine/r10788.cpp +++ b/src/devices/machine/r10788.cpp @@ -54,7 +54,7 @@ DEFINE_DEVICE_TYPE(R10788, r10788_device, "r10788", "Rockwell 10788 KDC") -r10788_device::r10788_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +r10788_device::r10788_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, R10788, tag, owner, clock) , m_ktr(0), m_kts(0), m_kla(0), m_klb(0), m_mask_a(15), m_mask_b(15), m_ker(0) , m_io_counter(0), m_scan_counter(0) diff --git a/src/devices/machine/r10788.h b/src/devices/machine/r10788.h index 9a94ad65b5c..7dea3287001 100644 --- a/src/devices/machine/r10788.h +++ b/src/devices/machine/r10788.h @@ -21,7 +21,7 @@ class r10788_device : public device_t { public: - r10788_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + r10788_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); enum { KTR = 0xc, //!< Transfer Keyboard Return diff --git a/src/devices/machine/ra17xx.cpp b/src/devices/machine/ra17xx.cpp index eebdc134727..24d50fdcd21 100644 --- a/src/devices/machine/ra17xx.cpp +++ b/src/devices/machine/ra17xx.cpp @@ -52,7 +52,7 @@ DEFINE_DEVICE_TYPE(RA17XX, ra17xx_device, "ra17xx", "Rockwell A17xx") -ra17xx_device::ra17xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ra17xx_device::ra17xx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RA17XX, tag, owner, clock) , m_enable(false) , m_iord(*this) diff --git a/src/devices/machine/ra17xx.h b/src/devices/machine/ra17xx.h index 54e4fc9028f..28a6b04c71d 100644 --- a/src/devices/machine/ra17xx.h +++ b/src/devices/machine/ra17xx.h @@ -22,7 +22,7 @@ class ra17xx_device : public device_t { public: - ra17xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ra17xx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t io_r(offs_t offset); void io_w(address_space &space, offs_t offset, uint8_t data); diff --git a/src/devices/machine/ram.cpp b/src/devices/machine/ram.cpp index 40b361bdc6a..826db0c6cec 100644 --- a/src/devices/machine/ram.cpp +++ b/src/devices/machine/ram.cpp @@ -120,7 +120,7 @@ DEFINE_DEVICE_TYPE(RAM, ram_device, "ram", "RAM") // ram_device - constructor //------------------------------------------------- -ram_device::ram_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ram_device::ram_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RAM, tag, owner, clock) , m_size(0) , m_default_size(0) diff --git a/src/devices/machine/ram.h b/src/devices/machine/ram.h index 8b17b3eadc5..3375f39938b 100644 --- a/src/devices/machine/ram.h +++ b/src/devices/machine/ram.h @@ -36,7 +36,7 @@ public: using extra_option_vector = std::vector<extra_option>; // construction/destruction - ram_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 0); + ram_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL()); // accessors u32 size() const { return m_size; } diff --git a/src/devices/machine/rf5c296.cpp b/src/devices/machine/rf5c296.cpp index 37a0adf3a3b..f040c9f16f9 100644 --- a/src/devices/machine/rf5c296.cpp +++ b/src/devices/machine/rf5c296.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(RF5C296, rf5c296_device, "rf5c296", "RF5C296 PC Card controller") -rf5c296_device::rf5c296_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rf5c296_device::rf5c296_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RF5C296, tag, owner, clock) , m_rf5c296_reg(0) , m_pccard(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/rf5c296.h b/src/devices/machine/rf5c296.h index b5f3beea7fc..312defb262c 100644 --- a/src/devices/machine/rf5c296.h +++ b/src/devices/machine/rf5c296.h @@ -11,7 +11,7 @@ class rf5c296_device : public device_t { public: - rf5c296_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rf5c296_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers template <typename T> void set_pccard(T &&tag) { m_pccard.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/machine/ripple_counter.cpp b/src/devices/machine/ripple_counter.cpp index 25639eb6bb3..47dcc36b789 100644 --- a/src/devices/machine/ripple_counter.cpp +++ b/src/devices/machine/ripple_counter.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(RIPPLE_COUNTER, ripple_counter_device, "ripple_counter", "Gen // ripple_counter_device - constructor //------------------------------------------------- -ripple_counter_device::ripple_counter_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ripple_counter_device::ripple_counter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RIPPLE_COUNTER, tag, owner, clock), device_rom_interface(mconfig, *this), m_count_out_cb(*this), diff --git a/src/devices/machine/ripple_counter.h b/src/devices/machine/ripple_counter.h index fb7648334e3..dc1e80f7375 100644 --- a/src/devices/machine/ripple_counter.h +++ b/src/devices/machine/ripple_counter.h @@ -23,7 +23,7 @@ class ripple_counter_device : public device_t, public device_rom_interface<14> { public: // construction/destruction - ripple_counter_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + ripple_counter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration void set_stages(u8 stages) { m_count_mask = (1U << stages) - 1; override_address_width(stages); } diff --git a/src/devices/machine/roc10937.cpp b/src/devices/machine/roc10937.cpp index e9c44ab822b..becac7e1a0c 100644 --- a/src/devices/machine/roc10937.cpp +++ b/src/devices/machine/roc10937.cpp @@ -129,7 +129,7 @@ static const int roc10937poslut[]= 0//15 }; -rocvfd_device::rocvfd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +rocvfd_device::rocvfd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_outputs(), m_cursor_pos(0), @@ -252,22 +252,22 @@ DEFINE_DEVICE_TYPE(MIC10937, mic10937_device, "mic10937", "Micrel MIC10937 VFD c DEFINE_DEVICE_TYPE(ROC10957, roc10957_device, "roc10957", "Rockwell 10957 VFD controller") // and compatible DEFINE_DEVICE_TYPE(S16LF01, s16lf01_device, "s16lf01", "Samsung 16LF01 Series VFD") // and compatible, basically the MSC1937 on a 16 seg display -roc10937_device::roc10937_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +roc10937_device::roc10937_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rocvfd_device(mconfig, ROC10937, tag, owner, clock) { } -msc1937_device::msc1937_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msc1937_device::msc1937_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rocvfd_device(mconfig, MSC1937, tag, owner, clock) { } -mic10937_device::mic10937_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mic10937_device::mic10937_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rocvfd_device(mconfig, MIC10937, tag, owner, clock) { } -s16lf01_device::s16lf01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s16lf01_device::s16lf01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rocvfd_device(mconfig, S16LF01, tag, owner, clock) { } @@ -324,7 +324,7 @@ void rocvfd_device::write_char(int data) } } -roc10957_device::roc10957_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +roc10957_device::roc10957_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rocvfd_device(mconfig, ROC10957, tag, owner, clock) { } diff --git a/src/devices/machine/roc10937.h b/src/devices/machine/roc10937.h index da0f21eb808..ac775e3c831 100644 --- a/src/devices/machine/roc10937.h +++ b/src/devices/machine/roc10937.h @@ -27,7 +27,7 @@ public: protected: - rocvfd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + rocvfd_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); std::unique_ptr<output_finder<16> > m_outputs; std::unique_ptr<output_finder<1> > m_brightness; @@ -59,29 +59,29 @@ private: class roc10937_device : public rocvfd_device { public: - roc10937_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 60); + roc10937_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(60)); }; class msc1937_device : public rocvfd_device { public: - msc1937_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 60); + msc1937_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(60)); }; class mic10937_device : public rocvfd_device { public: - mic10937_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 60); + mic10937_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(60)); }; class roc10957_device : public rocvfd_device { public: - roc10957_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 60); + roc10957_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(60)); void write_char(int data); }; class s16lf01_device : public rocvfd_device { public: - s16lf01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 60); + s16lf01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(60)); }; diff --git a/src/devices/machine/rp5c01.cpp b/src/devices/machine/rp5c01.cpp index 8a59f07e9f8..a628a8975aa 100644 --- a/src/devices/machine/rp5c01.cpp +++ b/src/devices/machine/rp5c01.cpp @@ -169,12 +169,12 @@ inline void rp5c01_device::check_alarm() // rp5c01_device - constructor //------------------------------------------------- -rp5c01_device::rp5c01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rp5c01_device::rp5c01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rp5c01_device(mconfig, RP5C01, tag, owner, clock) { } -rp5c01_device::rp5c01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +rp5c01_device::rp5c01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_rtc_interface(mconfig, *this), device_nvram_interface(mconfig, *this), @@ -428,7 +428,7 @@ void rp5c01_device::write(offs_t offset, uint8_t data) // tc8521_device - constructor //------------------------------------------------- -tc8521_device::tc8521_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tc8521_device::tc8521_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rp5c01_device(mconfig, TC8521, tag, owner, clock) { } diff --git a/src/devices/machine/rp5c01.h b/src/devices/machine/rp5c01.h index 7e48269b72c..2c8aa2c9851 100644 --- a/src/devices/machine/rp5c01.h +++ b/src/devices/machine/rp5c01.h @@ -38,7 +38,7 @@ class rp5c01_device : public device_t, { public: // construction/destruction - rp5c01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rp5c01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_alarm_callback() { return m_out_alarm_cb.bind(); } void remove_battery() { m_battery_backed = false; nvram_enable_backup(false); } @@ -50,7 +50,7 @@ public: protected: // construction/destruction - rp5c01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + rp5c01_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -98,7 +98,7 @@ class tc8521_device : public rp5c01_device { public: // construction/destruction - tc8521_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tc8521_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/machine/rp5c15.cpp b/src/devices/machine/rp5c15.cpp index a37b779c6fd..9708a996e0d 100644 --- a/src/devices/machine/rp5c15.cpp +++ b/src/devices/machine/rp5c15.cpp @@ -183,7 +183,7 @@ inline void rp5c15_device::check_alarm() // rp5c15_device - constructor //------------------------------------------------- -rp5c15_device::rp5c15_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rp5c15_device::rp5c15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RP5C15, tag, owner, clock), device_rtc_interface(mconfig, *this), m_out_alarm_cb(*this), diff --git a/src/devices/machine/rp5c15.h b/src/devices/machine/rp5c15.h index 15936a02445..3359e766ff0 100644 --- a/src/devices/machine/rp5c15.h +++ b/src/devices/machine/rp5c15.h @@ -30,7 +30,7 @@ class rp5c15_device : public device_t, { public: // construction/destruction - rp5c15_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rp5c15_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto alarm() { return m_out_alarm_cb.bind(); } auto clkout() { return m_out_clkout_cb.bind(); } diff --git a/src/devices/machine/rp5h01.cpp b/src/devices/machine/rp5h01.cpp index 655ffd5f841..f8e2658bcb9 100644 --- a/src/devices/machine/rp5h01.cpp +++ b/src/devices/machine/rp5h01.cpp @@ -32,7 +32,7 @@ uint8_t const rp5h01_device::s_initial_data[0x10] = DEFINE_DEVICE_TYPE(RP5H01, rp5h01_device, "rp5h01", "RP5H01 6/7-bit Counter") -rp5h01_device::rp5h01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rp5h01_device::rp5h01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RP5H01, tag, owner, clock) , m_data(nullptr) , m_rom(*this, DEVICE_SELF) diff --git a/src/devices/machine/rp5h01.h b/src/devices/machine/rp5h01.h index 686367c694e..46fa4c5d6b0 100644 --- a/src/devices/machine/rp5h01.h +++ b/src/devices/machine/rp5h01.h @@ -31,7 +31,7 @@ class rp5h01_device : public device_t { public: - rp5h01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rp5h01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( enable_w ); /* /CE */ DECLARE_WRITE_LINE_MEMBER( reset_w ); /* RESET */ diff --git a/src/devices/machine/rstbuf.cpp b/src/devices/machine/rstbuf.cpp index 9e13d72743a..b321bc0c9ef 100644 --- a/src/devices/machine/rstbuf.cpp +++ b/src/devices/machine/rstbuf.cpp @@ -71,7 +71,7 @@ DEFINE_DEVICE_TYPE(RST_NEG_BUFFER, rst_neg_buffer_device, "rst_neg_buffer", "RST // rst_buffer_device - constructor //------------------------------------------------- -rst_buffer_device::rst_buffer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +rst_buffer_device::rst_buffer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_int_cb(*this) , m_input_buffer(0) @@ -83,7 +83,7 @@ rst_buffer_device::rst_buffer_device(const machine_config &mconfig, device_type // rst_pos_buffer_device - constructor //------------------------------------------------- -rst_pos_buffer_device::rst_pos_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rst_pos_buffer_device::rst_pos_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rst_buffer_device(mconfig, RST_POS_BUFFER, tag, owner, clock) { } @@ -93,7 +93,7 @@ rst_pos_buffer_device::rst_pos_buffer_device(const machine_config &mconfig, cons // rst_neg_buffer_device - constructor //------------------------------------------------- -rst_neg_buffer_device::rst_neg_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rst_neg_buffer_device::rst_neg_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rst_buffer_device(mconfig, RST_NEG_BUFFER, tag, owner, clock) { } diff --git a/src/devices/machine/rstbuf.h b/src/devices/machine/rstbuf.h index 718a96f4861..f4cb6006acb 100644 --- a/src/devices/machine/rstbuf.h +++ b/src/devices/machine/rstbuf.h @@ -30,7 +30,7 @@ public: protected: // device base class constructor - rst_buffer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + rst_buffer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_resolve_objects() override; @@ -54,7 +54,7 @@ class rst_pos_buffer_device : public rst_buffer_device { public: // device constructor - rst_pos_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + rst_pos_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // set RST 1/RST 08H request line (modifies bit 3 of vector) DECLARE_WRITE_LINE_MEMBER(rst1_w) { sync_input(state, 0x08); } @@ -76,7 +76,7 @@ class rst_neg_buffer_device : public rst_buffer_device { public: // device constructor - rst_neg_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + rst_neg_buffer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // set RST 30H request line (modifies bit 3 of vector) DECLARE_WRITE_LINE_MEMBER(rst30_w) { sync_input(state, 0x08); } diff --git a/src/devices/machine/rtc4543.cpp b/src/devices/machine/rtc4543.cpp index 773724a4170..c57affcce15 100644 --- a/src/devices/machine/rtc4543.cpp +++ b/src/devices/machine/rtc4543.cpp @@ -49,12 +49,12 @@ DEFINE_DEVICE_TYPE(RTC4543, rtc4543_device, "rtc4543", "Epson R4543 RTC") // rtc4543_device - constructor //------------------------------------------------- -rtc4543_device::rtc4543_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rtc4543_device::rtc4543_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rtc4543_device(mconfig, RTC4543, tag, owner, clock) { } -rtc4543_device::rtc4543_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +rtc4543_device::rtc4543_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_rtc_interface(mconfig, *this) , m_data_cb(*this) @@ -350,7 +350,7 @@ DEFINE_DEVICE_TYPE(JRC6355E, jrc6355e_device, "jrc6355e", "JRC 6355E RTC") // jrc6355e_device - constructor //------------------------------------------------- -jrc6355e_device::jrc6355e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +jrc6355e_device::jrc6355e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rtc4543_device(mconfig, JRC6355E, tag, owner, clock) { } diff --git a/src/devices/machine/rtc4543.h b/src/devices/machine/rtc4543.h index a29cbb9ec30..8a8d7e397f4 100644 --- a/src/devices/machine/rtc4543.h +++ b/src/devices/machine/rtc4543.h @@ -28,7 +28,7 @@ class rtc4543_device : public device_t, public: // construction/destruction - rtc4543_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rtc4543_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( ce_w ); DECLARE_WRITE_LINE_MEMBER( wr_w ); @@ -39,7 +39,7 @@ public: auto data_cb() { return m_data_cb.bind(); } protected: - rtc4543_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + rtc4543_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -82,7 +82,7 @@ class jrc6355e_device : public rtc4543_device { public: // construction/destruction - jrc6355e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + jrc6355e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // rtc4543 overrides diff --git a/src/devices/machine/rtc65271.cpp b/src/devices/machine/rtc65271.cpp index dc7aad8d210..3f56da9773a 100644 --- a/src/devices/machine/rtc65271.cpp +++ b/src/devices/machine/rtc65271.cpp @@ -669,7 +669,7 @@ DEFINE_DEVICE_TYPE(RTC65271, rtc65271_device, "rtc65271", "Epson RTC-65271 RTC") // rtc65271_device - constructor //------------------------------------------------- -rtc65271_device::rtc65271_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rtc65271_device::rtc65271_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RTC65271, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_interrupt_cb(*this) diff --git a/src/devices/machine/rtc65271.h b/src/devices/machine/rtc65271.h index a3d77bf3fa9..aa1443cc6b6 100644 --- a/src/devices/machine/rtc65271.h +++ b/src/devices/machine/rtc65271.h @@ -17,7 +17,7 @@ class rtc65271_device : public device_t, { public: // construction/destruction - rtc65271_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rtc65271_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto interrupt_cb() { return m_interrupt_cb.bind(); } diff --git a/src/devices/machine/rtc9701.cpp b/src/devices/machine/rtc9701.cpp index 3dab4bd1835..89c145ef4ac 100644 --- a/src/devices/machine/rtc9701.cpp +++ b/src/devices/machine/rtc9701.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(RTC9701, rtc9701_device, "rtc9701", "Epson RTC-9701-JE RTC/EE // rtc9701_device - constructor //------------------------------------------------- -rtc9701_device::rtc9701_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rtc9701_device::rtc9701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RTC9701, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_latch(0) diff --git a/src/devices/machine/rtc9701.h b/src/devices/machine/rtc9701.h index 49d8e56582d..3f51c02ce0e 100644 --- a/src/devices/machine/rtc9701.h +++ b/src/devices/machine/rtc9701.h @@ -26,7 +26,7 @@ class rtc9701_device : public device_t, { public: // construction/destruction - rtc9701_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 32'768); + rtc9701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = 32'768); // I/O operations diff --git a/src/devices/machine/s2636.cpp b/src/devices/machine/s2636.cpp index 8ad26690bcf..c76e167dafb 100644 --- a/src/devices/machine/s2636.cpp +++ b/src/devices/machine/s2636.cpp @@ -157,7 +157,7 @@ uint16_t const s2636_device::SCORE_FONT[16][5] = DEFINE_DEVICE_TYPE(S2636, s2636_device, "s2636", "Signetics 2636 PVI") -s2636_device::s2636_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s2636_device::s2636_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S2636, tag, owner, clock) , device_video_interface(mconfig, *this) , device_sound_interface(mconfig, *this) diff --git a/src/devices/machine/s2636.h b/src/devices/machine/s2636.h index 8803c629015..7116fb57102 100644 --- a/src/devices/machine/s2636.h +++ b/src/devices/machine/s2636.h @@ -27,7 +27,7 @@ class s2636_device : public device_t, public device_sound_interface { public: - s2636_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s2636_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_offsets(int y_offset, int x_offset) { m_x_offset = x_offset; m_y_offset = y_offset; } diff --git a/src/devices/machine/s3520cf.cpp b/src/devices/machine/s3520cf.cpp index 86676ca3d2b..6a147852d81 100644 --- a/src/devices/machine/s3520cf.cpp +++ b/src/devices/machine/s3520cf.cpp @@ -36,12 +36,12 @@ DEFINE_DEVICE_TYPE(RTC4553, rtc4553_device, "rtc4553", "Epson RTC-4553 RTC/SRAM" // s3520cf_device - constructor //------------------------------------------------- -s3520cf_device::s3520cf_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +s3520cf_device::s3520cf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : s3520cf_device(mconfig, S3520CF, tag, owner, clock) { } -s3520cf_device::s3520cf_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +s3520cf_device::s3520cf_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_region(*this, DEVICE_SELF) @@ -334,7 +334,7 @@ WRITE_LINE_MEMBER( s3520cf_device::set_clock_line ) } } -rtc4553_device::rtc4553_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rtc4553_device::rtc4553_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : s3520cf_device(mconfig, RTC4553, tag, owner, clock) { } diff --git a/src/devices/machine/s3520cf.h b/src/devices/machine/s3520cf.h index 5c8f0c8614b..c3efa1bc940 100644 --- a/src/devices/machine/s3520cf.h +++ b/src/devices/machine/s3520cf.h @@ -23,7 +23,7 @@ class s3520cf_device : public device_t, { public: // construction/destruction - s3520cf_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 32'768); + s3520cf_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32'768)); // I/O operations DECLARE_READ_LINE_MEMBER( read_bit ); @@ -34,7 +34,7 @@ public: TIMER_CALLBACK_MEMBER(timer_callback); protected: - s3520cf_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + s3520cf_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); struct rtc_regs_t { @@ -79,7 +79,7 @@ Epson RTC-4553 class rtc4553_device : public s3520cf_device { public: - rtc4553_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 32'768); + rtc4553_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32'768)); }; // device type definition diff --git a/src/devices/machine/s3c2400.cpp b/src/devices/machine/s3c2400.cpp index 69649d04db0..cbffe4eda79 100644 --- a/src/devices/machine/s3c2400.cpp +++ b/src/devices/machine/s3c2400.cpp @@ -161,7 +161,7 @@ uint32_t s3c2400_device::screen_update(screen_device &screen, bitmap_rgb32 &bitm DEFINE_DEVICE_TYPE(S3C2400, s3c2400_device, "s3c2400", "Samsung S3C2400 SoC") -s3c2400_device::s3c2400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s3c2400_device::s3c2400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S3C2400, tag, owner, clock) , m_cpu(*this, ":maincpu") , m_palette(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/s3c2400.h b/src/devices/machine/s3c2400.h index b5390419a93..0f509404ce3 100644 --- a/src/devices/machine/s3c2400.h +++ b/src/devices/machine/s3c2400.h @@ -116,7 +116,7 @@ enum class s3c2400_device : public device_t, protected s3c24xx_peripheral_types { public: - s3c2400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s3c2400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~s3c2400_device(); // configuration diff --git a/src/devices/machine/s3c2410.cpp b/src/devices/machine/s3c2410.cpp index e630174b326..8d1aa87124e 100644 --- a/src/devices/machine/s3c2410.cpp +++ b/src/devices/machine/s3c2410.cpp @@ -217,7 +217,7 @@ uint32_t s3c2410_device::screen_update(screen_device &screen, bitmap_rgb32 &bitm DEFINE_DEVICE_TYPE(S3C2410, s3c2410_device, "s3c2410", "Samsung S3C2410 SoC") -s3c2410_device::s3c2410_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s3c2410_device::s3c2410_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S3C2410, tag, owner, clock) , m_cpu(*this, ":maincpu") , m_palette(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/s3c2410.h b/src/devices/machine/s3c2410.h index 9146baa7e7f..0ac17a9246a 100644 --- a/src/devices/machine/s3c2410.h +++ b/src/devices/machine/s3c2410.h @@ -134,7 +134,7 @@ enum class s3c2410_device : public device_t, protected s3c24xx_peripheral_types { public: - s3c2410_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s3c2410_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~s3c2410_device(); // configuration diff --git a/src/devices/machine/s3c2440.cpp b/src/devices/machine/s3c2440.cpp index 801c21dd01d..55e81fd38b9 100644 --- a/src/devices/machine/s3c2440.cpp +++ b/src/devices/machine/s3c2440.cpp @@ -232,7 +232,7 @@ uint32_t s3c2440_device::screen_update(screen_device &screen, bitmap_rgb32 &bitm DEFINE_DEVICE_TYPE(S3C2440, s3c2440_device, "s3c2440", "Samsung S3C2440 SoC") -s3c2440_device::s3c2440_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s3c2440_device::s3c2440_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S3C2440, tag, owner, clock) , m_cpu(*this, ":maincpu") , m_palette(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/s3c2440.h b/src/devices/machine/s3c2440.h index c4db773a475..97c34b6d8b5 100644 --- a/src/devices/machine/s3c2440.h +++ b/src/devices/machine/s3c2440.h @@ -154,7 +154,7 @@ enum class s3c2440_device : public device_t, protected s3c24xx_peripheral_types { public: - s3c2440_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s3c2440_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~s3c2440_device(); // configuration diff --git a/src/devices/machine/s3c44b0.cpp b/src/devices/machine/s3c44b0.cpp index dc5e52c31f0..df567201f99 100644 --- a/src/devices/machine/s3c44b0.cpp +++ b/src/devices/machine/s3c44b0.cpp @@ -223,7 +223,7 @@ static inline void ATTR_PRINTF(3,4) verboselog( device_t &device, int n_level, c DEFINE_DEVICE_TYPE(S3C44B0, s3c44b0_device, "s3c44b0", "Samsung S3C44B0 SoC") -s3c44b0_device::s3c44b0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s3c44b0_device::s3c44b0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S3C44B0, tag, owner, clock) , device_video_interface(mconfig, *this) , m_cpu(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/s3c44b0.h b/src/devices/machine/s3c44b0.h index e082937ea83..8bdacecbcbe 100644 --- a/src/devices/machine/s3c44b0.h +++ b/src/devices/machine/s3c44b0.h @@ -114,7 +114,7 @@ enum class s3c44b0_device : public device_t, public device_video_interface { public: - s3c44b0_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s3c44b0_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <class T> void set_cpu(T &&tag) { m_cpu.set_tag(std::forward<T>(tag)); } auto gpio_port_r_cb() { return m_port_r_cb.bind(); } diff --git a/src/devices/machine/s_smp.cpp b/src/devices/machine/s_smp.cpp index 9be87af48d5..b3547d2b28a 100644 --- a/src/devices/machine/s_smp.cpp +++ b/src/devices/machine/s_smp.cpp @@ -57,7 +57,7 @@ void s_smp_device::internal_map(address_map &map) DEFINE_DEVICE_TYPE(S_SMP, s_smp_device, "s_smp", "Nintendo/Sony S-SMP") -s_smp_device::s_smp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +s_smp_device::s_smp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spc700_device(mconfig, S_SMP, tag, owner, clock, address_map_constructor(FUNC(s_smp_device::internal_map), this)) , m_data_config("data", ENDIANNESS_LITTLE, 8, 16) , m_ipl_region(*this, "sound_ipl") diff --git a/src/devices/machine/s_smp.h b/src/devices/machine/s_smp.h index 45f83755507..17c4238eac5 100644 --- a/src/devices/machine/s_smp.h +++ b/src/devices/machine/s_smp.h @@ -18,7 +18,7 @@ class s_smp_device : public spc700_device { public: - s_smp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + s_smp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto dsp_io_read_callback() { return m_dsp_io_r_cb.bind(); } auto dsp_io_write_callback() { return m_dsp_io_w_cb.bind(); } diff --git a/src/devices/machine/sa1110.cpp b/src/devices/machine/sa1110.cpp index 5bcc62ba456..505108eb0bd 100644 --- a/src/devices/machine/sa1110.cpp +++ b/src/devices/machine/sa1110.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(SA1110_PERIPHERALS, sa1110_periphs_device, "sa1110_periphs", "Intel XScale SA1110 Peripherals") -sa1110_periphs_device::sa1110_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sa1110_periphs_device::sa1110_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SA1110_PERIPHERALS, tag, owner, clock) , device_serial_interface(mconfig, *this) , m_maincpu(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/sa1110.h b/src/devices/machine/sa1110.h index 3ef8e79042b..4a704562716 100644 --- a/src/devices/machine/sa1110.h +++ b/src/devices/machine/sa1110.h @@ -23,13 +23,13 @@ class sa1110_periphs_device : public device_t, public device_serial_interface { public: template <typename T> - sa1110_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag) + sa1110_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag) : sa1110_periphs_device(mconfig, tag, owner, clock) { m_maincpu.set_tag(std::forward<T>(cpu_tag)); } - sa1110_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sa1110_periphs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_codec_tag(T &&tag) { m_codec.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/machine/sa1111.cpp b/src/devices/machine/sa1111.cpp index 3a2dd300f78..848b4b59892 100644 --- a/src/devices/machine/sa1111.cpp +++ b/src/devices/machine/sa1111.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(SA1111, sa1111_device, "sa1111", "Intel SA1111 Microprocessor Companion Chip") -sa1111_device::sa1111_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sa1111_device::sa1111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SA1111, tag, owner, clock) , m_maincpu(*this, finder_base::DUMMY_TAG) , m_audio_codec(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/sa1111.h b/src/devices/machine/sa1111.h index 3804c06a30c..f18f7486d0a 100644 --- a/src/devices/machine/sa1111.h +++ b/src/devices/machine/sa1111.h @@ -18,13 +18,13 @@ class sa1111_device : public device_t { public: template <typename T> - sa1111_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag) + sa1111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag) : sa1111_device(mconfig, tag, owner, clock) { m_maincpu.set_tag(std::forward<T>(cpu_tag)); } - sa1111_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sa1111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_audio_codec_tag(T &&tag) { m_audio_codec.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/machine/saa1043.cpp b/src/devices/machine/saa1043.cpp index 053945c9a7e..1c0c89ccf8c 100644 --- a/src/devices/machine/saa1043.cpp +++ b/src/devices/machine/saa1043.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(SAA1043, saa1043_device, "saa1043", "Philips SAA1043") /*static*/ const uint32_t saa1043_device::s_line_counts[4] = { 624, 624, 524, 524 }; -saa1043_device::saa1043_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saa1043_device::saa1043_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAA1043, tag, owner, clock) , m_outputs(*this) , m_type(PAL) diff --git a/src/devices/machine/saa1043.h b/src/devices/machine/saa1043.h index 3a5851d0f42..cd5d6e9d899 100644 --- a/src/devices/machine/saa1043.h +++ b/src/devices/machine/saa1043.h @@ -42,7 +42,7 @@ class saa1043_device : public device_t { public: // construction/destruction - saa1043_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa1043_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); enum outputs : uint32_t { diff --git a/src/devices/machine/saa7191.cpp b/src/devices/machine/saa7191.cpp index a879506e84b..4f798dcad0e 100644 --- a/src/devices/machine/saa7191.cpp +++ b/src/devices/machine/saa7191.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(SAA7191, saa7191_device, "saa7191", "Philips SAA7191 DMSD") -saa7191_device::saa7191_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saa7191_device::saa7191_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAA7191, tag, owner, clock) , m_chr_in(*this) , m_cvbs_in(*this) diff --git a/src/devices/machine/saa7191.h b/src/devices/machine/saa7191.h index 907edfdc3b0..cf1f6a6d6a3 100644 --- a/src/devices/machine/saa7191.h +++ b/src/devices/machine/saa7191.h @@ -19,7 +19,7 @@ class saa7191_device : public device_t { public: - saa7191_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0U); + saa7191_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void i2c_data_w(uint8_t data); uint8_t i2c_data_r(); diff --git a/src/devices/machine/scc2698b.cpp b/src/devices/machine/scc2698b.cpp index 892c37c24bf..19285500ecc 100644 --- a/src/devices/machine/scc2698b.cpp +++ b/src/devices/machine/scc2698b.cpp @@ -67,7 +67,7 @@ void scc2698b_device::map(address_map &map) #define CHANH_TAG "chh" -scc2698b_channel::scc2698b_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +scc2698b_channel::scc2698b_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SCC2698B_CHANNEL, tag, owner, clock), device_serial_interface(mconfig, *this) { @@ -352,7 +352,7 @@ void scc2698b_channel::mpi1_w(int state) } -scc2698b_device::scc2698b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +scc2698b_device::scc2698b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SCC2698B, tag, owner, clock), m_channel(*this, "channel_%u",1), write_intr_A(*this), @@ -746,5 +746,5 @@ attotime scc2698b_device::generate_baudrate(int block, int tx, int table_index) void scc2698b_device::device_add_mconfig(machine_config &config) { for (required_device<scc2698b_channel> &channel : m_channel) - SCC2698B_CHANNEL(config, channel, 0); + SCC2698B_CHANNEL(config, channel); } diff --git a/src/devices/machine/scc2698b.h b/src/devices/machine/scc2698b.h index d883b45d0b9..e18b1473a3b 100644 --- a/src/devices/machine/scc2698b.h +++ b/src/devices/machine/scc2698b.h @@ -15,7 +15,7 @@ class scc2698b_channel : public device_t, public device_serial_interface { friend class scc2698b_device; public: - scc2698b_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc2698b_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void mpi0_w(int state); void mpi1_w(int state); @@ -76,7 +76,7 @@ protected: class scc2698b_device : public device_t { public: - scc2698b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc2698b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map); diff --git a/src/devices/machine/scc68070.cpp b/src/devices/machine/scc68070.cpp index a732b024ee6..ceca998c4e3 100644 --- a/src/devices/machine/scc68070.cpp +++ b/src/devices/machine/scc68070.cpp @@ -238,7 +238,7 @@ void scc68070_device::cpu_space_map(address_map &map) // scc68070_device - constructor //------------------------------------------------- -scc68070_device::scc68070_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scc68070_device::scc68070_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scc68070_base_device(mconfig, tag, owner, clock, SCC68070, address_map_constructor(FUNC(scc68070_device::internal_map), this)) , m_iack2_callback(*this) , m_iack4_callback(*this) diff --git a/src/devices/machine/scc68070.h b/src/devices/machine/scc68070.h index 430ed781c27..5c7bb00102a 100644 --- a/src/devices/machine/scc68070.h +++ b/src/devices/machine/scc68070.h @@ -46,7 +46,7 @@ enum scc68070_ocr_bits class scc68070_device : public scc68070_base_device { public: - scc68070_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc68070_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto iack2_callback() { return m_iack2_callback.bind(); } auto iack4_callback() { return m_iack4_callback.bind(); } diff --git a/src/devices/machine/scn_pci.cpp b/src/devices/machine/scn_pci.cpp index 43d450c4738..dbb80027839 100644 --- a/src/devices/machine/scn_pci.cpp +++ b/src/devices/machine/scn_pci.cpp @@ -157,7 +157,7 @@ ALLOW_SAVE_TYPE(scn_pci_device::xmtr_state); // scn_pci_device - constructor //------------------------------------------------- -scn_pci_device::scn_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, const u16 *br_div, bool is_enhanced, bool is_aci) +scn_pci_device::scn_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const u16 *br_div, bool is_enhanced, bool is_aci) : device_t(mconfig, type, tag, owner, clock) , m_dtr_callback(*this) , m_rts_callback(*this) @@ -210,7 +210,7 @@ scn_pci_device::scn_pci_device(const machine_config &mconfig, device_type type, // scn2651_device - constructor //------------------------------------------------- -scn2651_device::scn2651_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +scn2651_device::scn2651_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scn_pci_device(mconfig, SCN2651, tag, owner, clock, s_br_divisors_3, false, false) { } @@ -219,7 +219,7 @@ scn2651_device::scn2651_device(const machine_config &mconfig, const char *tag, d // scn2661a_device - constructor //------------------------------------------------- -scn2661a_device::scn2661a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +scn2661a_device::scn2661a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scn_pci_device(mconfig, SCN2661A, tag, owner, clock, s_br_divisors_1, true, false) { } @@ -228,7 +228,7 @@ scn2661a_device::scn2661a_device(const machine_config &mconfig, const char *tag, // scn2661b_device - constructor //------------------------------------------------- -scn2661b_device::scn2661b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +scn2661b_device::scn2661b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scn_pci_device(mconfig, SCN2661B, tag, owner, clock, s_br_divisors_2, true, false) { } @@ -237,7 +237,7 @@ scn2661b_device::scn2661b_device(const machine_config &mconfig, const char *tag, // scn2661c_device - constructor //------------------------------------------------- -scn2661c_device::scn2661c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +scn2661c_device::scn2661c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scn_pci_device(mconfig, SCN2661C, tag, owner, clock, s_br_divisors_3, true, false) { } @@ -246,7 +246,7 @@ scn2661c_device::scn2661c_device(const machine_config &mconfig, const char *tag, // scn2641_device - constructor //------------------------------------------------- -scn2641_device::scn2641_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +scn2641_device::scn2641_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scn_pci_device(mconfig, SCN2641, tag, owner, clock, s_br_divisors, true, true) , m_intr_callback(*this) { diff --git a/src/devices/machine/scn_pci.h b/src/devices/machine/scn_pci.h index acb16e90f72..86898859799 100644 --- a/src/devices/machine/scn_pci.h +++ b/src/devices/machine/scn_pci.h @@ -100,7 +100,7 @@ protected: }; // construction/destruction - scn_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, const u16 *br_div, bool is_enhanced, bool is_aci); + scn_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const u16 *br_div, bool is_enhanced, bool is_aci); // device-level overrides virtual void device_resolve_objects() override; @@ -215,7 +215,7 @@ class scn2651_device : public scn_pci_device { public: // device type constructor - scn2651_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + scn2651_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> scn2661a_device @@ -224,7 +224,7 @@ class scn2661a_device : public scn_pci_device { public: // device type constructor - scn2661a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + scn2661a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> scn2661b_device @@ -233,7 +233,7 @@ class scn2661b_device : public scn_pci_device { public: // device type constructor - scn2661b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + scn2661b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> scn2661c_device @@ -242,7 +242,7 @@ class scn2661c_device : public scn_pci_device { public: // device type constructor - scn2661c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + scn2661c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> scn2641_device @@ -251,7 +251,7 @@ class scn2641_device : public scn_pci_device { public: // device type constructor - scn2641_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + scn2641_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callback configuration auto intr_handler() { return m_intr_callback.bind(); } diff --git a/src/devices/machine/scnxx562.cpp b/src/devices/machine/scnxx562.cpp index 4f2da74c258..de337101675 100644 --- a/src/devices/machine/scnxx562.cpp +++ b/src/devices/machine/scnxx562.cpp @@ -129,8 +129,8 @@ DEFINE_DEVICE_TYPE(DUSCC68C562, duscc68c562_device, "duscc68c562", "Philips //------------------------------------------------- void duscc_device::device_add_mconfig(machine_config &config) { - DUSCC_CHANNEL(config, CHANA_TAG, 0); - DUSCC_CHANNEL(config, CHANB_TAG, 0); + DUSCC_CHANNEL(config, CHANA_TAG); + DUSCC_CHANNEL(config, CHANB_TAG); } //************************************************************************** @@ -140,7 +140,7 @@ void duscc_device::device_add_mconfig(machine_config &config) //------------------------------------------------- // duscc_device - constructor //------------------------------------------------- -duscc_device::duscc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +duscc_device::duscc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock) , device_z80daisy_interface(mconfig, *this) , m_chanA(*this, CHANA_TAG) @@ -174,27 +174,27 @@ duscc_device::duscc_device(const machine_config &mconfig, device_type type, cons elem = 0; } -duscc_device::duscc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +duscc_device::duscc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : duscc_device(mconfig, DUSCC, tag, owner, clock, TYPE_DUSCC) { } -duscc26562_device::duscc26562_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +duscc26562_device::duscc26562_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : duscc_device(mconfig, DUSCC26562, tag, owner, clock, TYPE_DUSCC26562) { } -duscc26c562_device::duscc26c562_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +duscc26c562_device::duscc26c562_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : duscc_device(mconfig, DUSCC26C562, tag, owner, clock, TYPE_DUSCC26C562) { } -duscc68562_device::duscc68562_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +duscc68562_device::duscc68562_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : duscc_device(mconfig, DUSCC68562, tag, owner, clock, TYPE_DUSCC68562) { } -duscc68c562_device::duscc68c562_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +duscc68c562_device::duscc68c562_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : duscc_device(mconfig, DUSCC68C562, tag, owner, clock, TYPE_DUSCC68C562) { } @@ -556,7 +556,7 @@ void duscc_device::write(offs_t offset, uint8_t data) //************************************************************************** // DUSCC CHANNEL //************************************************************************** -duscc_channel::duscc_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +duscc_channel::duscc_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DUSCC_CHANNEL, tag, owner, clock) , device_serial_interface(mconfig, *this) , m_brg_rx_rate(0) @@ -1968,7 +1968,7 @@ void duscc_channel::do_dusccreg_ccr_w(uint8_t data) status bit (GSR[I] or GSR[5] for Channels A and B, respectively). The counter/timer and other registers are not affected*/ case REG_CCR_RESET_TX: LOGINT("- Reset Tx\n"); - set_tra_rate(0); + set_tra_rate(XTAL::u(0)); m_tx_fifo_wp = m_tx_fifo_rp = 0; m_trsr &= 0x0f; m_uart->m_gsr &= ~(m_index == duscc_device::CHANNEL_A ? REG_GSR_CHAN_A_TXREADY : REG_GSR_CHAN_B_TXREADY); @@ -1990,7 +1990,7 @@ void duscc_channel::do_dusccreg_ccr_w(uint8_t data) will be transmitted. TODO: let all the chararcters be transmitted before shutting down shifter */ case REG_CCR_DISABLE_TX: LOGINT("- Disable Tx\n"); - set_tra_rate(0); + set_tra_rate(XTAL::u(0)); m_tra = 0; m_uart->m_gsr &= ~(m_index == duscc_device::CHANNEL_A ? REG_GSR_CHAN_A_TXREADY : REG_GSR_CHAN_B_TXREADY); m_uart->clear_interrupt(m_index, INT_TXREADY); @@ -2003,7 +2003,7 @@ void duscc_channel::do_dusccreg_ccr_w(uint8_t data) GSR[O] or GSR[4] for Channels A and B, respectively). The counter/timer and other registers are not affected.*/ case REG_CCR_RESET_RX: LOGINT("- Reset Rx\n"); - set_rcv_rate(0); + set_rcv_rate(XTAL::u(0)); m_rx_fifo_wp = m_rx_fifo_rp = 0; m_trsr &= 0xf0; m_rsr = 0; diff --git a/src/devices/machine/scnxx562.h b/src/devices/machine/scnxx562.h index c9ac458b44c..c6155e90b7e 100644 --- a/src/devices/machine/scnxx562.h +++ b/src/devices/machine/scnxx562.h @@ -58,7 +58,7 @@ class duscc_channel : public device_t, public device_serial_interface friend class duscc_device; public: - duscc_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + duscc_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // read register handlers uint8_t do_dusccreg_cmr1_r(); @@ -530,7 +530,7 @@ class duscc_device : public device_t, public device_z80daisy_interface public: // construction/destruction - duscc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + duscc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_txda_callback() { return m_out_txda_cb.bind(); } auto out_dtra_callback() { return m_out_dtra_cb.bind(); } @@ -547,13 +547,13 @@ public: auto out_trxcb_callback() { return m_out_trxcb_cb.bind(); } auto out_int_callback() { return m_out_int_cb.bind(); } - void configure_channels(int rxa, int txa, int rxb, int txb) + void configure_channels(const XTAL &rxa, const XTAL &txa, const XTAL &rxb, const XTAL &txb) { #if 0 // TODO: Fix this, need a way to set external rx/tx clocks for the channels - m_chanA->m_rxc = rxa; - m_chanA->m_txc = txa; - m_chanB->m_rxc = rxb; - m_chanB->m_txc = txb; + m_chanA->m_rxc = rxa.value(); + m_chanA->m_txc = txa.value(); + m_chanB->m_rxc = rxb.value(); + m_chanB->m_txc = txb.value(); #endif } @@ -587,7 +587,7 @@ public: void syncb_w(int state) { m_chanB->sync_w(state); } protected: - duscc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + duscc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_start() override; @@ -684,25 +684,25 @@ DECLARE_DEVICE_TYPE(DUSCC68C562, duscc68c562_device) class duscc26562_device : public duscc_device { public : - duscc26562_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + duscc26562_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class duscc26c562_device : public duscc_device { public : - duscc26c562_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + duscc26c562_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class duscc68562_device : public duscc_device { public : - duscc68562_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + duscc68562_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class duscc68c562_device : public duscc_device { public : - duscc68c562_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + duscc68c562_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; #endif // MAME_MACHINE_SCNXX562_H diff --git a/src/devices/machine/scoop.cpp b/src/devices/machine/scoop.cpp index 1a254169f93..2d73f7f936b 100644 --- a/src/devices/machine/scoop.cpp +++ b/src/devices/machine/scoop.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(SCOOP, scoop_device, "scoop", "Sharp SCOOP peripheral interface") -scoop_device::scoop_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scoop_device::scoop_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SCOOP, tag, owner, clock) , m_gpio_out(*this) { diff --git a/src/devices/machine/scoop.h b/src/devices/machine/scoop.h index 1fb0edaae66..24d93cced81 100644 --- a/src/devices/machine/scoop.h +++ b/src/devices/machine/scoop.h @@ -14,7 +14,7 @@ class scoop_device : public device_t { public: - scoop_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + scoop_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <unsigned Line> auto gpio_out() { return m_gpio_out[Line].bind(); } template <unsigned Line> void gpio_in(int state) { gpio_in((uint16_t)Line, state); } diff --git a/src/devices/machine/sda2006.cpp b/src/devices/machine/sda2006.cpp index 815cb829d85..b78a136a8af 100644 --- a/src/devices/machine/sda2006.cpp +++ b/src/devices/machine/sda2006.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(SDA2006, sda2006_device, "sda2006", "SDA2006 EEPROM") // sda2006_device - constructor //------------------------------------------------- -sda2006_device::sda2006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sda2006_device::sda2006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SDA2006, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_latch(0) diff --git a/src/devices/machine/sda2006.h b/src/devices/machine/sda2006.h index 1ae1748f5c2..7e77c60dc03 100644 --- a/src/devices/machine/sda2006.h +++ b/src/devices/machine/sda2006.h @@ -14,7 +14,7 @@ class sda2006_device : public device_t, { public: // construction/destruction - sda2006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sda2006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // I/O operations DECLARE_READ_LINE_MEMBER(read_data); diff --git a/src/devices/machine/sdlc.cpp b/src/devices/machine/sdlc.cpp index 7a7303b9e73..b5b96c1b60e 100644 --- a/src/devices/machine/sdlc.cpp +++ b/src/devices/machine/sdlc.cpp @@ -126,7 +126,7 @@ void device_sdlc_consumer_interface::rx_reset() } -sdlc_logger_device::sdlc_logger_device(machine_config const &mconfig, char const *tag, device_t *owner, std::uint32_t clock) : +sdlc_logger_device::sdlc_logger_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SDLC_LOGGER, tag, owner, clock), device_sdlc_consumer_interface(mconfig, *this), m_data_nrzi(0U), diff --git a/src/devices/machine/sdlc.h b/src/devices/machine/sdlc.h index 5dd7b177c3e..9bd589ea7ce 100644 --- a/src/devices/machine/sdlc.h +++ b/src/devices/machine/sdlc.h @@ -54,7 +54,7 @@ private: class sdlc_logger_device : public device_t, public device_sdlc_consumer_interface { public: - sdlc_logger_device(machine_config const &mconfig, char const *tag, device_t *owner, std::uint32_t clock); + sdlc_logger_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // input signals DECLARE_WRITE_LINE_MEMBER(data_w) { m_current_data = state ? 1U : 0U; } diff --git a/src/devices/machine/sega_scu.cpp b/src/devices/machine/sega_scu.cpp index c2e7191d7cb..990e0cda791 100644 --- a/src/devices/machine/sega_scu.cpp +++ b/src/devices/machine/sega_scu.cpp @@ -145,7 +145,7 @@ void sega_scu_device::regs_map(address_map &map) // sega_scu_device - constructor //------------------------------------------------- -sega_scu_device::sega_scu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega_scu_device::sega_scu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SEGA_SCU, tag, owner, clock), m_scudsp(*this, "scudsp"), m_hostcpu(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/machine/sega_scu.h b/src/devices/machine/sega_scu.h index 4ee8dd1f08d..0d4da8b9b7c 100644 --- a/src/devices/machine/sega_scu.h +++ b/src/devices/machine/sega_scu.h @@ -41,7 +41,7 @@ class sega_scu_device : public device_t { public: // construction/destruction - sega_scu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega_scu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations void regs_map(address_map &map); diff --git a/src/devices/machine/segacrp2_device.cpp b/src/devices/machine/segacrp2_device.cpp index 1a2676bd631..52254072344 100644 --- a/src/devices/machine/segacrp2_device.cpp +++ b/src/devices/machine/segacrp2_device.cpp @@ -92,7 +92,7 @@ DEFINE_DEVICE_TYPE(SEGA_317_0006, sega_317_0006_device, "sega_317_0006", "Sega 3 DEFINE_DEVICE_TYPE(SEGA_317_0007, sega_317_0007_device, "sega_317_0007", "Sega 317-0007") -segacrp2_z80_device::segacrp2_z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +segacrp2_z80_device::segacrp2_z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, type, tag, owner, clock), m_decrypted(*this, finder_base::DUMMY_TAG) { @@ -104,7 +104,7 @@ void segacrp2_z80_device::device_start() decrypt(); } -nec_315_5136_device::nec_315_5136_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nec_315_5136_device::nec_315_5136_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrp2_z80_device(mconfig, NEC_315_5136, tag, owner, clock) { } @@ -145,7 +145,7 @@ void nec_315_5136_device::decrypt() } -sega_315_5177_device::sega_315_5177_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_315_5177_device::sega_315_5177_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrp2_z80_device(mconfig, SEGA_315_5177, tag, owner, clock) { } @@ -202,7 +202,7 @@ void sega_315_5177_device::decrypt() } -sega_315_5176_device::sega_315_5176_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_315_5176_device::sega_315_5176_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrp2_z80_device(mconfig, SEGA_315_5176, tag, owner, clock) { } @@ -247,7 +247,7 @@ void sega_315_5176_device::decrypt() } -sega_315_5162_device::sega_315_5162_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_315_5162_device::sega_315_5162_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrp2_z80_device(mconfig, SEGA_315_5162, tag, owner, clock) { } @@ -282,7 +282,7 @@ void sega_315_5162_device::decrypt() -sega_315_5178_device::sega_315_5178_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_315_5178_device::sega_315_5178_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrp2_z80_device(mconfig, SEGA_315_5178, tag, owner, clock) { } @@ -329,7 +329,7 @@ void sega_315_5178_device::decrypt() } -sega_315_5179_device::sega_315_5179_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_315_5179_device::sega_315_5179_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrp2_z80_device(mconfig, SEGA_315_5179, tag, owner, clock) { } @@ -407,7 +407,7 @@ static void sega_decode_317(uint8_t *rom, uint8_t *decrypted, int shift) } -sega_317_0004_device::sega_317_0004_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_317_0004_device::sega_317_0004_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrp2_z80_device(mconfig, SEGA_317_0004, tag, owner, clock) { } @@ -418,7 +418,7 @@ void sega_317_0004_device::decrypt() } -sega_317_0005_device::sega_317_0005_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_317_0005_device::sega_317_0005_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrp2_z80_device(mconfig, SEGA_317_0005, tag, owner, clock) { } @@ -429,7 +429,7 @@ void sega_317_0005_device::decrypt() } -sega_317_0006_device::sega_317_0006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_317_0006_device::sega_317_0006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrp2_z80_device(mconfig, SEGA_317_0006, tag, owner, clock) { } @@ -440,7 +440,7 @@ void sega_317_0006_device::decrypt() } -sega_317_0007_device::sega_317_0007_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sega_317_0007_device::sega_317_0007_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrp2_z80_device(mconfig, SEGA_317_0007, tag, owner, clock) { } diff --git a/src/devices/machine/segacrp2_device.h b/src/devices/machine/segacrp2_device.h index a64f3fa5fe0..14e78acf367 100644 --- a/src/devices/machine/segacrp2_device.h +++ b/src/devices/machine/segacrp2_device.h @@ -15,7 +15,7 @@ public: template <typename T> void set_decrypted_tag(T &&decrypted_tag) { m_decrypted.set_tag(std::forward<T>(decrypted_tag)); } protected: - segacrp2_z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + segacrp2_z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void decrypt() = 0; @@ -29,7 +29,7 @@ protected: class nec_315_5136_device : public segacrp2_z80_device { public: - nec_315_5136_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + nec_315_5136_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -37,7 +37,7 @@ protected: class sega_315_5179_device : public segacrp2_z80_device { public: - sega_315_5179_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5179_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -46,7 +46,7 @@ protected: class sega_315_5178_device : public segacrp2_z80_device { public: - sega_315_5178_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5178_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -54,7 +54,7 @@ protected: class sega_315_5177_device : public segacrp2_z80_device { public: - sega_315_5177_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5177_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -62,7 +62,7 @@ protected: class sega_315_5176_device : public segacrp2_z80_device { public: - sega_315_5176_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5176_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -70,7 +70,7 @@ protected: class sega_315_5162_device : public segacrp2_z80_device { public: - sega_315_5162_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5162_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -78,7 +78,7 @@ protected: class sega_317_0004_device : public segacrp2_z80_device { public: - sega_317_0004_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_317_0004_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -87,7 +87,7 @@ protected: class sega_317_0005_device : public segacrp2_z80_device { public: - sega_317_0005_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_317_0005_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -96,7 +96,7 @@ protected: class sega_317_0006_device : public segacrp2_z80_device { public: - sega_317_0006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_317_0006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -104,7 +104,7 @@ protected: class sega_317_0007_device : public segacrp2_z80_device { public: - sega_317_0007_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_317_0007_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; diff --git a/src/devices/machine/segacrpt_device.cpp b/src/devices/machine/segacrpt_device.cpp index 330193aa2b9..2374819c018 100644 --- a/src/devices/machine/segacrpt_device.cpp +++ b/src/devices/machine/segacrpt_device.cpp @@ -284,7 +284,7 @@ DEFINE_DEVICE_TYPE(SEGA_315_5128, sega_315_5128_device, "sega_315_5128", "Sega 3 -segacrpt_z80_device::segacrpt_z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +segacrpt_z80_device::segacrpt_z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, type, tag, owner, clock), m_decrypted_ptr(nullptr), m_region_ptr(nullptr), @@ -335,7 +335,7 @@ void segacrpt_z80_device::set_decrypted_p(uint8_t* ptr) -sega_315_5132_device::sega_315_5132_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5132, tag, owner, clock) {} +sega_315_5132_device::sega_315_5132_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5132, tag, owner, clock) {} void sega_315_5132_device::decrypt() { static const uint8_t convtable[32][4] = @@ -366,7 +366,7 @@ void sega_315_5132_device::decrypt() -sega_315_5155_device::sega_315_5155_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5155, tag, owner, clock) {} +sega_315_5155_device::sega_315_5155_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5155, tag, owner, clock) {} void sega_315_5155_device::decrypt() { static const uint8_t convtable[32][4] = @@ -397,7 +397,7 @@ void sega_315_5155_device::decrypt() -sega_315_5110_device::sega_315_5110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5110, tag, owner, clock) {} +sega_315_5110_device::sega_315_5110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5110, tag, owner, clock) {} void sega_315_5110_device::decrypt() { static const uint8_t convtable[32][4] = @@ -427,7 +427,7 @@ void sega_315_5110_device::decrypt() -sega_315_5135_device::sega_315_5135_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5135, tag, owner, clock) {} +sega_315_5135_device::sega_315_5135_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5135, tag, owner, clock) {} void sega_315_5135_device::decrypt() { static const uint8_t convtable[32][4] = @@ -458,7 +458,7 @@ void sega_315_5135_device::decrypt() -sega_315_5051_device::sega_315_5051_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5051, tag, owner, clock) {} +sega_315_5051_device::sega_315_5051_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5051, tag, owner, clock) {} void sega_315_5051_device::decrypt() { static const uint8_t convtable[32][4] = @@ -488,7 +488,7 @@ void sega_315_5051_device::decrypt() -sega_315_5098_device::sega_315_5098_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5098, tag, owner, clock) {} +sega_315_5098_device::sega_315_5098_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5098, tag, owner, clock) {} void sega_315_5098_device::decrypt() { // also 315-5030 ? @@ -520,7 +520,7 @@ void sega_315_5098_device::decrypt() -sega_315_5102_device::sega_315_5102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5102, tag, owner, clock) {} +sega_315_5102_device::sega_315_5102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5102, tag, owner, clock) {} void sega_315_5102_device::decrypt() { static const uint8_t convtable[32][4] = @@ -549,7 +549,7 @@ void sega_315_5102_device::decrypt() } -sega_315_5065_device::sega_315_5065_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5065, tag, owner, clock) {} +sega_315_5065_device::sega_315_5065_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5065, tag, owner, clock) {} void sega_315_5065_device::decrypt() { static const uint8_t convtable[32][4] = @@ -578,7 +578,7 @@ void sega_315_5065_device::decrypt() } -sega_315_5064_device::sega_315_5064_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5064, tag, owner, clock) {} +sega_315_5064_device::sega_315_5064_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5064, tag, owner, clock) {} void sega_315_5064_device::decrypt() { static const uint8_t convtable[32][4] = @@ -608,7 +608,7 @@ void sega_315_5064_device::decrypt() -sega_315_5033_device::sega_315_5033_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5033, tag, owner, clock) {} +sega_315_5033_device::sega_315_5033_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5033, tag, owner, clock) {} void sega_315_5033_device::decrypt() { static const uint8_t convtable[32][4] = @@ -637,7 +637,7 @@ void sega_315_5033_device::decrypt() } -sega_315_5041_device::sega_315_5041_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5041, tag, owner, clock) {} +sega_315_5041_device::sega_315_5041_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5041, tag, owner, clock) {} void sega_315_5041_device::decrypt() { static const uint8_t convtable[32][4] = @@ -667,8 +667,8 @@ void sega_315_5041_device::decrypt() -sega_315_5048_device::sega_315_5048_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5048, tag, owner, clock) {} -sega_315_5048_device::sega_315_5048_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, type, tag, owner, clock) {} +sega_315_5048_device::sega_315_5048_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5048, tag, owner, clock) {} +sega_315_5048_device::sega_315_5048_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, type, tag, owner, clock) {} void sega_315_5048_device::decrypt() { static const uint8_t convtable[32][4] = @@ -697,7 +697,7 @@ void sega_315_5048_device::decrypt() } -sega_315_5093_device::sega_315_5093_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5093, tag, owner, clock) {} +sega_315_5093_device::sega_315_5093_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5093, tag, owner, clock) {} void sega_315_5093_device::decrypt() { static const uint8_t convtable[32][4] = @@ -727,7 +727,7 @@ void sega_315_5093_device::decrypt() -sega_315_5099_device::sega_315_5099_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5099, tag, owner, clock) {} +sega_315_5099_device::sega_315_5099_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5099, tag, owner, clock) {} void sega_315_5099_device::decrypt() { static const uint8_t convtable[32][4] = @@ -758,7 +758,7 @@ void sega_315_5099_device::decrypt() -sega_315_spat_device::sega_315_spat_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_SPAT, tag, owner, clock) {} +sega_315_spat_device::sega_315_spat_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_SPAT, tag, owner, clock) {} void sega_315_spat_device::decrypt() { static const uint8_t convtable[32][4] = @@ -786,7 +786,7 @@ void sega_315_spat_device::decrypt() decode(m_region_ptr, m_decrypted_ptr, m_decode_size, convtable, m_numbanks, m_banksize); } -sega_315_5015_device::sega_315_5015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5015, tag, owner, clock) {} +sega_315_5015_device::sega_315_5015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5015, tag, owner, clock) {} void sega_315_5015_device::decrypt() { static const uint8_t convtable[32][4] = @@ -816,11 +816,11 @@ void sega_315_5015_device::decrypt() } -sega_315_5133_device::sega_315_5133_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : sega_315_5048_device(mconfig, SEGA_315_5133, tag, owner, clock) {} +sega_315_5133_device::sega_315_5133_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega_315_5048_device(mconfig, SEGA_315_5133, tag, owner, clock) {} // == sega_315_5048_device -sega_315_5014_device::sega_315_5014_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5014, tag, owner, clock) {} +sega_315_5014_device::sega_315_5014_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5014, tag, owner, clock) {} void sega_315_5014_device::decrypt() { static const uint8_t convtable[32][4] = @@ -849,7 +849,7 @@ void sega_315_5014_device::decrypt() -sega_315_5013_device::sega_315_5013_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5013, tag, owner, clock) {} +sega_315_5013_device::sega_315_5013_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5013, tag, owner, clock) {} void sega_315_5013_device::decrypt() { static const uint8_t convtable[32][4] = @@ -878,7 +878,7 @@ void sega_315_5013_device::decrypt() } -sega_315_5061_device::sega_315_5061_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5061, tag, owner, clock) {} +sega_315_5061_device::sega_315_5061_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5061, tag, owner, clock) {} void sega_315_5061_device::decrypt() { static const uint8_t convtable[32][4] = @@ -908,7 +908,7 @@ void sega_315_5061_device::decrypt() -sega_315_5018_device::sega_315_5018_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5018, tag, owner, clock) {} +sega_315_5018_device::sega_315_5018_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5018, tag, owner, clock) {} void sega_315_5018_device::decrypt() { static const uint8_t convtable[32][4] = @@ -938,7 +938,7 @@ void sega_315_5018_device::decrypt() } -sega_315_5010_device::sega_315_5010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5010, tag, owner, clock) {} +sega_315_5010_device::sega_315_5010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5010, tag, owner, clock) {} void sega_315_5010_device::decrypt() { static const uint8_t convtable[32][4] = @@ -969,7 +969,7 @@ void sega_315_5010_device::decrypt() -sega_315_5128_device::sega_315_5128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5128, tag, owner, clock) {} +sega_315_5128_device::sega_315_5128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5128, tag, owner, clock) {} void sega_315_5128_device::decrypt() { static const uint8_t convtable[32][4] = @@ -998,7 +998,7 @@ void sega_315_5128_device::decrypt() } -sega_315_5028_device::sega_315_5028_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5028, tag, owner, clock) {} +sega_315_5028_device::sega_315_5028_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5028, tag, owner, clock) {} void sega_315_5028_device::decrypt() { static const uint8_t convtable[32][4] = @@ -1027,7 +1027,7 @@ void sega_315_5028_device::decrypt() } -sega_315_5084_device::sega_315_5084_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : segacrpt_z80_device(mconfig, SEGA_315_5084, tag, owner, clock) {} +sega_315_5084_device::sega_315_5084_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : segacrpt_z80_device(mconfig, SEGA_315_5084, tag, owner, clock) {} void sega_315_5084_device::decrypt() { static const uint8_t convtable[32][4] = diff --git a/src/devices/machine/segacrpt_device.h b/src/devices/machine/segacrpt_device.h index 63b50bde2d0..3bc9a6a7946 100644 --- a/src/devices/machine/segacrpt_device.h +++ b/src/devices/machine/segacrpt_device.h @@ -22,7 +22,7 @@ public: void set_region_p(uint8_t* ptr); protected: - segacrpt_z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + segacrpt_z80_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -44,7 +44,7 @@ private: class sega_315_5132_device : public segacrpt_z80_device { public: - sega_315_5132_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5132_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -52,7 +52,7 @@ protected: class sega_315_5155_device : public segacrpt_z80_device { public: - sega_315_5155_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5155_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -60,7 +60,7 @@ protected: class sega_315_5110_device : public segacrpt_z80_device { public: - sega_315_5110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -68,7 +68,7 @@ protected: class sega_315_5135_device : public segacrpt_z80_device { public: - sega_315_5135_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5135_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -76,7 +76,7 @@ protected: class sega_315_5051_device : public segacrpt_z80_device { public: - sega_315_5051_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5051_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -84,7 +84,7 @@ protected: class sega_315_5098_device : public segacrpt_z80_device { public: - sega_315_5098_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5098_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -92,7 +92,7 @@ protected: class sega_315_5102_device : public segacrpt_z80_device { public: - sega_315_5102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -100,7 +100,7 @@ protected: class sega_315_5065_device : public segacrpt_z80_device { public: - sega_315_5065_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5065_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -109,7 +109,7 @@ protected: class sega_315_5064_device : public segacrpt_z80_device { public: - sega_315_5064_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5064_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -118,7 +118,7 @@ protected: class sega_315_5033_device : public segacrpt_z80_device { public: - sega_315_5033_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5033_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -126,7 +126,7 @@ protected: class sega_315_5041_device : public segacrpt_z80_device { public: - sega_315_5041_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5041_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -134,8 +134,8 @@ protected: class sega_315_5048_device : public segacrpt_z80_device { public: - sega_315_5048_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); - sega_315_5048_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sega_315_5048_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); + sega_315_5048_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; @@ -144,7 +144,7 @@ protected: class sega_315_5093_device : public segacrpt_z80_device { public: - sega_315_5093_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5093_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -152,7 +152,7 @@ protected: class sega_315_5099_device : public segacrpt_z80_device { public: - sega_315_5099_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5099_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -160,7 +160,7 @@ protected: class sega_315_spat_device : public segacrpt_z80_device { public: - sega_315_spat_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_spat_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -168,7 +168,7 @@ protected: class sega_315_5015_device : public segacrpt_z80_device { public: - sega_315_5015_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5015_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -177,13 +177,13 @@ protected: class sega_315_5133_device : public sega_315_5048_device { public: - sega_315_5133_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5133_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class sega_315_5014_device : public segacrpt_z80_device { public: - sega_315_5014_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5014_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -191,7 +191,7 @@ protected: class sega_315_5013_device : public segacrpt_z80_device { public: - sega_315_5013_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5013_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -199,7 +199,7 @@ protected: class sega_315_5061_device : public segacrpt_z80_device { public: - sega_315_5061_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5061_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -209,7 +209,7 @@ protected: class sega_315_5018_device : public segacrpt_z80_device { public: - sega_315_5018_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5018_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -217,7 +217,7 @@ protected: class sega_315_5010_device : public segacrpt_z80_device { public: - sega_315_5010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -227,7 +227,7 @@ protected: class sega_315_5128_device : public segacrpt_z80_device { public: - sega_315_5128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -235,7 +235,7 @@ protected: class sega_315_5028_device : public segacrpt_z80_device { public: - sega_315_5028_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5028_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; @@ -243,7 +243,7 @@ protected: class sega_315_5084_device : public segacrpt_z80_device { public: - sega_315_5084_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t); + sega_315_5084_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void decrypt() override; }; diff --git a/src/devices/machine/sensorboard.cpp b/src/devices/machine/sensorboard.cpp index c7786a0c4d5..163e5497180 100644 --- a/src/devices/machine/sensorboard.cpp +++ b/src/devices/machine/sensorboard.cpp @@ -66,7 +66,7 @@ DEFINE_DEVICE_TYPE(SENSORBOARD, sensorboard_device, "sensorboard", "Sensorboard" // constructor //------------------------------------------------- -sensorboard_device::sensorboard_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sensorboard_device::sensorboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SENSORBOARD, tag, owner, clock), device_nvram_interface(mconfig, *this), m_out_piece(*this, "piece_%c%u", 0U + 'a', 1U), diff --git a/src/devices/machine/sensorboard.h b/src/devices/machine/sensorboard.h index b2d12e8a3d1..af51a51542e 100644 --- a/src/devices/machine/sensorboard.h +++ b/src/devices/machine/sensorboard.h @@ -14,7 +14,7 @@ class sensorboard_device : public device_t, public device_nvram_interface { public: - sensorboard_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + sensorboard_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); enum sb_type { diff --git a/src/devices/machine/serflash.cpp b/src/devices/machine/serflash.cpp index c7589e6f58e..f28e4a0d478 100644 --- a/src/devices/machine/serflash.cpp +++ b/src/devices/machine/serflash.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(SERFLASH, serflash_device, "serflash", "Serial Flash") // serflash_device - constructor //------------------------------------------------- -serflash_device::serflash_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +serflash_device::serflash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SERFLASH, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_length(0) diff --git a/src/devices/machine/serflash.h b/src/devices/machine/serflash.h index 1c9e5ab7afc..b536f7a7648 100644 --- a/src/devices/machine/serflash.h +++ b/src/devices/machine/serflash.h @@ -21,7 +21,7 @@ public: typedef device_delegate<void (serflash_device &, void *, size_t)> init_delegate; // construction/destruction - serflash_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + serflash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration void set_flash_page_size(uint16_t size) { m_flash_page_size = size; } diff --git a/src/devices/machine/sis5513_ide.cpp b/src/devices/machine/sis5513_ide.cpp index 99a9541f80e..e5111689235 100644 --- a/src/devices/machine/sis5513_ide.cpp +++ b/src/devices/machine/sis5513_ide.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(SIS5513_IDE, sis5513_ide_device, "sis5513_ide", "SiS 5513 IDE Controller") -sis5513_ide_device::sis5513_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis5513_ide_device::sis5513_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, SIS5513_IDE, tag, owner, clock) , m_ide1(*this, "ide1") , m_ide2(*this, "ide2") diff --git a/src/devices/machine/sis5513_ide.h b/src/devices/machine/sis5513_ide.h index 89d4916c47b..21b5a7f6cb0 100644 --- a/src/devices/machine/sis5513_ide.h +++ b/src/devices/machine/sis5513_ide.h @@ -13,7 +13,7 @@ class sis5513_ide_device : public pci_device { public: template <typename T> sis5513_ide_device( - const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, + const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&host_tag, uint32_t bmspace = AS_PROGRAM ) : sis5513_ide_device(mconfig, tag, owner, clock) { @@ -23,7 +23,7 @@ public: set_ids(0x10395513, 0xd0, 0x010180, 0x00); m_bus_master_space.set_tag(host_tag, bmspace); } - sis5513_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis5513_ide_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_pri() { return m_irq_pri_callback.bind(); } auto irq_sec() { return m_irq_sec_callback.bind(); } diff --git a/src/devices/machine/sis630_gui.cpp b/src/devices/machine/sis630_gui.cpp index 24270f95e02..9b19f0a90eb 100644 --- a/src/devices/machine/sis630_gui.cpp +++ b/src/devices/machine/sis630_gui.cpp @@ -66,7 +66,7 @@ // (definitely doesn't have dual segment mode for instance) DEFINE_DEVICE_TYPE(SIS630_SVGA, sis630_svga_device, "sis630_svga", "SiS 630 SVGA") -sis630_svga_device::sis630_svga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis630_svga_device::sis630_svga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : svga_device(mconfig, SIS630_SVGA, tag, owner, clock) { @@ -361,7 +361,7 @@ void sis630_svga_device::mem_w(offs_t offset, uint8_t data) DEFINE_DEVICE_TYPE(SIS630_GUI, sis630_gui_device, "sis630_gui", "SiS 630 GUI") -sis630_gui_device::sis630_gui_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis630_gui_device::sis630_gui_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, SIS630_GUI, tag, owner, clock) , m_svga(*this, "svga") , m_gui_rom(*this, "gui_rom") @@ -395,7 +395,7 @@ void sis630_gui_device::device_add_mconfig(machine_config &config) screen.set_raw(XTAL(25'174'800), 900, 0, 640, 526, 0, 480); screen.set_screen_update(m_svga, FUNC(sis630_svga_device::screen_update)); - SIS630_SVGA(config, m_svga, 0); + SIS630_SVGA(config, m_svga); m_svga->set_screen("screen"); // 64MB according to POST // documentation claims 128MB, assume being wrong @@ -663,7 +663,7 @@ void sis630_gui_device::vga_3d0_w(offs_t offset, uint32_t data, uint32_t mem_mas DEFINE_DEVICE_TYPE(SIS630_BRIDGE, sis630_bridge_device, "sis630_bridge", "SiS 630 Virtual PCI-to-PCI bridge") -sis630_bridge_device::sis630_bridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis630_bridge_device::sis630_bridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_bridge_device(mconfig, SIS630_BRIDGE, tag, owner, clock) , m_vga(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/machine/sis630_gui.h b/src/devices/machine/sis630_gui.h index 79690f81575..b84326bdc69 100644 --- a/src/devices/machine/sis630_gui.h +++ b/src/devices/machine/sis630_gui.h @@ -12,7 +12,7 @@ class sis630_svga_device : public svga_device { public: - sis630_svga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis630_svga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t mem_r(offs_t offset) override; virtual void mem_w(offs_t offset, uint8_t data) override; @@ -50,7 +50,7 @@ DECLARE_DEVICE_TYPE(SIS630_SVGA, sis630_svga_device) class sis630_gui_device : public pci_device { public: - sis630_gui_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis630_gui_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void legacy_memory_map(address_map &map); void legacy_io_map(address_map &map); @@ -111,7 +111,7 @@ class sis630_bridge_device : public pci_bridge_device { public: template <typename T> sis630_bridge_device( - const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, + const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&gui_tag ) : sis630_bridge_device(mconfig, tag, owner, clock) { @@ -121,7 +121,7 @@ public: m_vga.set_tag(std::forward<T>(gui_tag)); } - sis630_bridge_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis630_bridge_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/sis630_host.cpp b/src/devices/machine/sis630_host.cpp index 5088585aa5f..a6171a38ad6 100644 --- a/src/devices/machine/sis630_host.cpp +++ b/src/devices/machine/sis630_host.cpp @@ -36,7 +36,7 @@ DEFINE_DEVICE_TYPE(SIS630_HOST, sis630_host_device, "sis630_host", "SiS 630 Host-to-PCI Bridge") -sis630_host_device::sis630_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis630_host_device::sis630_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_host_device(mconfig, SIS630_HOST, tag, owner, clock) , m_host_cpu(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/machine/sis630_host.h b/src/devices/machine/sis630_host.h index 46efc0ed803..4bce6026d13 100644 --- a/src/devices/machine/sis630_host.h +++ b/src/devices/machine/sis630_host.h @@ -13,7 +13,7 @@ class sis630_host_device : public pci_host_device { public: template <typename T> sis630_host_device( - const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, + const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, int ram_size ) : sis630_host_device(mconfig, tag, owner, clock) { @@ -24,7 +24,7 @@ public: set_ram_size(ram_size); } - sis630_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis630_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_ram_size(int ram_size) { m_ram_size = ram_size; } diff --git a/src/devices/machine/sis7001_usb.cpp b/src/devices/machine/sis7001_usb.cpp index c54f62d9713..b59874e335a 100644 --- a/src/devices/machine/sis7001_usb.cpp +++ b/src/devices/machine/sis7001_usb.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(SIS7001_USB, sis7001_usb_device, "sis7001_usb", "SiS 7001 USB Host Controller") -sis7001_usb_device::sis7001_usb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis7001_usb_device::sis7001_usb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, SIS7001_USB, tag, owner, clock) { diff --git a/src/devices/machine/sis7001_usb.h b/src/devices/machine/sis7001_usb.h index 1087b06ce30..82a02e0dc69 100644 --- a/src/devices/machine/sis7001_usb.h +++ b/src/devices/machine/sis7001_usb.h @@ -12,7 +12,7 @@ class sis7001_usb_device : public pci_device { public: sis7001_usb_device( - const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, + const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, int num_ports ) : sis7001_usb_device(mconfig, tag, owner, clock) { @@ -22,7 +22,7 @@ public: // TODO: should really read from a std::list interface m_downstream_ports = num_ports; } - sis7001_usb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis7001_usb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::MEDIA; } diff --git a/src/devices/machine/sis7018_audio.cpp b/src/devices/machine/sis7018_audio.cpp index ac87ab46ac2..0e30ce12f3d 100644 --- a/src/devices/machine/sis7018_audio.cpp +++ b/src/devices/machine/sis7018_audio.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(SIS7018_AUDIO, sis7018_audio_device, "sis7018_audio", "SiS 7018 Audio AC97") -sis7018_audio_device::sis7018_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis7018_audio_device::sis7018_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, SIS7018_AUDIO, tag, owner, clock) { diff --git a/src/devices/machine/sis7018_audio.h b/src/devices/machine/sis7018_audio.h index d72794e05c6..8c2ff7131aa 100644 --- a/src/devices/machine/sis7018_audio.h +++ b/src/devices/machine/sis7018_audio.h @@ -11,7 +11,7 @@ class sis7018_audio_device : public pci_device { public: - sis7018_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis7018_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::SOUND; } diff --git a/src/devices/machine/sis85c496.cpp b/src/devices/machine/sis85c496.cpp index 66bab2adbda..73de49b49dd 100644 --- a/src/devices/machine/sis85c496.cpp +++ b/src/devices/machine/sis85c496.cpp @@ -47,7 +47,7 @@ void sis85c496_host_device::internal_io_map(address_map &map) void sis85c496_host_device::device_add_mconfig(machine_config &config) { - PIT8254(config, m_pit8254, 0); + PIT8254(config, m_pit8254); m_pit8254->set_clk<0>(4772720/4); // heartbeat IRQ m_pit8254->out_handler<0>().set(FUNC(sis85c496_host_device::at_pit8254_out0_changed)); m_pit8254->set_clk<1>(4772720/4); // DRAM refresh @@ -88,12 +88,12 @@ void sis85c496_host_device::device_add_mconfig(machine_config &config) m_dma8237_2->out_dack_callback<2>().set(FUNC(sis85c496_host_device::pc_dack6_w)); m_dma8237_2->out_dack_callback<3>().set(FUNC(sis85c496_host_device::pc_dack7_w)); - PIC8259(config, m_pic8259_master, 0); + PIC8259(config, m_pic8259_master); m_pic8259_master->out_int_callback().set(FUNC(sis85c496_host_device::cpu_int_w)); m_pic8259_master->in_sp_callback().set_constant(1); m_pic8259_master->read_slave_ack_callback().set(FUNC(sis85c496_host_device::get_slave_ack)); - PIC8259(config, m_pic8259_slave, 0); + PIC8259(config, m_pic8259_slave); m_pic8259_slave->out_int_callback().set(m_pic8259_master, FUNC(pic8259_device::ir2_w)); m_pic8259_slave->in_sp_callback().set_constant(0); @@ -118,7 +118,7 @@ void sis85c496_host_device::device_add_mconfig(machine_config &config) } -sis85c496_host_device::sis85c496_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis85c496_host_device::sis85c496_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_host_device(mconfig, SIS85C496, tag, owner, clock), m_maincpu(*this, finder_base::DUMMY_TAG), m_pic8259_master(*this, "pic8259_master"), diff --git a/src/devices/machine/sis85c496.h b/src/devices/machine/sis85c496.h index 05bd11d5d56..d8dd06873ac 100644 --- a/src/devices/machine/sis85c496.h +++ b/src/devices/machine/sis85c496.h @@ -32,7 +32,7 @@ class sis85c496_host_device : public pci_host_device { public: - sis85c496_host_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis85c496_host_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_cpu_tag(const char *tag); void set_ram_size(int ram_size); diff --git a/src/devices/machine/sis900_eth.cpp b/src/devices/machine/sis900_eth.cpp index d960c4b0293..560e0006c2f 100644 --- a/src/devices/machine/sis900_eth.cpp +++ b/src/devices/machine/sis900_eth.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(SIS900_ETH, sis900_eth_device, "sis900_eth", "SiS 900 Fast Ethernet Adapter") -sis900_eth_device::sis900_eth_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis900_eth_device::sis900_eth_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, SIS900_ETH, tag, owner, clock) , m_eeprom(*this, "eeprom") , m_eth_rom(*this, "eth_rom") diff --git a/src/devices/machine/sis900_eth.h b/src/devices/machine/sis900_eth.h index 4d5fb46f2bd..db801407758 100644 --- a/src/devices/machine/sis900_eth.h +++ b/src/devices/machine/sis900_eth.h @@ -12,7 +12,7 @@ class sis900_eth_device : public pci_device { public: - sis900_eth_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis900_eth_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::LAN; } diff --git a/src/devices/machine/sis950_lpc.cpp b/src/devices/machine/sis950_lpc.cpp index fa62813840b..a161f458ac0 100644 --- a/src/devices/machine/sis950_lpc.cpp +++ b/src/devices/machine/sis950_lpc.cpp @@ -51,7 +51,7 @@ DEFINE_DEVICE_TYPE(SIS950_LPC, sis950_lpc_device, "sis950_lpc", "SiS 950 LPC Super-South Bridge") -sis950_lpc_device::sis950_lpc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis950_lpc_device::sis950_lpc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, SIS950_LPC, tag, owner, clock) , m_host_cpu(*this, finder_base::DUMMY_TAG) , m_flash_rom(*this, finder_base::DUMMY_TAG) @@ -121,7 +121,7 @@ void sis950_lpc_device::device_add_mconfig(machine_config &config) constexpr XTAL lpc_pit_clock = XTAL(14'318'181); // confirmed 82C54 - PIT8254(config, m_pit, 0); + PIT8254(config, m_pit); // heartbeat IRQ m_pit->set_clk<0>(lpc_pit_clock / 12); m_pit->out_handler<0>().set(FUNC(sis950_lpc_device::pit_out0)); @@ -147,7 +147,7 @@ void sis950_lpc_device::device_add_mconfig(machine_config &config) // TODO: ior/iow/dack callbacks // Confirmed 82C59s - PIC8259(config, m_pic_master, 0); + PIC8259(config, m_pic_master); m_pic_master->out_int_callback().set_inputline(m_host_cpu, 0); m_pic_master->in_sp_callback().set_constant(1); m_pic_master->read_slave_ack_callback().set( @@ -159,7 +159,7 @@ void sis950_lpc_device::device_add_mconfig(machine_config &config) return 0; }); - PIC8259(config, m_pic_slave, 0); + PIC8259(config, m_pic_slave); m_pic_slave->out_int_callback().set(m_pic_master, FUNC(pic8259_device::ir2_w)); m_pic_slave->in_sp_callback().set_constant(0); diff --git a/src/devices/machine/sis950_lpc.h b/src/devices/machine/sis950_lpc.h index a91f442a653..c8fafc47b44 100644 --- a/src/devices/machine/sis950_lpc.h +++ b/src/devices/machine/sis950_lpc.h @@ -36,7 +36,7 @@ class sis950_lpc_device : public pci_device { public: template <typename T, typename U> sis950_lpc_device( - const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, + const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, U &&flash_tag ) : sis950_lpc_device(mconfig, tag, owner, clock) { @@ -47,7 +47,7 @@ public: m_flash_rom.set_tag(std::forward<U>(flash_tag)); } - sis950_lpc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis950_lpc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type unemulated_features() { return feature::MOUSE; } diff --git a/src/devices/machine/sis950_smbus.cpp b/src/devices/machine/sis950_smbus.cpp index b96898cbbe0..aa57416063f 100644 --- a/src/devices/machine/sis950_smbus.cpp +++ b/src/devices/machine/sis950_smbus.cpp @@ -50,7 +50,7 @@ void sis950_smbus_device::map(address_map &map) #endif } -sis950_smbus_device::sis950_smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sis950_smbus_device::sis950_smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SIS950_SMBUS, tag, owner, clock) { } diff --git a/src/devices/machine/sis950_smbus.h b/src/devices/machine/sis950_smbus.h index a474fe10914..cf9609c1043 100644 --- a/src/devices/machine/sis950_smbus.h +++ b/src/devices/machine/sis950_smbus.h @@ -9,7 +9,7 @@ class sis950_smbus_device : public device_t { public: - sis950_smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sis950_smbus_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void map(address_map &map); diff --git a/src/devices/machine/smartboard.cpp b/src/devices/machine/smartboard.cpp index ac18fd34534..55b7a92cd39 100644 --- a/src/devices/machine/smartboard.cpp +++ b/src/devices/machine/smartboard.cpp @@ -67,7 +67,7 @@ DEFINE_DEVICE_TYPE(TASC_SB30, tasc_sb30_device, "tasc_sb30", "Tasc SmartBoard SB // tasc_sb30_device - constructor //------------------------------------------------- -tasc_sb30_device::tasc_sb30_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tasc_sb30_device::tasc_sb30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TASC_SB30, tag, owner, clock) , m_board(*this, "board") , m_out_leds(*this, "sb30_led_%u.%u", 0U, 0U) diff --git a/src/devices/machine/smartboard.h b/src/devices/machine/smartboard.h index cb87bc36966..6d6a71b5409 100644 --- a/src/devices/machine/smartboard.h +++ b/src/devices/machine/smartboard.h @@ -16,7 +16,7 @@ class tasc_sb30_device : public device_t { public: - tasc_sb30_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + tasc_sb30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers auto data_out() { return m_data_out.bind(); } // data_r diff --git a/src/devices/machine/smartmed.cpp b/src/devices/machine/smartmed.cpp index 1c54d36d174..fd0fb440233 100644 --- a/src/devices/machine/smartmed.cpp +++ b/src/devices/machine/smartmed.cpp @@ -74,12 +74,12 @@ enum DEFINE_DEVICE_TYPE(NAND, nand_device, "nand", "NAND Flash Memory") -nand_device::nand_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nand_device::nand_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nand_device(mconfig, NAND, tag, owner, clock) { } -nand_device::nand_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nand_device::nand_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_page_data_size(0) , m_page_total_size(0) @@ -777,7 +777,7 @@ void nand_device::device_reset() DEFINE_DEVICE_TYPE(SMARTMEDIA, smartmedia_image_device, "smartmedia", "SmartMedia Flash card") -smartmedia_image_device::smartmedia_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +smartmedia_image_device::smartmedia_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nand_device(mconfig, SMARTMEDIA, tag, owner, clock) , device_memcard_image_interface(mconfig, *this) { diff --git a/src/devices/machine/smartmed.h b/src/devices/machine/smartmed.h index 77c7d53b209..63e2874113c 100644 --- a/src/devices/machine/smartmed.h +++ b/src/devices/machine/smartmed.h @@ -34,7 +34,7 @@ public: }; // construction/destruction - nand_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nand_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto rnb_wr_callback() { return m_write_rnb.bind(); } @@ -143,7 +143,7 @@ protected: SM_PM_C // accessing spare field }; - nand_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nand_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -199,7 +199,7 @@ class smartmedia_image_device : public nand_device, public device_memcard_image_ { public: // construction/destruction - smartmedia_image_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + smartmedia_image_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // image-level overrides virtual bool is_creatable() const noexcept override { return false; } diff --git a/src/devices/machine/smc91c9x.cpp b/src/devices/machine/smc91c9x.cpp index 3ca3fbeed13..59e36521beb 100644 --- a/src/devices/machine/smc91c9x.cpp +++ b/src/devices/machine/smc91c9x.cpp @@ -46,7 +46,7 @@ static const char *const ethernet_regname[64] = DEFINE_DEVICE_TYPE(SMC91C94, smc91c94_device, "smc91c94", "SMC91C94 Ethernet Controller") -smc91c94_device::smc91c94_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +smc91c94_device::smc91c94_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : smc91c9x_device(mconfig, SMC91C94, tag, owner, clock, dev_type::SMC91C94) { m_num_ebuf = 18; @@ -54,13 +54,13 @@ smc91c94_device::smc91c94_device(const machine_config &mconfig, const char *tag, DEFINE_DEVICE_TYPE(SMC91C96, smc91c96_device, "smc91c96", "SMC91C96 Ethernet Controller") -smc91c96_device::smc91c96_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +smc91c96_device::smc91c96_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : smc91c9x_device(mconfig, SMC91C96, tag, owner, clock, dev_type::SMC91C96) { m_num_ebuf = 24; } -smc91c9x_device::smc91c9x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, dev_type device_type) +smc91c9x_device::smc91c9x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, dev_type device_type) : device_t(mconfig, type, tag, owner, clock) , device_network_interface(mconfig, *this, 10) , m_device_type(device_type) diff --git a/src/devices/machine/smc91c9x.h b/src/devices/machine/smc91c9x.h index e1c91a3e566..8dae538ce54 100644 --- a/src/devices/machine/smc91c9x.h +++ b/src/devices/machine/smc91c9x.h @@ -35,7 +35,7 @@ protected: SMC91C96 }; - smc91c9x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, dev_type device_type); + smc91c9x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, dev_type device_type); // device-level overrides virtual void device_start() override; @@ -305,13 +305,13 @@ private: class smc91c94_device : public smc91c9x_device { public: - smc91c94_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + smc91c94_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class smc91c96_device : public smc91c9x_device { public: - smc91c96_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + smc91c96_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/machine/smioc.cpp b/src/devices/machine/smioc.cpp index 06c3e03adb1..f9b13ae9f86 100644 --- a/src/devices/machine/smioc.cpp +++ b/src/devices/machine/smioc.cpp @@ -192,7 +192,7 @@ void smioc_device::device_add_mconfig(machine_config &config) // smioc_device - constructor //------------------------------------------------- -smioc_device::smioc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +smioc_device::smioc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMIOC, tag, owner, clock), m_smioccpu(*this, I188_TAG), m_dma8237(*this, "dma8237_%u", 1), diff --git a/src/devices/machine/smioc.h b/src/devices/machine/smioc.h index 73dd874d149..ae3e7f24596 100644 --- a/src/devices/machine/smioc.h +++ b/src/devices/machine/smioc.h @@ -38,7 +38,7 @@ class smioc_device : public device_t { public: /* Constructor and Destructor */ - smioc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + smioc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto m68k_r_callback() { return m_m68k_r_cb.bind(); } auto m68k_w_callback() { return m_m68k_w_cb.bind(); } diff --git a/src/devices/machine/smpc.cpp b/src/devices/machine/smpc.cpp index 7161d97b7f9..271d4440544 100644 --- a/src/devices/machine/smpc.cpp +++ b/src/devices/machine/smpc.cpp @@ -202,7 +202,7 @@ void smpc_hle_device::smpc_regs(address_map &map) // smpc_hle_device - constructor //------------------------------------------------- -smpc_hle_device::smpc_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +smpc_hle_device::smpc_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SMPC_HLE, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_space_config("regs", ENDIANNESS_LITTLE, 8, 7, 0, address_map_constructor(FUNC(smpc_hle_device::smpc_regs), this)) diff --git a/src/devices/machine/smpc.h b/src/devices/machine/smpc.h index 60b461b6ad3..491bba38618 100644 --- a/src/devices/machine/smpc.h +++ b/src/devices/machine/smpc.h @@ -27,7 +27,7 @@ class smpc_hle_device : public device_t, { public: // construction/destruction - smpc_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + smpc_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations // void io_map(address_map &map); diff --git a/src/devices/machine/spchrom.cpp b/src/devices/machine/spchrom.cpp index 3cd95b87c2e..14d9a5fbd4e 100644 --- a/src/devices/machine/spchrom.cpp +++ b/src/devices/machine/spchrom.cpp @@ -25,7 +25,7 @@ // device type definition DEFINE_DEVICE_TYPE(SPEECHROM, speechrom_device, "speechrom", "TI Speech ROM") -speechrom_device::speechrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +speechrom_device::speechrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPEECHROM, tag, owner, clock), m_speechrom_data(nullptr), m_speechROMlen(0), m_speechROMaddr(0), m_load_pointer(0), diff --git a/src/devices/machine/spchrom.h b/src/devices/machine/spchrom.h index f84350da358..ad086e659e6 100644 --- a/src/devices/machine/spchrom.h +++ b/src/devices/machine/spchrom.h @@ -15,7 +15,7 @@ class speechrom_device : public device_t { public: // construction/destruction - speechrom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + speechrom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); /// TODO: implement bus behaviour int read(int count); diff --git a/src/devices/machine/spg110.cpp b/src/devices/machine/spg110.cpp index b4dbb4e8de8..72003dd2938 100644 --- a/src/devices/machine/spg110.cpp +++ b/src/devices/machine/spg110.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(SPG110, spg110_device, "spg110", "SPG110 System-on-a-Chip") -spg110_device::spg110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal) : +spg110_device::spg110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal) : unsp_device(mconfig, type, tag, owner, clock, internal), device_mixer_interface(mconfig, *this, 2), m_screen(*this, finder_base::DUMMY_TAG), @@ -36,7 +36,7 @@ spg110_device::spg110_device(const machine_config &mconfig, device_type type, co } -spg110_device::spg110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spg110_device::spg110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg110_device(mconfig, SPG110, tag, owner, clock, address_map_constructor(FUNC(spg110_device::internal_map), this)) { } diff --git a/src/devices/machine/spg110.h b/src/devices/machine/spg110.h index 8ecee9dea75..e38f4d7dc5e 100644 --- a/src/devices/machine/spg110.h +++ b/src/devices/machine/spg110.h @@ -17,10 +17,10 @@ class spg110_device : public unsp_device, public device_mixer_interface { public: - spg110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> - spg110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) + spg110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : spg110_device(mconfig, tag, owner, clock) { m_screen.set_tag(std::forward<T>(screen_tag)); @@ -43,7 +43,7 @@ public: DECLARE_WRITE_LINE_MEMBER(vblank) { m_spg_video->vblank(state); } protected: - spg110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, address_map_constructor internal); + spg110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, address_map_constructor internal); void internal_map(address_map &map); diff --git a/src/devices/machine/spg110_video.cpp b/src/devices/machine/spg110_video.cpp index e89bd5488ec..246ce34c472 100644 --- a/src/devices/machine/spg110_video.cpp +++ b/src/devices/machine/spg110_video.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(SPG110_VIDEO, spg110_video_device, "spg110_video", "SPG110 System-on-a-Chip (Video)") -spg110_video_device::spg110_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +spg110_video_device::spg110_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_memory_interface(mconfig, *this), m_space_config("spg110_video", ENDIANNESS_BIG, 16, 32, 0, address_map_constructor(FUNC(spg110_video_device::map_video), this)), @@ -26,7 +26,7 @@ spg110_video_device::spg110_video_device(const machine_config &mconfig, device_t { } -spg110_video_device::spg110_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spg110_video_device::spg110_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg110_video_device(mconfig, SPG110_VIDEO, tag, owner, clock) { } diff --git a/src/devices/machine/spg110_video.h b/src/devices/machine/spg110_video.h index 6f8e0db0b5c..a39f02cba01 100644 --- a/src/devices/machine/spg110_video.h +++ b/src/devices/machine/spg110_video.h @@ -16,11 +16,11 @@ class spg110_video_device : public device_t, public device_memory_interface { public: - spg110_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); - spg110_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg110_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + spg110_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T, typename U> - spg110_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, U &&screen_tag) + spg110_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, U &&screen_tag) : spg110_video_device(mconfig, tag, owner, clock) { m_cpu.set_tag(std::forward<T>(cpu_tag)); diff --git a/src/devices/machine/spg290_cdservo.cpp b/src/devices/machine/spg290_cdservo.cpp index 7d03836a486..26d4f885e2d 100644 --- a/src/devices/machine/spg290_cdservo.cpp +++ b/src/devices/machine/spg290_cdservo.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(SPG290_CDSERVO, spg290_cdservo_device, "spg290_cdservo", "SPG290 CDServo HLE") -spg290_cdservo_device::spg290_cdservo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spg290_cdservo_device::spg290_cdservo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPG290_CDSERVO, tag, owner, clock) , m_cdrom(*this, finder_base::DUMMY_TAG) , m_irq_cb(*this) diff --git a/src/devices/machine/spg290_cdservo.h b/src/devices/machine/spg290_cdservo.h index aa1d8077407..70b67522f33 100644 --- a/src/devices/machine/spg290_cdservo.h +++ b/src/devices/machine/spg290_cdservo.h @@ -13,10 +13,10 @@ class spg290_cdservo_device : public device_t { public: - spg290_cdservo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg290_cdservo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> - spg290_cdservo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cdrom_tag) + spg290_cdservo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cdrom_tag) : spg290_cdservo_device(mconfig, tag, owner, clock) { m_cdrom.set_tag(std::forward<T>(cdrom_tag)); diff --git a/src/devices/machine/spg290_i2c.cpp b/src/devices/machine/spg290_i2c.cpp index e360a451736..bfc81b26942 100644 --- a/src/devices/machine/spg290_i2c.cpp +++ b/src/devices/machine/spg290_i2c.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(SPG290_I2C, spg290_i2c_device, "spg290_i2c", "SPG290 I2C") -spg290_i2c_device::spg290_i2c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spg290_i2c_device::spg290_i2c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPG290_I2C, tag, owner, clock) , m_irq_cb(*this) , m_i2c_read_cb(*this) diff --git a/src/devices/machine/spg290_i2c.h b/src/devices/machine/spg290_i2c.h index 2dca1d145f4..7bdff611303 100644 --- a/src/devices/machine/spg290_i2c.h +++ b/src/devices/machine/spg290_i2c.h @@ -10,7 +10,7 @@ class spg290_i2c_device : public device_t { public: - spg290_i2c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg290_i2c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint32_t data, uint32_t mem_mask); uint32_t read(offs_t offset, uint32_t mem_mask); diff --git a/src/devices/machine/spg290_ppu.cpp b/src/devices/machine/spg290_ppu.cpp index 37f0def0f84..00da588f306 100644 --- a/src/devices/machine/spg290_ppu.cpp +++ b/src/devices/machine/spg290_ppu.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(SPG290_PPU, spg290_ppu_device, "spg290_ppu", "SPG290 PPU") -spg290_ppu_device::spg290_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spg290_ppu_device::spg290_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPG290_PPU, tag, owner, clock) , m_screen(*this, finder_base::DUMMY_TAG) , m_sprite_palette_ram(*this, "sprite_palette_ram") diff --git a/src/devices/machine/spg290_ppu.h b/src/devices/machine/spg290_ppu.h index 83960abe6d6..3e1cdc65b2e 100644 --- a/src/devices/machine/spg290_ppu.h +++ b/src/devices/machine/spg290_ppu.h @@ -13,10 +13,10 @@ class spg290_ppu_device : public device_t { public: - spg290_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg290_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> - spg290_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) + spg290_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : spg290_ppu_device(mconfig, tag, owner, clock) { m_screen.set_tag(std::forward<T>(screen_tag)); diff --git a/src/devices/machine/spg290_timer.cpp b/src/devices/machine/spg290_timer.cpp index ce3754079d3..0ee5161071d 100644 --- a/src/devices/machine/spg290_timer.cpp +++ b/src/devices/machine/spg290_timer.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(SPG290_TIMER, spg290_timer_device, "spg290_timer", "SPG290 Timer") -spg290_timer_device::spg290_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spg290_timer_device::spg290_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPG290_TIMER, tag, owner, clock) , m_irq_cb(*this) , m_enabled(false) diff --git a/src/devices/machine/spg290_timer.h b/src/devices/machine/spg290_timer.h index 486011cb90b..6a85bcdf5b4 100644 --- a/src/devices/machine/spg290_timer.h +++ b/src/devices/machine/spg290_timer.h @@ -10,7 +10,7 @@ class spg290_timer_device : public device_t { public: - spg290_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg290_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint32_t data, uint32_t mem_mask); uint32_t read(offs_t offset, uint32_t mem_mask); diff --git a/src/devices/machine/spg2xx.cpp b/src/devices/machine/spg2xx.cpp index 412b2d20a14..83609676db9 100644 --- a/src/devices/machine/spg2xx.cpp +++ b/src/devices/machine/spg2xx.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(SPG2XX_128, spg2xx_128_device, "spg2xx_128", "SPG2xx-series S DEFINE_DEVICE_TYPE(SPG28X, spg28x_device, "spg28x", "SPG280-series System-on-a-Chip") // 64 sprites -spg2xx_device::spg2xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint16_t sprite_limit, address_map_constructor internal) : +spg2xx_device::spg2xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint16_t sprite_limit, address_map_constructor internal) : unsp_device(mconfig, type, tag, owner, clock, internal), device_mixer_interface(mconfig, *this, 2), m_spg_audio(*this, "spgaudio"), @@ -45,23 +45,23 @@ spg2xx_device::spg2xx_device(const machine_config &mconfig, device_type type, co { } -spg24x_device::spg24x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spg24x_device::spg24x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg2xx_device(mconfig, SPG24X, tag, owner, clock, 256, address_map_constructor(FUNC(spg24x_device::internal_map), this)) { } -spg24x_device::spg24x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint16_t sprite_limit, address_map_constructor internal) : +spg24x_device::spg24x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint16_t sprite_limit, address_map_constructor internal) : spg2xx_device(mconfig, type, tag, owner, clock, sprite_limit, internal) { } -spg2xx_128_device::spg2xx_128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spg2xx_128_device::spg2xx_128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg24x_device(mconfig, SPG2XX_128, tag, owner, clock, 128, address_map_constructor(FUNC(spg2xx_128_device::internal_map), this)) { } -spg28x_device::spg28x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spg28x_device::spg28x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg24x_device(mconfig, SPG28X, tag, owner, clock, 64, address_map_constructor(FUNC(spg28x_device::internal_map), this)) { } diff --git a/src/devices/machine/spg2xx.h b/src/devices/machine/spg2xx.h index 6b6bfd0d560..541ded1dcfd 100644 --- a/src/devices/machine/spg2xx.h +++ b/src/devices/machine/spg2xx.h @@ -78,7 +78,7 @@ public: uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) { return m_spg_video->screen_update(screen, bitmap, cliprect); } protected: - spg2xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint16_t sprite_limit, address_map_constructor internal); + spg2xx_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint16_t sprite_limit, address_map_constructor internal); void internal_map(address_map &map); @@ -151,15 +151,15 @@ class spg24x_device : public spg2xx_device { public: template <typename T> - spg24x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) + spg24x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : spg24x_device(mconfig, tag, owner, clock) { m_screen.set_tag(std::forward<T>(screen_tag)); } - spg24x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint16_t sprite_limit, address_map_constructor internal); + spg24x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint16_t sprite_limit, address_map_constructor internal); - spg24x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg24x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void device_add_mconfig(machine_config &config) override; @@ -169,26 +169,26 @@ class spg2xx_128_device : public spg24x_device { public: template <typename T> - spg2xx_128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) + spg2xx_128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : spg2xx_128_device(mconfig, tag, owner, clock) { m_screen.set_tag(std::forward<T>(screen_tag)); } - spg2xx_128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg2xx_128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class spg28x_device : public spg24x_device { public: template <typename T> - spg28x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) + spg28x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : spg28x_device(mconfig, tag, owner, clock) { m_screen.set_tag(std::forward<T>(screen_tag)); } - spg28x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg28x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/machine/spg2xx_audio.cpp b/src/devices/machine/spg2xx_audio.cpp index e8518bdaa59..7bdb2d3a3af 100644 --- a/src/devices/machine/spg2xx_audio.cpp +++ b/src/devices/machine/spg2xx_audio.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(SUNPLUS_GCM394_AUDIO, sunplus_gcm394_audio_device, "gcm394_au static FILE *adpcm_file[16] = {}; #endif -spg2xx_audio_device::spg2xx_audio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +spg2xx_audio_device::spg2xx_audio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_space_read_cb(*this) @@ -56,17 +56,17 @@ spg2xx_audio_device::spg2xx_audio_device(const machine_config &mconfig, device_t { } -spg2xx_audio_device::spg2xx_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spg2xx_audio_device::spg2xx_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg2xx_audio_device(mconfig, SPG2XX_AUDIO, tag, owner, clock) { } -spg110_audio_device::spg110_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spg110_audio_device::spg110_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg2xx_audio_device(mconfig, SPG110_AUDIO, tag, owner, clock) { } -sunplus_gcm394_audio_device::sunplus_gcm394_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sunplus_gcm394_audio_device::sunplus_gcm394_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg2xx_audio_device(mconfig, SUNPLUS_GCM394_AUDIO, tag, owner, clock) { } diff --git a/src/devices/machine/spg2xx_audio.h b/src/devices/machine/spg2xx_audio.h index d0712139134..dd785f44cfe 100644 --- a/src/devices/machine/spg2xx_audio.h +++ b/src/devices/machine/spg2xx_audio.h @@ -17,8 +17,8 @@ class spg2xx_audio_device : public device_t, public device_sound_interface { public: - spg2xx_audio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); - spg2xx_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg2xx_audio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + spg2xx_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto space_read_callback() { return m_space_read_cb.bind(); } auto write_irq_callback() { return m_irq_cb.bind(); } @@ -381,7 +381,7 @@ private: class spg110_audio_device : public spg2xx_audio_device { public: - spg110_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg110_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void audio_w(offs_t offset, uint16_t data) override; @@ -395,7 +395,7 @@ public: class sunplus_gcm394_audio_device : public spg2xx_audio_device { public: - sunplus_gcm394_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sunplus_gcm394_audio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t control_r(offs_t offset); void control_w(offs_t offset, uint16_t data); diff --git a/src/devices/machine/spg2xx_io.cpp b/src/devices/machine/spg2xx_io.cpp index 13fa8a04c4f..8999375ffad 100644 --- a/src/devices/machine/spg2xx_io.cpp +++ b/src/devices/machine/spg2xx_io.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(SPG28X_IO, spg28x_io_device, "spg28x_io", "SPG280-series Syst #define IO_IRQ_ENABLE m_io_regs[REG_INT_CTRL] #define IO_IRQ_STATUS m_io_regs[REG_INT_CLEAR] -spg2xx_io_device::spg2xx_io_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +spg2xx_io_device::spg2xx_io_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_porta_out(*this), m_portb_out(*this), @@ -64,12 +64,12 @@ spg2xx_io_device::spg2xx_io_device(const machine_config &mconfig, device_type ty { } -spg24x_io_device::spg24x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spg24x_io_device::spg24x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg2xx_io_device(mconfig, SPG24X_IO, tag, owner, clock, 256) { } -spg28x_io_device::spg28x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spg28x_io_device::spg28x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg2xx_io_device(mconfig, SPG28X_IO, tag, owner, clock, 64) { } diff --git a/src/devices/machine/spg2xx_io.h b/src/devices/machine/spg2xx_io.h index c674ae72e6b..dc97813640a 100644 --- a/src/devices/machine/spg2xx_io.h +++ b/src/devices/machine/spg2xx_io.h @@ -12,7 +12,7 @@ class spg2xx_io_device : public device_t { public: - spg2xx_io_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spg2xx_io_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); auto porta_out() { return m_porta_out.bind(); } auto portb_out() { return m_portb_out.bind(); } @@ -54,7 +54,7 @@ public: template <size_t Line> uint16_t adc_r() { return m_adc_in[Line](); } protected: - spg2xx_io_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const uint32_t sprite_limit) + spg2xx_io_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const uint32_t sprite_limit) : spg2xx_io_device(mconfig, type, tag, owner, clock) { } @@ -275,28 +275,28 @@ class spg24x_io_device : public spg2xx_io_device { public: template <typename T, typename U> - spg24x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, U &&screen_tag) + spg24x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, U &&screen_tag) : spg24x_io_device(mconfig, tag, owner, clock) { m_cpu.set_tag(std::forward<T>(cpu_tag)); m_screen.set_tag(std::forward<U>(screen_tag)); } - spg24x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg24x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class spg28x_io_device : public spg2xx_io_device { public: template <typename T, typename U> - spg28x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, U &&screen_tag) + spg28x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, U &&screen_tag) : spg28x_io_device(mconfig, tag, owner, clock) { m_cpu.set_tag(std::forward<T>(cpu_tag)); m_screen.set_tag(std::forward<U>(screen_tag)); } - spg28x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg28x_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void io_extended_w(offs_t offset, uint16_t data) override; }; diff --git a/src/devices/machine/spg2xx_sysdma.cpp b/src/devices/machine/spg2xx_sysdma.cpp index d48eee75fdf..14c65dd0be9 100644 --- a/src/devices/machine/spg2xx_sysdma.cpp +++ b/src/devices/machine/spg2xx_sysdma.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(SPG2XX_SYSDMA, spg2xx_sysdma_device, "spg2xx_sysdma", "SPG240 -spg2xx_sysdma_device::spg2xx_sysdma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +spg2xx_sysdma_device::spg2xx_sysdma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPG2XX_SYSDMA, tag, owner, clock) , m_cpu(*this, finder_base::DUMMY_TAG) { diff --git a/src/devices/machine/spg2xx_sysdma.h b/src/devices/machine/spg2xx_sysdma.h index 3264d97ce66..4ba4e85410d 100644 --- a/src/devices/machine/spg2xx_sysdma.h +++ b/src/devices/machine/spg2xx_sysdma.h @@ -20,13 +20,13 @@ class spg2xx_sysdma_device : public device_t { public: template <typename T> - spg2xx_sysdma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag) + spg2xx_sysdma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag) : spg2xx_sysdma_device(mconfig, tag, owner, clock) { m_cpu.set_tag(std::forward<T>(cpu_tag)); } - spg2xx_sysdma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg2xx_sysdma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t dma_r(offs_t offset); void dma_w(offs_t offset, uint16_t data); diff --git a/src/devices/machine/spg2xx_video.cpp b/src/devices/machine/spg2xx_video.cpp index b8d9fa2d22d..b894d3f7300 100644 --- a/src/devices/machine/spg2xx_video.cpp +++ b/src/devices/machine/spg2xx_video.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(SPG24X_VIDEO, spg24x_video_device, "spg24x_video", "SPG240-se #define VIDEO_IRQ_ENABLE m_video_regs[0x62] #define VIDEO_IRQ_STATUS m_video_regs[0x63] -spg2xx_video_device::spg2xx_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +spg2xx_video_device::spg2xx_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_guny_in(*this), m_gunx_in(*this), @@ -42,7 +42,7 @@ spg2xx_video_device::spg2xx_video_device(const machine_config &mconfig, device_t { } -spg24x_video_device::spg24x_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spg24x_video_device::spg24x_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg2xx_video_device(mconfig, SPG24X_VIDEO, tag, owner, clock) { } @@ -479,5 +479,5 @@ TIMER_CALLBACK_MEMBER(spg2xx_video_device::screenpos_hit) void spg2xx_video_device::device_add_mconfig(machine_config &config) { - SPG_RENDERER(config, m_renderer, 0); + SPG_RENDERER(config, m_renderer); } diff --git a/src/devices/machine/spg2xx_video.h b/src/devices/machine/spg2xx_video.h index b484c42d1af..eca0e9ae960 100644 --- a/src/devices/machine/spg2xx_video.h +++ b/src/devices/machine/spg2xx_video.h @@ -18,7 +18,7 @@ class spg2xx_video_device : public device_t { public: - spg2xx_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spg2xx_video_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); auto guny_in() { return m_guny_in.bind(); } auto gunx_in() { return m_gunx_in.bind(); } @@ -65,14 +65,14 @@ class spg24x_video_device : public spg2xx_video_device { public: template <typename T, typename U> - spg24x_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag, U &&screen_tag) + spg24x_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag, U &&screen_tag) : spg24x_video_device(mconfig, tag, owner, clock) { m_cpu.set_tag(std::forward<T>(cpu_tag)); m_screen.set_tag(std::forward<U>(screen_tag)); } - spg24x_video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg24x_video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(SPG24X_VIDEO, spg24x_video_device) diff --git a/src/devices/machine/spg_renderer.cpp b/src/devices/machine/spg_renderer.cpp index 6dd526a902a..a0a127ecf5d 100644 --- a/src/devices/machine/spg_renderer.cpp +++ b/src/devices/machine/spg_renderer.cpp @@ -6,13 +6,13 @@ DEFINE_DEVICE_TYPE(SPG_RENDERER, spg_renderer_device, "spg_renderer", "SunPlus / GeneralPlus video rendering") -spg_renderer_device::spg_renderer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +spg_renderer_device::spg_renderer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_space_read_cb(*this) { } -spg_renderer_device::spg_renderer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spg_renderer_device::spg_renderer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spg_renderer_device(mconfig, SPG_RENDERER, tag, owner, clock) { } diff --git a/src/devices/machine/spg_renderer.h b/src/devices/machine/spg_renderer.h index 23a6a515106..0b04252981a 100644 --- a/src/devices/machine/spg_renderer.h +++ b/src/devices/machine/spg_renderer.h @@ -11,8 +11,8 @@ class spg_renderer_device : public device_t { public: - spg_renderer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); - spg_renderer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spg_renderer_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + spg_renderer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void draw_sprites(bool read_from_csspace, int extended_sprites_mode, bool alt_extrasprite_hack, uint32_t palbank, bool highres, const rectangle& cliprect, uint32_t scanline, int priority, uint32_t spritegfxdata_addr, address_space& spc, uint16_t* paletteram, uint16_t* spriteram, int sprlimit); void draw_page(bool read_from_csspace, bool has_extended_tilemaps, bool use_alt_tile_addressing, uint32_t palbank, const rectangle& cliprect, uint32_t scanline, int priority, uint32_t tilegfxdata_addr, uint16_t* scrollregs, uint16_t* tilemapregs, address_space& spc, uint16_t* paletteram, uint16_t* scrollram, uint32_t which); diff --git a/src/devices/machine/spi_sdcard.cpp b/src/devices/machine/spi_sdcard.cpp index 9166cf8be64..1a36a13c9dc 100644 --- a/src/devices/machine/spi_sdcard.cpp +++ b/src/devices/machine/spi_sdcard.cpp @@ -44,7 +44,7 @@ static constexpr u8 DATA_RESPONSE_IO_ERROR = 0x0d; DEFINE_DEVICE_TYPE(SPI_SDCARD, spi_sdcard_sdhc_device, "spi_sdhccard", "SDHC Card (SPI Interface)") DEFINE_DEVICE_TYPE(SPI_SDCARDV2, spi_sdcard_sdv2_device, "spi_sdv2card", "SDV2 Card (SPI Interface)") -spi_sdcard_device::spi_sdcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +spi_sdcard_device::spi_sdcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), write_miso(*this), m_image(*this, "image"), @@ -57,13 +57,13 @@ spi_sdcard_device::spi_sdcard_device(const machine_config &mconfig, device_type { } -spi_sdcard_sdv2_device::spi_sdcard_sdv2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spi_sdcard_sdv2_device::spi_sdcard_sdv2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spi_sdcard_device(mconfig, SPI_SDCARDV2, tag, owner, clock) { m_type = SD_TYPE_V2; } -spi_sdcard_sdhc_device::spi_sdcard_sdhc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spi_sdcard_sdhc_device::spi_sdcard_sdhc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : spi_sdcard_device(mconfig, SPI_SDCARD, tag, owner, clock) { m_type = SD_TYPE_HC; diff --git a/src/devices/machine/spi_sdcard.h b/src/devices/machine/spi_sdcard.h index 4aa81078685..3ca1be1d68e 100644 --- a/src/devices/machine/spi_sdcard.h +++ b/src/devices/machine/spi_sdcard.h @@ -27,7 +27,7 @@ protected: SD_TYPE_HC }; - spi_sdcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + spi_sdcard_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -82,13 +82,13 @@ private: class spi_sdcard_sdhc_device : public spi_sdcard_device { public: - spi_sdcard_sdhc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spi_sdcard_sdhc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class spi_sdcard_sdv2_device : public spi_sdcard_device { public: - spi_sdcard_sdv2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spi_sdcard_sdv2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(SPI_SDCARD, spi_sdcard_sdhc_device) diff --git a/src/devices/machine/steppers.cpp b/src/devices/machine/steppers.cpp index 98e67916f01..d6ab72da3a2 100644 --- a/src/devices/machine/steppers.cpp +++ b/src/devices/machine/steppers.cpp @@ -44,12 +44,12 @@ DEFINE_DEVICE_TYPE(STEPPER, stepper_device, "stepper", "Stepper Motor") DEFINE_DEVICE_TYPE(REEL, reel_device, "reel", "Fruit Machine Reel") -stepper_device::stepper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +stepper_device::stepper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : stepper_device(mconfig, STEPPER, tag, owner, clock) { } -stepper_device::stepper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +stepper_device::stepper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_max_steps(48*2) , m_optic_cb(*this) @@ -509,7 +509,7 @@ reel_device::reel_device(const machine_config &mconfig, const char *tag, device_ } /////////////////////////////////////////////////////////////////////////// -reel_device::reel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +reel_device::reel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : stepper_device(mconfig, REEL, tag, owner, clock) { } diff --git a/src/devices/machine/steppers.h b/src/devices/machine/steppers.h index 3a07de01d62..dedfe94c838 100644 --- a/src/devices/machine/steppers.h +++ b/src/devices/machine/steppers.h @@ -40,12 +40,12 @@ class stepper_device : public device_t { public: stepper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint8_t init_phase) - : stepper_device(mconfig, tag, owner, (uint32_t)0) + : stepper_device(mconfig, tag, owner) { set_init_phase(init_phase); } - stepper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + stepper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto optic_handler() { return m_optic_cb.bind(); } @@ -77,7 +77,7 @@ public: int get_max() { return m_max_steps; } protected: - stepper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock = 0); + stepper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // device-level overrides virtual void device_start() override; @@ -107,7 +107,7 @@ public: reel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint8_t type, int16_t start_index, int16_t end_index , int16_t index_pattern, uint8_t init_phase, int16_t max_steps = 48*2); - reel_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + reel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/machine/strata.cpp b/src/devices/machine/strata.cpp index 15841fe4597..437bd7558ee 100644 --- a/src/devices/machine/strata.cpp +++ b/src/devices/machine/strata.cpp @@ -45,7 +45,7 @@ DEFINE_DEVICE_TYPE(STRATAFLASH, strataflash_device, "strataflash", "Intel 28F640J5") -strataflash_device::strataflash_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +strataflash_device::strataflash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, STRATAFLASH, tag, owner, clock) , device_nvram_interface(mconfig, *this) { diff --git a/src/devices/machine/strata.h b/src/devices/machine/strata.h index 0c6f487c50e..8fed63319bf 100644 --- a/src/devices/machine/strata.h +++ b/src/devices/machine/strata.h @@ -9,7 +9,7 @@ class strataflash_device : public device_t, public device_nvram_interface { public: - strataflash_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + strataflash_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // 8-bit access uint8_t read8(offs_t offset); diff --git a/src/devices/machine/stvcd.cpp b/src/devices/machine/stvcd.cpp index 23720aa1277..4e29146e141 100644 --- a/src/devices/machine/stvcd.cpp +++ b/src/devices/machine/stvcd.cpp @@ -85,7 +85,7 @@ DASM notes: DEFINE_DEVICE_TYPE(STVCD, stvcd_device, "stvcd", "Sega Saturn/ST-V CD Block HLE") -stvcd_device::stvcd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +stvcd_device::stvcd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, STVCD, tag, owner, clock) , device_mixer_interface(mconfig, *this, 2) , device_memory_interface(mconfig, *this) diff --git a/src/devices/machine/stvcd.h b/src/devices/machine/stvcd.h index 78ad1392c24..509b00c4439 100644 --- a/src/devices/machine/stvcd.h +++ b/src/devices/machine/stvcd.h @@ -20,7 +20,7 @@ class stvcd_device : public device_t, static constexpr uint32_t MAX_DIR_SIZE = 256*1024; public: - stvcd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + stvcd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t stvcd_r(offs_t offset, uint32_t mem_mask = ~0); void stvcd_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0); diff --git a/src/devices/machine/sun4c_mmu.cpp b/src/devices/machine/sun4c_mmu.cpp index 91686a42fdf..6b78d0b495f 100644 --- a/src/devices/machine/sun4c_mmu.cpp +++ b/src/devices/machine/sun4c_mmu.cpp @@ -49,7 +49,7 @@ static FILE* s_mem_log = nullptr; #define VERBOSE (0) #include "logmacro.h" -sun4_mmu_base_device::sun4_mmu_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +sun4_mmu_base_device::sun4_mmu_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_cpu(*this, finder_base::DUMMY_TAG) , m_ram(*this, finder_base::DUMMY_TAG) @@ -71,12 +71,12 @@ sun4_mmu_base_device::sun4_mmu_base_device(const machine_config &mconfig, device { } -sun4_mmu_device::sun4_mmu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sun4_mmu_device::sun4_mmu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sun4_mmu_base_device(mconfig, SUN4_MMU, tag, owner, clock, 7, 0x7f, 0x7ff, 11, 0x1f, 0x7ffff, 0xfff) { } -sun4c_mmu_device::sun4c_mmu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sun4c_mmu_device::sun4c_mmu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sun4_mmu_base_device(mconfig, SUN4C_MMU, tag, owner, clock, 7, 0x7f, 0x3ff, 10, 0x3f, 0xffff, 0x3fff) { } diff --git a/src/devices/machine/sun4c_mmu.h b/src/devices/machine/sun4c_mmu.h index bd9b1201fbf..3ba13fbff97 100644 --- a/src/devices/machine/sun4c_mmu.h +++ b/src/devices/machine/sun4c_mmu.h @@ -20,7 +20,7 @@ class sun4_mmu_base_device : public device_t, public sparc_mmu_interface { public: - sun4_mmu_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock + sun4_mmu_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock , uint8_t ctx_mask, uint8_t pmeg_mask, uint32_t page_mask, uint32_t seg_entry_shift, uint32_t seg_entry_mask , uint32_t page_entry_mask, uint32_t cache_mask) : sun4_mmu_base_device(mconfig, type, tag, owner, clock) @@ -105,7 +105,7 @@ public: void hw_flush_all_w(uint32_t offset, uint32_t data, uint32_t mem_mask); protected: - sun4_mmu_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sun4_mmu_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); struct page_entry { @@ -225,13 +225,13 @@ protected: class sun4_mmu_device : public sun4_mmu_base_device { public: - sun4_mmu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sun4_mmu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class sun4c_mmu_device : public sun4_mmu_base_device { public: - sun4c_mmu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sun4c_mmu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(SUN4_MMU, sun4_mmu_device) diff --git a/src/devices/machine/swim1.cpp b/src/devices/machine/swim1.cpp index 2d0adc04c60..9a66f991641 100644 --- a/src/devices/machine/swim1.cpp +++ b/src/devices/machine/swim1.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(SWIM1, swim1_device, "swim1", "Apple SWIM1 (Sander/Wozniak Integrated Machine) version 1 floppy controller") -swim1_device::swim1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +swim1_device::swim1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : applefdintf_device(mconfig, SWIM1, tag, owner, clock), m_floppy(nullptr), m_timer(nullptr) diff --git a/src/devices/machine/swim1.h b/src/devices/machine/swim1.h index dd0b372d54f..0c515ff5fe6 100644 --- a/src/devices/machine/swim1.h +++ b/src/devices/machine/swim1.h @@ -22,7 +22,7 @@ class swim1_device : public applefdintf_device { public: // construction/destruction - swim1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + swim1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read(offs_t offset) override; virtual void write(offs_t offset, u8 data) override; diff --git a/src/devices/machine/swim2.cpp b/src/devices/machine/swim2.cpp index d1834aad676..9181a2311ae 100644 --- a/src/devices/machine/swim2.cpp +++ b/src/devices/machine/swim2.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(SWIM2, swim2_device, "swim2", "Apple SWIM2 (Sander/Wozniak Integrated Machine) version 2 floppy controller") -swim2_device::swim2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +swim2_device::swim2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : applefdintf_device(mconfig, SWIM2, tag, owner, clock), m_floppy(nullptr) { diff --git a/src/devices/machine/swim2.h b/src/devices/machine/swim2.h index bab440e4ec9..edcea871909 100644 --- a/src/devices/machine/swim2.h +++ b/src/devices/machine/swim2.h @@ -23,7 +23,7 @@ class swim2_device : public applefdintf_device { public: // construction/destruction - swim2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + swim2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 read(offs_t offset) override; virtual void write(offs_t offset, u8 data) override; diff --git a/src/devices/machine/swim3.cpp b/src/devices/machine/swim3.cpp index 6c93ee6b0c4..5e4db4bc62d 100644 --- a/src/devices/machine/swim3.cpp +++ b/src/devices/machine/swim3.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(SWIM3, swim3_device, "swim3", "Apple SWIM3 (Sander/Wozniak Integrated Machine) version 3 floppy controller") -swim3_device::swim3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +swim3_device::swim3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : applefdintf_device(mconfig, SWIM3, tag, owner, clock), m_irq_cb(*this), m_drq_cb(*this) diff --git a/src/devices/machine/swim3.h b/src/devices/machine/swim3.h index 61e280850e0..3bbfcda44ee 100644 --- a/src/devices/machine/swim3.h +++ b/src/devices/machine/swim3.h @@ -22,7 +22,7 @@ class swim3_device : public applefdintf_device { public: // construction/destruction - swim3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + swim3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_cb() { return m_irq_cb.bind(); } auto drq_cb() { return m_drq_cb.bind(); } diff --git a/src/devices/machine/swtpc8212.cpp b/src/devices/machine/swtpc8212.cpp index 4d214e43175..1870d4424e7 100644 --- a/src/devices/machine/swtpc8212.cpp +++ b/src/devices/machine/swtpc8212.cpp @@ -141,7 +141,7 @@ swtp|ct8212|southwest technical products ct8212, #include "screen.h" #include "speaker.h" -swtpc8212_device::swtpc8212_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +swtpc8212_device::swtpc8212_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_maincpu(*this, "maincpu") , m_pia0(*this, "pia0") @@ -163,7 +163,7 @@ swtpc8212_device::swtpc8212_device(const machine_config &mconfig, device_type ty { } -swtpc8212_device::swtpc8212_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +swtpc8212_device::swtpc8212_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : swtpc8212_device(mconfig, SWTPC8212, tag, owner, clock) { } @@ -547,14 +547,14 @@ void swtpc8212_device::device_add_mconfig(machine_config &config) m_crtc->set_show_border_area(false); m_crtc->set_update_row_callback(FUNC(swtpc8212_device::update_row)); - generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, "keyboard", 0)); + generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, "keyboard")); keyboard.set_keyboard_callback(FUNC(swtpc8212_device::keyboard_put)); SPEAKER(config, "bell").front_center(); - BEEP(config, m_beeper, 2000); + BEEP(config, m_beeper, XTAL::u(2000)); m_beeper->add_route(ALL_OUTPUTS, "bell", 0.25); - PRINTER(config, m_printer, 0); + PRINTER(config, m_printer); } ioport_constructor swtpc8212_device::device_input_ports() const diff --git a/src/devices/machine/swtpc8212.h b/src/devices/machine/swtpc8212.h index 0d363860c14..4107ce359ba 100644 --- a/src/devices/machine/swtpc8212.h +++ b/src/devices/machine/swtpc8212.h @@ -19,7 +19,7 @@ INPUT_PORTS_EXTERN(swtpc8212); class swtpc8212_device : public device_t { public: - swtpc8212_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + swtpc8212_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_INPUT_CHANGED_MEMBER(keypad_changed); @@ -34,7 +34,7 @@ public: void rs232_conn_rxd_w(int state); protected: - swtpc8212_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + swtpc8212_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_resolve_objects() override; virtual void device_start() override; diff --git a/src/devices/machine/tc009xlvc.cpp b/src/devices/machine/tc009xlvc.cpp index 8d4b762f53a..363cc9cb7cf 100644 --- a/src/devices/machine/tc009xlvc.cpp +++ b/src/devices/machine/tc009xlvc.cpp @@ -109,12 +109,12 @@ void tc0090lvc_device::vram_map(address_map &map) map(0x080000, 0x0801ff).ram().mirror(0x00e00).w("palette", FUNC(palette_device::write8)).share("palette"); } -tc0090lvc_device::tc0090lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tc0090lvc_device::tc0090lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tc0090lvc_device(mconfig, TC0090LVC, tag, owner, clock) { } -tc0090lvc_device::tc0090lvc_device(const machine_config &mconfig, device_type &type, const char *tag, device_t *owner, u32 clock) +tc0090lvc_device::tc0090lvc_device(const machine_config &mconfig, device_type &type, const char *tag, device_t *owner, const XTAL &clock) : z80_device(mconfig, type, tag, owner, clock) , device_gfx_interface(mconfig, *this, gfxinfo, "palette") , m_program_space_config("program", ENDIANNESS_LITTLE, 8, 16, 0, address_map_constructor(FUNC(tc0090lvc_device::cpu_map), this)) @@ -132,7 +132,7 @@ tc0090lvc_device::tc0090lvc_device(const machine_config &mconfig, device_type &t { } -tc0091lvc_device::tc0091lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tc0091lvc_device::tc0091lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tc0090lvc_device(mconfig, TC0091LVC, tag, owner, clock) { } diff --git a/src/devices/machine/tc009xlvc.h b/src/devices/machine/tc009xlvc.h index c4be5989a78..2123ed2bb1b 100644 --- a/src/devices/machine/tc009xlvc.h +++ b/src/devices/machine/tc009xlvc.h @@ -19,7 +19,7 @@ class tc0090lvc_device : public z80_device, public device_gfx_interface public: typedef device_delegate<void (u32 &code)> tc009xlvc_cb_delegate; - tc0090lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tc0090lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration template <typename... T> void set_tile_callback(T &&... args) { m_tile_cb.set(std::forward<T>(args)...); } @@ -54,7 +54,7 @@ public: void cpu_map(address_map &map); protected: - tc0090lvc_device(const machine_config &mconfig, device_type &type, const char *tag, device_t *owner, u32 clock); + tc0090lvc_device(const machine_config &mconfig, device_type &type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_add_mconfig(machine_config &config) override; @@ -123,7 +123,7 @@ protected: class tc0091lvc_device : public tc0090lvc_device { public: - tc0091lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tc0091lvc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u32 screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect) override; virtual void screen_eof() override; diff --git a/src/devices/machine/tdc1008.cpp b/src/devices/machine/tdc1008.cpp index 33966e08063..58d7b0a4f36 100644 --- a/src/devices/machine/tdc1008.cpp +++ b/src/devices/machine/tdc1008.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(TDC1008, tdc1008_device, "tdc1008", "TRW TDC1008 Multiplier-A // tdc1008_device - constructor //------------------------------------------------- -tdc1008_device::tdc1008_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tdc1008_device::tdc1008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TDC1008, tag, owner, clock) , m_x_in(0) , m_y_in(0) diff --git a/src/devices/machine/tdc1008.h b/src/devices/machine/tdc1008.h index dcb8d21c9d5..8760d212824 100644 --- a/src/devices/machine/tdc1008.h +++ b/src/devices/machine/tdc1008.h @@ -22,7 +22,7 @@ class tdc1008_device : public device_t { public: // construction/destruction - tdc1008_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + tdc1008_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void x_w(uint8_t data); void y_w(uint8_t data); diff --git a/src/devices/machine/te7750.cpp b/src/devices/machine/te7750.cpp index 540b3b27cf5..4b96ddd9cad 100644 --- a/src/devices/machine/te7750.cpp +++ b/src/devices/machine/te7750.cpp @@ -188,7 +188,7 @@ DEFINE_DEVICE_TYPE(TE7752, te7752_device, "te7752", "TE7752 Super I/O Expander") // te7750_device - constructor //------------------------------------------------- -te7750_device::te7750_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +te7750_device::te7750_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_input_cb(*this) , m_output_cb(*this) @@ -197,7 +197,7 @@ te7750_device::te7750_device(const machine_config &mconfig, device_type type, co std::fill(std::begin(m_data_dir), std::end(m_data_dir), 0xff); } -te7750_device::te7750_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +te7750_device::te7750_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : te7750_device(mconfig, TE7750, tag, owner, clock) { } @@ -206,7 +206,7 @@ te7750_device::te7750_device(const machine_config &mconfig, const char *tag, dev // te7751_device - constructor //------------------------------------------------- -te7751_device::te7751_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +te7751_device::te7751_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : te7750_device(mconfig, TE7751, tag, owner, clock) { } @@ -215,7 +215,7 @@ te7751_device::te7751_device(const machine_config &mconfig, const char *tag, dev // te7752_device - constructor //------------------------------------------------- -te7752_device::te7752_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +te7752_device::te7752_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : te7750_device(mconfig, TE7752, tag, owner, clock) { } diff --git a/src/devices/machine/te7750.h b/src/devices/machine/te7750.h index 8417fbce51a..cd79352cefe 100644 --- a/src/devices/machine/te7750.h +++ b/src/devices/machine/te7750.h @@ -22,7 +22,7 @@ class te7750_device : public device_t { public: // construction/destruction - te7750_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + te7750_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration auto in_port1_cb() { return m_input_cb[0].bind(); } @@ -50,7 +50,7 @@ public: void write(offs_t offset, u8 data); protected: - te7750_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + te7750_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -78,7 +78,7 @@ private: class te7751_device : public te7750_device { public: - te7751_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + te7751_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // ======================> te7752_device @@ -86,7 +86,7 @@ public: class te7752_device : public te7750_device { public: - te7752_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + te7752_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // device type definitions diff --git a/src/devices/machine/terminal.cpp b/src/devices/machine/terminal.cpp index fc1b5cf3092..0d173723a8b 100644 --- a/src/devices/machine/terminal.cpp +++ b/src/devices/machine/terminal.cpp @@ -143,7 +143,7 @@ static const uint8_t terminal_font[256*16] = 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; -generic_terminal_device::generic_terminal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, unsigned w, unsigned h) +generic_terminal_device::generic_terminal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, unsigned w, unsigned h) : device_t(mconfig, type, tag, owner, clock) , m_io_term_conf(*this, "TERM_CONF") , m_width(w) @@ -158,7 +158,7 @@ generic_terminal_device::generic_terminal_device(const machine_config &mconfig, { } -generic_terminal_device::generic_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +generic_terminal_device::generic_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : generic_terminal_device(mconfig, GENERIC_TERMINAL, tag, owner, clock, TERMINAL_WIDTH, TERMINAL_HEIGHT) { } @@ -335,11 +335,11 @@ void generic_terminal_device::device_add_mconfig(machine_config &config) screen.set_visarea(0, generic_terminal_device::TERMINAL_WIDTH*8-1, 0, generic_terminal_device::TERMINAL_HEIGHT*10-1); screen.set_screen_update(FUNC(generic_terminal_device::update)); - generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, KEYBOARD_TAG, 0)); + generic_keyboard_device &keyboard(GENERIC_KEYBOARD(config, KEYBOARD_TAG)); keyboard.set_keyboard_callback(FUNC(generic_terminal_device::kbd_put)); SPEAKER(config, "bell").front_center(); - BEEP(config, m_beeper, 2'000); + BEEP(config, m_beeper, XTAL::u(2'000)); m_beeper->add_route(ALL_OUTPUTS, "bell", 0.25); } diff --git a/src/devices/machine/terminal.h b/src/devices/machine/terminal.h index 5ebf1468b22..257c66f9f86 100644 --- a/src/devices/machine/terminal.h +++ b/src/devices/machine/terminal.h @@ -21,7 +21,7 @@ INPUT_PORTS_EXTERN( generic_terminal ); class generic_terminal_device : public device_t { public: - generic_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + generic_terminal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename... T> void set_keyboard_callback(T &&... args) @@ -34,7 +34,7 @@ public: void kbd_put(u8 data); protected: - generic_terminal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, unsigned w, unsigned h); + generic_terminal_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, unsigned w, unsigned h); virtual void term_write(uint8_t data); virtual void device_start() override; diff --git a/src/devices/machine/ticket.cpp b/src/devices/machine/ticket.cpp index cdc0385827d..2dcfbdac6e0 100644 --- a/src/devices/machine/ticket.cpp +++ b/src/devices/machine/ticket.cpp @@ -41,7 +41,7 @@ DEFINE_DEVICE_TYPE(HOPPER, hopper_device, "coin_hopper", "Coin Hopper") // ticket_dispenser_device - constructor //------------------------------------------------- -ticket_dispenser_device::ticket_dispenser_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ticket_dispenser_device::ticket_dispenser_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_motor_sense(TICKET_MOTOR_ACTIVE_LOW) , m_status_sense(TICKET_STATUS_ACTIVE_LOW) @@ -58,12 +58,12 @@ ticket_dispenser_device::ticket_dispenser_device(const machine_config &mconfig, { } -ticket_dispenser_device::ticket_dispenser_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ticket_dispenser_device::ticket_dispenser_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ticket_dispenser_device(mconfig, TICKET_DISPENSER, tag, owner, clock) { } -hopper_device::hopper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hopper_device::hopper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ticket_dispenser_device(mconfig, HOPPER, tag, owner, clock) { } diff --git a/src/devices/machine/ticket.h b/src/devices/machine/ticket.h index ac1cd01c029..fc4d45f4674 100644 --- a/src/devices/machine/ticket.h +++ b/src/devices/machine/ticket.h @@ -49,7 +49,7 @@ public: set_period(period); set_senses(motor_sense, status_sense, false); } - ticket_dispenser_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ticket_dispenser_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~ticket_dispenser_device(); // inline configuration helpers @@ -68,7 +68,7 @@ public: DECLARE_WRITE_LINE_MEMBER( motor_w ); protected: - ticket_dispenser_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock = 0); + ticket_dispenser_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // device-level overrides virtual void device_start() override; @@ -104,10 +104,7 @@ public: set_period(period); set_senses(motor_sense, status_sense, true); } - hopper_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); - -private: - + hopper_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; #endif // MAME_MACHINE_TICKET_H diff --git a/src/devices/machine/timekpr.cpp b/src/devices/machine/timekpr.cpp index 5825aa72100..7f21a6b76c0 100644 --- a/src/devices/machine/timekpr.cpp +++ b/src/devices/machine/timekpr.cpp @@ -88,7 +88,7 @@ inline int counter_from_ram(u8 const *data, s32 offset, u8 unmap = 0) // timekeeper_device_config - constructor //------------------------------------------------- -timekeeper_device::timekeeper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 size) +timekeeper_device::timekeeper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 size) : device_t(mconfig, type, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_reset_cb(*this) @@ -98,7 +98,7 @@ timekeeper_device::timekeeper_device(const machine_config &mconfig, device_type { } -m48t02_device::m48t02_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m48t02_device::m48t02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : timekeeper_device(mconfig, M48T02, tag, owner, clock, 0x800) { m_offset_watchdog = -1; @@ -114,7 +114,7 @@ m48t02_device::m48t02_device(const machine_config &mconfig, const char *tag, dev m_offset_flags = -1; } -m48t35_device::m48t35_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m48t35_device::m48t35_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : timekeeper_device(mconfig, M48T35, tag, owner, clock, 0x8000) { m_offset_watchdog = -1; @@ -130,7 +130,7 @@ m48t35_device::m48t35_device(const machine_config &mconfig, const char *tag, dev m_offset_flags = -1; } -m48t37_device::m48t37_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m48t37_device::m48t37_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : timekeeper_device(mconfig, M48T37, tag, owner, clock, 0x8000) { m_offset_watchdog = 0x7ff7; @@ -146,7 +146,7 @@ m48t37_device::m48t37_device(const machine_config &mconfig, const char *tag, dev m_offset_flags = 0x7ff0; } -m48t58_device::m48t58_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m48t58_device::m48t58_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : timekeeper_device(mconfig, M48T58, tag, owner, clock, 0x2000) { m_offset_watchdog = -1; @@ -162,7 +162,7 @@ m48t58_device::m48t58_device(const machine_config &mconfig, const char *tag, dev m_offset_flags = -1; } -mk48t08_device::mk48t08_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mk48t08_device::mk48t08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : timekeeper_device(mconfig, MK48T08, tag, owner, clock, 0x2000) { m_offset_watchdog = -1; @@ -178,7 +178,7 @@ mk48t08_device::mk48t08_device(const machine_config &mconfig, const char *tag, d m_offset_flags = 0x1ff0; } -mk48t12_device::mk48t12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +mk48t12_device::mk48t12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : timekeeper_device(mconfig, MK48T12, tag, owner, clock, 0x800) { m_offset_watchdog = -1; diff --git a/src/devices/machine/timekpr.h b/src/devices/machine/timekpr.h index 9d6d04fafb4..e61adf8e578 100644 --- a/src/devices/machine/timekpr.h +++ b/src/devices/machine/timekpr.h @@ -41,7 +41,7 @@ public: protected: // construction/destruction - timekeeper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 size); + timekeeper_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 size); // device-level overrides virtual void device_start() override; @@ -95,37 +95,37 @@ protected: class m48t02_device : public timekeeper_device { public: - m48t02_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + m48t02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class m48t35_device : public timekeeper_device { public: - m48t35_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + m48t35_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class m48t37_device : public timekeeper_device { public: - m48t37_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + m48t37_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class m48t58_device : public timekeeper_device { public: - m48t58_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + m48t58_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class mk48t08_device : public timekeeper_device { public: - mk48t08_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + mk48t08_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class mk48t12_device : public timekeeper_device { public: - mk48t12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + mk48t12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; // device type definition diff --git a/src/devices/machine/timer.cpp b/src/devices/machine/timer.cpp index 67621f1085f..871cb3ff87c 100644 --- a/src/devices/machine/timer.cpp +++ b/src/devices/machine/timer.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(TIMER, timer_device, "timer", "Timer") // timer_device - constructor //------------------------------------------------- -timer_device::timer_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +timer_device::timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TIMER, tag, owner, clock), m_type(TIMER_TYPE_GENERIC), m_callback(*this), diff --git a/src/devices/machine/timer.h b/src/devices/machine/timer.h index 2c138a1565c..aca06860c77 100644 --- a/src/devices/machine/timer.h +++ b/src/devices/machine/timer.h @@ -35,7 +35,7 @@ public: typedef device_delegate<void (timer_device &, s32)> expired_delegate; // construction/destruction - timer_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration helpers template <typename... T> void configure_generic(T &&... args) diff --git a/src/devices/machine/tmc0430.cpp b/src/devices/machine/tmc0430.cpp index 76e53c88ded..89505b39ac1 100644 --- a/src/devices/machine/tmc0430.cpp +++ b/src/devices/machine/tmc0430.cpp @@ -107,7 +107,7 @@ /* Constructor. */ -tmc0430_device::tmc0430_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tmc0430_device::tmc0430_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMC0430, tag, owner, clock), m_gromready(*this), m_current_clock_level(CLEAR_LINE), diff --git a/src/devices/machine/tmc0430.h b/src/devices/machine/tmc0430.h index 09800f2f514..b934cbc6823 100644 --- a/src/devices/machine/tmc0430.h +++ b/src/devices/machine/tmc0430.h @@ -28,12 +28,12 @@ class tmc0430_device : public device_t { public: tmc0430_device(const machine_config &mconfig, const char *tag, device_t *owner, const char *regionname, int offset, int ident) : - tmc0430_device(mconfig, tag, owner, 0) + tmc0430_device(mconfig, tag, owner) { set_region_and_ident(regionname, offset, ident); } - tmc0430_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmc0430_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto ready_cb() { return m_gromready.bind(); } diff --git a/src/devices/machine/tmc0999.cpp b/src/devices/machine/tmc0999.cpp index e270e871524..456d212b672 100644 --- a/src/devices/machine/tmc0999.cpp +++ b/src/devices/machine/tmc0999.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(TMC0999, tmc0999_device, "tmc0999", "TI TMC0999 RAM") // constructor //------------------------------------------------- -tmc0999_device::tmc0999_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +tmc0999_device::tmc0999_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMC0999, tag, owner, clock) { } diff --git a/src/devices/machine/tmc0999.h b/src/devices/machine/tmc0999.h index 24305b8d8ee..df5766cb27b 100644 --- a/src/devices/machine/tmc0999.h +++ b/src/devices/machine/tmc0999.h @@ -27,7 +27,7 @@ quick pinout reference (18-pin DIP) class tmc0999_device : public device_t { public: - tmc0999_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + tmc0999_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void di_w(u8 data); u8 do_r(); diff --git a/src/devices/machine/tmc208k.cpp b/src/devices/machine/tmc208k.cpp index fe275fd693c..52e1c31d241 100644 --- a/src/devices/machine/tmc208k.cpp +++ b/src/devices/machine/tmc208k.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(TMC28KU, tmc28ku_device, "tmc28ku", "TRW TMC28KU 8x8-bit Mult //------------------------------------------------- template <typename RegType, typename OutType> -tmc208_base_device<RegType, OutType>::tmc208_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +tmc208_base_device<RegType, OutType>::tmc208_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_a_in(0) , m_a(0) @@ -44,12 +44,12 @@ tmc208_base_device<RegType, OutType>::tmc208_base_device(const machine_config &m { } -tmc208k_device::tmc208k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmc208k_device::tmc208k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tmc208_base_device<int8_t, int16_t>(mconfig, TMC208K, tag, owner, clock) { } -tmc28ku_device::tmc28ku_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmc28ku_device::tmc28ku_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tmc208_base_device<uint8_t, uint16_t>(mconfig, TMC28KU, tag, owner, clock) { } diff --git a/src/devices/machine/tmc208k.h b/src/devices/machine/tmc208k.h index eb077934eb2..29ececfe8b0 100644 --- a/src/devices/machine/tmc208k.h +++ b/src/devices/machine/tmc208k.h @@ -26,7 +26,7 @@ class tmc208_base_device : public device_t { public: // construction/destruction - tmc208_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock = 0); + tmc208_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void a_w(uint8_t data); void b_w(uint8_t data); @@ -79,7 +79,7 @@ class tmc208k_device : public tmc208_base_device<int8_t, int16_t> { public: // construction/destruction - tmc208k_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + tmc208k_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; @@ -89,7 +89,7 @@ class tmc28ku_device : public tmc208_base_device<uint8_t, uint16_t> { public: // construction/destruction - tmc28ku_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + tmc28ku_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void clock_b() override; diff --git a/src/devices/machine/tmp68301.cpp b/src/devices/machine/tmp68301.cpp index bd3d2dc06f1..9967ecde7d4 100644 --- a/src/devices/machine/tmp68301.cpp +++ b/src/devices/machine/tmp68301.cpp @@ -134,7 +134,7 @@ void tmp68301_device::icr_w(offs_t offset, uint8_t data) m_icr[offset] = data; } -tmp68301_device::tmp68301_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmp68301_device::tmp68301_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : m68000_device(mconfig, TMP68301, tag, owner, clock), m_in_parallel_cb(*this), m_out_parallel_cb(*this), diff --git a/src/devices/machine/tmp68301.h b/src/devices/machine/tmp68301.h index 060519ebd1b..17113306f3c 100644 --- a/src/devices/machine/tmp68301.h +++ b/src/devices/machine/tmp68301.h @@ -19,7 +19,7 @@ class tmp68301_device : public m68000_device { public: - tmp68301_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmp68301_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto in_parallel_callback() { return m_in_parallel_cb.bind(); } auto out_parallel_callback() { return m_out_parallel_cb.bind(); } diff --git a/src/devices/machine/tms1024.cpp b/src/devices/machine/tms1024.cpp index a17fe1811e9..bd067f6aec6 100644 --- a/src/devices/machine/tms1024.cpp +++ b/src/devices/machine/tms1024.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(TMS1025, tms1025_device, "tms1025", "TMS1025 I/O Expander") // constructor //------------------------------------------------- -tms1024_device::tms1024_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +tms1024_device::tms1024_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_h(0), m_s(0), m_std(0), m_ms(0) , m_read_port(*this) @@ -29,12 +29,12 @@ tms1024_device::tms1024_device(const machine_config &mconfig, device_type type, { } -tms1024_device::tms1024_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tms1024_device::tms1024_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1024_device(mconfig, TMS1024, tag, owner, clock) { } -tms1025_device::tms1025_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tms1025_device::tms1025_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms1024_device(mconfig, TMS1025, tag, owner, clock) { } diff --git a/src/devices/machine/tms1024.h b/src/devices/machine/tms1024.h index 49193191bfa..ee61cb7563d 100644 --- a/src/devices/machine/tms1024.h +++ b/src/devices/machine/tms1024.h @@ -57,7 +57,7 @@ public: PORT7 }; - tms1024_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + tms1024_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers auto read_port4_callback() { return m_read_port[3].bind(); } @@ -77,7 +77,7 @@ public: void write_ms(int state); protected: - tms1024_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + tms1024_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -96,7 +96,7 @@ protected: class tms1025_device : public tms1024_device { public: - tms1025_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + tms1025_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto read_port1_callback() { return m_read_port[0].bind(); } auto read_port2_callback() { return m_read_port[1].bind(); } diff --git a/src/devices/machine/tms5501.cpp b/src/devices/machine/tms5501.cpp index f5844d1c8bf..752466049e3 100644 --- a/src/devices/machine/tms5501.cpp +++ b/src/devices/machine/tms5501.cpp @@ -55,7 +55,7 @@ void tms5501_device::io_map(address_map &map) // tms5501_device - constructor //------------------------------------------------- -tms5501_device::tms5501_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tms5501_device::tms5501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMS5501, tag, owner, clock), device_serial_interface(mconfig, *this), m_write_int(*this), diff --git a/src/devices/machine/tms5501.h b/src/devices/machine/tms5501.h index e916141d12c..d2a0f23dc2d 100644 --- a/src/devices/machine/tms5501.h +++ b/src/devices/machine/tms5501.h @@ -49,7 +49,7 @@ class tms5501_device : public device_t, { public: // construction/destruction - tms5501_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms5501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto int_callback() { return m_write_int.bind(); } auto xmt_callback() { return m_write_xmt.bind(); } diff --git a/src/devices/machine/tms6100.cpp b/src/devices/machine/tms6100.cpp index 62bfc994b1f..06babec0ef6 100644 --- a/src/devices/machine/tms6100.cpp +++ b/src/devices/machine/tms6100.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(TMS6100, tms6100_device, "tms6100", "TMS6100 VSM") DEFINE_DEVICE_TYPE(M58819, m58819_device, "m58819s", "M68819S") -tms6100_device::tms6100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +tms6100_device::tms6100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_rom(*this, DEVICE_SELF) , m_reverse_bits(false) @@ -38,13 +38,13 @@ tms6100_device::tms6100_device(const machine_config &mconfig, device_type type, { } -tms6100_device::tms6100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tms6100_device::tms6100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms6100_device(mconfig, TMS6100, tag, owner, clock) { } -m58819_device::m58819_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +m58819_device::m58819_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms6100_device(mconfig, M58819, tag, owner, clock) { } diff --git a/src/devices/machine/tms6100.h b/src/devices/machine/tms6100.h index b7bfd7b3b45..d2e4da6b162 100644 --- a/src/devices/machine/tms6100.h +++ b/src/devices/machine/tms6100.h @@ -82,7 +82,7 @@ class tms6100_device : public device_t { public: - tms6100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms6100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // 4-bit mode (mask option) // note: in 4-bit mode, use data_r, otherwise use data_line_r @@ -99,7 +99,7 @@ public: int data_line_r(); protected: - tms6100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + tms6100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -131,7 +131,7 @@ protected: class m58819_device : public tms6100_device { public: - m58819_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + m58819_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/machine/tms9901.cpp b/src/devices/machine/tms9901.cpp index 6714945fa2a..966562f144b 100644 --- a/src/devices/machine/tms9901.cpp +++ b/src/devices/machine/tms9901.cpp @@ -167,7 +167,7 @@ Clock mode: /* Constructor */ -tms9901_device::tms9901_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9901_device::tms9901_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMS9901, tag, owner, clock), m_int_level(0), m_last_level(0), diff --git a/src/devices/machine/tms9901.h b/src/devices/machine/tms9901.h index 3d4808654a3..064dd01e86f 100644 --- a/src/devices/machine/tms9901.h +++ b/src/devices/machine/tms9901.h @@ -56,7 +56,7 @@ public: P6 } pins; - tms9901_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9901_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_int_line(int pin_number, int state); diff --git a/src/devices/machine/tms9902.cpp b/src/devices/machine/tms9902.cpp index 68c0f671155..cddbe599922 100644 --- a/src/devices/machine/tms9902.cpp +++ b/src/devices/machine/tms9902.cpp @@ -72,7 +72,7 @@ /* Constructor */ -tms9902_device::tms9902_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9902_device::tms9902_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMS9902, tag, owner, clock) , m_int_cb(*this) , m_rcv_cb(*this) diff --git a/src/devices/machine/tms9902.h b/src/devices/machine/tms9902.h index c784687bbe8..2679f7d1067 100644 --- a/src/devices/machine/tms9902.h +++ b/src/devices/machine/tms9902.h @@ -48,7 +48,7 @@ public: static constexpr unsigned DTR = 0x02; static constexpr unsigned RI = 0x01; - tms9902_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9902_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Callbacks auto int_cb() { return m_int_cb.bind(); } diff --git a/src/devices/machine/tms9914.cpp b/src/devices/machine/tms9914.cpp index 14cfcb7b039..dec9870d9f9 100644 --- a/src/devices/machine/tms9914.cpp +++ b/src/devices/machine/tms9914.cpp @@ -174,7 +174,7 @@ constexpr uint8_t IFCMD_UNT = 0x5f; // Untalk DEFINE_DEVICE_TYPE(TMS9914, tms9914_device, "tms9914", "TMS9914 GPIB Controller") // Constructors -tms9914_device::tms9914_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9914_device::tms9914_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig , TMS9914 , tag , owner , clock), m_dio_read_func(*this), m_dio_write_func(*this), diff --git a/src/devices/machine/tms9914.h b/src/devices/machine/tms9914.h index d67b85de025..4dddcab3dda 100644 --- a/src/devices/machine/tms9914.h +++ b/src/devices/machine/tms9914.h @@ -39,7 +39,7 @@ class tms9914_device : public device_t { public: // construction/destruction - tms9914_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9914_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // See ieee488.h enum ieee_488_signal_t { diff --git a/src/devices/machine/tsb12lv01a.cpp b/src/devices/machine/tsb12lv01a.cpp index b893eafeefe..3fd4484d55d 100644 --- a/src/devices/machine/tsb12lv01a.cpp +++ b/src/devices/machine/tsb12lv01a.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(TSB12LV01A, tsb12lv01a_device, "tsb12lv01a", "TSB12LV01A IEEE 1394 Link Controller") -tsb12lv01a_device::tsb12lv01a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tsb12lv01a_device::tsb12lv01a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TSB12LV01A, tag, owner, clock) , m_int_cb(*this) , m_phy_read_cb(*this) diff --git a/src/devices/machine/tsb12lv01a.h b/src/devices/machine/tsb12lv01a.h index 4f47fd31815..57de0b41da9 100644 --- a/src/devices/machine/tsb12lv01a.h +++ b/src/devices/machine/tsb12lv01a.h @@ -17,7 +17,7 @@ class tsb12lv01a_device : public device_t { public: - tsb12lv01a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tsb12lv01a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t read(offs_t offset); void write(offs_t offset, uint32_t data, uint32_t mem_mask); diff --git a/src/devices/machine/tube.cpp b/src/devices/machine/tube.cpp index f16fed18da5..28177c9b1dc 100644 --- a/src/devices/machine/tube.cpp +++ b/src/devices/machine/tube.cpp @@ -29,7 +29,7 @@ DEFINE_DEVICE_TYPE(TUBE, tube_device, "tube", "Acorn Tube ULA") // bbc_tube_slot_device - constructor //------------------------------------------------- -tube_device::tube_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tube_device::tube_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TUBE, tag, owner, clock) , m_hirq_handler(*this) , m_pnmi_handler(*this) diff --git a/src/devices/machine/tube.h b/src/devices/machine/tube.h index 079c89cf86d..eb6171c50e5 100644 --- a/src/devices/machine/tube.h +++ b/src/devices/machine/tube.h @@ -24,7 +24,7 @@ class tube_device : public device_t { public: // construction/destruction - tube_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + tube_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // callbacks auto hirq_handler() { return m_hirq_handler.bind(); } diff --git a/src/devices/machine/ucb1200.cpp b/src/devices/machine/ucb1200.cpp index 54e68321523..555959d507f 100644 --- a/src/devices/machine/ucb1200.cpp +++ b/src/devices/machine/ucb1200.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(UCB1200, ucb1200_device, "ucb1200", "Philips UCB1200 modem/audio codec") -ucb1200_device::ucb1200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ucb1200_device::ucb1200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UCB1200, tag, owner, clock) , m_gpio_out(*this) , m_audio_out(*this) diff --git a/src/devices/machine/ucb1200.h b/src/devices/machine/ucb1200.h index 19cf474917b..84f133d25c1 100644 --- a/src/devices/machine/ucb1200.h +++ b/src/devices/machine/ucb1200.h @@ -14,7 +14,7 @@ class ucb1200_device : public device_t { public: - ucb1200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ucb1200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <unsigned Line> auto gpio_out() { return m_gpio_out[Line].bind(); } template <unsigned Line> void gpio_in(int state) { gpio_in((uint16_t)Line, state); } diff --git a/src/devices/machine/upc82c710.cpp b/src/devices/machine/upc82c710.cpp index bf6352a69c7..c3685d3d7a1 100644 --- a/src/devices/machine/upc82c710.cpp +++ b/src/devices/machine/upc82c710.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(UPC82C710, upc82c710_device, "upc82c710", "Universal Peripheral Controller 82C710") -upc82c710_device::upc82c710_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upc82c710_device::upc82c710_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPC82C710, tag, owner, clock) , m_ide(*this, "ide") , m_fdc(*this, "fdc") diff --git a/src/devices/machine/upc82c710.h b/src/devices/machine/upc82c710.h index 7868fec6b2f..966ec12b482 100644 --- a/src/devices/machine/upc82c710.h +++ b/src/devices/machine/upc82c710.h @@ -22,7 +22,7 @@ class upc82c710_device : public device_t { public: // construction/destruction - upc82c710_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upc82c710_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u16 io_r(offs_t offset, u16 mem_mask = ~0); void io_w(offs_t offset, u16 data, u16 mem_mask = ~0); diff --git a/src/devices/machine/upc82c711.cpp b/src/devices/machine/upc82c711.cpp index b162029daa0..33c0bd5391e 100644 --- a/src/devices/machine/upc82c711.cpp +++ b/src/devices/machine/upc82c711.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(UPC82C711, upc82c711_device, "upc82c711", "Universal Peripheral Controller 82C711") -upc82c711_device::upc82c711_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upc82c711_device::upc82c711_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPC82C711, tag, owner, clock) , m_ide(*this, "ide") , m_fdc(*this, "fdc") diff --git a/src/devices/machine/upc82c711.h b/src/devices/machine/upc82c711.h index 543bb594337..17565f1186d 100644 --- a/src/devices/machine/upc82c711.h +++ b/src/devices/machine/upc82c711.h @@ -24,7 +24,7 @@ class upc82c711_device : public device_t { public: // construction/destruction - upc82c711_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upc82c711_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u16 io_r(offs_t offset, u16 mem_mask = ~0); void io_w(offs_t offset, u16 data, u16 mem_mask = ~0); diff --git a/src/devices/machine/upd1990a.cpp b/src/devices/machine/upd1990a.cpp index 191d2b634cb..e56d4737de0 100644 --- a/src/devices/machine/upd1990a.cpp +++ b/src/devices/machine/upd1990a.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(UPD4990A, upd4990a_device, "upd4990a", "uPD4990A RTC") // upd1990a_device - constructor //------------------------------------------------- -upd1990a_device::upd1990a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +upd1990a_device::upd1990a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock) , device_rtc_interface(mconfig, *this) , m_write_data(*this) @@ -49,12 +49,12 @@ upd1990a_device::upd1990a_device(const machine_config &mconfig, device_type type { } -upd1990a_device::upd1990a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd1990a_device::upd1990a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd1990a_device(mconfig, UPD1990A, tag, owner, clock, TYPE_1990A) { } -upd4990a_device::upd4990a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd4990a_device::upd4990a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd1990a_device(mconfig, UPD4990A, tag, owner, clock, TYPE_4990A) { } diff --git a/src/devices/machine/upd1990a.h b/src/devices/machine/upd1990a.h index 8a170a15021..d68703c446d 100644 --- a/src/devices/machine/upd1990a.h +++ b/src/devices/machine/upd1990a.h @@ -34,7 +34,7 @@ class upd1990a_device : public device_t, public device_rtc_interface { public: // construction/destruction - upd1990a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 32'768); + upd1990a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32'768)); auto data_callback() { return m_write_data.bind(); } auto tp_callback() { return m_write_tp.bind(); } @@ -52,7 +52,7 @@ public: protected: // device-level overrides - upd1990a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + upd1990a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); virtual void device_start() override; @@ -127,7 +127,7 @@ private: class upd4990a_device : public upd1990a_device { public: - upd4990a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 32'768); + upd4990a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32'768)); }; diff --git a/src/devices/machine/upd4701.cpp b/src/devices/machine/upd4701.cpp index d840492073b..824ed0a39cc 100644 --- a/src/devices/machine/upd4701.cpp +++ b/src/devices/machine/upd4701.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(UPD4701A, upd4701_device, "upd4701a", "uPD4701A Incremental Encoder") -upd4701_device::upd4701_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd4701_device::upd4701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD4701A, tag, owner, clock) , m_cs(true) , m_xy(false) diff --git a/src/devices/machine/upd4701.h b/src/devices/machine/upd4701.h index 245ef7bf82c..41b7b9e7a42 100644 --- a/src/devices/machine/upd4701.h +++ b/src/devices/machine/upd4701.h @@ -30,7 +30,7 @@ class upd4701_device : public device_t { public: - upd4701_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + upd4701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration template <typename T> void set_portx_tag(T &&tag) { m_portx.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/machine/upd4991a.cpp b/src/devices/machine/upd4991a.cpp index 0f1419d7270..31e9b13b874 100644 --- a/src/devices/machine/upd4991a.cpp +++ b/src/devices/machine/upd4991a.cpp @@ -37,7 +37,7 @@ DEFINE_DEVICE_TYPE(UPD4991A, upd4991a_device, "upd4991a", "NEC uPD4991a parallel // upd4991a_device - constructor //------------------------------------------------- -upd4991a_device::upd4991a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd4991a_device::upd4991a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD4991A, tag, owner, clock) , device_rtc_interface(mconfig, *this) , m_timer_clock(nullptr) diff --git a/src/devices/machine/upd4991a.h b/src/devices/machine/upd4991a.h index 9a9da912279..a06abfde92b 100644 --- a/src/devices/machine/upd4991a.h +++ b/src/devices/machine/upd4991a.h @@ -24,7 +24,7 @@ class upd4991a_device : public device_t, public device_rtc_interface { public: // construction/destruction - upd4991a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd4991a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations void address_w(offs_t offset, u8 data); diff --git a/src/devices/machine/upd4992.cpp b/src/devices/machine/upd4992.cpp index 52e3f8d9f10..eef85e61b7b 100644 --- a/src/devices/machine/upd4992.cpp +++ b/src/devices/machine/upd4992.cpp @@ -33,7 +33,7 @@ DEFINE_DEVICE_TYPE(UPD4992, upd4992_device, "upd4992", "uPD4992 RTC") // upd4992_device - constructor //------------------------------------------------- -upd4992_device::upd4992_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd4992_device::upd4992_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD4992, tag, owner, clock) , device_rtc_interface(mconfig, *this) , m_timer_clock(nullptr) diff --git a/src/devices/machine/upd4992.h b/src/devices/machine/upd4992.h index 3151aa12eaa..841220bc072 100644 --- a/src/devices/machine/upd4992.h +++ b/src/devices/machine/upd4992.h @@ -24,7 +24,7 @@ class upd4992_device : public device_t, public device_rtc_interface { public: // construction/destruction - upd4992_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + upd4992_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations void write(offs_t offset, u8 data); diff --git a/src/devices/machine/upd7001.cpp b/src/devices/machine/upd7001.cpp index a6ae938b64c..7b4ab21337c 100644 --- a/src/devices/machine/upd7001.cpp +++ b/src/devices/machine/upd7001.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(UPD7001, upd7001_device, "upd7001", "NEC uPD7001 A/D Converte // upd7001_device - constructor //------------------------------------------------- -upd7001_device::upd7001_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +upd7001_device::upd7001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD7001, tag, owner, clock) , m_an_callback(*this) , m_eoc_callback(*this) diff --git a/src/devices/machine/upd7001.h b/src/devices/machine/upd7001.h index afc4b632293..db483851c42 100644 --- a/src/devices/machine/upd7001.h +++ b/src/devices/machine/upd7001.h @@ -33,9 +33,9 @@ class upd7001_device : public device_t { public: // device type constructors - upd7001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); upd7001_device(const machine_config &mconfig, const char *tag, device_t *owner, double r, double c) - : upd7001_device(mconfig, tag, owner, 0U) + : upd7001_device(mconfig, tag, owner) { set_rc(r, c); } diff --git a/src/devices/machine/upd7002.cpp b/src/devices/machine/upd7002.cpp index da1036d109d..f67a474248a 100644 --- a/src/devices/machine/upd7002.cpp +++ b/src/devices/machine/upd7002.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(UPD7002, upd7002_device, "upd7002", "uPD7002 ADC") -upd7002_device::upd7002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd7002_device::upd7002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD7002, tag, owner, clock) , m_status(0) , m_data1(0) diff --git a/src/devices/machine/upd7002.h b/src/devices/machine/upd7002.h index 7069a68361d..f4cdccd33d7 100644 --- a/src/devices/machine/upd7002.h +++ b/src/devices/machine/upd7002.h @@ -25,7 +25,7 @@ public: typedef device_delegate<int (int channel_number)> get_analogue_delegate; typedef device_delegate<void (int data)> eoc_delegate; - upd7002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename... T> void set_get_analogue_callback(T &&... args) { m_get_analogue_cb.set(std::forward<T>(args)...); } template <typename... T> void set_eoc_callback(T &&... args) { m_eoc_cb.set(std::forward<T>(args)...); } diff --git a/src/devices/machine/upd7004.cpp b/src/devices/machine/upd7004.cpp index a5fb2cba78f..40c80586728 100644 --- a/src/devices/machine/upd7004.cpp +++ b/src/devices/machine/upd7004.cpp @@ -37,7 +37,7 @@ ALLOW_SAVE_TYPE(upd7004_device::state); // upd7004_device - constructor //------------------------------------------------- -upd7004_device::upd7004_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +upd7004_device::upd7004_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD7004, tag, owner, clock), m_eoc_cb(*this), m_eoc_ff_cb(*this), m_in_cb(*this), diff --git a/src/devices/machine/upd7004.h b/src/devices/machine/upd7004.h index 78d7eae559c..da0979b5699 100644 --- a/src/devices/machine/upd7004.h +++ b/src/devices/machine/upd7004.h @@ -38,7 +38,7 @@ class upd7004_device : public device_t { public: // construction/destruction - upd7004_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7004_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto eoc_callback() { return m_eoc_cb.bind(); } auto eoc_ff_callback() { return m_eoc_ff_cb.bind(); } diff --git a/src/devices/machine/upd71071.cpp b/src/devices/machine/upd71071.cpp index 0a928be5361..cf381c3cbc5 100644 --- a/src/devices/machine/upd71071.cpp +++ b/src/devices/machine/upd71071.cpp @@ -93,7 +93,7 @@ DEFINE_DEVICE_TYPE(UPD71071, upd71071_device, "upd71071", "NEC uPD71071 DMA Controller") -upd71071_device::upd71071_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd71071_device::upd71071_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD71071, tag, owner, clock) , m_upd_clock(0) , m_out_hreq_cb(*this) diff --git a/src/devices/machine/upd71071.h b/src/devices/machine/upd71071.h index 0ccf146f931..b1b60129562 100644 --- a/src/devices/machine/upd71071.h +++ b/src/devices/machine/upd71071.h @@ -9,10 +9,10 @@ class upd71071_device : public device_t { public: - upd71071_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd71071_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_cpu_tag(const char *tag) { m_cpu.set_tag(tag); } - void set_clock(int clock) { m_upd_clock = clock; } + void set_clock(const XTAL &clock) { m_upd_clock = clock; } auto out_hreq_callback() { return m_out_hreq_cb.bind(); } auto out_eop_callback() { return m_out_eop_cb.bind(); } @@ -62,7 +62,7 @@ private: //int m_in_progress[4]; //int m_transfer_size[4]; int m_base; - int m_upd_clock; + XTAL m_upd_clock; devcb_write_line m_out_hreq_cb; devcb_write_line m_out_eop_cb; devcb_read16::array<4> m_dma_read_cb; diff --git a/src/devices/machine/upd765.cpp b/src/devices/machine/upd765.cpp index acf4182fecc..603c2ffa119 100644 --- a/src/devices/machine/upd765.cpp +++ b/src/devices/machine/upd765.cpp @@ -182,7 +182,7 @@ void tc8566af_device::map(address_map &map) constexpr int upd765_family_device::rates[4]; -upd765_family_device::upd765_family_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +upd765_family_device::upd765_family_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), ready_connected(true), ready_polled(true), @@ -538,9 +538,9 @@ void upd765_family_device::dsr_w(uint8_t data) cur_rate = rates[dsr & 3]; } -void upd765_family_device::set_rate(int rate) +void upd765_family_device::set_rate(const XTAL &rate) { - cur_rate = rate; + cur_rate = rate.value(); } uint8_t upd765_family_device::fifo_r() @@ -2769,32 +2769,32 @@ bool upd765_family_device::sector_matches() const cur_live.idbuf[3] == command[5]; } -upd765a_device::upd765a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : upd765_family_device(mconfig, UPD765A, tag, owner, clock) +upd765a_device::upd765a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, UPD765A, tag, owner, clock) { has_dor = false; } -upd765b_device::upd765b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : upd765_family_device(mconfig, UPD765B, tag, owner, clock) +upd765b_device::upd765b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, UPD765B, tag, owner, clock) { has_dor = false; } -i8272a_device::i8272a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : upd765_family_device(mconfig, I8272A, tag, owner, clock) +i8272a_device::i8272a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, I8272A, tag, owner, clock) { has_dor = false; } -upd72065_device::upd72065_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : upd72065_device(mconfig, UPD72065, tag, owner, clock) +upd72065_device::upd72065_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd72065_device(mconfig, UPD72065, tag, owner, clock) { } -upd72065_device::upd72065_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : upd765_family_device(mconfig, type, tag, owner, clock) +upd72065_device::upd72065_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, type, tag, owner, clock) { has_dor = false; recalibrate_steps = 255; } -upd72067_device::upd72067_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : upd72065_device(mconfig, UPD72067, tag, owner, clock) +upd72067_device::upd72067_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd72065_device(mconfig, UPD72067, tag, owner, clock) { ready_polled = true; ready_connected = true; @@ -2802,7 +2802,7 @@ upd72067_device::upd72067_device(const machine_config &mconfig, const char *tag, select_multiplexed = false; } -upd72069_device::upd72069_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : upd72065_device(mconfig, UPD72069, tag, owner, clock) +upd72069_device::upd72069_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd72065_device(mconfig, UPD72069, tag, owner, clock) { ready_polled = true; ready_connected = true; @@ -2810,7 +2810,7 @@ upd72069_device::upd72069_device(const machine_config &mconfig, const char *tag, select_multiplexed = false; } -i82072_device::i82072_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : upd765_family_device(mconfig, I82072, tag, owner, clock) +i82072_device::i82072_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, I82072, tag, owner, clock) { has_dor = false; recalibrate_steps = 255; @@ -3095,7 +3095,7 @@ void i82072_device::index_callback(floppy_image_device *floppy, int state) upd765_family_device::index_callback(floppy, state); } -ps2_fdc_device::ps2_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : upd765_family_device(mconfig, type, tag, owner, clock) +ps2_fdc_device::ps2_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, type, tag, owner, clock) { } @@ -3120,7 +3120,7 @@ void ps2_fdc_device::soft_reset() perpmode &= 0x3c; } -smc37c78_device::smc37c78_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : ps2_fdc_device(mconfig, SMC37C78, tag, owner, clock) +smc37c78_device::smc37c78_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ps2_fdc_device(mconfig, SMC37C78, tag, owner, clock) { ready_connected = false; select_connected = true; @@ -3128,14 +3128,14 @@ smc37c78_device::smc37c78_device(const machine_config &mconfig, const char *tag, recalibrate_steps = 80; } -n82077aa_device::n82077aa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : ps2_fdc_device(mconfig, N82077AA, tag, owner, clock) +n82077aa_device::n82077aa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ps2_fdc_device(mconfig, N82077AA, tag, owner, clock) { ready_connected = false; select_connected = true; select_multiplexed = false; } -pc_fdc_superio_device::pc_fdc_superio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : upd765_family_device(mconfig, PC_FDC_SUPERIO, tag, owner, clock) +pc_fdc_superio_device::pc_fdc_superio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, PC_FDC_SUPERIO, tag, owner, clock) { ready_polled = false; ready_connected = false; @@ -3143,7 +3143,7 @@ pc_fdc_superio_device::pc_fdc_superio_device(const machine_config &mconfig, cons select_multiplexed = false; } -dp8473_device::dp8473_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : upd765_family_device(mconfig, DP8473, tag, owner, clock) +dp8473_device::dp8473_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, DP8473, tag, owner, clock) { ready_polled = false; ready_connected = false; @@ -3160,7 +3160,7 @@ void dp8473_device::soft_reset() other_irq = true; } -pc8477a_device::pc8477a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : ps2_fdc_device(mconfig, PC8477A, tag, owner, clock) +pc8477a_device::pc8477a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ps2_fdc_device(mconfig, PC8477A, tag, owner, clock) { ready_polled = true; ready_connected = false; @@ -3169,7 +3169,7 @@ pc8477a_device::pc8477a_device(const machine_config &mconfig, const char *tag, d recalibrate_steps = 85; // TODO: may also be programmed as 255, 3925 or 4095 by (unemulated) mode command } -pc8477b_device::pc8477b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : ps2_fdc_device(mconfig, PC8477B, tag, owner, clock) +pc8477b_device::pc8477b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ps2_fdc_device(mconfig, PC8477B, tag, owner, clock) { ready_polled = true; ready_connected = false; @@ -3178,7 +3178,7 @@ pc8477b_device::pc8477b_device(const machine_config &mconfig, const char *tag, d recalibrate_steps = 85; // TODO: may also be programmed as 255, 3925 or 4095 by (unemulated) mode command } -wd37c65c_device::wd37c65c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wd37c65c_device::wd37c65c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, WD37C65C, tag, owner, clock), m_clock2(0) { @@ -3201,7 +3201,7 @@ uint8_t wd37c65c_device::get_st3(floppy_info &fi) return st3; } -mcs3201_device::mcs3201_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mcs3201_device::mcs3201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, MCS3201, tag, owner, clock), m_input_handler(*this) { @@ -3223,7 +3223,7 @@ uint8_t mcs3201_device::input_r() return m_input_handler(); } -tc8566af_device::tc8566af_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tc8566af_device::tc8566af_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd765_family_device(mconfig, TC8566AF, tag, owner, clock) , m_cr1(0) { diff --git a/src/devices/machine/upd765.h b/src/devices/machine/upd765.h index 0eba7da4b29..d0ff26ff544 100644 --- a/src/devices/machine/upd765.h +++ b/src/devices/machine/upd765.h @@ -51,7 +51,7 @@ public: DECLARE_WRITE_LINE_MEMBER(tc_line_w) { tc_w(state == ASSERT_LINE); } DECLARE_WRITE_LINE_MEMBER(reset_w); - void set_rate(int rate); // rate in bps, to be used when the fdc is externally frequency-controlled + void set_rate(const XTAL &rate); // rate in bps, to be used when the fdc is externally frequency-controlled void set_ready_line_connected(bool ready); void set_select_lines_connected(bool select); @@ -59,7 +59,7 @@ public: virtual void soft_reset(); protected: - upd765_family_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + upd765_family_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_resolve_objects() override; virtual void device_start() override; @@ -353,50 +353,50 @@ protected: class upd765a_device : public upd765_family_device { public: - upd765a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, bool ready, bool select) + upd765a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool ready, bool select) : upd765a_device(mconfig, tag, owner, clock) { set_ready_line_connected(ready); set_select_lines_connected(select); } - upd765a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd765a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; }; class upd765b_device : public upd765_family_device { public: - upd765b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, bool ready, bool select) + upd765b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool ready, bool select) : upd765b_device(mconfig, tag, owner, clock) { set_ready_line_connected(ready); set_select_lines_connected(select); } - upd765b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd765b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; }; class i8272a_device : public upd765_family_device { public: - i8272a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, bool ready) + i8272a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool ready) : i8272a_device(mconfig, tag, owner, clock) { set_ready_line_connected(ready); } - i8272a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8272a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; }; class i82072_device : public upd765_family_device { public: - i82072_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, bool ready) + i82072_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool ready) : i82072_device(mconfig, tag, owner, clock) { set_ready_line_connected(ready); } - i82072_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82072_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; @@ -437,7 +437,7 @@ public: uint8_t srb_r(); protected: - ps2_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ps2_fdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -450,63 +450,63 @@ protected: class smc37c78_device : public ps2_fdc_device { public: - smc37c78_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + smc37c78_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; }; class upd72065_device : public upd765_family_device { public: - upd72065_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, bool ready, bool select) + upd72065_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, bool ready, bool select) : upd72065_device(mconfig, tag, owner, clock) { set_ready_line_connected(ready); set_select_lines_connected(select); } - upd72065_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd72065_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; virtual void auxcmd_w(uint8_t data); protected: - upd72065_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + upd72065_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; class upd72067_device : public upd72065_device { public: - upd72067_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd72067_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void auxcmd_w(uint8_t data) override; }; class upd72069_device : public upd72065_device { public: - upd72069_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd72069_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class n82077aa_device : public ps2_fdc_device { public: - n82077aa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, mode_t mode) + n82077aa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, mode_t mode) : n82077aa_device(mconfig, tag, owner, clock) { set_mode(mode); } - n82077aa_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + n82077aa_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; }; class pc_fdc_superio_device : public upd765_family_device { public: - pc_fdc_superio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc_fdc_superio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; }; class dp8473_device : public upd765_family_device { public: - dp8473_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dp8473_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; @@ -516,12 +516,12 @@ protected: class pc8477a_device : public ps2_fdc_device { public: - pc8477a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, mode_t mode) + pc8477a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, mode_t mode) : pc8477a_device(mconfig, tag, owner, clock) { set_mode(mode); } - pc8477a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pc8477a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; }; @@ -540,10 +540,10 @@ public: class wd37c65c_device : public upd765_family_device { public: - wd37c65c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd37c65c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename X> - wd37c65c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, X &&clock2) + wd37c65c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, X &&clock2) : wd37c65c_device(mconfig, tag, owner, clock) { set_clock2(std::forward<X>(clock2)); @@ -561,7 +561,7 @@ private: class mcs3201_device : public upd765_family_device { public: - mcs3201_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mcs3201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto input_handler() { return m_input_handler.bind(); } @@ -578,7 +578,7 @@ private: class tc8566af_device : public upd765_family_device { public: - tc8566af_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tc8566af_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; diff --git a/src/devices/machine/v3021.cpp b/src/devices/machine/v3021.cpp index 6d84109e2ec..ae82249ef6a 100644 --- a/src/devices/machine/v3021.cpp +++ b/src/devices/machine/v3021.cpp @@ -114,7 +114,7 @@ DEFINE_DEVICE_TYPE(V3021, v3021_device, "v3021", "EM Microelectronic-Marin SA V3 // v3021_device - constructor //------------------------------------------------- -v3021_device::v3021_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v3021_device::v3021_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, V3021, tag, owner, clock) , device_rtc_interface(mconfig, *this) { diff --git a/src/devices/machine/v3021.h b/src/devices/machine/v3021.h index cac5c6884d4..58fc96e74f1 100644 --- a/src/devices/machine/v3021.h +++ b/src/devices/machine/v3021.h @@ -27,7 +27,7 @@ class v3021_device : public device_t, public device_rtc_interface { public: // construction/destruction - v3021_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 32'768); + v3021_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(32'768)); // parallel interface void write(u8 data); diff --git a/src/devices/machine/vic_pl192.cpp b/src/devices/machine/vic_pl192.cpp index 2e7a2f4ad85..3fcbc005fda 100644 --- a/src/devices/machine/vic_pl192.cpp +++ b/src/devices/machine/vic_pl192.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(PL190_VIC, vic_pl190_device, "vic_pl190", "ARM PL190 VIC") DEFINE_DEVICE_TYPE(UPD800468_VIC, vic_upd800468_device, "vic_upd800468", "NEC uPD800468 VIC") DEFINE_DEVICE_TYPE(PL192_VIC, vic_pl192_device, "vic_pl192", "ARM PL192 VIC") -vic_pl190_device::vic_pl190_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vic_pl190_device::vic_pl190_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , num_vectors(16) @@ -26,18 +26,18 @@ vic_pl190_device::vic_pl190_device(const machine_config &mconfig, device_type ty { } -vic_pl190_device::vic_pl190_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic_pl190_device::vic_pl190_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vic_pl190_device(mconfig, PL190_VIC, tag, owner, clock) { } -vic_upd800468_device::vic_upd800468_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic_upd800468_device::vic_upd800468_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vic_pl190_device(mconfig, UPD800468_VIC, tag, owner, clock) { num_vectors = 32; } -vic_pl192_device::vic_pl192_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic_pl192_device::vic_pl192_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vic_pl190_device(mconfig, PL192_VIC, tag, owner, clock) { num_vectors = 32; diff --git a/src/devices/machine/vic_pl192.h b/src/devices/machine/vic_pl192.h index 6ef01a3a935..0ede696b9f1 100644 --- a/src/devices/machine/vic_pl192.h +++ b/src/devices/machine/vic_pl192.h @@ -9,7 +9,7 @@ class vic_pl190_device : public device_t, public device_memory_interface { public: - vic_pl190_device(const machine_config &mconfig, const char* tag, device_t *owner, uint32_t clock = 0); + vic_pl190_device(const machine_config &mconfig, const char* tag, device_t *owner, const XTAL &clock = XTAL()); auto out_irq_cb() { return m_out_irq_func.bind(); } auto out_fiq_cb() { return m_out_fiq_func.bind(); } @@ -50,7 +50,7 @@ public: void vect_ctl_w(offs_t offset, u32 data); protected: - vic_pl190_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vic_pl190_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -87,7 +87,7 @@ private: class vic_upd800468_device : public vic_pl190_device { public: - vic_upd800468_device(const machine_config &mconfig, const char* tag, device_t *owner, uint32_t clock = 0); + vic_upd800468_device(const machine_config &mconfig, const char* tag, device_t *owner, const XTAL &clock = XTAL()); void map(address_map &map); @@ -97,7 +97,7 @@ public: class vic_pl192_device : public vic_pl190_device { public: - vic_pl192_device(const machine_config &mconfig, const char* tag, device_t *owner, uint32_t clock = 0); + vic_pl192_device(const machine_config &mconfig, const char* tag, device_t *owner, const XTAL &clock = XTAL()); void map(address_map &map); diff --git a/src/devices/machine/vr0uart.cpp b/src/devices/machine/vr0uart.cpp index 1bfbf0ebf3d..dded790b186 100644 --- a/src/devices/machine/vr0uart.cpp +++ b/src/devices/machine/vr0uart.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(VRENDER0_UART, vr0uart_device, "vr0uart", "MagicEyes VRender0 // vr0uart_device - constructor //------------------------------------------------- -vr0uart_device::vr0uart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vr0uart_device::vr0uart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VRENDER0_UART, tag, owner, clock), device_serial_interface(mconfig, *this) { @@ -102,8 +102,8 @@ void vr0uart_device::update_serial_config() } else { - set_rcv_rate(0); - set_tra_rate(0); + set_rcv_rate(XTAL::u(0)); + set_tra_rate(XTAL::u(0)); } } diff --git a/src/devices/machine/vrc4373.cpp b/src/devices/machine/vrc4373.cpp index 1100df8b375..815813183db 100644 --- a/src/devices/machine/vrc4373.cpp +++ b/src/devices/machine/vrc4373.cpp @@ -94,7 +94,7 @@ void vrc4373_device::target2_map(address_map &map) map(0x00000000, 0xFFFFFFFF).rw(FUNC(vrc4373_device::target2_r), FUNC(vrc4373_device::target2_w)); } -vrc4373_device::vrc4373_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vrc4373_device::vrc4373_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_host_device(mconfig, VRC4373, tag, owner, clock) , m_cpu_space(nullptr), m_irq_cb(*this), m_cpu(*this, finder_base::DUMMY_TAG), m_ram_size(0x0), m_simm0_size(0x0) , m_mem_config("memory_space", ENDIANNESS_LITTLE, 32, 32) diff --git a/src/devices/machine/vrc4373.h b/src/devices/machine/vrc4373.h index 7717a979e23..600825f0618 100644 --- a/src/devices/machine/vrc4373.h +++ b/src/devices/machine/vrc4373.h @@ -13,13 +13,13 @@ class vrc4373_device : public pci_host_device { public: template <typename T> - vrc4373_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag) - : vrc4373_device(mconfig, tag, owner, clock) + vrc4373_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag) + : vrc4373_device(mconfig, tag, owner) { set_cpu_tag(std::forward<T>(cpu_tag)); } - vrc4373_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vrc4373_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual void reset_all_mappings() override; virtual void map_extra(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space, diff --git a/src/devices/machine/vrc5074.cpp b/src/devices/machine/vrc5074.cpp index e812cf20d25..3c21b5e3351 100644 --- a/src/devices/machine/vrc5074.cpp +++ b/src/devices/machine/vrc5074.cpp @@ -157,7 +157,7 @@ void vrc5074_device::device_add_mconfig(machine_config &config) ttys00.cts_handler().set(m_uart, FUNC(ns16550_device::cts_w)); } -vrc5074_device::vrc5074_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vrc5074_device::vrc5074_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_host_device(mconfig, VRC5074, tag, owner, clock), m_uart(*this, "uart"), m_cpu_space(nullptr), m_cpu(*this, finder_base::DUMMY_TAG), diff --git a/src/devices/machine/vrc5074.h b/src/devices/machine/vrc5074.h index 749068b1ff8..f54676724d4 100644 --- a/src/devices/machine/vrc5074.h +++ b/src/devices/machine/vrc5074.h @@ -15,13 +15,13 @@ class vrc5074_device : public pci_host_device { public: template <typename T> - vrc5074_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag) + vrc5074_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag) : vrc5074_device(mconfig, tag, owner, clock) { set_cpu_tag(std::forward<T>(cpu_tag)); } - vrc5074_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vrc5074_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); required_device<ns16550_device> m_uart; virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/machine/vrender0.cpp b/src/devices/machine/vrender0.cpp index f59edbe4a2e..d492e44d8fc 100644 --- a/src/devices/machine/vrender0.cpp +++ b/src/devices/machine/vrender0.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(VRENDER0_SOC, vrender0soc_device, "vrender0", "MagicEyes VRen // vrender0soc_device - constructor //------------------------------------------------- -vrender0soc_device::vrender0soc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vrender0soc_device::vrender0soc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VRENDER0_SOC, tag, owner, clock), m_host_cpu(*this, finder_base::DUMMY_TAG), m_screen(*this, "screen"), @@ -121,7 +121,7 @@ void vrender0soc_device::frame_map(address_map &map) void vrender0soc_device::device_add_mconfig(machine_config &config) { for (required_device<vr0uart_device> &uart : m_uart) - VRENDER0_UART(config, uart, 3579500); + VRENDER0_UART(config, uart, XTAL::u(3579500)); SCREEN(config, m_screen, SCREEN_TYPE_RASTER); // evolution soccer defaults @@ -130,7 +130,7 @@ void vrender0soc_device::device_add_mconfig(machine_config &config) m_screen->screen_vblank().set(FUNC(vrender0soc_device::screen_vblank)); m_screen->set_palette(m_palette); - VIDEO_VRENDER0(config, m_vr0vid, 14318180); + VIDEO_VRENDER0(config, m_vr0vid, XTAL::u(14318180)); #ifdef IDLE_LOOP_SPEEDUP m_vr0vid->idleskip_cb().set(FUNC(vrender0soc_device::idle_skip_speedup_w)); #endif diff --git a/src/devices/machine/vrender0.h b/src/devices/machine/vrender0.h index 8a3b19d59fb..7cb19ee39c8 100644 --- a/src/devices/machine/vrender0.h +++ b/src/devices/machine/vrender0.h @@ -40,7 +40,7 @@ class vr0uart_device : public device_t, { public: // construction/destruction - vr0uart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vr0uart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void regs_map(address_map &map); void set_channel_num(int ch) { m_channel_num = ch; } @@ -87,7 +87,7 @@ class vrender0soc_device : public device_t { public: // construction/destruction - vrender0soc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vrender0soc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void regs_map(address_map &map); void audiovideo_map(address_map &map); diff --git a/src/devices/machine/vt82c496.cpp b/src/devices/machine/vt82c496.cpp index cf1632edd49..5bcbcd8dafa 100644 --- a/src/devices/machine/vt82c496.cpp +++ b/src/devices/machine/vt82c496.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(VT82C496, vt82c496_device, "vt82c496", "VIA VT82C496 system chipset") -vt82c496_device::vt82c496_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vt82c496_device::vt82c496_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VT82C496, tag, owner, clock), m_cpu(*this, finder_base::DUMMY_TAG), m_space(nullptr), m_ram(*this, finder_base::DUMMY_TAG), m_rom(*this, finder_base::DUMMY_TAG), m_bios_c0_r(*this, "bios_c0_r"), m_bios_c4_r(*this, "bios_c4_r"), diff --git a/src/devices/machine/vt82c496.h b/src/devices/machine/vt82c496.h index c73a0ace79a..9249689fe18 100644 --- a/src/devices/machine/vt82c496.h +++ b/src/devices/machine/vt82c496.h @@ -18,7 +18,7 @@ class vt82c496_device : public device_t { public: // construction/destruction - vt82c496_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + vt82c496_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> void set_cputag(T &&tag) { m_cpu.set_tag(std::forward<T>(tag)); } template <typename T> void set_ramtag(T &&tag) { m_ram.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/machine/vt83c461.cpp b/src/devices/machine/vt83c461.cpp index 005e41d2848..e15611eb733 100644 --- a/src/devices/machine/vt83c461.cpp +++ b/src/devices/machine/vt83c461.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(VT83C461, vt83c461_device, "vt83c461", "VIA VT83C461 IDE Controller") -vt83c461_device::vt83c461_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +vt83c461_device::vt83c461_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ide_controller_32_device(mconfig, VT83C461, tag, owner, clock), m_config_unknown(0), m_config_register_num(0) diff --git a/src/devices/machine/vt83c461.h b/src/devices/machine/vt83c461.h index 97e4941dd56..54cea16041d 100644 --- a/src/devices/machine/vt83c461.h +++ b/src/devices/machine/vt83c461.h @@ -18,7 +18,7 @@ class vt83c461_device : public ide_controller_32_device { public: - vt83c461_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + vt83c461_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> vt83c461_device &master(T &&opts, const char *dflt = nullptr, bool fixed = false) { diff --git a/src/devices/machine/watchdog.cpp b/src/devices/machine/watchdog.cpp index 3d7e17178d4..62cfcf79b1d 100644 --- a/src/devices/machine/watchdog.cpp +++ b/src/devices/machine/watchdog.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(WATCHDOG_TIMER, watchdog_timer_device, "watchdog", "Watchdog // watchdog_timer_device - constructor //------------------------------------------------- -watchdog_timer_device::watchdog_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +watchdog_timer_device::watchdog_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WATCHDOG_TIMER, tag, owner, clock) , m_vblank_count(0) , m_time(attotime::zero) diff --git a/src/devices/machine/watchdog.h b/src/devices/machine/watchdog.h index aaeed0fa494..f9511bc0d36 100644 --- a/src/devices/machine/watchdog.h +++ b/src/devices/machine/watchdog.h @@ -18,7 +18,7 @@ class watchdog_timer_device : public device_t { public: // construction/destruction - watchdog_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + watchdog_timer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration helpers template <typename T> void set_vblank_count(T &&screen_tag, int32_t count) { m_screen.set_tag(std::forward<T>(screen_tag)); m_vblank_count = count; } diff --git a/src/devices/machine/wd1000.cpp b/src/devices/machine/wd1000.cpp index ba4c6a5c1a9..64a6b2996db 100644 --- a/src/devices/machine/wd1000.cpp +++ b/src/devices/machine/wd1000.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(WD1000, wd1000_device, "wd1000", "Western Digital WD1000 Winc // wd1000_device - constructor //------------------------------------------------- -wd1000_device::wd1000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +wd1000_device::wd1000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WD1000, tag, owner, clock) , m_intrq_cb(*this) , m_drq_cb(*this) diff --git a/src/devices/machine/wd1000.h b/src/devices/machine/wd1000.h index 4e2882ee81c..0b69a5ce19d 100644 --- a/src/devices/machine/wd1000.h +++ b/src/devices/machine/wd1000.h @@ -24,7 +24,7 @@ class wd1000_device : public device_t { public: // construction/destruction - wd1000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd1000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto intrq_wr_callback() { return m_intrq_cb.bind(); } auto drq_wr_callback() { return m_drq_cb.bind(); } diff --git a/src/devices/machine/wd1010.cpp b/src/devices/machine/wd1010.cpp index cef0b5d9dd2..f6f948840cc 100644 --- a/src/devices/machine/wd1010.cpp +++ b/src/devices/machine/wd1010.cpp @@ -43,7 +43,7 @@ DEFINE_DEVICE_TYPE(WD1010, wd1010_device, "wd1010", "Western Digital WD1010-05") // wd1010_device - constructor //------------------------------------------------- -wd1010_device::wd1010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wd1010_device::wd1010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WD1010, tag, owner, clock), m_out_intrq_cb(*this), m_out_bdrq_cb(*this), diff --git a/src/devices/machine/wd1010.h b/src/devices/machine/wd1010.h index 70d8a687163..59d73a9c7d0 100644 --- a/src/devices/machine/wd1010.h +++ b/src/devices/machine/wd1010.h @@ -24,7 +24,7 @@ class wd1010_device : public device_t { public: // construction/destruction - wd1010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd1010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_intrq_callback() { return m_out_intrq_cb.bind(); } auto out_bdrq_callback() { return m_out_bdrq_cb.bind(); } diff --git a/src/devices/machine/wd11c00_17.cpp b/src/devices/machine/wd11c00_17.cpp index 981672a70d9..43d034844a3 100644 --- a/src/devices/machine/wd11c00_17.cpp +++ b/src/devices/machine/wd11c00_17.cpp @@ -175,7 +175,7 @@ inline void wd11c00_17_device::select() // wd11c00_17_device - constructor //------------------------------------------------- -wd11c00_17_device::wd11c00_17_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +wd11c00_17_device::wd11c00_17_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WD11C00_17, tag, owner, clock) , m_out_irq5_cb(*this) , m_out_drq3_cb(*this) diff --git a/src/devices/machine/wd11c00_17.h b/src/devices/machine/wd11c00_17.h index 91175d2472d..64e081f5736 100644 --- a/src/devices/machine/wd11c00_17.h +++ b/src/devices/machine/wd11c00_17.h @@ -22,7 +22,7 @@ class wd11c00_17_device : public device_t { public: // construction/destruction - wd11c00_17_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd11c00_17_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_irq5_callback() { return m_out_irq5_cb.bind(); } auto out_drq3_callback() { return m_out_drq3_cb.bind(); } diff --git a/src/devices/machine/wd2010.cpp b/src/devices/machine/wd2010.cpp index 840d0f6f4d8..ab3f7c7f4f8 100644 --- a/src/devices/machine/wd2010.cpp +++ b/src/devices/machine/wd2010.cpp @@ -153,7 +153,7 @@ DEFINE_DEVICE_TYPE(WD2010, wd2010_device, "wd2010", "Western Digital WD2010 Winc // wd2010_device - constructor //------------------------------------------------- -wd2010_device::wd2010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +wd2010_device::wd2010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WD2010, tag, owner, clock) , m_out_intrq_cb(*this) , m_out_bdrq_cb(*this) diff --git a/src/devices/machine/wd2010.h b/src/devices/machine/wd2010.h index a39935326ba..034a6466616 100644 --- a/src/devices/machine/wd2010.h +++ b/src/devices/machine/wd2010.h @@ -22,7 +22,7 @@ class wd2010_device : public device_t { public: // construction/destruction - wd2010_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd2010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_intrq_callback() { return m_out_intrq_cb.bind(); } auto out_bdrq_callback() { return m_out_bdrq_cb.bind(); } diff --git a/src/devices/machine/wd33c9x.cpp b/src/devices/machine/wd33c9x.cpp index cb59256cea1..a2b8ab668d7 100644 --- a/src/devices/machine/wd33c9x.cpp +++ b/src/devices/machine/wd33c9x.cpp @@ -357,7 +357,7 @@ DEFINE_DEVICE_TYPE(WD33C93B, wd33c93b_device, "wd33c93b", "Western Digital WD33C // wd33c9x_base_device - constructor/destructor //------------------------------------------------- -wd33c9x_base_device::wd33c9x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +wd33c9x_base_device::wd33c9x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : nscsi_device{ mconfig, type, tag, owner, clock } , nscsi_slot_card_interface(mconfig, *this, DEVICE_SELF) , m_addr{ 0 } @@ -1723,22 +1723,22 @@ uint8_t wd33c9x_base_device::get_msg_out() const -wd33c92_device::wd33c92_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +wd33c92_device::wd33c92_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd33c9x_base_device(mconfig, WD33C92, tag, owner, clock) { } -wd33c93_device::wd33c93_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +wd33c93_device::wd33c93_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd33c9x_base_device(mconfig, WD33C93, tag, owner, clock) { } -wd33c93a_device::wd33c93a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +wd33c93a_device::wd33c93a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd33c9x_base_device(mconfig, WD33C93A, tag, owner, clock) { } -wd33c93b_device::wd33c93b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +wd33c93b_device::wd33c93b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd33c9x_base_device(mconfig, WD33C93B, tag, owner, clock) { } diff --git a/src/devices/machine/wd33c9x.h b/src/devices/machine/wd33c9x.h index 8fb9e8ea78a..6c539934ff5 100644 --- a/src/devices/machine/wd33c9x.h +++ b/src/devices/machine/wd33c9x.h @@ -39,7 +39,7 @@ public: void dma_w(const uint8_t data); protected: - wd33c9x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + wd33c9x_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -112,45 +112,25 @@ private: class wd33c92_device : public wd33c9x_base_device { public: - wd33c92_device(const machine_config &mconfig, const char *tag, device_t *owner) - : wd33c92_device(mconfig, tag, owner, 0) - { - } - - wd33c92_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd33c92_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class wd33c93_device : public wd33c9x_base_device { public: - wd33c93_device(const machine_config &mconfig, const char *tag, device_t *owner) - : wd33c93_device(mconfig, tag, owner, 0) - { - } - - wd33c93_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd33c93_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class wd33c93a_device : public wd33c9x_base_device { public: - wd33c93a_device(const machine_config &mconfig, const char *tag, device_t *owner) - : wd33c93a_device(mconfig, tag, owner, 0) - { - } - - wd33c93a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd33c93a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class wd33c93b_device : public wd33c9x_base_device { public: - wd33c93b_device(const machine_config &mconfig, const char *tag, device_t *owner) - : wd33c93b_device(mconfig, tag, owner, 0) - { - } - - wd33c93b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd33c93b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; diff --git a/src/devices/machine/wd7600.cpp b/src/devices/machine/wd7600.cpp index e1f81e0282b..d65943fae02 100644 --- a/src/devices/machine/wd7600.cpp +++ b/src/devices/machine/wd7600.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(WD7600, wd7600_device, "wd7600", "Western Digital WD7600 chip void wd7600_device::device_add_mconfig(machine_config & config) { - AM9517A(config, m_dma1, 0); + AM9517A(config, m_dma1); m_dma1->out_hreq_callback().set(m_dma2, FUNC(am9517a_device::dreq0_w)); m_dma1->out_eop_callback().set(FUNC(wd7600_device::dma1_eop_w)); m_dma1->in_memr_callback().set(FUNC(wd7600_device::dma_read_byte)); @@ -41,7 +41,7 @@ void wd7600_device::device_add_mconfig(machine_config & config) m_dma1->out_dack_callback<2>().set(FUNC(wd7600_device::dma1_dack2_w)); m_dma1->out_dack_callback<3>().set(FUNC(wd7600_device::dma1_dack3_w)); - AM9517A(config, m_dma2, 0); + AM9517A(config, m_dma2); m_dma2->out_hreq_callback().set(FUNC(wd7600_device::dma2_hreq_w)); m_dma2->in_memr_callback().set(FUNC(wd7600_device::dma_read_word)); m_dma2->out_memw_callback().set(FUNC(wd7600_device::dma_write_word)); @@ -56,16 +56,16 @@ void wd7600_device::device_add_mconfig(machine_config & config) m_dma2->out_dack_callback<2>().set(FUNC(wd7600_device::dma2_dack2_w)); m_dma2->out_dack_callback<3>().set(FUNC(wd7600_device::dma2_dack3_w)); - PIC8259(config, m_pic1, 0); + PIC8259(config, m_pic1); m_pic1->out_int_callback().set(FUNC(wd7600_device::pic1_int_w)); m_pic1->in_sp_callback().set_constant(1); m_pic1->read_slave_ack_callback().set(FUNC(wd7600_device::pic1_slave_ack_r)); - PIC8259(config, m_pic2, 0); + PIC8259(config, m_pic2); m_pic2->out_int_callback().set(m_pic1, FUNC(pic8259_device::ir2_w)); m_pic2->in_sp_callback().set_constant(0); - PIT8254(config, m_ctc, 0); + PIT8254(config, m_ctc); m_ctc->set_clk<0>(XTAL(14'318'181) / 12.0); m_ctc->out_handler<0>().set(m_pic1, FUNC(pic8259_device::ir0_w)); m_ctc->set_clk<1>(XTAL(14'318'181) / 12.0); @@ -79,7 +79,7 @@ void wd7600_device::device_add_mconfig(machine_config & config) } -wd7600_device::wd7600_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +wd7600_device::wd7600_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WD7600, tag, owner, clock), m_read_ior(*this), m_write_iow(*this), diff --git a/src/devices/machine/wd7600.h b/src/devices/machine/wd7600.h index 43ddb00b038..e9e137190c7 100644 --- a/src/devices/machine/wd7600.h +++ b/src/devices/machine/wd7600.h @@ -29,7 +29,7 @@ class wd7600_device : public device_t { public: // construction/destruction - wd7600_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd7600_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto ior_callback() { return m_read_ior.bind(); } diff --git a/src/devices/machine/wd_fdc.cpp b/src/devices/machine/wd_fdc.cpp index 253f9e5a19d..afab2249f2b 100644 --- a/src/devices/machine/wd_fdc.cpp +++ b/src/devices/machine/wd_fdc.cpp @@ -134,7 +134,7 @@ static const char *const states[] = "WRITE_SECTOR_PRE_BYTE" }; -wd_fdc_device_base::wd_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +wd_fdc_device_base::wd_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), intrq_cb(*this), drq_cb(*this), @@ -2443,7 +2443,7 @@ int wd_fdc_device_base::settle_time() const return 60000; } -wd_fdc_analog_device_base::wd_fdc_analog_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +wd_fdc_analog_device_base::wd_fdc_analog_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_device_base(mconfig, type, tag, owner, clock) { clock_ratio = 1; @@ -2495,7 +2495,7 @@ bool wd_fdc_analog_device_base::pll_write_next_bit(bool bit, attotime &tm, flopp return cur_pll.write_next_bit(bit, tm, floppy, limit); } -wd_fdc_digital_device_base::wd_fdc_digital_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +wd_fdc_digital_device_base::wd_fdc_digital_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_device_base(mconfig, type, tag, owner, clock) { clock_ratio = 4; @@ -2704,7 +2704,7 @@ void wd_fdc_digital_device_base::digital_pll_t::commit(floppy_image_device *flop write_position = 0; } -fd1771_device::fd1771_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1771, tag, owner, clock) +fd1771_device::fd1771_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1771, tag, owner, clock) { constexpr static int fd1771_step_times[4] = { 12000, 12000, 20000, 40000 }; @@ -2731,7 +2731,7 @@ int fd1771_device::calc_sector_size(uint8_t size, uint8_t command) const return size ? size << 4 : 4096; } -fd1781_device::fd1781_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1781, tag, owner, clock) +fd1781_device::fd1781_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1781, tag, owner, clock) { constexpr static int fd1781_step_times[4] = { 6000, 12000, 20000, 40000 }; @@ -2759,7 +2759,7 @@ int fd1781_device::calc_sector_size(uint8_t size, uint8_t command) const constexpr int wd_fdc_device_base::fd179x_step_times[4]; constexpr int wd_fdc_device_base::fd176x_step_times[4]; -fd1791_device::fd1791_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1791, tag, owner, clock) +fd1791_device::fd1791_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1791, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 4; @@ -2775,7 +2775,7 @@ fd1791_device::fd1791_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -fd1792_device::fd1792_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1792, tag, owner, clock) +fd1792_device::fd1792_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1792, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 4; @@ -2791,7 +2791,7 @@ fd1792_device::fd1792_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -fd1793_device::fd1793_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1793, tag, owner, clock) +fd1793_device::fd1793_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1793, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 4; @@ -2807,7 +2807,7 @@ fd1793_device::fd1793_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -kr1818vg93_device::kr1818vg93_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, KR1818VG93, tag, owner, clock) +kr1818vg93_device::kr1818vg93_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, KR1818VG93, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 4; @@ -2823,7 +2823,7 @@ kr1818vg93_device::kr1818vg93_device(const machine_config &mconfig, const char * ready_hooked = true; } -fd1794_device::fd1794_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1794, tag, owner, clock) +fd1794_device::fd1794_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1794, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 4; @@ -2839,7 +2839,7 @@ fd1794_device::fd1794_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -fd1795_device::fd1795_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1795, tag, owner, clock) +fd1795_device::fd1795_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1795, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 4; @@ -2863,7 +2863,7 @@ int fd1795_device::calc_sector_size(uint8_t size, uint8_t command) const return 128 << ((size + 1) & 3); } -fd1797_device::fd1797_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1797, tag, owner, clock) +fd1797_device::fd1797_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1797, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 4; @@ -2887,7 +2887,7 @@ int fd1797_device::calc_sector_size(uint8_t size, uint8_t command) const return 128 << ((size + 1) & 3); } -mb8866_device::mb8866_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, MB8866, tag, owner, clock) +mb8866_device::mb8866_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, MB8866, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 4; @@ -2903,7 +2903,7 @@ mb8866_device::mb8866_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -mb8876_device::mb8876_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, MB8876, tag, owner, clock) +mb8876_device::mb8876_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, MB8876, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 4; @@ -2919,7 +2919,7 @@ mb8876_device::mb8876_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -mb8877_device::mb8877_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, MB8877, tag, owner, clock) +mb8877_device::mb8877_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, MB8877, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 4; @@ -2935,7 +2935,7 @@ mb8877_device::mb8877_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -fd1761_device::fd1761_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1761, tag, owner, clock) +fd1761_device::fd1761_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1761, tag, owner, clock) { step_times = fd176x_step_times; delay_register_commit = 16; @@ -2951,7 +2951,7 @@ fd1761_device::fd1761_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -fd1763_device::fd1763_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1763, tag, owner, clock) +fd1763_device::fd1763_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1763, tag, owner, clock) { step_times = fd176x_step_times; delay_register_commit = 16; @@ -2967,7 +2967,7 @@ fd1763_device::fd1763_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -fd1765_device::fd1765_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1765, tag, owner, clock) +fd1765_device::fd1765_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1765, tag, owner, clock) { step_times = fd176x_step_times; delay_register_commit = 16; @@ -2991,7 +2991,7 @@ int fd1765_device::calc_sector_size(uint8_t size, uint8_t command) const return 128 << ((size + 1) & 3); } -fd1767_device::fd1767_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, FD1767, tag, owner, clock) +fd1767_device::fd1767_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, FD1767, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 16; @@ -3015,7 +3015,7 @@ int fd1767_device::calc_sector_size(uint8_t size, uint8_t command) const return 128 << ((size + 1) & 3); } -wd2791_device::wd2791_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, WD2791, tag, owner, clock) +wd2791_device::wd2791_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, WD2791, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 16; @@ -3031,7 +3031,7 @@ wd2791_device::wd2791_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -wd2793_device::wd2793_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, WD2793, tag, owner, clock) +wd2793_device::wd2793_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, WD2793, tag, owner, clock) { step_times = fd179x_step_times; @@ -3048,7 +3048,7 @@ wd2793_device::wd2793_device(const machine_config &mconfig, const char *tag, dev ready_hooked = true; } -wd2795_device::wd2795_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, WD2795, tag, owner, clock) +wd2795_device::wd2795_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, WD2795, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 16; @@ -3072,7 +3072,7 @@ int wd2795_device::calc_sector_size(uint8_t size, uint8_t command) const return 128 << ((size + 1) & 3); } -wd2797_device::wd2797_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_analog_device_base(mconfig, WD2797, tag, owner, clock) +wd2797_device::wd2797_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_analog_device_base(mconfig, WD2797, tag, owner, clock) { step_times = fd179x_step_times; delay_register_commit = 16; @@ -3096,7 +3096,7 @@ int wd2797_device::calc_sector_size(uint8_t size, uint8_t command) const return 128 << ((size + 1) & 3); } -wd1770_device::wd1770_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_digital_device_base(mconfig, WD1770, tag, owner, clock) +wd1770_device::wd1770_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_digital_device_base(mconfig, WD1770, tag, owner, clock) { step_times = wd_digital_step_times; delay_register_commit = 16; @@ -3112,7 +3112,7 @@ wd1770_device::wd1770_device(const machine_config &mconfig, const char *tag, dev ready_hooked = false; } -wd1772_device::wd1772_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_digital_device_base(mconfig, WD1772, tag, owner, clock) +wd1772_device::wd1772_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_digital_device_base(mconfig, WD1772, tag, owner, clock) { const static int wd1772_step_times[4] = { 12000, 24000, 4000, 6000 }; @@ -3140,7 +3140,7 @@ int wd1772_device::settle_time() const return 30000; } -wd1773_device::wd1773_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : wd_fdc_digital_device_base(mconfig, WD1773, tag, owner, clock) +wd1773_device::wd1773_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wd_fdc_digital_device_base(mconfig, WD1773, tag, owner, clock) { step_times = wd_digital_step_times; delay_register_commit = 16; diff --git a/src/devices/machine/wd_fdc.h b/src/devices/machine/wd_fdc.h index e870542fcbc..1ba959ec796 100644 --- a/src/devices/machine/wd_fdc.h +++ b/src/devices/machine/wd_fdc.h @@ -93,7 +93,7 @@ public: void index_callback(floppy_image_device *floppy, int state); protected: - wd_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + wd_fdc_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // Chip-specific configuration flags bool disable_mfm; @@ -373,7 +373,7 @@ private: class wd_fdc_analog_device_base : public wd_fdc_device_base { protected: - wd_fdc_analog_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + wd_fdc_analog_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void pll_reset(bool fm, bool enmf, const attotime &when) override; virtual void pll_start_writing(const attotime &tm) override; @@ -390,7 +390,7 @@ private: class wd_fdc_digital_device_base : public wd_fdc_device_base { protected: - wd_fdc_digital_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + wd_fdc_digital_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); static constexpr int wd_digital_step_times[4] = { 12000, 24000, 40000, 60000 }; @@ -433,7 +433,7 @@ private: class fd1771_device : public wd_fdc_analog_device_base { public: - fd1771_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1771_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int calc_sector_size(uint8_t size, uint8_t command) const override; @@ -441,7 +441,7 @@ protected: class fd1781_device : public wd_fdc_analog_device_base { public: - fd1781_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1781_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int calc_sector_size(uint8_t size, uint8_t command) const override; @@ -449,32 +449,32 @@ protected: class fd1791_device : public wd_fdc_analog_device_base { public: - fd1791_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1791_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class fd1792_device : public wd_fdc_analog_device_base { public: - fd1792_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1792_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class fd1793_device : public wd_fdc_analog_device_base { public: - fd1793_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1793_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class kr1818vg93_device : public wd_fdc_analog_device_base { public: - kr1818vg93_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + kr1818vg93_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class fd1794_device : public wd_fdc_analog_device_base { public: - fd1794_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1794_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class fd1795_device : public wd_fdc_analog_device_base { public: - fd1795_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1795_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int calc_sector_size(uint8_t size, uint8_t command) const override; @@ -482,7 +482,7 @@ protected: class fd1797_device : public wd_fdc_analog_device_base { public: - fd1797_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1797_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int calc_sector_size(uint8_t size, uint8_t command) const override; @@ -490,32 +490,32 @@ protected: class mb8866_device : public wd_fdc_analog_device_base { public: - mb8866_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb8866_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mb8876_device : public wd_fdc_analog_device_base { public: - mb8876_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb8876_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mb8877_device : public wd_fdc_analog_device_base { public: - mb8877_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb8877_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class fd1761_device : public wd_fdc_analog_device_base { public: - fd1761_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1761_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class fd1763_device : public wd_fdc_analog_device_base { public: - fd1763_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1763_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class fd1765_device : public wd_fdc_analog_device_base { public: - fd1765_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1765_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int calc_sector_size(uint8_t size, uint8_t command) const override; @@ -523,7 +523,7 @@ protected: class fd1767_device : public wd_fdc_analog_device_base { public: - fd1767_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + fd1767_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int calc_sector_size(uint8_t size, uint8_t command) const override; @@ -531,19 +531,19 @@ protected: class wd2791_device : public wd_fdc_analog_device_base { public: - wd2791_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd2791_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(enmf_w) { enmf = state ? false : true; } }; class wd2793_device : public wd_fdc_analog_device_base { public: - wd2793_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd2793_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(enmf_w) { enmf = state ? false : true; } }; class wd2795_device : public wd_fdc_analog_device_base { public: - wd2795_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd2795_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int calc_sector_size(uint8_t size, uint8_t command) const override; @@ -551,7 +551,7 @@ protected: class wd2797_device : public wd_fdc_analog_device_base { public: - wd2797_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd2797_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int calc_sector_size(uint8_t size, uint8_t command) const override; @@ -559,12 +559,12 @@ protected: class wd1770_device : public wd_fdc_digital_device_base { public: - wd1770_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd1770_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class wd1772_device : public wd_fdc_digital_device_base { public: - wd1772_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd1772_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int settle_time() const override; @@ -572,7 +572,7 @@ protected: class wd1773_device : public wd_fdc_digital_device_base { public: - wd1773_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + wd1773_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(FD1771, fd1771_device) diff --git a/src/devices/machine/wozfdc.cpp b/src/devices/machine/wozfdc.cpp index bee2f043e7e..fda72801509 100644 --- a/src/devices/machine/wozfdc.cpp +++ b/src/devices/machine/wozfdc.cpp @@ -56,18 +56,18 @@ void wozfdc_device::device_add_mconfig(machine_config &config) // LIVE DEVICE //************************************************************************** -wozfdc_device::wozfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +wozfdc_device::wozfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_phaselatch(*this, "phaselatch") { } -diskii_fdc_device::diskii_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +diskii_fdc_device::diskii_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wozfdc_device(mconfig, DISKII_FDC, tag, owner, clock) { } -appleiii_fdc_device::appleiii_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +appleiii_fdc_device::appleiii_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : wozfdc_device(mconfig, APPLEIII_FDC, tag, owner, clock) { } diff --git a/src/devices/machine/wozfdc.h b/src/devices/machine/wozfdc.h index f92ccaec39f..ccc32cbde41 100644 --- a/src/devices/machine/wozfdc.h +++ b/src/devices/machine/wozfdc.h @@ -35,7 +35,7 @@ public: protected: // construction/destruction - wozfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + wozfdc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -83,7 +83,7 @@ protected: class diskii_fdc_device : public wozfdc_device { public: - diskii_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + diskii_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_floppies(floppy_connector *f0, floppy_connector *f1); @@ -94,7 +94,7 @@ protected: class appleiii_fdc_device : public wozfdc_device { public: - appleiii_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + appleiii_fdc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_floppies_4(floppy_connector *f0, floppy_connector *f1, floppy_connector *f2, floppy_connector *f3); diff --git a/src/devices/machine/wtl3132.cpp b/src/devices/machine/wtl3132.cpp index 2e86798b878..28479af0b56 100644 --- a/src/devices/machine/wtl3132.cpp +++ b/src/devices/machine/wtl3132.cpp @@ -31,7 +31,7 @@ ALLOW_SAVE_TYPE(float32_t); DEFINE_DEVICE_TYPE(WTL3132, wtl3132_device, "wtl3132", "Weitek 3132") -wtl3132_device::wtl3132_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +wtl3132_device::wtl3132_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WTL3132, tag, owner, clock) , m_fpcn_cb(*this) , m_fpex_cb(*this) diff --git a/src/devices/machine/wtl3132.h b/src/devices/machine/wtl3132.h index deca6dd7f26..cf676e62273 100644 --- a/src/devices/machine/wtl3132.h +++ b/src/devices/machine/wtl3132.h @@ -11,7 +11,7 @@ class wtl3132_device : public device_t { public: - wtl3132_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + wtl3132_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); // output lines auto out_fpcn() { return m_fpcn_cb.bind(); } diff --git a/src/devices/machine/x2201.cpp b/src/devices/machine/x2201.cpp index 30ee78a8cfd..57106c42ebe 100644 --- a/src/devices/machine/x2201.cpp +++ b/src/devices/machine/x2201.cpp @@ -43,7 +43,7 @@ DEFINE_DEVICE_TYPE(X2201, x2201_device, "x2201", "Xicor X2201 1024x1 NOVRAM") // x2201_device - constructor //------------------------------------------------- -x2201_device::x2201_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +x2201_device::x2201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, X2201, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_default_data(*this, DEVICE_SELF) diff --git a/src/devices/machine/x2201.h b/src/devices/machine/x2201.h index 1e23493fdb7..d8b755d0ea2 100644 --- a/src/devices/machine/x2201.h +++ b/src/devices/machine/x2201.h @@ -34,7 +34,7 @@ class x2201_device : public device_t, public device_nvram_interface { public: // construction/destruction - x2201_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + x2201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // read/write handlers u8 read(offs_t offset); diff --git a/src/devices/machine/x2212.cpp b/src/devices/machine/x2212.cpp index f8c7fb906e3..f52a60c1474 100644 --- a/src/devices/machine/x2212.cpp +++ b/src/devices/machine/x2212.cpp @@ -26,12 +26,12 @@ DEFINE_DEVICE_TYPE(X2210, x2210_device, "x2210", "Xicor X2210 64x4 NOVRAM") // x2212_device - constructor //------------------------------------------------- -x2212_device::x2212_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +x2212_device::x2212_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : x2212_device(mconfig, X2212, tag, owner, clock, 0x100) { } -x2212_device::x2212_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int size_data) +x2212_device::x2212_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int size_data) : device_t(mconfig, type, tag, owner, clock) , device_nvram_interface(mconfig, *this) , m_auto_save(false) @@ -183,7 +183,7 @@ void x2212_device::recall(int state) } -x2210_device::x2210_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +x2210_device::x2210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : x2212_device(mconfig, X2210, tag, owner, clock, 0x40) { } diff --git a/src/devices/machine/x2212.h b/src/devices/machine/x2212.h index feeb91a0d23..a324bf1d7b3 100644 --- a/src/devices/machine/x2212.h +++ b/src/devices/machine/x2212.h @@ -38,7 +38,7 @@ class x2212_device : public device_t, public device_nvram_interface { public: // construction/destruction - x2212_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + x2212_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // some systems (like many early Atari games) wire up the /STORE signal // to fire on power-down, effectively creating an "auto-save" functionality @@ -52,7 +52,7 @@ public: void recall(int state); protected: - x2212_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int size_data); + x2212_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int size_data); // device-level overrides virtual void device_start() override; @@ -84,7 +84,7 @@ private: class x2210_device : public x2212_device { public: - x2210_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + x2210_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; diff --git a/src/devices/machine/x76f041.cpp b/src/devices/machine/x76f041.cpp index 340cf224800..73e67032347 100644 --- a/src/devices/machine/x76f041.cpp +++ b/src/devices/machine/x76f041.cpp @@ -36,7 +36,7 @@ inline void ATTR_PRINTF( 3, 4 ) x76f041_device::verboselog( int n_level, const c // device type definition DEFINE_DEVICE_TYPE(X76F041, x76f041_device, "x76f041", "X76F041 Secure SerialFlash") -x76f041_device::x76f041_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +x76f041_device::x76f041_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : device_t( mconfig, X76F041, tag, owner, clock ), device_nvram_interface(mconfig, *this), m_region(*this, DEVICE_SELF), diff --git a/src/devices/machine/x76f041.h b/src/devices/machine/x76f041.h index bd0a792cf9c..722d2e23081 100644 --- a/src/devices/machine/x76f041.h +++ b/src/devices/machine/x76f041.h @@ -18,7 +18,7 @@ class x76f041_device : public device_t, { public: // construction/destruction - x76f041_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + x76f041_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); DECLARE_WRITE_LINE_MEMBER( write_cs ); DECLARE_WRITE_LINE_MEMBER( write_rst ); diff --git a/src/devices/machine/x76f100.cpp b/src/devices/machine/x76f100.cpp index 032020059d9..fefb2f4c878 100644 --- a/src/devices/machine/x76f100.cpp +++ b/src/devices/machine/x76f100.cpp @@ -34,7 +34,7 @@ inline void ATTR_PRINTF( 3, 4 ) x76f100_device::verboselog( int n_level, const c // device type definition DEFINE_DEVICE_TYPE(X76F100, x76f100_device, "x76f100", "X76F100 Secure SerialFlash") -x76f100_device::x76f100_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock ) +x76f100_device::x76f100_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock ) : device_t( mconfig, X76F100, tag, owner, clock ), device_nvram_interface(mconfig, *this), m_region(*this, DEVICE_SELF), diff --git a/src/devices/machine/x76f100.h b/src/devices/machine/x76f100.h index 38302f7caeb..eff43a514d5 100644 --- a/src/devices/machine/x76f100.h +++ b/src/devices/machine/x76f100.h @@ -17,7 +17,7 @@ class x76f100_device : public device_t, public device_nvram_interface { public: // construction/destruction - x76f100_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + x76f100_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); DECLARE_WRITE_LINE_MEMBER( write_cs ); DECLARE_WRITE_LINE_MEMBER( write_rst ); diff --git a/src/devices/machine/xc1700e.cpp b/src/devices/machine/xc1700e.cpp index fe056664b07..e622ee90415 100644 --- a/src/devices/machine/xc1700e.cpp +++ b/src/devices/machine/xc1700e.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(XC1701, xc1701_device, "xc1701", "Xilinx 1,048,576 bit DEFINE_DEVICE_TYPE(XC1702L, xc1702l_device, "xc1702l", "Xilinx 2,097,152 bit Serial PROM") DEFINE_DEVICE_TYPE(XC1704L, xc1704l_device, "xc1704l", "Xilinx 4,194,304 bit Serial PROM") -base_xc1700e_device::base_xc1700e_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 capacity) +base_xc1700e_device::base_xc1700e_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 capacity) : device_t(mconfig, type, tag, owner, clock) , m_capacity(capacity) , m_region(*this, DEVICE_SELF) diff --git a/src/devices/machine/xc1700e.h b/src/devices/machine/xc1700e.h index 42a191c73ce..0ae51f4950f 100644 --- a/src/devices/machine/xc1700e.h +++ b/src/devices/machine/xc1700e.h @@ -17,7 +17,7 @@ public: int data_r(); protected: - base_xc1700e_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u32 capacity); + base_xc1700e_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 capacity); // device_t overrides virtual void device_start() override; @@ -46,7 +46,7 @@ DECLARE_DEVICE_TYPE(XC1704L, xc1704l_device) class xc1736e_device : public base_xc1700e_device { public: - xc1736e_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + xc1736e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : base_xc1700e_device(mconfig, XC1736E, tag, owner, clock, 36'288UL) { } @@ -55,7 +55,7 @@ public: class xc1765e_device : public base_xc1700e_device { public: - xc1765e_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + xc1765e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : base_xc1700e_device(mconfig, XC1765E, tag, owner, clock, 65'536UL) { } @@ -64,7 +64,7 @@ public: class xc17128e_device : public base_xc1700e_device { public: - xc17128e_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + xc17128e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : base_xc1700e_device(mconfig, XC17128E, tag, owner, clock, 131'072UL) { } @@ -73,7 +73,7 @@ public: class xc17256e_device : public base_xc1700e_device { public: - xc17256e_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + xc17256e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : base_xc1700e_device(mconfig, XC17256E, tag, owner, clock, 262'144UL) { } @@ -82,7 +82,7 @@ public: class xc17512l_device : public base_xc1700e_device { public: - xc17512l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + xc17512l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : base_xc1700e_device(mconfig, XC17512L, tag, owner, clock, 524'288UL) { } @@ -91,7 +91,7 @@ public: class xc1701_device : public base_xc1700e_device { public: - xc1701_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + xc1701_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : base_xc1700e_device(mconfig, XC1701, tag, owner, clock, 1'048'576UL) { } @@ -100,7 +100,7 @@ public: class xc1702l_device : public base_xc1700e_device { public: - xc1702l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + xc1702l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : base_xc1700e_device(mconfig, XC1702L, tag, owner, clock, 2'097'152UL) { } @@ -109,7 +109,7 @@ public: class xc1704l_device : public base_xc1700e_device { public: - xc1704l_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0) + xc1704l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : base_xc1700e_device(mconfig, XC1704L, tag, owner, clock, 4'194'304UL) { } diff --git a/src/devices/machine/ym2148.cpp b/src/devices/machine/ym2148.cpp index 88f7db02b1e..0c32b782924 100644 --- a/src/devices/machine/ym2148.cpp +++ b/src/devices/machine/ym2148.cpp @@ -16,7 +16,7 @@ TODO: DEFINE_DEVICE_TYPE(YM2148, ym2148_device, "ym2148", "Yamaha YM2148 MIDI/Keyboard Interface") -ym2148_device::ym2148_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ym2148_device::ym2148_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, YM2148, tag, owner, clock) , device_serial_interface(mconfig, *this) , m_txd_handler(*this) diff --git a/src/devices/machine/ym2148.h b/src/devices/machine/ym2148.h index 07cacfbc589..525f5269c87 100644 --- a/src/devices/machine/ym2148.h +++ b/src/devices/machine/ym2148.h @@ -23,7 +23,7 @@ class ym2148_device : public device_t, public device_serial_interface { public: // construction/destruction - ym2148_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2148_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto txd_handler() { return m_txd_handler.bind(); } diff --git a/src/devices/machine/ym3802.cpp b/src/devices/machine/ym3802.cpp index 4a8f6a7ffae..ab073b6057b 100644 --- a/src/devices/machine/ym3802.cpp +++ b/src/devices/machine/ym3802.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(YM3802, ym3802_device, "ym3802", "Yamaha YM3802 MCS MIDI Communication and Service Controller") -ym3802_device::ym3802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ym3802_device::ym3802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, YM3802, tag, owner, clock) , device_serial_interface(mconfig, *this) , m_irq_handler(*this) diff --git a/src/devices/machine/ym3802.h b/src/devices/machine/ym3802.h index 00e6683ed25..f5fd91ea35d 100644 --- a/src/devices/machine/ym3802.h +++ b/src/devices/machine/ym3802.h @@ -30,7 +30,7 @@ class ym3802_device : public device_t, public device_serial_interface { public: // construction/destruction - ym3802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym3802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/machine/z8038.cpp b/src/devices/machine/z8038.cpp index 699c43898ca..4640bb2267a 100644 --- a/src/devices/machine/z8038.cpp +++ b/src/devices/machine/z8038.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(Z8038, z8038_device, "z8038", "FIFO Input/Output Interface Unit") -z8038_device::z8038_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z8038_device::z8038_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z8038, tag, owner, clock) , m_out_int_cb(*this) , m_out_E_cb(*this) diff --git a/src/devices/machine/z8038.h b/src/devices/machine/z8038.h index 2e2201f10d6..2f6a199e7c7 100644 --- a/src/devices/machine/z8038.h +++ b/src/devices/machine/z8038.h @@ -9,7 +9,7 @@ class z8038_device : public device_t { public: - z8038_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z8038_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // port 1 and 2 I̅N̅T̅ output lines template <u8 Port> auto out_int_cb() { return m_out_int_cb[Port - 1].bind(); } diff --git a/src/devices/machine/z80ctc.cpp b/src/devices/machine/z80ctc.cpp index 6a6e728d548..0623725940f 100644 --- a/src/devices/machine/z80ctc.cpp +++ b/src/devices/machine/z80ctc.cpp @@ -76,7 +76,7 @@ DEFINE_DEVICE_TYPE(Z80CTC_CHANNEL, z80ctc_channel_device, "z80ctc_channel", "Z80 // z80ctc_device - constructor //------------------------------------------------- -z80ctc_device::z80ctc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +z80ctc_device::z80ctc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z80CTC, tag, owner, clock) , device_z80daisy_interface(mconfig, *this) , m_intr_cb(*this) @@ -286,7 +286,7 @@ void z80ctc_device::interrupt_check() // z80ctc_channel_device - constructor //------------------------------------------------- -z80ctc_channel_device::z80ctc_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +z80ctc_channel_device::z80ctc_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z80CTC_CHANNEL, tag, owner, clock), m_device(*this, DEVICE_SELF_OWNER), m_index(0), diff --git a/src/devices/machine/z80ctc.h b/src/devices/machine/z80ctc.h index 2e61a80df1b..8bfb441def9 100644 --- a/src/devices/machine/z80ctc.h +++ b/src/devices/machine/z80ctc.h @@ -47,7 +47,7 @@ class z80ctc_channel_device : public device_t public: // construction/destruction - z80ctc_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + z80ctc_channel_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device-level overrides @@ -82,11 +82,10 @@ class z80ctc_device : public device_t, public: // construction/destruction - z80ctc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + z80ctc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto intr_callback() { return m_intr_cb.bind(); } template <int Channel> auto zc_callback() { return m_zc_cb[Channel].bind(); } // m_zc_cb[3] not supported on a standard ctc, only used for the tmpz84c015 - template <int Channel> void set_clk(u32 clock) { channel_config(Channel).set_clock(clock); } template <int Channel> void set_clk(const XTAL &xtal) { channel_config(Channel).set_clock(xtal); } // read/write handlers diff --git a/src/devices/machine/z80daisy_generic.cpp b/src/devices/machine/z80daisy_generic.cpp index 3a5b6562f30..92bf68c3612 100644 --- a/src/devices/machine/z80daisy_generic.cpp +++ b/src/devices/machine/z80daisy_generic.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(Z80DAISY_GENERIC, z80daisy_generic_device, "z80daisy_generic" // z80daisy_generic_device - constructor //------------------------------------------------- -z80daisy_generic_device::z80daisy_generic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +z80daisy_generic_device::z80daisy_generic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z80DAISY_GENERIC, tag, owner, clock), device_z80daisy_interface(mconfig, *this), m_int_handler(*this), diff --git a/src/devices/machine/z80daisy_generic.h b/src/devices/machine/z80daisy_generic.h index d26b50e6ee7..34b01f1d7bd 100644 --- a/src/devices/machine/z80daisy_generic.h +++ b/src/devices/machine/z80daisy_generic.h @@ -22,7 +22,7 @@ class z80daisy_generic_device : public device_t, public device_z80daisy_interfac { public: // construction/destruction - z80daisy_generic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80daisy_generic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto int_handler() { return m_int_handler.bind(); } diff --git a/src/devices/machine/z80dma.cpp b/src/devices/machine/z80dma.cpp index 7ed0e61160f..9b00cade7b0 100644 --- a/src/devices/machine/z80dma.cpp +++ b/src/devices/machine/z80dma.cpp @@ -149,7 +149,7 @@ DEFINE_DEVICE_TYPE(Z80DMA, z80dma_device, "z80dma", "Z80 DMA Controller") // z80dma_device - constructor //------------------------------------------------- -z80dma_device::z80dma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z80dma_device::z80dma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z80DMA, tag, owner, clock) , device_z80daisy_interface(mconfig, *this) , m_out_busreq_cb(*this) diff --git a/src/devices/machine/z80dma.h b/src/devices/machine/z80dma.h index 26613e74b80..11fd05f22b4 100644 --- a/src/devices/machine/z80dma.h +++ b/src/devices/machine/z80dma.h @@ -49,7 +49,7 @@ class z80dma_device : public device_t, { public: // construction/destruction - z80dma_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80dma_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_busreq_callback() { return m_out_busreq_cb.bind(); } auto out_int_callback() { return m_out_int_cb.bind(); } diff --git a/src/devices/machine/z80pio.cpp b/src/devices/machine/z80pio.cpp index e1664055f21..37c9ddd9a5f 100644 --- a/src/devices/machine/z80pio.cpp +++ b/src/devices/machine/z80pio.cpp @@ -37,7 +37,7 @@ DEFINE_DEVICE_TYPE(Z80PIO, z80pio_device, "z80pio", "Z80 PIO") // z80pio_device - constructor //------------------------------------------------- -z80pio_device::z80pio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +z80pio_device::z80pio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z80PIO, tag, owner, clock), device_z80daisy_interface(mconfig, *this), m_out_int_cb(*this), diff --git a/src/devices/machine/z80pio.h b/src/devices/machine/z80pio.h index a448fd9d502..e7c7a867183 100644 --- a/src/devices/machine/z80pio.h +++ b/src/devices/machine/z80pio.h @@ -56,7 +56,7 @@ public: }; // construction/destruction - z80pio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80pio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_int_callback() { return m_out_int_cb.bind(); } auto in_pa_callback() { return m_in_pa_cb.bind(); } diff --git a/src/devices/machine/z80scc.cpp b/src/devices/machine/z80scc.cpp index 020b2678bfd..c6a8a63401c 100644 --- a/src/devices/machine/z80scc.cpp +++ b/src/devices/machine/z80scc.cpp @@ -386,8 +386,8 @@ DEFINE_DEVICE_TYPE(SCC8523L, scc8523l_device, "scc8523l", "Zilog Z85 //------------------------------------------------- void z80scc_device::device_add_mconfig(machine_config &config) { - Z80SCC_CHANNEL(config, CHANA_TAG, 0); - Z80SCC_CHANNEL(config, CHANB_TAG, 0); + Z80SCC_CHANNEL(config, CHANA_TAG); + Z80SCC_CHANNEL(config, CHANB_TAG); } @@ -413,7 +413,7 @@ inline void z80scc_channel::out_dtr_cb(int state) //------------------------------------------------- // z80scc_device - constructor //------------------------------------------------- -z80scc_device::z80scc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +z80scc_device::z80scc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock), device_z80daisy_interface(mconfig, *this), m_wr9(0), @@ -440,42 +440,42 @@ z80scc_device::z80scc_device(const machine_config &mconfig, device_type type, co elem = 0; } -scc8030_device::scc8030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scc8030_device::scc8030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80scc_device(mconfig, SCC8030, tag, owner, clock, TYPE_SCC8030) { } -scc80c30_device::scc80c30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scc80c30_device::scc80c30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80scc_device(mconfig, SCC80C30, tag, owner, clock, TYPE_SCC80C30) { } -scc80230_device::scc80230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scc80230_device::scc80230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80scc_device(mconfig, SCC80230, tag, owner, clock, TYPE_SCC80230) { } -scc8530_device::scc8530_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scc8530_device::scc8530_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80scc_device(mconfig, SCC8530N, tag, owner, clock, TYPE_SCC8530) { } -scc85c30_device::scc85c30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scc85c30_device::scc85c30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80scc_device(mconfig, SCC85C30, tag, owner, clock, TYPE_SCC85C30) { } -scc85230_device::scc85230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scc85230_device::scc85230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80scc_device(mconfig, SCC85230, tag, owner, clock, TYPE_SCC85230) { } -scc85233_device::scc85233_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scc85233_device::scc85233_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80scc_device(mconfig, SCC85233, tag, owner, clock, TYPE_SCC85233) { } -scc8523l_device::scc8523l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scc8523l_device::scc8523l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80scc_device(mconfig, SCC8523L, tag, owner, clock, TYPE_SCC8523L) { } @@ -1011,7 +1011,7 @@ void z80scc_device::ab_dc_w(offs_t offset, uint8_t data) //------------------------------------------------- // SCC_channel - constructor //------------------------------------------------- -z80scc_channel::z80scc_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z80scc_channel::z80scc_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z80SCC_CHANNEL, tag, owner, clock), device_serial_interface(mconfig, *this), m_baudtimer(0), @@ -2915,8 +2915,8 @@ void z80scc_channel::update_serial() else { LOG("- BRG disabled\n"); - set_rcv_rate(0); - set_tra_rate(0); + set_rcv_rate(XTAL::u(0)); + set_tra_rate(XTAL::u(0)); } // TODO: Check registers for use of RTxC and TRxC, if used as direct Tx and/or Rx clocks set them to value as programmed // in m_uart->txca/txcb and rxca/rxcb respectivelly diff --git a/src/devices/machine/z80scc.h b/src/devices/machine/z80scc.h index 4ef274aba92..5bae5fe767b 100644 --- a/src/devices/machine/z80scc.h +++ b/src/devices/machine/z80scc.h @@ -53,7 +53,7 @@ class z80scc_channel : public device_t, friend class z80scc_device; public: - z80scc_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80scc_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -330,12 +330,12 @@ public: void set_cputag(const char *tag) { m_cputag = tag; } - void configure_channels(int rxa, int txa, int rxb, int txb) + void configure_channels(const XTAL &rxa, const XTAL &txa, const XTAL &rxb, const XTAL &txb) { - m_rxca = rxa; - m_txca = txa; - m_rxcb = rxb; - m_txcb = txb; + m_rxca = rxa.value(); + m_txca = txa.value(); + m_rxcb = rxb.value(); + m_txcb = txb.value(); } uint8_t dc_ab_r(offs_t offset); @@ -380,7 +380,7 @@ public: int get_extint_priority(int type); protected: - z80scc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + z80scc_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_resolve_objects() override; @@ -460,49 +460,49 @@ protected: class scc8030_device : public z80scc_device { public: - scc8030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc8030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class scc80c30_device : public z80scc_device { public: - scc80c30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc80c30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class scc80230_device : public z80scc_device { public: - scc80230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc80230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class scc8530_device : public z80scc_device { public: - scc8530_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc8530_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class scc85c30_device : public z80scc_device { public: - scc85c30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc85c30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class scc85230_device : public z80scc_device { public: - scc85230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc85230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class scc85233_device : public z80scc_device { public: - scc85233_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc85233_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class scc8523l_device : public z80scc_device { public: - scc8523l_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scc8523l_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/machine/z80sio.cpp b/src/devices/machine/z80sio.cpp index 8306c48bab4..5ba14295c4f 100644 --- a/src/devices/machine/z80sio.cpp +++ b/src/devices/machine/z80sio.cpp @@ -269,26 +269,26 @@ DEFINE_DEVICE_TYPE(MK68564, mk68564_device, "mk68564", "Most //------------------------------------------------- void z80sio_device::device_add_mconfig(machine_config &config) { - Z80SIO_CHANNEL(config, CHANA_TAG, 0); - Z80SIO_CHANNEL(config, CHANB_TAG, 0); + Z80SIO_CHANNEL(config, CHANA_TAG); + Z80SIO_CHANNEL(config, CHANB_TAG); } void z80dart_device::device_add_mconfig(machine_config &config) { - Z80DART_CHANNEL(config, CHANA_TAG, 0); - Z80DART_CHANNEL(config, CHANB_TAG, 0); + Z80DART_CHANNEL(config, CHANA_TAG); + Z80DART_CHANNEL(config, CHANB_TAG); } void i8274_device::device_add_mconfig(machine_config &config) { - I8274_CHANNEL(config, CHANA_TAG, 0); - I8274_CHANNEL(config, CHANB_TAG, 0); + I8274_CHANNEL(config, CHANA_TAG); + I8274_CHANNEL(config, CHANB_TAG); } void mk68564_device::device_add_mconfig(machine_config &config) { - MK68564_CHANNEL(config, CHANA_TAG, 0); - MK68564_CHANNEL(config, CHANB_TAG, 0); + MK68564_CHANNEL(config, CHANA_TAG); + MK68564_CHANNEL(config, CHANB_TAG); } @@ -397,7 +397,7 @@ void z80dart_channel::tx_setup_idle() //------------------------------------------------- // z80sio_device - constructor //------------------------------------------------- -z80sio_device::z80sio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +z80sio_device::z80sio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_z80daisy_interface(mconfig, *this), m_chanA(*this, CHANA_TAG), @@ -416,32 +416,32 @@ z80sio_device::z80sio_device(const machine_config &mconfig, device_type type, co elem = 0; } -z80sio_device::z80sio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +z80sio_device::z80sio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80sio_device(mconfig, Z80SIO, tag, owner, clock) { } -z80dart_device::z80dart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +z80dart_device::z80dart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80sio_device(mconfig, Z80DART, tag, owner, clock) { } -i8274_device::i8274_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +i8274_device::i8274_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : z80sio_device(mconfig, type, tag, owner, clock) { } -i8274_device::i8274_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i8274_device::i8274_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8274_device(mconfig, I8274, tag, owner, clock) { } -upd7201_device::upd7201_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +upd7201_device::upd7201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8274_device(mconfig, UPD7201, tag, owner, clock) { } -mk68564_device::mk68564_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mk68564_device::mk68564_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8274_device(mconfig, MK68564, tag, owner, clock) { } @@ -978,22 +978,22 @@ z80sio_channel::z80sio_channel( m_wr0 = m_wr1 = m_wr2 = m_wr3 = m_wr4 = m_wr5 = m_wr6 = m_wr7 = 0; } -z80sio_channel::z80sio_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z80sio_channel::z80sio_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80sio_channel(mconfig, Z80SIO_CHANNEL, tag, owner, clock, RR1_END_OF_FRAME | RR1_CRC_FRAMING_ERROR | RR1_RESIDUE_CODE_MASK) { } -z80dart_channel::z80dart_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z80dart_channel::z80dart_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80sio_channel(mconfig, Z80DART_CHANNEL, tag, owner, clock, RR1_END_OF_FRAME | RR1_CRC_FRAMING_ERROR | RR1_RESIDUE_CODE_MASK) { } -i8274_channel::i8274_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i8274_channel::i8274_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80sio_channel(mconfig, I8274_CHANNEL, tag, owner, clock, RR1_RX_OVERRUN_ERROR) { } -mk68564_channel::mk68564_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mk68564_channel::mk68564_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : z80sio_channel(mconfig, MK68564_CHANNEL, tag, owner, clock, RR1_END_OF_FRAME | RR1_CRC_FRAMING_ERROR | RR1_RESIDUE_CODE_MASK) , m_tx_auto_enable(false) , m_brg_tc(0) diff --git a/src/devices/machine/z80sio.h b/src/devices/machine/z80sio.h index f8fbc1522c9..de27b405072 100644 --- a/src/devices/machine/z80sio.h +++ b/src/devices/machine/z80sio.h @@ -178,7 +178,7 @@ class z80sio_channel : public device_t friend class mk68564_device; public: - z80sio_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80sio_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // read register handlers uint8_t do_sioreg_rr0(); @@ -397,7 +397,7 @@ protected: class z80dart_channel : public z80sio_channel { public: - z80dart_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80dart_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void enter_hunt_mode() override; @@ -414,7 +414,7 @@ protected: class i8274_channel : public z80sio_channel { public: - i8274_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8274_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -425,7 +425,7 @@ class mk68564_channel : public z80sio_channel friend class mk68564_device; public: - mk68564_channel(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mk68564_channel(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -473,7 +473,7 @@ class z80sio_device : public device_t, public: // construction/destruction - z80sio_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80sio_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_txda_callback() { return m_out_txd_cb[0].bind(); } auto out_txdb_callback() { return m_out_txd_cb[1].bind(); } @@ -526,7 +526,7 @@ public: DECLARE_WRITE_LINE_MEMBER( syncb_w ) { m_chanB->sync_w(state); } protected: - z80sio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + z80sio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_validity_check(validity_checker &valid) const override; @@ -579,7 +579,7 @@ protected: class z80dart_device : public z80sio_device { public: - z80dart_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80dart_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( ria_w ) { m_chanA->sync_w(state); } DECLARE_WRITE_LINE_MEMBER( rib_w ) { m_chanB->sync_w(state); } @@ -592,12 +592,12 @@ protected: class i8274_device : public z80sio_device { public: - i8274_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8274_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t inta_r() { return m1_r(); } protected: - i8274_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + i8274_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device_t overrides virtual void device_add_mconfig(machine_config &config) override; @@ -613,13 +613,13 @@ protected: class upd7201_device : public i8274_device { public: - upd7201_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7201_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mk68564_device : public i8274_device { public: - mk68564_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mk68564_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_xtal(uint32_t clock); void set_xtal(const XTAL &clock) { set_xtal(clock.value()); } diff --git a/src/devices/machine/z80sti.cpp b/src/devices/machine/z80sti.cpp index a72a370ec79..4ed129c2faa 100644 --- a/src/devices/machine/z80sti.cpp +++ b/src/devices/machine/z80sti.cpp @@ -76,7 +76,7 @@ const int z80sti_device::PRESCALER[] = { 0, 4, 10, 16, 50, 64, 100, 200 }; // z80sti_device - constructor //------------------------------------------------- -z80sti_device::z80sti_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +z80sti_device::z80sti_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, Z80STI, tag, owner, clock) , device_serial_interface(mconfig, *this) , device_z80daisy_interface(mconfig, *this) diff --git a/src/devices/machine/z80sti.h b/src/devices/machine/z80sti.h index 9cd0ff40d59..9bee4619055 100644 --- a/src/devices/machine/z80sti.h +++ b/src/devices/machine/z80sti.h @@ -50,7 +50,7 @@ class z80sti_device : public device_t, { public: // construction/destruction - z80sti_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + z80sti_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto out_int_cb() { return m_out_int_cb.bind(); } auto in_gpio_cb() { return m_in_gpio_cb.bind(); } diff --git a/src/devices/machine/z8536.cpp b/src/devices/machine/z8536.cpp index c30868d0dbb..4f21fa59125 100644 --- a/src/devices/machine/z8536.cpp +++ b/src/devices/machine/z8536.cpp @@ -776,7 +776,7 @@ void cio_base_device::external_port_w(int port, int bit, int state) // cio_base_device - constructor //------------------------------------------------- -cio_base_device::cio_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +cio_base_device::cio_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_write_irq(*this), m_read_pa(*this), @@ -794,7 +794,7 @@ cio_base_device::cio_base_device(const machine_config &mconfig, device_type type // z8036_device - constructor //------------------------------------------------- -z8036_device::z8036_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +z8036_device::z8036_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cio_base_device(mconfig, Z8036, tag, owner, clock) { } @@ -804,7 +804,7 @@ z8036_device::z8036_device(const machine_config &mconfig, const char *tag, devic // z8536_device - constructor //------------------------------------------------- -z8536_device::z8536_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +z8536_device::z8536_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cio_base_device(mconfig, Z8536, tag, owner, clock), device_z80daisy_interface(mconfig, *this) { diff --git a/src/devices/machine/z8536.h b/src/devices/machine/z8536.h index 382649a15f9..ea1b624d940 100644 --- a/src/devices/machine/z8536.h +++ b/src/devices/machine/z8536.h @@ -104,7 +104,7 @@ public: protected: // construction/destruction - cio_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + cio_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -416,7 +416,7 @@ class z8036_device : public cio_base_device { public: // construction/destruction - z8036_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + z8036_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 read(offs_t offset); void write(offs_t offset, u8 data); @@ -428,7 +428,7 @@ class z8536_device : public cio_base_device, public device_z80daisy_interface { public: // construction/destruction - z8536_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + z8536_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 read(offs_t offset); void write(offs_t offset, u8 data); diff --git a/src/devices/sound/315-5641.cpp b/src/devices/sound/315-5641.cpp index 7b5f06b0d8b..3836794f5f7 100644 --- a/src/devices/sound/315-5641.cpp +++ b/src/devices/sound/315-5641.cpp @@ -7,7 +7,7 @@ DEFINE_DEVICE_TYPE(SEGA_315_5641_PCM, sega_315_5641_pcm_device, "315_5641_pcm", "Sega 315-5641 PCM") -sega_315_5641_pcm_device::sega_315_5641_pcm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sega_315_5641_pcm_device::sega_315_5641_pcm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd7759_device(mconfig, SEGA_315_5641_PCM, tag, owner, clock) , m_fifocallback(*this) , m_fifo_read(0) diff --git a/src/devices/sound/315-5641.h b/src/devices/sound/315-5641.h index 2f986a912f0..7631a376298 100644 --- a/src/devices/sound/315-5641.h +++ b/src/devices/sound/315-5641.h @@ -16,7 +16,7 @@ class sega_315_5641_pcm_device : public upd7759_device { public: - sega_315_5641_pcm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sega_315_5641_pcm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto fifo_cb() { return m_fifocallback.bind(); } virtual void port_w(u8 data) override; diff --git a/src/devices/sound/ad1848.cpp b/src/devices/sound/ad1848.cpp index 7c62b4912ef..983eede0d5f 100644 --- a/src/devices/sound/ad1848.cpp +++ b/src/devices/sound/ad1848.cpp @@ -12,7 +12,7 @@ DEFINE_DEVICE_TYPE(AD1848, ad1848_device, "ad1848", "AD1848 16-bit SoundPort Stereo Codec") -ad1848_device::ad1848_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ad1848_device::ad1848_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AD1848, tag, owner, clock), m_irq_cb(*this), m_drq_cb(*this), @@ -25,8 +25,8 @@ void ad1848_device::device_add_mconfig(machine_config &config) { SPEAKER(config, "lspeaker").front_left(); SPEAKER(config, "rspeaker").front_right(); - DAC_16BIT_R2R(config, m_ldac, 0).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // unknown DAC - DAC_16BIT_R2R(config, m_rdac, 0).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // unknown DAC + DAC_16BIT_R2R(config, m_ldac).add_route(ALL_OUTPUTS, "lspeaker", 0.5); // unknown DAC + DAC_16BIT_R2R(config, m_rdac).add_route(ALL_OUTPUTS, "rspeaker", 0.5); // unknown DAC } diff --git a/src/devices/sound/ad1848.h b/src/devices/sound/ad1848.h index 1fd354c3427..1524119fde1 100644 --- a/src/devices/sound/ad1848.h +++ b/src/devices/sound/ad1848.h @@ -11,7 +11,7 @@ class ad1848_device : public device_t { public: - ad1848_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ad1848_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq() { return m_irq_cb.bind(); } auto drq() { return m_drq_cb.bind(); } diff --git a/src/devices/sound/aica.cpp b/src/devices/sound/aica.cpp index a746f80eae0..8fdb58f169f 100644 --- a/src/devices/sound/aica.cpp +++ b/src/devices/sound/aica.cpp @@ -1538,7 +1538,7 @@ u8 aica_device::midi_out_r() DEFINE_DEVICE_TYPE(AICA, aica_device, "aica", "Yamaha AICA") -aica_device::aica_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +aica_device::aica_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AICA, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_memory_interface(mconfig, *this) diff --git a/src/devices/sound/aica.h b/src/devices/sound/aica.h index 09a042b1aad..01c208e134f 100644 --- a/src/devices/sound/aica.h +++ b/src/devices/sound/aica.h @@ -19,7 +19,7 @@ class aica_device : public device_t, public device_sound_interface, public devic public: static constexpr feature_type imperfect_features() { return feature::SOUND; } - aica_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + aica_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq() { return m_irq_cb.bind(); } auto main_irq() { return m_main_irq_cb.bind(); } diff --git a/src/devices/sound/asc.cpp b/src/devices/sound/asc.cpp index 2216b38f328..2bb61779166 100644 --- a/src/devices/sound/asc.cpp +++ b/src/devices/sound/asc.cpp @@ -49,7 +49,7 @@ DEFINE_DEVICE_TYPE(ASC, asc_device, "asc", "ASC") // asc_device - constructor //------------------------------------------------- -asc_device::asc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +asc_device::asc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASC, tag, owner, clock) , device_sound_interface(mconfig, *this) , write_irq(*this) diff --git a/src/devices/sound/asc.h b/src/devices/sound/asc.h index 591c95d71af..b5bea7e4ca2 100644 --- a/src/devices/sound/asc.h +++ b/src/devices/sound/asc.h @@ -36,13 +36,13 @@ public: ARDBEG = 7 // Subset of ASC included in the Ardbeg ASIC (LC520) }; - asc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, asc_type type) + asc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, asc_type type) : asc_device(mconfig, tag, owner, clock) { set_type(type); } - asc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + asc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static constexpr feature_type imperfect_features() { return feature::SOUND; } diff --git a/src/devices/sound/astrocde.cpp b/src/devices/sound/astrocde.cpp index 91d0fdc46b9..27c8303c682 100644 --- a/src/devices/sound/astrocde.cpp +++ b/src/devices/sound/astrocde.cpp @@ -69,7 +69,7 @@ DEFINE_DEVICE_TYPE(ASTROCADE_IO, astrocade_io_device, "astrocade_io", "Astrocade // astrocade_io_device - constructor //------------------------------------------------- -astrocade_io_device::astrocade_io_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +astrocade_io_device::astrocade_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ASTROCADE_IO, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr) diff --git a/src/devices/sound/astrocde.h b/src/devices/sound/astrocde.h index 387ef7f9ca3..a57f0ddbf86 100644 --- a/src/devices/sound/astrocde.h +++ b/src/devices/sound/astrocde.h @@ -44,7 +44,7 @@ class astrocade_io_device : public device_t, public device_sound_interface { public: - astrocade_io_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + astrocade_io_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration access auto si_cb() { return m_si_callback.bind(); } diff --git a/src/devices/sound/awacs.cpp b/src/devices/sound/awacs.cpp index 07ec04e4f14..0ca84b66323 100644 --- a/src/devices/sound/awacs.cpp +++ b/src/devices/sound/awacs.cpp @@ -27,7 +27,7 @@ const u8 awacs_device::divider[4] = { 16, 12, 8, 16 }; // awacs_device - constructor //------------------------------------------------- -awacs_device::awacs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +awacs_device::awacs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AWACS, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_irq_out_cb(*this) diff --git a/src/devices/sound/awacs.h b/src/devices/sound/awacs.h index a1c17f1aa10..656cc7a814e 100644 --- a/src/devices/sound/awacs.h +++ b/src/devices/sound/awacs.h @@ -23,7 +23,7 @@ class awacs_device : public device_t, public device_sound_interface { public: // construction/destruction - awacs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + awacs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_out_cb() { return m_irq_out_cb.bind(); } auto irq_in_cb() { return m_irq_in_cb.bind(); } diff --git a/src/devices/sound/ay8910.cpp b/src/devices/sound/ay8910.cpp index 1f0acab67d7..98e2309adc4 100644 --- a/src/devices/sound/ay8910.cpp +++ b/src/devices/sound/ay8910.cpp @@ -1302,7 +1302,7 @@ void ay8910_device::ay8910_statesave() void ay8910_device::device_start() { - const int master_clock = clock(); + const XTAL master_clock = clock(); if (m_ioports < 1 && !(m_port_a_read_cb.isnull() && m_port_a_write_cb.isnull())) fatalerror("Device '%s' is a %s and has no port A!", tag(), name()); @@ -1378,7 +1378,7 @@ void ay8910_device::set_volume(int channel,int volume) set_output_gain(ch, volume / 100.0); } -void ay8910_device::ay_set_clock(int clock) +void ay8910_device::ay_set_clock(const XTAL &clock) { // FIXME: this doesn't belong here, it should be an input pin exposed via devcb if (((m_feature & PSG_PIN26_IS_CLKSEL) && (m_flags & YM2149_PIN26_LOW)) || (m_feature & PSG_HAS_INTERNAL_DIVIDER)) @@ -1588,12 +1588,12 @@ void ay8914_device::write(offs_t offset, u8 data) DEFINE_DEVICE_TYPE(AY8910, ay8910_device, "ay8910", "AY-3-8910A PSG") -ay8910_device::ay8910_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ay8910_device::ay8910_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay8910_device(mconfig, AY8910, tag, owner, clock, PSG_TYPE_AY, 3, 2) { } -ay8910_device::ay8910_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, +ay8910_device::ay8910_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, psg_type_t psg_type, int streams, int ioports, int feature) : device_t(mconfig, type, tag, owner, clock), device_sound_interface(mconfig, *this), @@ -1658,7 +1658,7 @@ void ay8910_device::set_type(psg_type_t psg_type) DEFINE_DEVICE_TYPE(AY8912, ay8912_device, "ay8912", "AY-3-8912A PSG") -ay8912_device::ay8912_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ay8912_device::ay8912_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay8910_device(mconfig, AY8912, tag, owner, clock, PSG_TYPE_AY, 3, 1) { } @@ -1666,7 +1666,7 @@ ay8912_device::ay8912_device(const machine_config &mconfig, const char *tag, dev DEFINE_DEVICE_TYPE(AY8913, ay8913_device, "ay8913", "AY-3-8913 PSG") -ay8913_device::ay8913_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ay8913_device::ay8913_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay8910_device(mconfig, AY8913, tag, owner, clock, PSG_TYPE_AY, 3, 0) { } @@ -1674,7 +1674,7 @@ ay8913_device::ay8913_device(const machine_config &mconfig, const char *tag, dev DEFINE_DEVICE_TYPE(AY8914, ay8914_device, "ay8914", "AY-3-8914A PSG") -ay8914_device::ay8914_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ay8914_device::ay8914_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay8910_device(mconfig, AY8914, tag, owner, clock, PSG_TYPE_AY, 3, 2, PSG_EXTENDED_ENVELOPE) { } @@ -1682,7 +1682,7 @@ ay8914_device::ay8914_device(const machine_config &mconfig, const char *tag, dev DEFINE_DEVICE_TYPE(AY8930, ay8930_device, "ay8930", "AY8930 EPSG") -ay8930_device::ay8930_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ay8930_device::ay8930_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay8910_device(mconfig, AY8930, tag, owner, clock, PSG_TYPE_YM, 3, 2, PSG_PIN26_IS_CLKSEL | PSG_HAS_EXPANDED_MODE) { } @@ -1690,7 +1690,7 @@ ay8930_device::ay8930_device(const machine_config &mconfig, const char *tag, dev DEFINE_DEVICE_TYPE(YM2149, ym2149_device, "ym2149", "YM2149 SSG") -ym2149_device::ym2149_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ym2149_device::ym2149_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay8910_device(mconfig, YM2149, tag, owner, clock, PSG_TYPE_YM, 3, 2, PSG_PIN26_IS_CLKSEL) { } @@ -1698,7 +1698,7 @@ ym2149_device::ym2149_device(const machine_config &mconfig, const char *tag, dev DEFINE_DEVICE_TYPE(YM3439, ym3439_device, "ym3439", "YM3439 SSGC") -ym3439_device::ym3439_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ym3439_device::ym3439_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay8910_device(mconfig, YM3439, tag, owner, clock, PSG_TYPE_YM, 3, 2, PSG_PIN26_IS_CLKSEL) { } @@ -1706,7 +1706,7 @@ ym3439_device::ym3439_device(const machine_config &mconfig, const char *tag, dev DEFINE_DEVICE_TYPE(YMZ284, ymz284_device, "ymz284", "YMZ284 SSGL") -ymz284_device::ymz284_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ymz284_device::ymz284_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay8910_device(mconfig, YMZ284, tag, owner, clock, PSG_TYPE_YM, 1, 0) { } @@ -1714,7 +1714,7 @@ ymz284_device::ymz284_device(const machine_config &mconfig, const char *tag, dev DEFINE_DEVICE_TYPE(YMZ294, ymz294_device, "ymz294", "YMZ294 SSGLP") -ymz294_device::ymz294_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ymz294_device::ymz294_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay8910_device(mconfig, YMZ294, tag, owner, clock, PSG_TYPE_YM, 1, 0) { } @@ -1722,7 +1722,7 @@ ymz294_device::ymz294_device(const machine_config &mconfig, const char *tag, dev DEFINE_DEVICE_TYPE(SUNSOFT_5B_SOUND, sunsoft_5b_sound_device, "sunsoft_5b_sound", "Sunsoft/Yamaha 5B 6630B (Sound)") -sunsoft_5b_sound_device::sunsoft_5b_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sunsoft_5b_sound_device::sunsoft_5b_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ay8910_device(mconfig, SUNSOFT_5B_SOUND, tag, owner, clock, PSG_TYPE_YM, 1, 0, PSG_HAS_INTERNAL_DIVIDER) { } diff --git a/src/devices/sound/ay8910.h b/src/devices/sound/ay8910.h index e17c5e1f367..8e236896c42 100644 --- a/src/devices/sound/ay8910.h +++ b/src/devices/sound/ay8910.h @@ -72,7 +72,7 @@ public: }; // construction/destruction - ay8910_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ay8910_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers void set_flags(int flags) { m_flags = flags; } @@ -109,7 +109,7 @@ public: void write_bc1_bc2(offs_t offset, u8 data); void set_volume(int channel,int volume); - void ay_set_clock(int clock); + void ay_set_clock(const XTAL &clock); struct ay_ym_param { @@ -132,7 +132,7 @@ public: protected: ay8910_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, - u32 clock, psg_type_t psg_type, int streams, int ioports, int feature = PSG_DEFAULT); + const XTAL &clock, psg_type_t psg_type, int streams, int ioports, int feature = PSG_DEFAULT); // device-level overrides virtual void device_start() override; @@ -341,7 +341,7 @@ DECLARE_DEVICE_TYPE(AY8910, ay8910_device) class ay8912_device : public ay8910_device { public: - ay8912_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ay8912_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(AY8912, ay8912_device) @@ -349,7 +349,7 @@ DECLARE_DEVICE_TYPE(AY8912, ay8912_device) class ay8913_device : public ay8910_device { public: - ay8913_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ay8913_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(AY8913, ay8913_device) @@ -357,7 +357,7 @@ DECLARE_DEVICE_TYPE(AY8913, ay8913_device) class ay8914_device : public ay8910_device { public: - ay8914_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ay8914_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // AY8914 handlers needed due to different register map u8 read(offs_t offset); @@ -369,7 +369,7 @@ DECLARE_DEVICE_TYPE(AY8914, ay8914_device) class ay8930_device : public ay8910_device { public: - ay8930_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ay8930_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(AY8930, ay8930_device) @@ -377,7 +377,7 @@ DECLARE_DEVICE_TYPE(AY8930, ay8930_device) class ym2149_device : public ay8910_device { public: - ym2149_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ym2149_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(YM2149, ym2149_device) @@ -385,7 +385,7 @@ DECLARE_DEVICE_TYPE(YM2149, ym2149_device) class ym3439_device : public ay8910_device { public: - ym3439_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ym3439_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(YM3439, ym3439_device) @@ -393,7 +393,7 @@ DECLARE_DEVICE_TYPE(YM3439, ym3439_device) class ymz284_device : public ay8910_device { public: - ymz284_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ymz284_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(YMZ284, ymz284_device) @@ -401,7 +401,7 @@ DECLARE_DEVICE_TYPE(YMZ284, ymz284_device) class ymz294_device : public ay8910_device { public: - ymz294_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ymz294_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(YMZ294, ymz294_device) @@ -409,7 +409,7 @@ DECLARE_DEVICE_TYPE(YMZ294, ymz294_device) class sunsoft_5b_sound_device : public ay8910_device { public: - sunsoft_5b_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sunsoft_5b_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(SUNSOFT_5B_SOUND, sunsoft_5b_sound_device) diff --git a/src/devices/sound/bbd.cpp b/src/devices/sound/bbd.cpp index e270108b04e..ef5433c49ef 100644 --- a/src/devices/sound/bbd.cpp +++ b/src/devices/sound/bbd.cpp @@ -13,7 +13,7 @@ //------------------------------------------------- template<int Entries, int Outputs> -bbd_device_base<Entries, Outputs>::bbd_device_base(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, device_type type) : +bbd_device_base<Entries, Outputs>::bbd_device_base(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, device_type type) : device_t(mconfig, type, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), @@ -37,7 +37,7 @@ void bbd_device_base<Entries, Outputs>::device_start() if (m_cv_handler.isnull()) m_stream = stream_alloc(1, Outputs, sample_rate()); else - m_stream = stream_alloc(1, Outputs, SAMPLE_RATE_OUTPUT_ADAPTIVE, STREAM_DISABLE_INPUT_RESAMPLING); + m_stream = stream_alloc(1, Outputs, XTAL(), STREAM_DISABLE_INPUT_RESAMPLING, SAMPLE_RATE_OUTPUT_ADAPTIVE); save_item(NAME(m_buffer)); save_item(NAME(m_curpos)); @@ -120,7 +120,7 @@ void bbd_device_base<Entries, Outputs>::sound_stream_update(sound_stream &stream // device type definition DEFINE_DEVICE_TYPE(MN3004, mn3004_device, "mn3004", "MN3004 BBD") -mn3004_device::mn3004_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mn3004_device::mn3004_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbd_device_base(mconfig, tag, owner, clock, MN3004) { } @@ -133,7 +133,7 @@ mn3004_device::mn3004_device(const machine_config &mconfig, const char *tag, dev // device type definition DEFINE_DEVICE_TYPE(MN3005, mn3005_device, "mn3005", "MN3005 BBD") -mn3005_device::mn3005_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mn3005_device::mn3005_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbd_device_base(mconfig, tag, owner, clock, MN3005) { } @@ -146,7 +146,7 @@ mn3005_device::mn3005_device(const machine_config &mconfig, const char *tag, dev // device type definition DEFINE_DEVICE_TYPE(MN3006, mn3006_device, "mn3006", "MN3006 BBD") -mn3006_device::mn3006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mn3006_device::mn3006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbd_device_base(mconfig, tag, owner, clock, MN3006) { } @@ -159,7 +159,7 @@ mn3006_device::mn3006_device(const machine_config &mconfig, const char *tag, dev // device type definition DEFINE_DEVICE_TYPE(MN3204P, mn3204p_device, "mn3204p", "MN3204P BBD") -mn3204p_device::mn3204p_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mn3204p_device::mn3204p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bbd_device_base(mconfig, tag, owner, clock, MN3204P) { } diff --git a/src/devices/sound/bbd.h b/src/devices/sound/bbd.h index f9c84b8d6a6..f2d35f397f4 100644 --- a/src/devices/sound/bbd.h +++ b/src/devices/sound/bbd.h @@ -25,7 +25,7 @@ protected: using cv_delegate = device_delegate<attoseconds_t (attotime const &)>; // internal constructor - bbd_device_base(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, device_type type); + bbd_device_base(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, device_type type); // device-level overrides virtual void device_start() override; @@ -37,7 +37,7 @@ protected: protected: // override to convert clock to sample rate stream_buffer::sample_t outputval(s32 index) const { return m_buffer[(m_curpos - index) % std::size(m_buffer)]; } - virtual u32 sample_rate() const { return clock(); } + virtual XTAL sample_rate() const { return clock(); } sound_stream * m_stream; u32 m_curpos; @@ -52,7 +52,7 @@ protected: class mn3004_device : public bbd_device_base<512, 2> { public: - mn3004_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mn3004_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(MN3004, mn3004_device) @@ -63,7 +63,7 @@ DECLARE_DEVICE_TYPE(MN3004, mn3004_device) class mn3005_device : public bbd_device_base<4096, 2> { public: - mn3005_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mn3005_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(MN3005, mn3005_device) @@ -74,7 +74,7 @@ DECLARE_DEVICE_TYPE(MN3005, mn3005_device) class mn3006_device : public bbd_device_base<128, 2> { public: - mn3006_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mn3006_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(MN3006, mn3006_device) @@ -85,7 +85,7 @@ DECLARE_DEVICE_TYPE(MN3006, mn3006_device) class mn3204p_device : public bbd_device_base<512, 2> { public: - mn3204p_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mn3204p_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(MN3204P, mn3204p_device) diff --git a/src/devices/sound/beep.cpp b/src/devices/sound/beep.cpp index 47f4701a662..1aac8ade153 100644 --- a/src/devices/sound/beep.cpp +++ b/src/devices/sound/beep.cpp @@ -20,7 +20,7 @@ // device type definition DEFINE_DEVICE_TYPE(BEEP, beep_device, "beep", "Beep") -beep_device::beep_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +beep_device::beep_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BEEP, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr) diff --git a/src/devices/sound/beep.h b/src/devices/sound/beep.h index 52943d83465..45642b434cd 100644 --- a/src/devices/sound/beep.h +++ b/src/devices/sound/beep.h @@ -21,7 +21,7 @@ class beep_device : public device_t, public device_sound_interface { public: - beep_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + beep_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/sound/bsmt2000.cpp b/src/devices/sound/bsmt2000.cpp index 30b078b6da6..64f9e73d5ba 100644 --- a/src/devices/sound/bsmt2000.cpp +++ b/src/devices/sound/bsmt2000.cpp @@ -61,7 +61,7 @@ ROM_END // bsmt2000_device - constructor //------------------------------------------------- -bsmt2000_device::bsmt2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bsmt2000_device::bsmt2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BSMT2000, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/bsmt2000.h b/src/devices/sound/bsmt2000.h index 771ad8f3c64..e81b6f87ca7 100644 --- a/src/devices/sound/bsmt2000.h +++ b/src/devices/sound/bsmt2000.h @@ -32,7 +32,7 @@ public: typedef device_delegate<void ()> ready_callback; // construction/destruction - bsmt2000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bsmt2000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration helpers template <typename... T> void set_ready_callback(T &&... args) { m_ready_callback.set(std::forward<T>(args)...); } diff --git a/src/devices/sound/c140.cpp b/src/devices/sound/c140.cpp index d723e124e35..e785a2f2a17 100644 --- a/src/devices/sound/c140.cpp +++ b/src/devices/sound/c140.cpp @@ -81,12 +81,12 @@ DEFINE_DEVICE_TYPE(C219, c219_device, "c219", "Namco C219") // c140_device - constructor //------------------------------------------------- -c140_device::c140_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c140_device::c140_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c140_device(mconfig, C140, tag, owner, clock) { } -c140_device::c140_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +c140_device::c140_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) @@ -101,7 +101,7 @@ c140_device::c140_device(const machine_config &mconfig, device_type type, const std::fill(std::begin(m_pcmtbl), std::end(m_pcmtbl), 0); } -c219_device::c219_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c219_device::c219_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : c140_device(mconfig, C219, tag, owner, clock) { // TODO: unknown address bus bits diff --git a/src/devices/sound/c140.h b/src/devices/sound/c140.h index 918f5dae31a..7f8a0a00040 100644 --- a/src/devices/sound/c140.h +++ b/src/devices/sound/c140.h @@ -22,7 +22,7 @@ class c140_device : public device_t, public device_rom_interface<25, 1, 0, ENDIANNESS_BIG> { public: - c140_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c140_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration auto int1_callback() { return m_int1_callback.bind(); } @@ -35,7 +35,7 @@ public: void c140_le_w(offs_t offset, u8 data) { c140_w(offset ^ 1, data);} protected: - c140_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + c140_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -104,7 +104,7 @@ protected: class c219_device : public c140_device { public: - c219_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c219_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 c219_r(offs_t offset); void c219_w(offs_t offset, u8 data); diff --git a/src/devices/sound/c352.cpp b/src/devices/sound/c352.cpp index dcbd58f3eb3..52925f0fe05 100644 --- a/src/devices/sound/c352.cpp +++ b/src/devices/sound/c352.cpp @@ -41,7 +41,7 @@ DEFINE_DEVICE_TYPE(C352, c352_device, "c352", "Namco C352") // c352_device - constructor //------------------------------------------------- -c352_device::c352_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +c352_device::c352_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C352, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/c352.h b/src/devices/sound/c352.h index cf333ba356e..f0e9b896a97 100644 --- a/src/devices/sound/c352.h +++ b/src/devices/sound/c352.h @@ -19,13 +19,13 @@ class c352_device : public device_t, { public: // construction/destruction - c352_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, int divider) + c352_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, int divider) : c352_device(mconfig, tag, owner, clock) { set_divider(divider); } - c352_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + c352_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_divider(int divider) { m_divider = divider; } diff --git a/src/devices/sound/c6280.cpp b/src/devices/sound/c6280.cpp index 644269e01f7..cfeb4292583 100644 --- a/src/devices/sound/c6280.cpp +++ b/src/devices/sound/c6280.cpp @@ -292,7 +292,7 @@ void c6280_device::c6280_w(offs_t offset, uint8_t data) DEFINE_DEVICE_TYPE(C6280, c6280_device, "c6280", "Hudson Soft HuC6280 PSG") -c6280_device::c6280_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +c6280_device::c6280_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, C6280, tag, owner, clock) , device_sound_interface(mconfig, *this) { diff --git a/src/devices/sound/c6280.h b/src/devices/sound/c6280.h index 60ea993f71b..08df35de323 100644 --- a/src/devices/sound/c6280.h +++ b/src/devices/sound/c6280.h @@ -10,7 +10,7 @@ class c6280_device : public device_t, public device_sound_interface public: static constexpr feature_type imperfect_features() { return feature::SOUND; } // Incorrect / Not verified noise / LFO output - c6280_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + c6280_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // write only void c6280_w(offs_t offset, uint8_t data); diff --git a/src/devices/sound/cdda.cpp b/src/devices/sound/cdda.cpp index 38a4c4736cc..e2f58b00fd5 100644 --- a/src/devices/sound/cdda.cpp +++ b/src/devices/sound/cdda.cpp @@ -233,7 +233,7 @@ int16_t cdda_device::get_channel_volume(int channel) DEFINE_DEVICE_TYPE(CDDA, cdda_device, "cdda", "CD/DA") -cdda_device::cdda_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cdda_device::cdda_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDDA, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_disc(nullptr) diff --git a/src/devices/sound/cdda.h b/src/devices/sound/cdda.h index b0c7b7f81e8..b6f36c9b3c1 100644 --- a/src/devices/sound/cdda.h +++ b/src/devices/sound/cdda.h @@ -11,7 +11,7 @@ class cdda_device : public device_t, public device_sound_interface { public: - cdda_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 44'100); + cdda_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(44'100)); void set_cdrom(void *file); diff --git a/src/devices/sound/cdp1863.cpp b/src/devices/sound/cdp1863.cpp index da9194b9a7e..b63d3397fe6 100644 --- a/src/devices/sound/cdp1863.cpp +++ b/src/devices/sound/cdp1863.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(CDP1863, cdp1863_device, "cdp1863", "RCA CDP1863") // cdp1863_device - constructor //------------------------------------------------- -cdp1863_device::cdp1863_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cdp1863_device::cdp1863_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDP1863, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr) diff --git a/src/devices/sound/cdp1863.h b/src/devices/sound/cdp1863.h index ec0706e9a7c..8090705a5e4 100644 --- a/src/devices/sound/cdp1863.h +++ b/src/devices/sound/cdp1863.h @@ -36,7 +36,7 @@ class cdp1863_device : public device_t, { public: // construction/destruction - cdp1863_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1863_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration helpers void set_clock2(int clock2) { m_clock2 = clock2; } diff --git a/src/devices/sound/cdp1864.cpp b/src/devices/sound/cdp1864.cpp index a3e8f5c037f..642925b4311 100644 --- a/src/devices/sound/cdp1864.cpp +++ b/src/devices/sound/cdp1864.cpp @@ -58,7 +58,7 @@ DEFINE_DEVICE_TYPE(CDP1864, cdp1864_device, "cdp1864", "RCA CDP1864") // cdp1864_device - constructor //------------------------------------------------- -cdp1864_device::cdp1864_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cdp1864_device::cdp1864_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDP1864, tag, owner, clock), device_sound_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/sound/cdp1864.h b/src/devices/sound/cdp1864.h index 8dc1eb04e8e..9da7d1a1604 100644 --- a/src/devices/sound/cdp1864.h +++ b/src/devices/sound/cdp1864.h @@ -80,7 +80,7 @@ public: static constexpr unsigned SCANLINE_EFX_BOTTOM_END = SCANLINE_DISPLAY_END; // construction/destruction - cdp1864_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1864_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto inlace_cb() { return m_read_inlace.bind(); } auto int_cb() { return m_write_int.bind(); } diff --git a/src/devices/sound/cdp1869.cpp b/src/devices/sound/cdp1869.cpp index 70e4718f212..179e7d99a03 100644 --- a/src/devices/sound/cdp1869.cpp +++ b/src/devices/sound/cdp1869.cpp @@ -350,7 +350,7 @@ int cdp1869_device::get_pen(int ccb0, int ccb1, int pcb) // cdp1869_device - constructor //------------------------------------------------- -cdp1869_device::cdp1869_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cdp1869_device::cdp1869_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDP1869, tag, owner, clock), device_sound_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/sound/cdp1869.h b/src/devices/sound/cdp1869.h index 6ce373a6931..94a8856a5e8 100644 --- a/src/devices/sound/cdp1869.h +++ b/src/devices/sound/cdp1869.h @@ -147,12 +147,12 @@ public: // construction/destruction template <typename T> - cdp1869_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&addrmap) + cdp1869_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&addrmap) : cdp1869_device(mconfig, tag, owner, clock) { set_addrmap(0, std::forward<T>(addrmap)); } - cdp1869_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1869_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto pal_ntsc_callback() { return m_read_pal_ntsc.bind(); } auto prd_callback() { return m_write_prd.bind(); } diff --git a/src/devices/sound/cem3394.cpp b/src/devices/sound/cem3394.cpp index 0a4ba228827..fc27e3b902a 100644 --- a/src/devices/sound/cem3394.cpp +++ b/src/devices/sound/cem3394.cpp @@ -129,7 +129,7 @@ DEFINE_DEVICE_TYPE(CEM3394, cem3394_device, "cem3394", "CEM3394 Synthesizer Voic // cem3394_device - constructor //------------------------------------------------- -cem3394_device::cem3394_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +cem3394_device::cem3394_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CEM3394, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/cem3394.h b/src/devices/sound/cem3394.h index a3e5e3a85ea..2a2262f6de4 100644 --- a/src/devices/sound/cem3394.h +++ b/src/devices/sound/cem3394.h @@ -22,7 +22,7 @@ public: FINAL_GAIN }; - cem3394_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + cem3394_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_vco_zero_freq(double freq) { m_vco_zero_freq = freq; } void set_filter_zero_freq(double freq) { m_filter_zero_freq = freq; } diff --git a/src/devices/sound/dac.cpp b/src/devices/sound/dac.cpp index 7305f2c12a7..ee35c6d60a9 100644 --- a/src/devices/sound/dac.cpp +++ b/src/devices/sound/dac.cpp @@ -65,7 +65,7 @@ stream_buffer::sample_t dac_mapper_ones_complement(u32 input, u8 bits) // dac_device_base - constructor //------------------------------------------------- -dac_device_base::dac_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, u8 bits, dac_mapper_callback mapper, stream_buffer::sample_t gain) : +dac_device_base::dac_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 bits, dac_mapper_callback mapper, stream_buffer::sample_t gain) : device_t(mconfig, type, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/dac.h b/src/devices/sound/dac.h index e0b4fb01cf9..246c78044b4 100644 --- a/src/devices/sound/dac.h +++ b/src/devices/sound/dac.h @@ -82,7 +82,7 @@ class dac_device_base : public device_t, public device_sound_interface { protected: // constructor - dac_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, u8 bits, dac_mapper_callback mapper, stream_buffer::sample_t gain); + dac_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 bits, dac_mapper_callback mapper, stream_buffer::sample_t gain); // device startup virtual void device_start() override; @@ -128,7 +128,7 @@ private: class dac_bit_device_base : public dac_device_base, public dac_bit_interface { protected: - dac_bit_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 bits, dac_mapper_callback mapper, stream_buffer::sample_t gain) : + dac_bit_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 bits, dac_mapper_callback mapper, stream_buffer::sample_t gain) : dac_device_base(mconfig, type, tag, owner, clock, bits, mapper, gain) { } @@ -144,7 +144,7 @@ public: class dac_byte_device_base : public dac_device_base, public dac_byte_interface { protected: - dac_byte_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 bits, dac_mapper_callback mapper, stream_buffer::sample_t gain) : + dac_byte_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 bits, dac_mapper_callback mapper, stream_buffer::sample_t gain) : dac_device_base(mconfig, type, tag, owner, clock, bits, mapper, gain) { } @@ -160,7 +160,7 @@ public: class dac_word_device_base : public dac_device_base, public dac_word_interface { protected: - dac_word_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 bits, dac_mapper_callback mapper, stream_buffer::sample_t gain) : + dac_word_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 bits, dac_mapper_callback mapper, stream_buffer::sample_t gain) : dac_device_base(mconfig, type, tag, owner, clock, bits, mapper, gain) { } @@ -186,7 +186,7 @@ DECLARE_DEVICE_TYPE(_dac_type, _dac_class) \ class _dac_class : public _dac_base_class \ {\ public: \ - _dac_class(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0) : \ + _dac_class(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()) : \ _dac_base_class(mconfig, _dac_type, tag, owner, clock, _dac_bits, _dac_mapper, _dac_gain) {} \ }; \ DAC_GENERATOR_EPILOG(_dac_type, _dac_class, _dac_description, _dac_shortname) diff --git a/src/devices/sound/dac76.cpp b/src/devices/sound/dac76.cpp index 1c73d7b02c1..16baaff2e46 100644 --- a/src/devices/sound/dac76.cpp +++ b/src/devices/sound/dac76.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(DAC76, dac76_device, "dac76", "PMI DAC-76 COMDAC") // dac76_device - constructor //------------------------------------------------- -dac76_device::dac76_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +dac76_device::dac76_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DAC76, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/dac76.h b/src/devices/sound/dac76.h index 7f3cd1a52fd..5c2e7adc5a3 100644 --- a/src/devices/sound/dac76.h +++ b/src/devices/sound/dac76.h @@ -34,7 +34,7 @@ class dac76_device : public device_t, public device_sound_interface { public: // construction/destruction - dac76_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dac76_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // chord DECLARE_WRITE_LINE_MEMBER(b1_w) { m_chord &= ~(1 << 2); m_chord |= (state << 2); } diff --git a/src/devices/sound/dave.cpp b/src/devices/sound/dave.cpp index 44719ab4584..fa8916ef8aa 100644 --- a/src/devices/sound/dave.cpp +++ b/src/devices/sound/dave.cpp @@ -57,7 +57,7 @@ void dave_device::io_map(address_map &map) // dave_device - constructor //------------------------------------------------- -dave_device::dave_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dave_device::dave_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DAVE, tag, owner, clock), device_memory_interface(mconfig, *this), device_sound_interface(mconfig, *this), diff --git a/src/devices/sound/dave.h b/src/devices/sound/dave.h index 82c024f748e..8a9340ec7e1 100644 --- a/src/devices/sound/dave.h +++ b/src/devices/sound/dave.h @@ -23,7 +23,7 @@ class dave_device : public device_t, public device_sound_interface { public: - dave_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dave_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_wr() { return m_write_irq.bind(); } auto lh_wr() { return m_write_lh.bind(); } diff --git a/src/devices/sound/digitalk.cpp b/src/devices/sound/digitalk.cpp index 2bff98478e5..94e8eefc455 100644 --- a/src/devices/sound/digitalk.cpp +++ b/src/devices/sound/digitalk.cpp @@ -263,7 +263,7 @@ static constexpr int pitch_vals[32] = { DEFINE_DEVICE_TYPE(DIGITALKER, digitalker_device, "digitalker", "MM54104 Digitalker") -digitalker_device::digitalker_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +digitalker_device::digitalker_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DIGITALKER, tag, owner, clock), device_sound_interface(mconfig, *this), m_rom(*this, DEVICE_SELF), diff --git a/src/devices/sound/digitalk.h b/src/devices/sound/digitalk.h index 18cc32fd3bd..ece8a38a201 100644 --- a/src/devices/sound/digitalk.h +++ b/src/devices/sound/digitalk.h @@ -15,7 +15,7 @@ class digitalker_device : public device_t, public device_sound_interface { public: - digitalker_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + digitalker_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void digitalker_0_cs_w(int line); void digitalker_0_cms_w(int line); diff --git a/src/devices/sound/discrete.cpp b/src/devices/sound/discrete.cpp index 8568c647657..1b5fa493e3d 100644 --- a/src/devices/sound/discrete.cpp +++ b/src/devices/sound/discrete.cpp @@ -810,7 +810,7 @@ int discrete_device::same_module_index(const discrete_base_node &node) // discrete_device - constructor //------------------------------------------------- -discrete_device::discrete_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +discrete_device::discrete_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_intf(nullptr), m_sample_rate(0), @@ -825,7 +825,7 @@ discrete_device::discrete_device(const machine_config &mconfig, device_type type { } -discrete_sound_device::discrete_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +discrete_sound_device::discrete_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : discrete_device(mconfig, DISCRETE, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr) diff --git a/src/devices/sound/discrete.h b/src/devices/sound/discrete.h index eebc4936df7..6b55107fe74 100644 --- a/src/devices/sound/discrete.h +++ b/src/devices/sound/discrete.h @@ -4180,7 +4180,7 @@ class discrete_device : public device_t { protected: // construction/destruction - discrete_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + discrete_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); public: typedef std::vector<std::unique_ptr<discrete_task> > task_list_t; @@ -4280,17 +4280,17 @@ class discrete_sound_device : public discrete_device, { public: // construction/destruction - discrete_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, const discrete_block *intf) + discrete_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, const discrete_block *intf) : discrete_sound_device(mconfig, tag, owner, clock) { set_intf(intf); } discrete_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const discrete_block *intf) - : discrete_sound_device(mconfig, tag, owner, uint32_t(0)) + : discrete_sound_device(mconfig, tag, owner) { set_intf(intf); } - discrete_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + discrete_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~discrete_sound_device() { } /* --------------------------------- */ diff --git a/src/devices/sound/dmadac.cpp b/src/devices/sound/dmadac.cpp index ae2ebce61ad..40ed75cd132 100644 --- a/src/devices/sound/dmadac.cpp +++ b/src/devices/sound/dmadac.cpp @@ -163,7 +163,7 @@ void dmadac_sound_device::set_volume(uint16_t volume) DEFINE_DEVICE_TYPE(DMADAC, dmadac_sound_device, "dmadac", "DMA-driven DAC") -dmadac_sound_device::dmadac_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmadac_sound_device::dmadac_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DMADAC, tag, owner, clock), device_sound_interface(mconfig, *this), m_buffer(BUFFER_SIZE), diff --git a/src/devices/sound/dmadac.h b/src/devices/sound/dmadac.h index 6cbe8312231..a7904e5f50b 100644 --- a/src/devices/sound/dmadac.h +++ b/src/devices/sound/dmadac.h @@ -16,7 +16,7 @@ class dmadac_sound_device : public device_t, public device_sound_interface { public: - dmadac_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + dmadac_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void initialize_state(); void flush(); diff --git a/src/devices/sound/dspv.cpp b/src/devices/sound/dspv.cpp index cf14ead15d3..86f88bb56f3 100644 --- a/src/devices/sound/dspv.cpp +++ b/src/devices/sound/dspv.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(DSPV, dspv_device, "dspv", "Yamaha DSPV audio simulation DSP (YSS217-F/") -dspv_device::dspv_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dspv_device::dspv_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cpu_device(mconfig, DSPV, tag, owner, clock), device_sound_interface(mconfig, *this), m_program_config("program", ENDIANNESS_BIG, 16, 16, -1, address_map_constructor(FUNC(dspv_device::prg_map), this)), diff --git a/src/devices/sound/dspv.h b/src/devices/sound/dspv.h index fb68acda569..a1d16c9222f 100644 --- a/src/devices/sound/dspv.h +++ b/src/devices/sound/dspv.h @@ -13,7 +13,7 @@ class dspv_device : public cpu_device, public device_sound_interface { public: - dspv_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 22579200); + dspv_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = 22579200); void map(address_map &map); diff --git a/src/devices/sound/es1373.cpp b/src/devices/sound/es1373.cpp index d254527b0bc..ccdf4903fc9 100644 --- a/src/devices/sound/es1373.cpp +++ b/src/devices/sound/es1373.cpp @@ -84,7 +84,7 @@ void es1373_device::map(address_map &map) map(0x00, 0x3f).rw(FUNC(es1373_device::reg_r), FUNC(es1373_device::reg_w)); } -es1373_device::es1373_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +es1373_device::es1373_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, ES1373, tag, owner, clock) , device_sound_interface(mconfig, *this), m_stream(nullptr) , m_eslog(nullptr), m_tempCount(0), m_timer(nullptr), m_memory_space(nullptr), m_irq_handler(*this) diff --git a/src/devices/sound/es1373.h b/src/devices/sound/es1373.h index 6d493391ae4..13b8159247f 100644 --- a/src/devices/sound/es1373.h +++ b/src/devices/sound/es1373.h @@ -11,7 +11,7 @@ class es1373_device : public pci_device, public device_sound_interface { public: - es1373_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + es1373_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map_extra(uint64_t memory_window_start, uint64_t memory_window_end, uint64_t memory_offset, address_space *memory_space, uint64_t io_window_start, uint64_t io_window_end, uint64_t io_offset, address_space *io_space) override; diff --git a/src/devices/sound/es5503.cpp b/src/devices/sound/es5503.cpp index f460050df66..3d3fa530a0e 100644 --- a/src/devices/sound/es5503.cpp +++ b/src/devices/sound/es5503.cpp @@ -57,7 +57,7 @@ static constexpr int resshifts[8] = { 9, 10, 11, 12, 13, 14, 15, 16 }; // es5503_device - constructor //------------------------------------------------- -es5503_device::es5503_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +es5503_device::es5503_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ES5503, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this), diff --git a/src/devices/sound/es5503.h b/src/devices/sound/es5503.h index 4499d58d1f3..fc8063ddd3d 100644 --- a/src/devices/sound/es5503.h +++ b/src/devices/sound/es5503.h @@ -15,7 +15,7 @@ class es5503_device : public device_t, { public: // construction/destruction - es5503_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + es5503_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // channels must be a power of two void set_channels(int channels) { output_channels = channels; } diff --git a/src/devices/sound/es5506.cpp b/src/devices/sound/es5506.cpp index 3ea90a97261..c4197f1c9ff 100644 --- a/src/devices/sound/es5506.cpp +++ b/src/devices/sound/es5506.cpp @@ -146,7 +146,7 @@ enum : u16 { } -es550x_device::es550x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +es550x_device::es550x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_memory_interface(mconfig, *this) @@ -178,7 +178,7 @@ es550x_device::es550x_device(const machine_config &mconfig, device_type type, co DEFINE_DEVICE_TYPE(ES5506, es5506_device, "es5506", "Ensoniq ES5506") -es5506_device::es5506_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +es5506_device::es5506_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : es550x_device(mconfig, ES5506, tag, owner, clock) , m_bank0_config("bank0", ENDIANNESS_BIG, 16, 21, -1) // 21 bit address bus, word addressing only , m_bank1_config("bank1", ENDIANNESS_BIG, 16, 21, -1) @@ -348,7 +348,7 @@ device_memory_interface::space_config_vector es5506_device::memory_space_config( DEFINE_DEVICE_TYPE(ES5505, es5505_device, "es5505", "Ensoniq ES5505") -es5505_device::es5505_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +es5505_device::es5505_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : es550x_device(mconfig, ES5505, tag, owner, clock) , m_bank0_config("bank0", ENDIANNESS_BIG, 16, 20, -1) // 20 bit address bus, word addressing only , m_bank1_config("bank1", ENDIANNESS_BIG, 16, 20, -1) diff --git a/src/devices/sound/es5506.h b/src/devices/sound/es5506.h index 73f5c0a3c8f..3305afc5abe 100644 --- a/src/devices/sound/es5506.h +++ b/src/devices/sound/es5506.h @@ -75,7 +75,7 @@ protected: u8 filtcount = 0; // filter count }; - es550x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + es550x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -159,7 +159,7 @@ protected: class es5506_device : public es550x_device { public: - es5506_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + es5506_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~es5506_device() {} u8 read(offs_t offset); @@ -217,7 +217,7 @@ DECLARE_DEVICE_TYPE(ES5506, es5506_device) class es5505_device : public es550x_device { public: - es5505_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + es5505_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u16 read(offs_t offset); void write(offs_t offset, u16 data, u16 mem_mask = ~0); diff --git a/src/devices/sound/es8712.cpp b/src/devices/sound/es8712.cpp index 5cddf18cc7e..a9ef9e922b1 100644 --- a/src/devices/sound/es8712.cpp +++ b/src/devices/sound/es8712.cpp @@ -37,7 +37,7 @@ DEFINE_DEVICE_TYPE(ES8712, es8712_device, "es8712", "Excellent Systems ES8712 So // es8712_device - constructor //------------------------------------------------- -es8712_device::es8712_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +es8712_device::es8712_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ES8712, tag, owner, clock) , device_rom_interface(mconfig, *this) , m_adpcm_select(*this, "adpcm_select") @@ -59,7 +59,7 @@ es8712_device::es8712_device(const machine_config &mconfig, const char *tag, dev void es8712_device::device_add_mconfig(machine_config &config) { - HCT157(config, m_adpcm_select, 0); // TODO : gcpinbal case, differs per games? + HCT157(config, m_adpcm_select); // TODO : gcpinbal case, differs per games? m_adpcm_select->out_callback().set(FUNC(es8712_device::msm_w)); } diff --git a/src/devices/sound/es8712.h b/src/devices/sound/es8712.h index 27fc5bab853..b5fb2193431 100644 --- a/src/devices/sound/es8712.h +++ b/src/devices/sound/es8712.h @@ -21,7 +21,7 @@ class es8712_device : public device_t, public device_rom_interface<20> // TODO : 20 address bits? { public: - es8712_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + es8712_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration template <typename T> void set_msm_tag(T &&tag) { m_msm.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/sound/esqpump.cpp b/src/devices/sound/esqpump.cpp index 38b95a15bed..21486d82b7f 100644 --- a/src/devices/sound/esqpump.cpp +++ b/src/devices/sound/esqpump.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(ESQ_5505_5510_PUMP, esq_5505_5510_pump_device, "esq_5505_5510_pump", "Ensoniq 5505/5506 to 5510 interface") -esq_5505_5510_pump_device::esq_5505_5510_pump_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +esq_5505_5510_pump_device::esq_5505_5510_pump_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ESQ_5505_5510_PUMP, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr) diff --git a/src/devices/sound/esqpump.h b/src/devices/sound/esqpump.h index 897475cd8b4..51f7e378c9e 100644 --- a/src/devices/sound/esqpump.h +++ b/src/devices/sound/esqpump.h @@ -18,7 +18,7 @@ class esq_5505_5510_pump_device : public device_t, public device_sound_interface public: static constexpr feature_type imperfect_features() { return feature::SOUND; } - esq_5505_5510_pump_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + esq_5505_5510_pump_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_esp(T &&tag) { m_esp.set_tag(std::forward<T>(tag)); } void set_esp_halted(bool esp_halted) { diff --git a/src/devices/sound/flt_biquad.cpp b/src/devices/sound/flt_biquad.cpp index 6ae1bde0109..cc7ff2e002d 100644 --- a/src/devices/sound/flt_biquad.cpp +++ b/src/devices/sound/flt_biquad.cpp @@ -46,7 +46,7 @@ ALLOW_SAVE_TYPE(filter_biquad_device::biquad_type); //------------------------------------------------- // initialize with some sane defaults for a highpass filter with a cutoff at 16hz, same as flt_rc's 'ac' mode. -filter_biquad_device::filter_biquad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +filter_biquad_device::filter_biquad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, FILTER_BIQUAD, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/flt_biquad.h b/src/devices/sound/flt_biquad.h index e565aa6da8a..20e5ffd8364 100644 --- a/src/devices/sound/flt_biquad.h +++ b/src/devices/sound/flt_biquad.h @@ -36,7 +36,7 @@ public: double gain; }; - filter_biquad_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + filter_biquad_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // set up the filter with the specified filter parameters and return a pointer to the new device filter_biquad_device& setup(biquad_type type, double fc, double q, double gain); diff --git a/src/devices/sound/flt_rc.cpp b/src/devices/sound/flt_rc.cpp index 489cb01fb07..8dfd97ba43f 100644 --- a/src/devices/sound/flt_rc.cpp +++ b/src/devices/sound/flt_rc.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(FILTER_RC, filter_rc_device, "filter_rc", "RC Filter") // filter_rc_device - constructor //------------------------------------------------- -filter_rc_device::filter_rc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +filter_rc_device::filter_rc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, FILTER_RC, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/flt_rc.h b/src/devices/sound/flt_rc.h index def09f1eb11..30df14ee8aa 100644 --- a/src/devices/sound/flt_rc.h +++ b/src/devices/sound/flt_rc.h @@ -44,7 +44,7 @@ * (10KOhm R, 1uF C) * This filter may be setup just with * - * FILTER_RC(config, "tag", 0).set_ac(); + * FILTER_RC(config, "tag").set_ac(); * * Default behaviour: * @@ -69,7 +69,7 @@ public: AC = 4 }; - filter_rc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + filter_rc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration filter_rc_device &set_rc(int type, double R1, double R2, double R3, double C) diff --git a/src/devices/sound/flt_vol.cpp b/src/devices/sound/flt_vol.cpp index 6e63fa1ae1b..fc57255a417 100644 --- a/src/devices/sound/flt_vol.cpp +++ b/src/devices/sound/flt_vol.cpp @@ -11,7 +11,7 @@ DEFINE_DEVICE_TYPE(FILTER_VOLUME, filter_volume_device, "filter_volume", "Volume // filter_volume_device - constructor //------------------------------------------------- -filter_volume_device::filter_volume_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +filter_volume_device::filter_volume_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, FILTER_VOLUME, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/flt_vol.h b/src/devices/sound/flt_vol.h index 022a980a6a5..021271809bd 100644 --- a/src/devices/sound/flt_vol.h +++ b/src/devices/sound/flt_vol.h @@ -15,7 +15,7 @@ class filter_volume_device : public device_t, public device_sound_interface { public: - filter_volume_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + filter_volume_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void flt_volume_set_volume(float volume); diff --git a/src/devices/sound/gaelco.cpp b/src/devices/sound/gaelco.cpp index 39a14d6487f..19439718587 100644 --- a/src/devices/sound/gaelco.cpp +++ b/src/devices/sound/gaelco.cpp @@ -57,12 +57,12 @@ static util::wav_file_ptr wavraw; // Raw waveform DEFINE_DEVICE_TYPE(GAELCO_GAE1, gaelco_gae1_device, "gaelco_gae1", "Gaelco GAE1") -gaelco_gae1_device::gaelco_gae1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gaelco_gae1_device::gaelco_gae1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gaelco_gae1_device(mconfig, GAELCO_GAE1, tag, owner, clock) { } -gaelco_gae1_device::gaelco_gae1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gaelco_gae1_device::gaelco_gae1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) @@ -339,7 +339,7 @@ void gaelco_gae1_device::rom_bank_pre_change() DEFINE_DEVICE_TYPE(GAELCO_CG1V, gaelco_cg1v_device, "gaelco_cg1v", "Gaelco CG1V") -gaelco_cg1v_device::gaelco_cg1v_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gaelco_cg1v_device::gaelco_cg1v_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gaelco_gae1_device(mconfig, GAELCO_CG1V, tag, owner, clock) { } diff --git a/src/devices/sound/gaelco.h b/src/devices/sound/gaelco.h index 3bfac39f988..6c663cc92f0 100644 --- a/src/devices/sound/gaelco.h +++ b/src/devices/sound/gaelco.h @@ -19,7 +19,7 @@ class gaelco_gae1_device : public device_t, public device_rom_interface<27> // Unknown address bits { public: - gaelco_gae1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + gaelco_gae1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_bank_offsets(int offs1, int offs2, int offs3, int offs4) { @@ -33,7 +33,7 @@ public: uint16_t gaelcosnd_r(offs_t offset); protected: - gaelco_gae1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gaelco_gae1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -81,7 +81,7 @@ DECLARE_DEVICE_TYPE(GAELCO_GAE1, gaelco_gae1_device) class gaelco_cg1v_device : public gaelco_gae1_device { public: - gaelco_cg1v_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + gaelco_cg1v_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; DECLARE_DEVICE_TYPE(GAELCO_CG1V, gaelco_cg1v_device) diff --git a/src/devices/sound/gb.cpp b/src/devices/sound/gb.cpp index 643ecf9ec68..de319513f7f 100644 --- a/src/devices/sound/gb.cpp +++ b/src/devices/sound/gb.cpp @@ -84,20 +84,20 @@ DEFINE_DEVICE_TYPE(CGB04_APU, cgb04_apu_device, "cgb04_apu", "CGB04 APU") // gameboy_sound_device - constructor //------------------------------------------------- -gameboy_sound_device::gameboy_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +gameboy_sound_device::gameboy_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) { } -dmg_apu_device::dmg_apu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmg_apu_device::dmg_apu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gameboy_sound_device(mconfig, DMG_APU, tag, owner, clock) { } -cgb04_apu_device::cgb04_apu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cgb04_apu_device::cgb04_apu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : gameboy_sound_device(mconfig, CGB04_APU, tag, owner, clock) { } diff --git a/src/devices/sound/gb.h b/src/devices/sound/gb.h index 162672f0287..bdcac58a1eb 100644 --- a/src/devices/sound/gb.h +++ b/src/devices/sound/gb.h @@ -9,7 +9,7 @@ class gameboy_sound_device : public device_t, public device_sound_interface { public: - gameboy_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gameboy_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 sound_r(offs_t offset); virtual u8 wave_r(offs_t offset) = 0; @@ -17,7 +17,7 @@ public: virtual void wave_w(offs_t offset, u8 data) = 0; protected: - gameboy_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + gameboy_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -164,7 +164,7 @@ protected: class dmg_apu_device : public gameboy_sound_device { public: - dmg_apu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmg_apu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 wave_r(offs_t offset) override; virtual void wave_w(offs_t offset, u8 data) override; @@ -180,7 +180,7 @@ protected: class cgb04_apu_device : public gameboy_sound_device { public: - cgb04_apu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cgb04_apu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual u8 wave_r(offs_t offset) override; virtual void wave_w(offs_t offset, u8 data) override; diff --git a/src/devices/sound/hc55516.cpp b/src/devices/sound/hc55516.cpp index ab4497a4a93..a1dc4568cc0 100644 --- a/src/devices/sound/hc55516.cpp +++ b/src/devices/sound/hc55516.cpp @@ -36,7 +36,7 @@ //##################################### // COMMON //##################################### -cvsd_device_base::cvsd_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool active_clock_edge, uint8_t shiftreg_mask) +cvsd_device_base::cvsd_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool active_clock_edge, uint8_t shiftreg_mask) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_clock_state_push_cb(*this) @@ -215,13 +215,13 @@ void cvsd_device_base::sound_stream_update(sound_stream &stream, std::vector<rea //######################################### DEFINE_DEVICE_TYPE(HC55516, hc55516_device, "hc55516", "HC-55516") -hc55516_device::hc55516_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hc55516_device::hc55516_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hc55516_device(mconfig, HC55516, tag, owner, clock, 0xfc0, 6, 0xfc1, 4) { } // overridable type for hc55532 etc -hc55516_device::hc55516_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t sylmask, int32_t sylshift, int32_t syladd, int32_t intshift) +hc55516_device::hc55516_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t sylmask, int32_t sylshift, int32_t syladd, int32_t intshift) : cvsd_device_base(mconfig, type, tag, owner, clock, RISING, 0x7) , m_agc_push_cb(*this) , m_fzq_pull_cb(*this) @@ -414,7 +414,7 @@ void hc55516_device::sound_stream_update(sound_stream &stream, std::vector<read_ //######################################### DEFINE_DEVICE_TYPE(HC55532, hc55532_device, "hc55532", "HC-55532") -hc55532_device::hc55532_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hc55532_device::hc55532_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hc55516_device(mconfig, HC55532, tag, owner, clock, 0xf80, 7, 0xfe1, 5) { } @@ -440,13 +440,13 @@ void hc55532_device::device_reset() //########################################## DEFINE_DEVICE_TYPE(MC3417, mc3417_device, "mc3417", "MC3417") -mc3417_device::mc3417_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc3417_device::mc3417_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc3417_device(mconfig, MC3417, tag, owner, clock, 0x7) { } // overridable type for mc3418 etc -mc3417_device::mc3417_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t shiftreg_mask) +mc3417_device::mc3417_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t shiftreg_mask) : cvsd_device_base(mconfig, type, tag, owner, clock, FALLING, shiftreg_mask) , m_charge(pow(exp(-1.0), 1.0 / (FILTER_CHARGE_TC * 16000.0))) , m_decay(pow(exp(-1.0), 1.0 / (FILTER_DECAY_TC * 16000.0))) @@ -561,7 +561,7 @@ void mc3417_device::sound_stream_update(sound_stream &stream, std::vector<read_s //########################################## DEFINE_DEVICE_TYPE(MC3418, mc3418_device, "mc3418", "MC3418") -mc3418_device::mc3418_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc3418_device::mc3418_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc3417_device(mconfig, MC3418, tag, owner, clock, 0xf) { } diff --git a/src/devices/sound/hc55516.h b/src/devices/sound/hc55516.h index 8f06ba55a28..3e93898555e 100644 --- a/src/devices/sound/hc55516.h +++ b/src/devices/sound/hc55516.h @@ -66,7 +66,7 @@ public: virtual int clock_state_r(); protected: - cvsd_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool active_clock_edge, uint8_t shiftreg_mask); + cvsd_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool active_clock_edge, uint8_t shiftreg_mask); // device-level overrides virtual void device_start() override; @@ -108,7 +108,7 @@ protected: class hc55516_device : public cvsd_device_base { public: - hc55516_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hc55516_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // /FZ (partial reset) pull callback, ok to leave unconnected (we assume it is pulled high) auto fzq_cb() { return m_fzq_pull_cb.bind(); } @@ -124,7 +124,7 @@ public: protected: // overridable type for subclass - hc55516_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t sylmask, int32_t sylshift, int32_t syladd, int32_t intshift); + hc55516_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t sylmask, int32_t sylshift, int32_t syladd, int32_t intshift); // device-level overrides virtual void device_start() override; @@ -157,7 +157,7 @@ protected: class hc55532_device : public hc55516_device { public: - hc55532_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hc55532_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides virtual void device_reset() override; @@ -167,14 +167,14 @@ protected: class mc3417_device : public cvsd_device_base { public: - mc3417_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc3417_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // override for clock_w //virtual void clock_w(int state) override; protected: // overridable type for subclass - mc3417_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint8_t shiftreg_mask); + mc3417_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint8_t shiftreg_mask); // device-level overrides virtual void device_start() override; @@ -200,7 +200,7 @@ protected: class mc3418_device : public mc3417_device { public: - mc3418_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc3418_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/sound/huc6230.cpp b/src/devices/sound/huc6230.cpp index d257572f79e..587a2fed1c5 100644 --- a/src/devices/sound/huc6230.cpp +++ b/src/devices/sound/huc6230.cpp @@ -147,7 +147,7 @@ TIMER_CALLBACK_MEMBER(huc6230_device::adpcm_timer) DEFINE_DEVICE_TYPE(HuC6230, huc6230_device, "huc6230", "Hudson Soft HuC6230 SoundBox") -huc6230_device::huc6230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +huc6230_device::huc6230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HuC6230, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr) diff --git a/src/devices/sound/huc6230.h b/src/devices/sound/huc6230.h index a2ca7824617..1b73c35a191 100644 --- a/src/devices/sound/huc6230.h +++ b/src/devices/sound/huc6230.h @@ -13,7 +13,7 @@ class huc6230_device : public device_t, public device_sound_interface public: static constexpr feature_type imperfect_features() { return feature::SOUND; } // Incorrect ADPCM - huc6230_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + huc6230_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <unsigned N> auto adpcm_update_cb() { return m_adpcm_update_cb[N].bind(); } auto vca_callback() { return m_vca_cb.bind(); } diff --git a/src/devices/sound/i5000.cpp b/src/devices/sound/i5000.cpp index 3f194ef74c5..e4a006771eb 100644 --- a/src/devices/sound/i5000.cpp +++ b/src/devices/sound/i5000.cpp @@ -23,7 +23,7 @@ // device type definition DEFINE_DEVICE_TYPE(I5000_SND, i5000snd_device, "i5000snd", "Imagetek I5000 Sound") -i5000snd_device::i5000snd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +i5000snd_device::i5000snd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I5000_SND, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr), m_rom_base(nullptr), m_rom_mask(0) diff --git a/src/devices/sound/i5000.h b/src/devices/sound/i5000.h index abd84f5ac43..7b07decd966 100644 --- a/src/devices/sound/i5000.h +++ b/src/devices/sound/i5000.h @@ -23,7 +23,7 @@ class i5000snd_device : public device_t, { public: // construction/destruction - i5000snd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i5000snd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t read(offs_t offset); void write(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/sound/ics2115.cpp b/src/devices/sound/ics2115.cpp index 56c0cf607c4..87f2ccebdb9 100644 --- a/src/devices/sound/ics2115.cpp +++ b/src/devices/sound/ics2115.cpp @@ -30,7 +30,7 @@ // device type definition DEFINE_DEVICE_TYPE(ICS2115, ics2115_device, "ics2115", "ICS2115 WaveFront Synthesizer") -ics2115_device::ics2115_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ics2115_device::ics2115_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ICS2115, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_memory_interface(mconfig, *this) diff --git a/src/devices/sound/ics2115.h b/src/devices/sound/ics2115.h index 269069ff387..7f0151b19ef 100644 --- a/src/devices/sound/ics2115.h +++ b/src/devices/sound/ics2115.h @@ -19,7 +19,7 @@ public: // current ramping behavior is seems like incorrect? // construction/destruction - ics2115_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ics2115_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq() { return m_irq_cb.bind(); } diff --git a/src/devices/sound/iopspu.cpp b/src/devices/sound/iopspu.cpp index 55e6cd3b789..2ba17bfae83 100644 --- a/src/devices/sound/iopspu.cpp +++ b/src/devices/sound/iopspu.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(SONYIOP_SPU, iop_spu_device, "iopspu", "PlayStation 2 IOP SPU") -iop_spu_device::iop_spu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +iop_spu_device::iop_spu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYIOP_SPU, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_iop(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/sound/iopspu.h b/src/devices/sound/iopspu.h index bea55615c04..672cbc2e534 100644 --- a/src/devices/sound/iopspu.h +++ b/src/devices/sound/iopspu.h @@ -21,14 +21,14 @@ class iop_spu_device : public device_t, public device_sound_interface { public: template <typename T, typename U> - iop_spu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&iop_tag, U &&intc_tag) + iop_spu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&iop_tag, U &&intc_tag) : iop_spu_device(mconfig, tag, owner, clock) { m_iop.set_tag(std::forward<T>(iop_tag)); m_intc.set_tag(std::forward<U>(intc_tag)); } - iop_spu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iop_spu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~iop_spu_device() override; uint16_t read(offs_t offset, uint16_t mem_mask = ~0); diff --git a/src/devices/sound/iremga20.cpp b/src/devices/sound/iremga20.cpp index b87c9f26da0..f902ca16be9 100644 --- a/src/devices/sound/iremga20.cpp +++ b/src/devices/sound/iremga20.cpp @@ -58,7 +58,7 @@ DEFINE_DEVICE_TYPE(IREMGA20, iremga20_device, "iremga20", "Irem GA20") // iremga20_device - constructor //------------------------------------------------- -iremga20_device::iremga20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +iremga20_device::iremga20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, IREMGA20, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this), diff --git a/src/devices/sound/iremga20.h b/src/devices/sound/iremga20.h index 99440bc5782..25650667038 100644 --- a/src/devices/sound/iremga20.h +++ b/src/devices/sound/iremga20.h @@ -24,7 +24,7 @@ class iremga20_device : public device_t, public device_rom_interface<20> { public: - iremga20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + iremga20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint8_t data); uint8_t read(offs_t offset); diff --git a/src/devices/sound/k005289.cpp b/src/devices/sound/k005289.cpp index ffdfb4f0588..d3a32141c6a 100644 --- a/src/devices/sound/k005289.cpp +++ b/src/devices/sound/k005289.cpp @@ -53,7 +53,7 @@ DEFINE_DEVICE_TYPE(K005289, k005289_device, "k005289", "K005289 SCC") // k005289_device - constructor //------------------------------------------------- -k005289_device::k005289_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +k005289_device::k005289_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K005289, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_sound_prom(*this, DEVICE_SELF) diff --git a/src/devices/sound/k005289.h b/src/devices/sound/k005289.h index cacf1d98f52..76d6f186610 100644 --- a/src/devices/sound/k005289.h +++ b/src/devices/sound/k005289.h @@ -12,7 +12,7 @@ class k005289_device : public device_t, public device_sound_interface { public: - k005289_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + k005289_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void control_A_w(u8 data); void control_B_w(u8 data); diff --git a/src/devices/sound/k007232.cpp b/src/devices/sound/k007232.cpp index 9b4bc9e4b16..0754d55f062 100644 --- a/src/devices/sound/k007232.cpp +++ b/src/devices/sound/k007232.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(K007232, k007232_device, "k007232", "K007232 PCM Controller") -k007232_device::k007232_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +k007232_device::k007232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K007232, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_memory_interface(mconfig, *this) diff --git a/src/devices/sound/k007232.h b/src/devices/sound/k007232.h index f467670fc9b..a1319ef78e2 100644 --- a/src/devices/sound/k007232.h +++ b/src/devices/sound/k007232.h @@ -12,7 +12,7 @@ class k007232_device : public device_t, public device_sound_interface, public device_memory_interface { public: - k007232_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + k007232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto port_write() { return m_port_write_handler.bind(); } diff --git a/src/devices/sound/k051649.cpp b/src/devices/sound/k051649.cpp index 5ddffc5f36f..b27f123a0de 100644 --- a/src/devices/sound/k051649.cpp +++ b/src/devices/sound/k051649.cpp @@ -49,7 +49,7 @@ DEFINE_DEVICE_TYPE(K051649, k051649_device, "k051649", "K051649 SCC1") // k051649_device - constructor //------------------------------------------------- -k051649_device::k051649_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +k051649_device::k051649_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K051649, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr) diff --git a/src/devices/sound/k051649.h b/src/devices/sound/k051649.h index d9174e00dc9..4b90ceb7f2f 100644 --- a/src/devices/sound/k051649.h +++ b/src/devices/sound/k051649.h @@ -16,7 +16,7 @@ class k051649_device : public device_t, public device_sound_interface { public: - k051649_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + k051649_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void k051649_waveform_w(offs_t offset, u8 data); u8 k051649_waveform_r(offs_t offset); diff --git a/src/devices/sound/k053260.cpp b/src/devices/sound/k053260.cpp index 7cd0e6b3baa..12f751146e5 100644 --- a/src/devices/sound/k053260.cpp +++ b/src/devices/sound/k053260.cpp @@ -90,7 +90,7 @@ const int k053260_device::pan_mul[8][2] = { // k053260_device - constructor //------------------------------------------------- -k053260_device::k053260_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +k053260_device::k053260_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K053260, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/k053260.h b/src/devices/sound/k053260.h index 9b652bba4fe..494b906477f 100644 --- a/src/devices/sound/k053260.h +++ b/src/devices/sound/k053260.h @@ -24,7 +24,7 @@ class k053260_device : public device_t, public device_rom_interface<21> { public: - k053260_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + k053260_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 main_read(offs_t offset); void main_write(offs_t offset, u8 data); diff --git a/src/devices/sound/k054539.cpp b/src/devices/sound/k054539.cpp index 762bdce92c8..f704a55e9cf 100644 --- a/src/devices/sound/k054539.cpp +++ b/src/devices/sound/k054539.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(K054539, k054539_device, "k054539", "K054539 ADPCM") -k054539_device::k054539_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +k054539_device::k054539_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K054539, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/k054539.h b/src/devices/sound/k054539.h index 15ec7ecfe16..7d398e8cd3f 100644 --- a/src/devices/sound/k054539.h +++ b/src/devices/sound/k054539.h @@ -33,7 +33,7 @@ public: using apan_delegate = device_delegate<void (double left, double right)>; // construction/destruction - k054539_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + k054539_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto timer_handler() { return m_timer_handler.bind(); } diff --git a/src/devices/sound/k056800.cpp b/src/devices/sound/k056800.cpp index aae1aa10bf2..6810fb87c4d 100644 --- a/src/devices/sound/k056800.cpp +++ b/src/devices/sound/k056800.cpp @@ -20,7 +20,7 @@ DEFINE_DEVICE_TYPE(K056800, k056800_device, "k056800", "K056800 MIRAC") // k056800_device - constructor //------------------------------------------------- -k056800_device::k056800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +k056800_device::k056800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K056800, tag, owner, clock) , m_int_pending(false) , m_int_enabled(false) diff --git a/src/devices/sound/k056800.h b/src/devices/sound/k056800.h index a6d0aa6e567..c165b130734 100644 --- a/src/devices/sound/k056800.h +++ b/src/devices/sound/k056800.h @@ -18,7 +18,7 @@ class k056800_device : public device_t { public: // construction/destruction - k056800_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + k056800_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto int_callback() { return m_int_handler.bind(); } diff --git a/src/devices/sound/ks0164.cpp b/src/devices/sound/ks0164.cpp index f5c3c4d02e9..d04259b5f6c 100644 --- a/src/devices/sound/ks0164.cpp +++ b/src/devices/sound/ks0164.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(KS0164, ks0164_device, "ks0164", "Samsung KS0164 Wavetable Synthesizer") -ks0164_device::ks0164_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ks0164_device::ks0164_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, KS0164, tag, owner, clock), device_sound_interface(mconfig, *this), device_memory_interface(mconfig, *this), diff --git a/src/devices/sound/ks0164.h b/src/devices/sound/ks0164.h index 208176c6e2e..d3ed92557b8 100644 --- a/src/devices/sound/ks0164.h +++ b/src/devices/sound/ks0164.h @@ -14,7 +14,7 @@ class ks0164_device : public device_t, public device_sound_interface, public device_memory_interface, public device_serial_interface { public: - ks0164_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 16934400); + ks0164_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(16934400)); void mpu401_data_w(u8 data); void mpu401_ctrl_w(u8 data); diff --git a/src/devices/sound/l7a1045_l6028_dsp_a.cpp b/src/devices/sound/l7a1045_l6028_dsp_a.cpp index a9db61b5deb..08b6716aa48 100644 --- a/src/devices/sound/l7a1045_l6028_dsp_a.cpp +++ b/src/devices/sound/l7a1045_l6028_dsp_a.cpp @@ -100,7 +100,7 @@ DEFINE_DEVICE_TYPE(L7A1045, l7a1045_sound_device, "l7a1045", "L7A1045 L6028 DSP- // l7a1045_sound_device - constructor //------------------------------------------------- -l7a1045_sound_device::l7a1045_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +l7a1045_sound_device::l7a1045_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, L7A1045, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/l7a1045_l6028_dsp_a.h b/src/devices/sound/l7a1045_l6028_dsp_a.h index 4fff2caa465..3d132db7b18 100644 --- a/src/devices/sound/l7a1045_l6028_dsp_a.h +++ b/src/devices/sound/l7a1045_l6028_dsp_a.h @@ -15,7 +15,7 @@ class l7a1045_sound_device : public device_t, public device_sound_interface { public: - l7a1045_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + l7a1045_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // void set_base(int8_t* base) { m_base = base; } diff --git a/src/devices/sound/lc7535.cpp b/src/devices/sound/lc7535.cpp index 0f05bb14456..14a5faa8f87 100644 --- a/src/devices/sound/lc7535.cpp +++ b/src/devices/sound/lc7535.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(LC7535, lc7535_device, "lc7535", "Sanyo LC7535") // lc7535_device - constructor //------------------------------------------------- -lc7535_device::lc7535_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +lc7535_device::lc7535_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LC7535, tag, owner, clock), m_select_cb(*this), m_volume_cb(*this), diff --git a/src/devices/sound/lc7535.h b/src/devices/sound/lc7535.h index 4fcf649abd9..bcd7487d9eb 100644 --- a/src/devices/sound/lc7535.h +++ b/src/devices/sound/lc7535.h @@ -37,7 +37,7 @@ class lc7535_device : public device_t { public: // construction/destruction - lc7535_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + lc7535_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); typedef device_delegate<void (int attenuation_right, int attenuation_left, bool loudness)> volume_delegate; diff --git a/src/devices/sound/lmc1992.cpp b/src/devices/sound/lmc1992.cpp index c3f2d6d3bf4..cd8dc1444c2 100644 --- a/src/devices/sound/lmc1992.cpp +++ b/src/devices/sound/lmc1992.cpp @@ -139,7 +139,7 @@ inline void lmc1992_device::execute_command(int addr, int data) // lmc1992_device - constructor //------------------------------------------------- -lmc1992_device::lmc1992_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lmc1992_device::lmc1992_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LMC1992, tag, owner, clock) , device_sound_interface(mconfig, *this) { diff --git a/src/devices/sound/lmc1992.h b/src/devices/sound/lmc1992.h index beb893d9983..79c892f51d3 100644 --- a/src/devices/sound/lmc1992.h +++ b/src/devices/sound/lmc1992.h @@ -60,7 +60,7 @@ class lmc1992_device : public device_t, { public: // construction/destruction - lmc1992_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + lmc1992_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); DECLARE_WRITE_LINE_MEMBER( clock_w ); DECLARE_WRITE_LINE_MEMBER( data_w ); diff --git a/src/devices/sound/lynx.cpp b/src/devices/sound/lynx.cpp index d546e4ce00c..1cfb797be88 100644 --- a/src/devices/sound/lynx.cpp +++ b/src/devices/sound/lynx.cpp @@ -100,12 +100,12 @@ DEFINE_DEVICE_TYPE(LYNX2_SND, lynx2_sound_device, "lynx2_sound", "Atari Hayato ( // lynx_sound_device - constructor //------------------------------------------------- -lynx_sound_device::lynx_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lynx_sound_device::lynx_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : lynx_sound_device(mconfig, LYNX_SND, tag, owner, clock) { } -lynx_sound_device::lynx_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +lynx_sound_device::lynx_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_timer_delegate(*this) @@ -113,7 +113,7 @@ lynx_sound_device::lynx_sound_device(const machine_config &mconfig, device_type } -lynx2_sound_device::lynx2_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lynx2_sound_device::lynx2_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : lynx_sound_device(mconfig, LYNX2_SND, tag, owner, clock) { } diff --git a/src/devices/sound/lynx.h b/src/devices/sound/lynx.h index 6f9eb575013..046583f89d3 100644 --- a/src/devices/sound/lynx.h +++ b/src/devices/sound/lynx.h @@ -11,7 +11,7 @@ class lynx_sound_device : public device_t, public device_sound_interface public: typedef device_delegate<void (void)> timer_delegate; - lynx_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + lynx_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 read(offs_t offset); void write(offs_t offset, u8 data); @@ -48,7 +48,7 @@ protected: s16 count = 0; }; - lynx_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + lynx_sound_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -78,7 +78,7 @@ protected: class lynx2_sound_device : public lynx_sound_device { public: - lynx2_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + lynx2_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/sound/mas3507d.cpp b/src/devices/sound/mas3507d.cpp index eb156ec63b7..b7d6c52c718 100644 --- a/src/devices/sound/mas3507d.cpp +++ b/src/devices/sound/mas3507d.cpp @@ -46,7 +46,7 @@ ALLOW_SAVE_TYPE(mas3507d_device::i2c_command_t) // device type definition DEFINE_DEVICE_TYPE(MAS3507D, mas3507d_device, "mas3507d", "Micronas MAS 3507D MPEG decoder") -mas3507d_device::mas3507d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mas3507d_device::mas3507d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MAS3507D, tag, owner, clock) , device_sound_interface(mconfig, *this) , cb_mpeg_frame_sync(*this), cb_demand(*this) diff --git a/src/devices/sound/mas3507d.h b/src/devices/sound/mas3507d.h index 52c2e924109..e4cbbb25ff3 100644 --- a/src/devices/sound/mas3507d.h +++ b/src/devices/sound/mas3507d.h @@ -13,7 +13,7 @@ class mas3507d_device : public device_t, public device_sound_interface { public: // construction/destruction - mas3507d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mas3507d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); auto mpeg_frame_sync_cb() { return cb_mpeg_frame_sync.bind(); } auto demand_cb() { return cb_demand.bind(); } diff --git a/src/devices/sound/mea8000.cpp b/src/devices/sound/mea8000.cpp index e557d046db4..fba5500686a 100644 --- a/src/devices/sound/mea8000.cpp +++ b/src/devices/sound/mea8000.cpp @@ -114,7 +114,7 @@ static const int pi_table[32] = DEFINE_DEVICE_TYPE(MEA8000, mea8000_device, "mea8000", "Philips/Signetics MEA 8000 speech synthesizer") -mea8000_device::mea8000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mea8000_device::mea8000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MEA8000, tag, owner, clock), device_sound_interface(mconfig, *this), m_write_req(*this), diff --git a/src/devices/sound/mea8000.h b/src/devices/sound/mea8000.h index 7538bffa62c..01cbc006129 100644 --- a/src/devices/sound/mea8000.h +++ b/src/devices/sound/mea8000.h @@ -19,7 +19,7 @@ class mea8000_device : public device_t, public device_sound_interface { public: - mea8000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mea8000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto req() { return m_write_req.bind(); } diff --git a/src/devices/sound/meg.cpp b/src/devices/sound/meg.cpp index f6a90812d6a..34bc8639081 100644 --- a/src/devices/sound/meg.cpp +++ b/src/devices/sound/meg.cpp @@ -27,7 +27,7 @@ void meg_base_device::offsets_map(address_map &map) map(0, 0x7f).ram(); } -meg_base_device::meg_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, u32 prg_size) : +meg_base_device::meg_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 prg_size) : cpu_device(mconfig, type, tag, owner, clock), m_program_config("program", ENDIANNESS_BIG, 64, prg_size > 256 ? 9 : 8, -3, address_map_constructor(FUNC(meg_base_device::prg_map), this)), m_fp_config("fp", ENDIANNESS_BIG, 16, prg_size > 256 ? 9 : 8, -1, address_map_constructor(FUNC(meg_base_device::fp_map), this)), @@ -168,12 +168,12 @@ std::unique_ptr<util::disasm_interface> meg_base_device::create_disassembler() return std::make_unique<meg_disassembler>(this); } -meg_embedded_device::meg_embedded_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +meg_embedded_device::meg_embedded_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : meg_base_device(mconfig, MEGEMB, tag, owner, clock, 384) { } -meg_device::meg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +meg_device::meg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : meg_base_device(mconfig, MEG, tag, owner, clock, 256) { } diff --git a/src/devices/sound/meg.h b/src/devices/sound/meg.h index 40129158fc8..9deb7ff6af4 100644 --- a/src/devices/sound/meg.h +++ b/src/devices/sound/meg.h @@ -21,7 +21,7 @@ public: AS_OFFSETS = 2 }; - meg_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, u32 prg_size); + meg_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u32 prg_size); void prg_w(u16 address, u64 opcode); void fp_w(u16 address, u16 value); @@ -64,13 +64,13 @@ private: class meg_embedded_device : public meg_base_device { public: - meg_embedded_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 44100*384); + meg_embedded_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(44100*384)); }; class meg_device : public meg_base_device { public: - meg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 44100*256); + meg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(44100*256)); void map(address_map &map); private: diff --git a/src/devices/sound/mixer.cpp b/src/devices/sound/mixer.cpp index ba57be9b10c..64e94cc6e2c 100644 --- a/src/devices/sound/mixer.cpp +++ b/src/devices/sound/mixer.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(MIXER, mixer_device, "mixer", "Generic Audio Mixer") // mixer_device - constructor //------------------------------------------------- -mixer_device::mixer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mixer_device::mixer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MIXER, tag, owner, clock), device_mixer_interface(mconfig, *this) { diff --git a/src/devices/sound/mixer.h b/src/devices/sound/mixer.h index 5be1d45d5d3..8c98ddd26c5 100644 --- a/src/devices/sound/mixer.h +++ b/src/devices/sound/mixer.h @@ -17,7 +17,7 @@ class mixer_device : public device_t, public device_mixer_interface { public: // internal constructor - mixer_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mixer_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: // device-level overrides diff --git a/src/devices/sound/mm5837.cpp b/src/devices/sound/mm5837.cpp index ae6687655f3..34582123cad 100644 --- a/src/devices/sound/mm5837.cpp +++ b/src/devices/sound/mm5837.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(MM5837_STREAM, mm5837_stream_device, "mm5837_stream", "MM5837 // mm5837_device - constructor //------------------------------------------------- -mm5837_device::mm5837_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mm5837_device::mm5837_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MM5837, tag, owner, clock), m_output_cb(*this), m_timer(nullptr), @@ -88,7 +88,7 @@ TIMER_CALLBACK_MEMBER(mm5837_device::update_clock_output) // mm5837_stream_device - constructor //------------------------------------------------- -mm5837_stream_device::mm5837_stream_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +mm5837_stream_device::mm5837_stream_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MM5837_STREAM, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/mm5837.h b/src/devices/sound/mm5837.h index df76f6171fd..5f946472340 100644 --- a/src/devices/sound/mm5837.h +++ b/src/devices/sound/mm5837.h @@ -158,7 +158,7 @@ class mm5837_device : public device_t { public: // construction/destruction - mm5837_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + mm5837_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration void set_vdd(double voltage) { m_vdd = voltage; } @@ -186,7 +186,7 @@ class mm5837_stream_device : public device_t, public device_sound_interface { public: // construction/destruction - mm5837_stream_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mm5837_stream_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration void set_vdd(double voltage) { m_vdd = voltage; } diff --git a/src/devices/sound/mos6560.cpp b/src/devices/sound/mos6560.cpp index bd35429c31c..959d123430e 100644 --- a/src/devices/sound/mos6560.cpp +++ b/src/devices/sound/mos6560.cpp @@ -680,7 +680,7 @@ void mos6560_device::mos6560_colorram_map(address_map &map) map(0x000, 0x3ff).ram(); } -mos6560_device::mos6560_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +mos6560_device::mos6560_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock), device_memory_interface(mconfig, *this), device_sound_interface(mconfig, *this), @@ -693,17 +693,17 @@ mos6560_device::mos6560_device(const machine_config &mconfig, device_type type, { } -mos6560_device::mos6560_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6560_device::mos6560_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6560_device(mconfig, MOS6560, tag, owner, clock, TYPE_6560) { } -mos6561_device::mos6561_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6561_device::mos6561_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6560_device(mconfig, MOS6561, tag, owner, clock, TYPE_6561) { } -mos656x_attack_ufo_device::mos656x_attack_ufo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos656x_attack_ufo_device::mos656x_attack_ufo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6560_device(mconfig, MOS656X_ATTACK_UFO, tag, owner, clock, TYPE_ATTACK_UFO) { } diff --git a/src/devices/sound/mos6560.h b/src/devices/sound/mos6560.h index bf1b8604695..36063198fd3 100644 --- a/src/devices/sound/mos6560.h +++ b/src/devices/sound/mos6560.h @@ -68,8 +68,8 @@ /* the following values depend on the VIC clock, * but to achieve TV-frequency the clock must have a fix frequency */ -#define MOS6560_CLOCK (14318181/14) -#define MOS6561_CLOCK (4433618/4) +#define MOS6560_CLOCK (XTAL::u(14318181)/14) +#define MOS6561_CLOCK (XTAL::u(4433618)/4) @@ -85,7 +85,7 @@ class mos6560_device : public device_t, public device_video_interface { public: - mos6560_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6560_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto potx_rd_callback() { return m_read_potx.bind(); } auto poty_rd_callback() { return m_read_poty.bind(); } @@ -111,7 +111,7 @@ protected: TYPE_ATTACK_UFO // NTSC-M, less features }; - mos6560_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + mos6560_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_start() override; @@ -183,7 +183,7 @@ class mos6561_device : public mos6560_device { public: // construction/destruction - mos6561_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6561_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -193,7 +193,7 @@ class mos656x_attack_ufo_device : public mos6560_device { public: // construction/destruction - mos656x_attack_ufo_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos656x_attack_ufo_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/sound/mos6581.cpp b/src/devices/sound/mos6581.cpp index 6682ddca4fe..3f3fb7c54bf 100644 --- a/src/devices/sound/mos6581.cpp +++ b/src/devices/sound/mos6581.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(MOS8580, mos8580_device, "mos8580", "MOS 8580 SID") // mos6581_device - constructor //------------------------------------------------- -mos6581_device::mos6581_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +mos6581_device::mos6581_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_read_potx(*this) @@ -49,7 +49,7 @@ mos6581_device::mos6581_device(const machine_config &mconfig, device_type type, { } -mos6581_device::mos6581_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6581_device::mos6581_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6581_device(mconfig, MOS6581, tag, owner, clock, TYPE_6581) { } @@ -62,7 +62,7 @@ mos6581_device::~mos6581_device() // mos8580_device - constructor //------------------------------------------------- -mos8580_device::mos8580_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8580_device::mos8580_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6581_device(mconfig, MOS8580, tag, owner, clock, TYPE_8580) { } diff --git a/src/devices/sound/mos6581.h b/src/devices/sound/mos6581.h index de05db489d3..9ab6811f6fd 100644 --- a/src/devices/sound/mos6581.h +++ b/src/devices/sound/mos6581.h @@ -47,7 +47,7 @@ public: TYPE_8580 }; - mos6581_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6581_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~mos6581_device(); auto potx() { return m_read_potx.bind(); } @@ -57,7 +57,7 @@ public: void write(offs_t offset, uint8_t data); protected: - mos6581_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + mos6581_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_start() override; @@ -85,7 +85,7 @@ private: class mos8580_device : public mos6581_device { public: - mos8580_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8580_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/sound/mos7360.cpp b/src/devices/sound/mos7360.cpp index c76e1d8adb7..7671206679f 100644 --- a/src/devices/sound/mos7360.cpp +++ b/src/devices/sound/mos7360.cpp @@ -261,7 +261,7 @@ inline uint8_t mos7360_device::read_rom(offs_t offset) // mos7360_device - constructor //------------------------------------------------- -mos7360_device::mos7360_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos7360_device::mos7360_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MOS7360, tag, owner, clock), device_memory_interface(mconfig, *this), device_sound_interface(mconfig, *this), diff --git a/src/devices/sound/mos7360.h b/src/devices/sound/mos7360.h index fd0a51f597b..1c05fd6e825 100644 --- a/src/devices/sound/mos7360.h +++ b/src/devices/sound/mos7360.h @@ -75,7 +75,7 @@ public: static constexpr unsigned PAL_LINES = 312; // construction/destruction - mos7360_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos7360_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto write_irq_callback() { return m_write_irq.bind(); } diff --git a/src/devices/sound/msm5205.cpp b/src/devices/sound/msm5205.cpp index ba196a419a3..f06d5d467fd 100644 --- a/src/devices/sound/msm5205.cpp +++ b/src/devices/sound/msm5205.cpp @@ -62,12 +62,12 @@ DEFINE_DEVICE_TYPE(MSM5205, msm5205_device, "msm5205", "OKI MSM5205 ADPCM") DEFINE_DEVICE_TYPE(MSM6585, msm6585_device, "msm6585", "OKI MSM6585 ADPCM") -msm5205_device::msm5205_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +msm5205_device::msm5205_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msm5205_device(mconfig, MSM5205, tag, owner, clock, 10) { } -msm5205_device::msm5205_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 dac_bits) +msm5205_device::msm5205_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 dac_bits) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_s1(false) @@ -80,7 +80,7 @@ msm5205_device::msm5205_device(const machine_config &mconfig, device_type type, } -msm6585_device::msm6585_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +msm6585_device::msm6585_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msm5205_device(mconfig, MSM6585, tag, owner, clock, 12) { } diff --git a/src/devices/sound/msm5205.h b/src/devices/sound/msm5205.h index 46052aaffcb..b7eb947ea05 100644 --- a/src/devices/sound/msm5205.h +++ b/src/devices/sound/msm5205.h @@ -20,7 +20,7 @@ public: static constexpr int S64_4B = 6; // prescaler 1/64(6KHz) , data 4bit static constexpr int SEX_4B = 7; // VCK slave mode , data 4bit - msm5205_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + msm5205_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_prescaler_selector(int select) { @@ -48,7 +48,7 @@ public: void s2_w(int state); protected: - msm5205_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 dac_bits); + msm5205_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 dac_bits); // device-level overrides virtual void device_start() override; @@ -94,7 +94,7 @@ public: static constexpr int S80 = 6 + 8; /* prescaler 1/80 (8KHz), data 4bit */ static constexpr int S20 = 7 + 8; /* prescaler 1/20(32KHz), data 4bit */ - msm6585_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + msm6585_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int get_prescaler() const override; diff --git a/src/devices/sound/msm5232.cpp b/src/devices/sound/msm5232.cpp index 3d08f3582a8..7506d2dd2ae 100644 --- a/src/devices/sound/msm5232.cpp +++ b/src/devices/sound/msm5232.cpp @@ -12,7 +12,7 @@ DEFINE_DEVICE_TYPE(MSM5232, msm5232_device, "msm5232", "MSM5232") -msm5232_device::msm5232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +msm5232_device::msm5232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSM5232, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr) diff --git a/src/devices/sound/msm5232.h b/src/devices/sound/msm5232.h index 552cd7669e3..0ee73ae1d32 100644 --- a/src/devices/sound/msm5232.h +++ b/src/devices/sound/msm5232.h @@ -10,13 +10,13 @@ class msm5232_device : public device_t, public device_sound_interface { public: - msm5232_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msm5232_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_capacitors(double cap1, double cap2, double cap3, double cap4, double cap5, double cap6, double cap7, double cap8); auto gate() { return m_gate_handler_cb.bind(); } void write(offs_t offset, uint8_t data); - void set_clock(int clock); + void set_clock(const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/sound/multipcm.cpp b/src/devices/sound/multipcm.cpp index e8564f22698..175b5c2a8d4 100644 --- a/src/devices/sound/multipcm.cpp +++ b/src/devices/sound/multipcm.cpp @@ -464,7 +464,7 @@ void multipcm_device::write(offs_t offset, uint8_t data) DEFINE_DEVICE_TYPE(MULTIPCM, multipcm_device, "ymw258f", "Yamaha YMW-258-F") -multipcm_device::multipcm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +multipcm_device::multipcm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MULTIPCM, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this), diff --git a/src/devices/sound/multipcm.h b/src/devices/sound/multipcm.h index 786b5a3f02c..bc62df41538 100644 --- a/src/devices/sound/multipcm.h +++ b/src/devices/sound/multipcm.h @@ -18,7 +18,7 @@ class multipcm_device : public device_t, public device_rom_interface<22, 0, 0, ENDIANNESS_BIG> { public: - multipcm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + multipcm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint8_t data); uint8_t read(); diff --git a/src/devices/sound/n63701x.cpp b/src/devices/sound/n63701x.cpp index 6f16c988d8e..04bf7d62925 100644 --- a/src/devices/sound/n63701x.cpp +++ b/src/devices/sound/n63701x.cpp @@ -31,7 +31,7 @@ static const int vol_table[4] = { 26, 84, 200, 258 }; // device type definition DEFINE_DEVICE_TYPE(NAMCO_63701X, namco_63701x_device, "namco_63701x", "Namco 63701X") -namco_63701x_device::namco_63701x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +namco_63701x_device::namco_63701x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NAMCO_63701X, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_rom(*this, DEVICE_SELF) diff --git a/src/devices/sound/n63701x.h b/src/devices/sound/n63701x.h index 3ca5411df6d..c45b4d4447d 100644 --- a/src/devices/sound/n63701x.h +++ b/src/devices/sound/n63701x.h @@ -16,7 +16,7 @@ class namco_63701x_device : public device_t, public device_sound_interface { public: - namco_63701x_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + namco_63701x_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint8_t data); diff --git a/src/devices/sound/namco.cpp b/src/devices/sound/namco.cpp index a83f0ccbb65..4e3d600fdb6 100644 --- a/src/devices/sound/namco.cpp +++ b/src/devices/sound/namco.cpp @@ -49,7 +49,7 @@ DEFINE_DEVICE_TYPE(NAMCO, namco_device, "namco", "Namco") DEFINE_DEVICE_TYPE(NAMCO_15XX, namco_15xx_device, "namco_15xx", "Namco 15xx") DEFINE_DEVICE_TYPE(NAMCO_CUS30, namco_cus30_device, "namco_cus30", "Namco CUS30") -namco_audio_device::namco_audio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +namco_audio_device::namco_audio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_wave_ptr(*this, DEVICE_SELF) @@ -66,19 +66,19 @@ namco_audio_device::namco_audio_device(const machine_config &mconfig, device_typ { } -namco_device::namco_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +namco_device::namco_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : namco_audio_device(mconfig, NAMCO, tag, owner, clock) , m_soundregs(nullptr) { } -namco_15xx_device::namco_15xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +namco_15xx_device::namco_15xx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) :namco_audio_device(mconfig, NAMCO_15XX, tag, owner, clock) , m_soundregs(nullptr) { } -namco_cus30_device::namco_cus30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +namco_cus30_device::namco_cus30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : namco_audio_device(mconfig, NAMCO_CUS30, tag, owner, clock) { } diff --git a/src/devices/sound/namco.h b/src/devices/sound/namco.h index f032a71a536..45bda912528 100644 --- a/src/devices/sound/namco.h +++ b/src/devices/sound/namco.h @@ -34,7 +34,7 @@ protected: int32_t waveform_select; }; - namco_audio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + namco_audio_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -76,7 +76,7 @@ protected: class namco_device : public namco_audio_device { public: - namco_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + namco_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void pacman_sound_w(offs_t offset, uint8_t data); @@ -97,7 +97,7 @@ private: class namco_15xx_device : public namco_audio_device { public: - namco_15xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + namco_15xx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void namco_15xx_w(offs_t offset, uint8_t data); uint8_t sharedram_r(offs_t offset); @@ -117,7 +117,7 @@ private: class namco_cus30_device : public namco_audio_device { public: - namco_cus30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + namco_cus30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void namcos1_cus30_w(offs_t offset, uint8_t data); /* wavedata + sound registers + RAM */ uint8_t namcos1_cus30_r(offs_t offset); diff --git a/src/devices/sound/namco_163.cpp b/src/devices/sound/namco_163.cpp index c26a1f1c638..87a3611fc37 100644 --- a/src/devices/sound/namco_163.cpp +++ b/src/devices/sound/namco_163.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(NAMCO_163, namco_163_sound_device, "namco_163_sound", "Namco 163 (Sound)") -namco_163_sound_device::namco_163_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +namco_163_sound_device::namco_163_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, NAMCO_163, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_reg_addr(0x78) diff --git a/src/devices/sound/namco_163.h b/src/devices/sound/namco_163.h index f3a7428300d..fd928bc31e4 100644 --- a/src/devices/sound/namco_163.h +++ b/src/devices/sound/namco_163.h @@ -10,7 +10,7 @@ class namco_163_sound_device : public device_t, public device_sound_interface { public: - namco_163_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + namco_163_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(disable_w); diff --git a/src/devices/sound/nes_apu.cpp b/src/devices/sound/nes_apu.cpp index ee059c1cd22..9af003bfff7 100644 --- a/src/devices/sound/nes_apu.cpp +++ b/src/devices/sound/nes_apu.cpp @@ -48,7 +48,7 @@ DEFINE_DEVICE_TYPE(NES_APU, nesapu_device, "nesapu", "RP2A0X APU") DEFINE_DEVICE_TYPE(APU_2A03, apu2a03_device, "apu2a03", "RP2A03 APU") -nesapu_device::nesapu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +nesapu_device::nesapu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_is_pal(0) @@ -59,7 +59,7 @@ nesapu_device::nesapu_device(const machine_config &mconfig, device_type type, co { } -nesapu_device::nesapu_device(const machine_config& mconfig, const char* tag, device_t* owner, u32 clock) +nesapu_device::nesapu_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : nesapu_device(mconfig, NES_APU, tag, owner, clock) { } diff --git a/src/devices/sound/nes_apu.h b/src/devices/sound/nes_apu.h index 8837e683034..d7e17a530ef 100644 --- a/src/devices/sound/nes_apu.h +++ b/src/devices/sound/nes_apu.h @@ -43,7 +43,7 @@ class nesapu_device : public device_t, public device_sound_interface { public: - nesapu_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nesapu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq() { return m_irq_handler.bind(); } @@ -56,7 +56,7 @@ public: void write(offs_t offset, u8 data); protected: - nesapu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + nesapu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -97,7 +97,7 @@ private: class apu2a03_device : public nesapu_device { public: - apu2a03_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + apu2a03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void update_lfsr(apu_t::noise_t &chan) override; diff --git a/src/devices/sound/nes_apu_vt.cpp b/src/devices/sound/nes_apu_vt.cpp index f93c3203bac..a3093b1e9e3 100644 --- a/src/devices/sound/nes_apu_vt.cpp +++ b/src/devices/sound/nes_apu_vt.cpp @@ -12,7 +12,7 @@ DEFINE_DEVICE_TYPE(NES_APU_VT, nes_apu_vt_device, "nes_apu_vt", "XOP APU") -nes_apu_vt_device::nes_apu_vt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nes_apu_vt_device::nes_apu_vt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nesapu_device(mconfig, NES_APU_VT, tag, owner, clock) { } diff --git a/src/devices/sound/nes_apu_vt.h b/src/devices/sound/nes_apu_vt.h index f93616673fa..c38f3c3bd9e 100644 --- a/src/devices/sound/nes_apu_vt.h +++ b/src/devices/sound/nes_apu_vt.h @@ -14,7 +14,7 @@ class nes_apu_vt_device : public nesapu_device { public: // construction/destruction - nes_apu_vt_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nes_apu_vt_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/sound/okim6258.cpp b/src/devices/sound/okim6258.cpp index 349fe9ca13c..88ff1ddfb55 100644 --- a/src/devices/sound/okim6258.cpp +++ b/src/devices/sound/okim6258.cpp @@ -46,7 +46,7 @@ DEFINE_DEVICE_TYPE(OKIM6258, okim6258_device, "okim6258", "OKI MSM6258 ADPCM") // okim6258_device - constructor //------------------------------------------------- -okim6258_device::okim6258_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +okim6258_device::okim6258_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, OKIM6258, tag, owner, clock), device_sound_interface(mconfig, *this), m_status(0), diff --git a/src/devices/sound/okim6258.h b/src/devices/sound/okim6258.h index 95189f0ef3c..e5c37327645 100644 --- a/src/devices/sound/okim6258.h +++ b/src/devices/sound/okim6258.h @@ -26,7 +26,7 @@ public: static constexpr int OUTPUT_10BITS = 10; static constexpr int OUTPUT_12BITS = 12; - okim6258_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + okim6258_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration void set_start_div(int div) { m_start_divider = div; } diff --git a/src/devices/sound/okim6295.cpp b/src/devices/sound/okim6295.cpp index fbded659cf1..b14ffccf046 100644 --- a/src/devices/sound/okim6295.cpp +++ b/src/devices/sound/okim6295.cpp @@ -85,7 +85,7 @@ const stream_buffer::sample_t okim6295_device::s_volume_table[16] = // okim6295_device - constructor //------------------------------------------------- -okim6295_device::okim6295_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +okim6295_device::okim6295_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, OKIM6295, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this), diff --git a/src/devices/sound/okim6295.h b/src/devices/sound/okim6295.h index 4d372a8a47c..cbad0f281a3 100644 --- a/src/devices/sound/okim6295.h +++ b/src/devices/sound/okim6295.h @@ -35,12 +35,12 @@ public: }; // construction/destruction - okim6295_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, pin7_state pin7) + okim6295_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, pin7_state pin7) : okim6295_device(mconfig, tag, owner, clock) { config_pin7(pin7); } - okim6295_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + okim6295_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration helpers void config_pin7(pin7_state pin7) { assert(!started()); m_pin7_state = pin7; } diff --git a/src/devices/sound/okim6376.cpp b/src/devices/sound/okim6376.cpp index 58a52858ecf..b95fe5284a6 100644 --- a/src/devices/sound/okim6376.cpp +++ b/src/devices/sound/okim6376.cpp @@ -113,7 +113,7 @@ void okim6376_device::ADPCMVoice::reset() DEFINE_DEVICE_TYPE(OKIM6376, okim6376_device, "okim6376", "OKI MSM6376 ADPCM") DEFINE_DEVICE_TYPE(OKIM6650, okim6650_device, "okim6650", "OKI MSM6650 ADPCM") -okim6376_device::okim6376_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int addrbits) +okim6376_device::okim6376_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addrbits) : device_t(mconfig, type, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this), @@ -135,12 +135,12 @@ okim6376_device::okim6376_device(const machine_config &mconfig, device_type type override_address_width(addrbits); } -okim6376_device::okim6376_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +okim6376_device::okim6376_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : okim6376_device(mconfig, OKIM6376, tag, owner, clock, 21) { } -okim6650_device::okim6650_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +okim6650_device::okim6650_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : okim6376_device(mconfig, OKIM6650, tag, owner, clock, 23) { } diff --git a/src/devices/sound/okim6376.h b/src/devices/sound/okim6376.h index aca7eb4de31..2ea932be760 100644 --- a/src/devices/sound/okim6376.h +++ b/src/devices/sound/okim6376.h @@ -12,7 +12,7 @@ class okim6376_device : public device_t, public device_sound_interface, public device_rom_interface<23, 0, 0, ENDIANNESS_BIG> { public: - okim6376_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + okim6376_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(uint8_t data); @@ -23,7 +23,7 @@ public: DECLARE_READ_LINE_MEMBER( nar_r ); protected: - okim6376_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int addrbits); + okim6376_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int addrbits); // device-level overrides virtual void device_start() override; @@ -84,7 +84,7 @@ protected: class okim6650_device : public okim6376_device { public: - okim6650_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + okim6650_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( cmd_w ); diff --git a/src/devices/sound/okim9810.cpp b/src/devices/sound/okim9810.cpp index db658eacf00..8eca6dfaf08 100644 --- a/src/devices/sound/okim9810.cpp +++ b/src/devices/sound/okim9810.cpp @@ -80,7 +80,7 @@ const uint32_t okim9810_device::s_sampling_freq_div_table[16] = // okim9810_device - constructor //------------------------------------------------- -okim9810_device::okim9810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +okim9810_device::okim9810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, OKIM9810, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this), diff --git a/src/devices/sound/okim9810.h b/src/devices/sound/okim9810.h index 18db148aa40..3b0e145b0a1 100644 --- a/src/devices/sound/okim9810.h +++ b/src/devices/sound/okim9810.h @@ -34,7 +34,7 @@ class okim9810_device : public device_t, { public: // construction/destruction - okim9810_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + okim9810_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read_status(); void write_tmp_register(uint8_t command); diff --git a/src/devices/sound/pcd3311.cpp b/src/devices/sound/pcd3311.cpp index 4b5a4fb87f5..1102e923ff8 100644 --- a/src/devices/sound/pcd3311.cpp +++ b/src/devices/sound/pcd3311.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(PCD3311, pcd3311_device, "pcd3311", "PCD3311") // pcd3311_device - constructor //------------------------------------------------- -pcd3311_device::pcd3311_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pcd3311_device::pcd3311_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCD3311, tag, owner, clock), device_sound_interface(mconfig, *this) { diff --git a/src/devices/sound/pcd3311.h b/src/devices/sound/pcd3311.h index 5d5b8870008..26a74d7a58d 100644 --- a/src/devices/sound/pcd3311.h +++ b/src/devices/sound/pcd3311.h @@ -36,7 +36,7 @@ class pcd3311_device : public device_t, { public: // construction/destruction - pcd3311_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pcd3311_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(uint8_t data) { m_data = data; } void strobe_w(int state) { m_strobe = state; } diff --git a/src/devices/sound/pci-ac97.cpp b/src/devices/sound/pci-ac97.cpp index 939ef832ab7..6b944c933fc 100644 --- a/src/devices/sound/pci-ac97.cpp +++ b/src/devices/sound/pci-ac97.cpp @@ -21,7 +21,7 @@ void ac97_device::bus_mastering_map(address_map &map) { } -ac97_device::ac97_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ac97_device::ac97_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, AC97, tag, owner, clock) { } diff --git a/src/devices/sound/pci-ac97.h b/src/devices/sound/pci-ac97.h index 4633337e6dc..ba7c82903f1 100644 --- a/src/devices/sound/pci-ac97.h +++ b/src/devices/sound/pci-ac97.h @@ -9,12 +9,12 @@ class ac97_device : public pci_device { public: - ac97_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) + ac97_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t main_id, uint32_t revision, uint32_t subdevice_id) : ac97_device(mconfig, tag, owner, clock) { set_ids(main_id, revision, 0x040300, subdevice_id); } - ac97_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ac97_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/sound/pokey.cpp b/src/devices/sound/pokey.cpp index b490126c0d5..f003f048199 100644 --- a/src/devices/sound/pokey.cpp +++ b/src/devices/sound/pokey.cpp @@ -192,7 +192,7 @@ DEFINE_DEVICE_TYPE(POKEY, pokey_device, "pokey", "Atari C012294 POKEY") // pokey_device - constructor //------------------------------------------------- -pokey_device::pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pokey_device::pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, POKEY, tag, owner, clock), device_sound_interface(mconfig, *this), device_execute_interface(mconfig, *this), diff --git a/src/devices/sound/pokey.h b/src/devices/sound/pokey.h index 018394d3003..2c167fed057 100644 --- a/src/devices/sound/pokey.h +++ b/src/devices/sound/pokey.h @@ -66,7 +66,7 @@ public: /* CONSTANT DEFINITIONS */ /* exact 1.79 MHz clock freq (of the Atari 800 that is) */ - static constexpr unsigned FREQ_17_EXACT = 1789790; + static constexpr auto FREQ_17_EXACT = XTAL::u(1789790); enum { @@ -124,7 +124,7 @@ public: }; // construction/destruction - pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pokey_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <unsigned N> auto pot_r() { return m_pot_r_cb[N].bind(); } auto allpot_r() { return m_allpot_r_cb.bind(); } diff --git a/src/devices/sound/qs1000.cpp b/src/devices/sound/qs1000.cpp index fb42e4936db..8f6c1997ecc 100644 --- a/src/devices/sound/qs1000.cpp +++ b/src/devices/sound/qs1000.cpp @@ -164,7 +164,7 @@ ROM_END //------------------------------------------------- // qs1000_device - constructor //------------------------------------------------- -qs1000_device::qs1000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +qs1000_device::qs1000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, QS1000, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this), diff --git a/src/devices/sound/qs1000.h b/src/devices/sound/qs1000.h index 22683ff7d35..77765d13e2e 100644 --- a/src/devices/sound/qs1000.h +++ b/src/devices/sound/qs1000.h @@ -31,7 +31,7 @@ public: static constexpr feature_type imperfect_features() { return feature::SOUND; } // construction/destruction - qs1000_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + qs1000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_external_rom(bool external_rom) { m_external_rom = external_rom; } auto p1_in() { return m_in_p1_cb.bind(); } diff --git a/src/devices/sound/qsound.cpp b/src/devices/sound/qsound.cpp index bae635a6f7b..58a0ec3eeec 100644 --- a/src/devices/sound/qsound.cpp +++ b/src/devices/sound/qsound.cpp @@ -130,7 +130,7 @@ ROM_END // qsound_device - constructor //------------------------------------------------- -qsound_device::qsound_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +qsound_device::qsound_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, QSOUND, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/qsound.h b/src/devices/sound/qsound.h index 48ccf3acf87..d571c14f9fb 100644 --- a/src/devices/sound/qsound.h +++ b/src/devices/sound/qsound.h @@ -18,7 +18,7 @@ class qsound_device : public device_t, public device_sound_interface, public dev { public: // default 60MHz clock (divided by 2 for DSP core clock, and then by 1248 for sample rate) - qsound_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock = 60'000'000); + qsound_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL::u(60'000'000)); void qsound_w(offs_t offset, u8 data); u8 qsound_r(); diff --git a/src/devices/sound/qsoundhle.cpp b/src/devices/sound/qsoundhle.cpp index ed69b569cb5..42658abd73a 100644 --- a/src/devices/sound/qsoundhle.cpp +++ b/src/devices/sound/qsoundhle.cpp @@ -39,7 +39,7 @@ ROM_END // qsound_hle_device - constructor //------------------------------------------------- -qsound_hle_device::qsound_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +qsound_hle_device::qsound_hle_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, QSOUND_HLE, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/qsoundhle.h b/src/devices/sound/qsoundhle.h index d5256854842..0cc1f5a7bd6 100644 --- a/src/devices/sound/qsoundhle.h +++ b/src/devices/sound/qsoundhle.h @@ -18,7 +18,7 @@ class qsound_hle_device : public device_t, public device_sound_interface, public { public: // default 60MHz clock (divided by 2 for DSP core clock, and then by 1248 for sample rate) - qsound_hle_device(machine_config const &mconfig, char const *tag, device_t *owner, uint32_t clock = 60'000'000); + qsound_hle_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock = XTAL::u(60'000'000)); void qsound_w(offs_t offset, uint8_t data); uint8_t qsound_r(); diff --git a/src/devices/sound/rf5c400.cpp b/src/devices/sound/rf5c400.cpp index fc466fb0a0f..ab3af9117c9 100644 --- a/src/devices/sound/rf5c400.cpp +++ b/src/devices/sound/rf5c400.cpp @@ -115,7 +115,7 @@ void rf5c400_device::envelope_tables::init(uint32_t clock) // rf5c400_device - constructor //------------------------------------------------- -rf5c400_device::rf5c400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +rf5c400_device::rf5c400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RF5C400, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/rf5c400.h b/src/devices/sound/rf5c400.h index a91ba9ee097..a95c92f6d10 100644 --- a/src/devices/sound/rf5c400.h +++ b/src/devices/sound/rf5c400.h @@ -23,7 +23,7 @@ class rf5c400_device : public device_t, public: static constexpr feature_type imperfect_features() { return feature::SOUND; } // unemulated and/or unverified effects and envelopes - rf5c400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + rf5c400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t rf5c400_r(offs_t offset, uint16_t mem_mask = ~0); void rf5c400_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); diff --git a/src/devices/sound/rf5c68.cpp b/src/devices/sound/rf5c68.cpp index 09fd397d4fb..8530fec3e2b 100644 --- a/src/devices/sound/rf5c68.cpp +++ b/src/devices/sound/rf5c68.cpp @@ -40,7 +40,7 @@ void rf5c164_device::rf5c164_map(address_map &map) // rf5c68_device - constructor //------------------------------------------------- -rf5c68_device::rf5c68_device(const machine_config & mconfig, device_type type, const char * tag, device_t * owner, u32 clock, int output_bits) +rf5c68_device::rf5c68_device(const machine_config & mconfig, device_type type, const char * tag, device_t * owner, const XTAL &clock, int output_bits) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_memory_interface(mconfig, *this) @@ -54,7 +54,7 @@ rf5c68_device::rf5c68_device(const machine_config & mconfig, device_type type, c { } -rf5c68_device::rf5c68_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rf5c68_device::rf5c68_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rf5c68_device(mconfig, RF5C68, tag, owner, clock, 10) { } @@ -64,7 +64,7 @@ rf5c68_device::rf5c68_device(const machine_config &mconfig, const char *tag, dev // rf5c164_device - constructor //------------------------------------------------- -rf5c164_device::rf5c164_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rf5c164_device::rf5c164_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : rf5c68_device(mconfig, RF5C164, tag, owner, clock, 16) { } diff --git a/src/devices/sound/rf5c68.h b/src/devices/sound/rf5c68.h index d78f378faaf..219d11477da 100644 --- a/src/devices/sound/rf5c68.h +++ b/src/devices/sound/rf5c68.h @@ -26,7 +26,7 @@ class rf5c68_device : public device_t, public: typedef device_delegate<void (int channel)> sample_end_cb_delegate; - rf5c68_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rf5c68_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename... T> void set_end_callback(T &&... args) { m_sample_end_cb.set(std::forward<T>(args)...); } @@ -38,7 +38,7 @@ public: void map(address_map &map); protected: - rf5c68_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, int output_bits); + rf5c68_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int output_bits); // device-level overrides virtual void device_start() override; @@ -84,7 +84,7 @@ private: class rf5c164_device : public rf5c68_device { public: - rf5c164_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rf5c164_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void rf5c164_map(address_map &map); }; diff --git a/src/devices/sound/rolandpcm.cpp b/src/devices/sound/rolandpcm.cpp index e31132b934e..16191b60282 100644 --- a/src/devices/sound/rolandpcm.cpp +++ b/src/devices/sound/rolandpcm.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(MB87419_MB87420, mb87419_mb87420_device, "mb87419_mb87420", "Roland MB87419/MB87420 PCM") -mb87419_mb87420_device::mb87419_mb87420_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb87419_mb87420_device::mb87419_mb87420_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MB87419_MB87420, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/rolandpcm.h b/src/devices/sound/rolandpcm.h index 702da28dcf1..0a6c6a64397 100644 --- a/src/devices/sound/rolandpcm.h +++ b/src/devices/sound/rolandpcm.h @@ -10,7 +10,7 @@ class mb87419_mb87420_device : public device_t, public device_sound_interface, public device_rom_interface<22> { public: - mb87419_mb87420_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb87419_mb87420_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto int_callback() { return m_int_callback.bind(); } diff --git a/src/devices/sound/rp2c33_snd.cpp b/src/devices/sound/rp2c33_snd.cpp index d0701041a6b..b1efe47636e 100644 --- a/src/devices/sound/rp2c33_snd.cpp +++ b/src/devices/sound/rp2c33_snd.cpp @@ -36,7 +36,7 @@ DEFINE_DEVICE_TYPE(RP2C33_SOUND, rp2c33_sound_device, "rp2c33_snd", "Ricoh RP2C3 // rp2c33_sound_device - constructor //------------------------------------------------- -rp2c33_sound_device::rp2c33_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +rp2c33_sound_device::rp2c33_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RP2C33_SOUND, tag, owner, clock) , device_sound_interface(mconfig, *this) { diff --git a/src/devices/sound/rp2c33_snd.h b/src/devices/sound/rp2c33_snd.h index bdb32e58f60..1f480519e3b 100644 --- a/src/devices/sound/rp2c33_snd.h +++ b/src/devices/sound/rp2c33_snd.h @@ -26,7 +26,7 @@ public: static constexpr feature_type imperfect_features() { return feature::SOUND; } // one or more features are not verified, and possibly incorrect // construction/destruction - rp2c33_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + rp2c33_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // host interface void write(offs_t offset, u8 data); diff --git a/src/devices/sound/s14001a.cpp b/src/devices/sound/s14001a.cpp index 50f2ca07eaa..b3bf75c777b 100644 --- a/src/devices/sound/s14001a.cpp +++ b/src/devices/sound/s14001a.cpp @@ -196,7 +196,7 @@ uint8_t CalculateOutput(bool bVoiced, bool bXSilence, uint8_t uPPQtr, bool bPPQS // device definition DEFINE_DEVICE_TYPE(S14001A, s14001a_device, "s14001a", "SSi TSI S14001A") -s14001a_device::s14001a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s14001a_device::s14001a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S14001A, tag, owner, clock), device_sound_interface(mconfig, *this), m_SpeechRom(*this, DEVICE_SELF), diff --git a/src/devices/sound/s14001a.h b/src/devices/sound/s14001a.h index 511503d9daa..d43884b310b 100644 --- a/src/devices/sound/s14001a.h +++ b/src/devices/sound/s14001a.h @@ -11,7 +11,7 @@ class s14001a_device : public device_t, public device_sound_interface { public: - s14001a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s14001a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto bsy() { return m_bsy_handler.bind(); } diff --git a/src/devices/sound/s_dsp.cpp b/src/devices/sound/s_dsp.cpp index 98cd204b503..1492738534e 100644 --- a/src/devices/sound/s_dsp.cpp +++ b/src/devices/sound/s_dsp.cpp @@ -141,7 +141,7 @@ ALLOW_SAVE_TYPE(s_dsp_device::env_state_t32); DEFINE_DEVICE_TYPE(S_DSP, s_dsp_device, "s_dsp", "Nintendo/Sony S-DSP") -s_dsp_device::s_dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +s_dsp_device::s_dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, S_DSP, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_memory_interface(mconfig, *this) diff --git a/src/devices/sound/s_dsp.h b/src/devices/sound/s_dsp.h index 00097b17303..f52d638eda4 100644 --- a/src/devices/sound/s_dsp.h +++ b/src/devices/sound/s_dsp.h @@ -16,7 +16,7 @@ class s_dsp_device : public device_t, public device_sound_interface, public device_memory_interface { public: - s_dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + s_dsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_volume(int volume); diff --git a/src/devices/sound/saa1099.cpp b/src/devices/sound/saa1099.cpp index 682cbb5873f..eeaa4dd44e6 100644 --- a/src/devices/sound/saa1099.cpp +++ b/src/devices/sound/saa1099.cpp @@ -136,7 +136,7 @@ DEFINE_DEVICE_TYPE(SAA1099, saa1099_device, "saa1099", "Philips SAA1099") // saa1099_device - constructor //------------------------------------------------- -saa1099_device::saa1099_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +saa1099_device::saa1099_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SAA1099, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr) diff --git a/src/devices/sound/saa1099.h b/src/devices/sound/saa1099.h index 87f5b58f48a..7b0b3a783b2 100644 --- a/src/devices/sound/saa1099.h +++ b/src/devices/sound/saa1099.h @@ -19,7 +19,7 @@ class saa1099_device : public device_t, public device_sound_interface { public: - saa1099_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + saa1099_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void control_w(u8 data); void data_w(u8 data); diff --git a/src/devices/sound/samples.cpp b/src/devices/sound/samples.cpp index 999f4da7e0b..8120b917ff9 100644 --- a/src/devices/sound/samples.cpp +++ b/src/devices/sound/samples.cpp @@ -46,12 +46,12 @@ DEFINE_DEVICE_TYPE(SAMPLES, samples_device, "samples", "Samples") // samples_device - constructors //------------------------------------------------- -samples_device::samples_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +samples_device::samples_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : samples_device(mconfig, SAMPLES, tag, owner, clock) { } -samples_device::samples_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +samples_device::samples_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_channels(0) diff --git a/src/devices/sound/samples.h b/src/devices/sound/samples.h index 073fc3ae180..dcc10c34694 100644 --- a/src/devices/sound/samples.h +++ b/src/devices/sound/samples.h @@ -34,7 +34,7 @@ public: typedef device_delegate<void ()> start_cb_delegate; // construction/destruction - samples_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + samples_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers void set_channels(uint8_t channels) { m_channels = channels; } @@ -75,7 +75,7 @@ public: protected: // subclasses can do it this way - samples_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + samples_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/sound/sb0400.cpp b/src/devices/sound/sb0400.cpp index b124a99b8f9..99073db5d8b 100644 --- a/src/devices/sound/sb0400.cpp +++ b/src/devices/sound/sb0400.cpp @@ -9,7 +9,7 @@ void sb0400_device::map(address_map &map) { } -sb0400_device::sb0400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sb0400_device::sb0400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, SB0400, tag, owner, clock) { } diff --git a/src/devices/sound/sb0400.h b/src/devices/sound/sb0400.h index 440e82a0544..bd4f4d887d0 100644 --- a/src/devices/sound/sb0400.h +++ b/src/devices/sound/sb0400.h @@ -9,12 +9,12 @@ class sb0400_device : public pci_device { public: - sb0400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t subdevice_id) + sb0400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t subdevice_id) : sb0400_device(mconfig, tag, owner, clock) { set_ids(0x11020008, 0x00, 0x040100, subdevice_id); } - sb0400_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sb0400_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/sound/scsp.cpp b/src/devices/sound/scsp.cpp index 96436fefd90..e6d17af76b3 100644 --- a/src/devices/sound/scsp.cpp +++ b/src/devices/sound/scsp.cpp @@ -142,7 +142,7 @@ static const float SDLT[8] = {-1000000.0f,-36.0f,-30.0f,-24.0f,-18.0f,-12.0f,-6. DEFINE_DEVICE_TYPE(SCSP, scsp_device, "scsp", "Yamaha YMF292-F SCSP") -scsp_device::scsp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +scsp_device::scsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SCSP, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this), diff --git a/src/devices/sound/scsp.h b/src/devices/sound/scsp.h index dfd62c24dd0..e6bd22acfa8 100644 --- a/src/devices/sound/scsp.h +++ b/src/devices/sound/scsp.h @@ -25,7 +25,7 @@ class scsp_device : public device_t, public: static constexpr feature_type imperfect_features() { return feature::SOUND; } // DSP / EG incorrections, etc - scsp_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 22'579'200); + scsp_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(22'579'200)); auto irq_cb() { return m_irq_cb.bind(); } auto main_irq_cb() { return m_main_irq_cb.bind(); } diff --git a/src/devices/sound/segapcm.cpp b/src/devices/sound/segapcm.cpp index 9f7a9b6fc63..e9415754590 100644 --- a/src/devices/sound/segapcm.cpp +++ b/src/devices/sound/segapcm.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(SEGAPCM, segapcm_device, "segapcm", "Sega PCM") // segapcm_device - constructor //------------------------------------------------- -segapcm_device::segapcm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +segapcm_device::segapcm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SEGAPCM, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/segapcm.h b/src/devices/sound/segapcm.h index ff098088037..bb9c6d44941 100644 --- a/src/devices/sound/segapcm.h +++ b/src/devices/sound/segapcm.h @@ -27,7 +27,7 @@ public: static constexpr int BANK_MASKF = 0xf0 << 16; static constexpr int BANK_MASKF8 = 0xf8 << 16; - segapcm_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + segapcm_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration void set_bank(int bank) { m_bankshift = (bank & 0xf); m_bankmask = (0x70|((bank >> 16) & 0xfc)); } diff --git a/src/devices/sound/setapcm.cpp b/src/devices/sound/setapcm.cpp index ab002f68f10..fdde501f704 100644 --- a/src/devices/sound/setapcm.cpp +++ b/src/devices/sound/setapcm.cpp @@ -75,7 +75,7 @@ DEFINE_DEVICE_TYPE(ST0032_SOUND, st0032_sound_device, "st0032_sound", "Seta ST-0 //------------------------------------------------- template<unsigned MaxVoices, unsigned Divider> -setapcm_device<MaxVoices, Divider>::setapcm_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +setapcm_device<MaxVoices, Divider>::setapcm_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) @@ -84,12 +84,12 @@ setapcm_device<MaxVoices, Divider>::setapcm_device(const machine_config &mconfig { } -nile_sound_device::nile_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +nile_sound_device::nile_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : setapcm_device<8, 160>(mconfig, NILE_SOUND, tag, owner, clock) { } -st0032_sound_device::st0032_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +st0032_sound_device::st0032_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : setapcm_device<16, 384>(mconfig, ST0032_SOUND, tag, owner, clock) { } diff --git a/src/devices/sound/setapcm.h b/src/devices/sound/setapcm.h index 2da5c147563..ed96f17fe79 100644 --- a/src/devices/sound/setapcm.h +++ b/src/devices/sound/setapcm.h @@ -31,7 +31,7 @@ public: u16 key_r(); protected: - setapcm_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + setapcm_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -82,7 +82,7 @@ private: class nile_sound_device : public setapcm_device<8, 160> { public: - nile_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + nile_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> st0032_sound_device @@ -90,7 +90,7 @@ public: class st0032_sound_device : public setapcm_device<16, 384> { public: - st0032_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + st0032_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; //************************************************************************** diff --git a/src/devices/sound/sn76477.cpp b/src/devices/sound/sn76477.cpp index 1ccbd2fc4b5..90c73099065 100644 --- a/src/devices/sound/sn76477.cpp +++ b/src/devices/sound/sn76477.cpp @@ -143,7 +143,7 @@ static constexpr double out_neg_gain[] = DEFINE_DEVICE_TYPE(SN76477, sn76477_device, "sn76477", "TI SN76477 CSG") -sn76477_device::sn76477_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sn76477_device::sn76477_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SN76477, tag, owner, clock), device_sound_interface(mconfig, *this), m_enable(0), diff --git a/src/devices/sound/sn76477.h b/src/devices/sound/sn76477.h index 6aa4c10c9f0..261c60118db 100644 --- a/src/devices/sound/sn76477.h +++ b/src/devices/sound/sn76477.h @@ -55,7 +55,7 @@ class sn76477_device : public device_t, public device_sound_interface { public: - sn76477_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sn76477_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void set_noise_params(double clock_res, double filter_res, double filter_cap) { diff --git a/src/devices/sound/sn76496.cpp b/src/devices/sound/sn76496.cpp index 96c6a3ba789..37a8cdd6cd3 100644 --- a/src/devices/sound/sn76496.cpp +++ b/src/devices/sound/sn76496.cpp @@ -173,52 +173,52 @@ sn76496_base_device::sn76496_base_device( { } -sn76496_device::sn76496_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sn76496_device::sn76496_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sn76496_base_device(mconfig, SN76496, tag, 0x10000, 0x04, 0x08, false, false, 8, false, true, owner, clock) { } -y2404_device::y2404_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +y2404_device::y2404_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sn76496_base_device(mconfig, Y2404, tag, 0x10000, 0x04, 0x08, false, false, 8, false, true, owner, clock) { } -sn76489_device::sn76489_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sn76489_device::sn76489_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sn76496_base_device(mconfig, SN76489, tag, 0x4000, 0x01, 0x02, true, false, 8, false, true, owner, clock) { } -sn76489a_device::sn76489a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sn76489a_device::sn76489a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sn76496_base_device(mconfig, SN76489A, tag, 0x10000, 0x04, 0x08, false, false, 8, false, true, owner, clock) { } -sn76494_device::sn76494_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sn76494_device::sn76494_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sn76496_base_device(mconfig, SN76494, tag, 0x10000, 0x04, 0x08, false, false, 1, false, true, owner, clock) { } -sn94624_device::sn94624_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sn94624_device::sn94624_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sn76496_base_device(mconfig, SN94624, tag, 0x4000, 0x01, 0x02, true, false, 1, false, true, owner, clock) { } -ncr8496_device::ncr8496_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ncr8496_device::ncr8496_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sn76496_base_device(mconfig, NCR8496, tag, 0x8000, 0x02, 0x20, true, false, 8, true, true, owner, clock) { } -pssj3_device::pssj3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +pssj3_device::pssj3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sn76496_base_device(mconfig, PSSJ3, tag, 0x8000, 0x02, 0x20, false, false, 8, true, true, owner, clock) { } -gamegear_device::gamegear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gamegear_device::gamegear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sn76496_base_device(mconfig, GAMEGEAR, tag, 0x8000, 0x01, 0x08, true, true, 8, false, false, owner, clock) { } -segapsg_device::segapsg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +segapsg_device::segapsg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sn76496_base_device(mconfig, SEGAPSG, tag, 0x8000, 0x01, 0x08, true, false, 8, false, false, owner, clock) { } diff --git a/src/devices/sound/sn76496.h b/src/devices/sound/sn76496.h index f5484248715..f5b33167bdc 100644 --- a/src/devices/sound/sn76496.h +++ b/src/devices/sound/sn76496.h @@ -29,7 +29,7 @@ public: protected: sn76496_base_device(const machine_config &mconfig, device_type type, const char *tag, int feedbackmask, int noisetap1, int noisetap2, bool negate, bool stereo, int clockdivider, - bool ncr, bool sega, device_t *owner, uint32_t clock); + bool ncr, bool sega, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_clock_changed() override; @@ -73,70 +73,70 @@ private: class sn76496_device : public sn76496_base_device { public: - sn76496_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sn76496_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // Y2404 not verified yet. todo: verify; (don't be fooled by the Y, it's a TI chip, not Yamaha) class y2404_device : public sn76496_base_device { public: - y2404_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + y2404_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // SN76489 not verified yet. todo: verify; class sn76489_device : public sn76496_base_device { public: - sn76489_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sn76489_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // SN76489A: whitenoise verified, phase verified, periodic verified (by plgdavid) class sn76489a_device : public sn76496_base_device { public: - sn76489a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sn76489a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // SN76494 not verified, (according to datasheet: same as sn76489a but without the /8 divider) class sn76494_device : public sn76496_base_device { public: - sn76494_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sn76494_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // SN94624 whitenoise verified, phase verified, period verified; verified by PlgDavid class sn94624_device : public sn76496_base_device { public: - sn94624_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sn94624_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // NCR8496 whitenoise verified, phase verified; verified by ValleyBell & NewRisingSun class ncr8496_device : public sn76496_base_device { public: - ncr8496_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ncr8496_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // PSSJ-3 whitenoise verified, phase verified; verified by ValleyBell & NewRisingSun class pssj3_device : public sn76496_base_device { public: - pssj3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pssj3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // Verified by Justin Kerk class gamegear_device : public sn76496_base_device { public: - gamegear_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gamegear_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // todo: verify; from smspower wiki, assumed to have same invert as gamegear class segapsg_device : public sn76496_base_device { public: - segapsg_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + segapsg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; #endif // MAME_SOUND_SN76496_H diff --git a/src/devices/sound/snkwave.cpp b/src/devices/sound/snkwave.cpp index 44e6ba51466..1dda2bcb31c 100644 --- a/src/devices/sound/snkwave.cpp +++ b/src/devices/sound/snkwave.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(SNKWAVE, snkwave_device, "snkwave", "SNK Wave") // snkwave_device - constructor //------------------------------------------------- -snkwave_device::snkwave_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +snkwave_device::snkwave_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNKWAVE, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/snkwave.h b/src/devices/sound/snkwave.h index bf40a33e500..4cc085b6831 100644 --- a/src/devices/sound/snkwave.h +++ b/src/devices/sound/snkwave.h @@ -17,7 +17,7 @@ class snkwave_device : public device_t, public device_sound_interface { public: - snkwave_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snkwave_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void snkwave_w(offs_t offset, uint8_t data); diff --git a/src/devices/sound/sp0250.cpp b/src/devices/sound/sp0250.cpp index 9544adb3c38..75e6c646333 100644 --- a/src/devices/sound/sp0250.cpp +++ b/src/devices/sound/sp0250.cpp @@ -22,7 +22,7 @@ static constexpr int PWM_CLOCKS = 39; DEFINE_DEVICE_TYPE(SP0250, sp0250_device, "sp0250", "GI SP0250 LPC") -sp0250_device::sp0250_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sp0250_device::sp0250_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SP0250, tag, owner, clock), device_sound_interface(mconfig, *this), m_timer(nullptr), diff --git a/src/devices/sound/sp0250.h b/src/devices/sound/sp0250.h index 31c32ef4d5d..4b473d4d05d 100644 --- a/src/devices/sound/sp0250.h +++ b/src/devices/sound/sp0250.h @@ -8,7 +8,7 @@ class sp0250_device : public device_t, public device_sound_interface { public: - sp0250_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sp0250_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto drq() { return m_drq.bind(); } void set_pwm_mode() { m_pwm_mode = true; } diff --git a/src/devices/sound/sp0256.cpp b/src/devices/sound/sp0256.cpp index 7f709ec90c0..b8e69cee24d 100644 --- a/src/devices/sound/sp0256.cpp +++ b/src/devices/sound/sp0256.cpp @@ -51,7 +51,7 @@ DEFINE_DEVICE_TYPE(SP0256, sp0256_device, "sp0256", "GI SP0256 Narrator Speech P // LIVE DEVICE //************************************************************************** -sp0256_device::sp0256_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sp0256_device::sp0256_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SP0256, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_rom(*this, DEVICE_SELF) diff --git a/src/devices/sound/sp0256.h b/src/devices/sound/sp0256.h index 0047b5bb0a3..6b91a399f1f 100644 --- a/src/devices/sound/sp0256.h +++ b/src/devices/sound/sp0256.h @@ -40,7 +40,7 @@ class sp0256_device : public device_t, public device_sound_interface { public: - sp0256_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sp0256_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto data_request_callback() { return m_drq_cb.bind(); } auto standby_callback() { return m_sby_cb.bind(); } diff --git a/src/devices/sound/spkrdev.cpp b/src/devices/sound/spkrdev.cpp index 7d9333d02cb..77d01f880f1 100644 --- a/src/devices/sound/spkrdev.cpp +++ b/src/devices/sound/spkrdev.cpp @@ -84,7 +84,7 @@ static constexpr int RATE_MULTIPLIER = 4; DEFINE_DEVICE_TYPE(SPEAKER_SOUND, speaker_sound_device, "speaker_sound_device", "Filtered DAC") -speaker_sound_device::speaker_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +speaker_sound_device::speaker_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPEAKER_SOUND, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_num_levels(2) diff --git a/src/devices/sound/spkrdev.h b/src/devices/sound/spkrdev.h index 98289857f07..2d8fc409e87 100644 --- a/src/devices/sound/spkrdev.h +++ b/src/devices/sound/spkrdev.h @@ -17,7 +17,7 @@ class speaker_sound_device : public device_t, public device_sound_interface { public: - speaker_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + speaker_sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); ~speaker_sound_device() {} // configuration diff --git a/src/devices/sound/spu.cpp b/src/devices/sound/spu.cpp index 7cc987a8067..0e9a5111379 100644 --- a/src/devices/sound/spu.cpp +++ b/src/devices/sound/spu.cpp @@ -937,7 +937,7 @@ static int shift_register15(int &shift) // spu_device - constructor //------------------------------------------------- -spu_device::spu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, psxcpu_device *cpu) +spu_device::spu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, psxcpu_device *cpu) : spu_device(mconfig, tag, owner, clock) { cpu->spu_read().set(tag, FUNC(spu_device::read)); @@ -947,7 +947,7 @@ spu_device::spu_device(const machine_config &mconfig, const char *tag, device_t irq_handler().set(*cpu->subdevice<psxirq_device>("irq"), FUNC(psxirq_device::intin9)); } -spu_device::spu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +spu_device::spu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SPU, tag, owner, clock), device_sound_interface(mconfig, *this), m_irq_handler(*this), diff --git a/src/devices/sound/spu.h b/src/devices/sound/spu.h index 7aee602e38c..9cb7a4bc74d 100644 --- a/src/devices/sound/spu.h +++ b/src/devices/sound/spu.h @@ -200,8 +200,8 @@ protected: static reverb_preset *find_reverb_preset(const unsigned short *param); public: - spu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, psxcpu_device *cpu); - spu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + spu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, psxcpu_device *cpu); + spu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/sound/st0016.cpp b/src/devices/sound/st0016.cpp index 39d85aed58b..bb90e3483c1 100644 --- a/src/devices/sound/st0016.cpp +++ b/src/devices/sound/st0016.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(ST0016, st0016_device, "st0016", "Seta ST0016 (Audio)") // st0016_device - constructor //------------------------------------------------- -st0016_device::st0016_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +st0016_device::st0016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ST0016, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_memory_interface(mconfig, *this) diff --git a/src/devices/sound/st0016.h b/src/devices/sound/st0016.h index c965687732e..655833e1cfa 100644 --- a/src/devices/sound/st0016.h +++ b/src/devices/sound/st0016.h @@ -15,7 +15,7 @@ class st0016_device : public device_t, public device_sound_interface, public device_memory_interface { public: - st0016_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + st0016_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 snd_r(offs_t offset); void snd_w(offs_t offset, u8 data); diff --git a/src/devices/sound/swp00.cpp b/src/devices/sound/swp00.cpp index c985da89b8c..a793d2352e8 100644 --- a/src/devices/sound/swp00.cpp +++ b/src/devices/sound/swp00.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(SWP00, swp00_device, "swp00", "Yamaha SWP00 (TC170C120SF / XQ036A00) sound chip") -swp00_device::swp00_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +swp00_device::swp00_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SWP00, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/swp00.h b/src/devices/sound/swp00.h index 166ebe0951e..b36daaa2055 100644 --- a/src/devices/sound/swp00.h +++ b/src/devices/sound/swp00.h @@ -14,7 +14,7 @@ class swp00_device : public device_t, public device_sound_interface, public device_rom_interface<25+2, 2, 0, ENDIANNESS_LITTLE> { public: - swp00_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 33868800); + swp00_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = 33868800); void map(address_map &map); diff --git a/src/devices/sound/swp20.cpp b/src/devices/sound/swp20.cpp index da4ef34dc4d..c48bb3d69f1 100644 --- a/src/devices/sound/swp20.cpp +++ b/src/devices/sound/swp20.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(SWP20, swp20_device, "swp20", "Yamaha SWP20 sound chip") -swp20_device::swp20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +swp20_device::swp20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SWP20, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/swp20.h b/src/devices/sound/swp20.h index 83f665fdc5b..5989a42a216 100644 --- a/src/devices/sound/swp20.h +++ b/src/devices/sound/swp20.h @@ -13,7 +13,7 @@ class swp20_device : public device_t, public device_sound_interface, public device_rom_interface<23+2, 1, 0, ENDIANNESS_LITTLE> { public: - swp20_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 11289600); + swp20_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = 11289600); void map(address_map &map); diff --git a/src/devices/sound/swp30.cpp b/src/devices/sound/swp30.cpp index 5dd853f8151..28d01317c14 100644 --- a/src/devices/sound/swp30.cpp +++ b/src/devices/sound/swp30.cpp @@ -171,7 +171,7 @@ static int scount = 0; DEFINE_DEVICE_TYPE(SWP30, swp30_device, "swp30", "Yamaha SWP30 sound chip") -swp30_device::swp30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +swp30_device::swp30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SWP30, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this), diff --git a/src/devices/sound/swp30.h b/src/devices/sound/swp30.h index 0ef1223eb4f..a2f7c989917 100644 --- a/src/devices/sound/swp30.h +++ b/src/devices/sound/swp30.h @@ -14,7 +14,7 @@ class swp30_device : public device_t, public device_sound_interface, public device_rom_interface<25+2, 2, 0, ENDIANNESS_LITTLE> { public: - swp30_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 33868800); + swp30_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL::u(33868800)); void map(address_map &map); diff --git a/src/devices/sound/t6721a.cpp b/src/devices/sound/t6721a.cpp index 2c29e31dc62..4053bae39e9 100644 --- a/src/devices/sound/t6721a.cpp +++ b/src/devices/sound/t6721a.cpp @@ -31,7 +31,7 @@ DEFINE_DEVICE_TYPE(T6721A, t6721a_device, "t6721a", "Toshiba T6721A") // t6721a_device - constructor //------------------------------------------------- -t6721a_device::t6721a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +t6721a_device::t6721a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, T6721A, tag, owner, clock), device_sound_interface(mconfig, *this), m_write_eos(*this), diff --git a/src/devices/sound/t6721a.h b/src/devices/sound/t6721a.h index 52a76393894..ca6b57875a6 100644 --- a/src/devices/sound/t6721a.h +++ b/src/devices/sound/t6721a.h @@ -45,7 +45,7 @@ class t6721a_device : public device_t, public device_sound_interface { public: - t6721a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + t6721a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // static configuration helpers auto eos_handler() { return m_write_eos.bind(); } diff --git a/src/devices/sound/t6w28.cpp b/src/devices/sound/t6w28.cpp index 9525794e489..0f8604cd366 100644 --- a/src/devices/sound/t6w28.cpp +++ b/src/devices/sound/t6w28.cpp @@ -347,7 +347,7 @@ void t6w28_device::set_enable(bool enable) DEFINE_DEVICE_TYPE(T6W28, t6w28_device, "t6w28", "T6W28") -t6w28_device::t6w28_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +t6w28_device::t6w28_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, T6W28, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_channel(nullptr) diff --git a/src/devices/sound/t6w28.h b/src/devices/sound/t6w28.h index 6b953449f87..8090bf5c57a 100644 --- a/src/devices/sound/t6w28.h +++ b/src/devices/sound/t6w28.h @@ -8,7 +8,7 @@ class t6w28_device : public device_t, public device_sound_interface { public: - t6w28_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + t6w28_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint8_t data); void set_enable(bool enable); diff --git a/src/devices/sound/ta7630.cpp b/src/devices/sound/ta7630.cpp index 6dcb84455b9..3888cda6e1b 100644 --- a/src/devices/sound/ta7630.cpp +++ b/src/devices/sound/ta7630.cpp @@ -38,7 +38,7 @@ DEFINE_DEVICE_TYPE(TA7630, ta7630_device, "ta7630", "Toshiba TA7630P") // ta7630_device - constructor //------------------------------------------------- -ta7630_device::ta7630_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ta7630_device::ta7630_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TA7630, tag, owner, clock) // ,device_sound_interface(mconfig, *this) { diff --git a/src/devices/sound/ta7630.h b/src/devices/sound/ta7630.h index e32b4bab407..8a7fed74a74 100644 --- a/src/devices/sound/ta7630.h +++ b/src/devices/sound/ta7630.h @@ -22,7 +22,7 @@ class ta7630_device : public device_t { public: // construction/destruction - ta7630_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ta7630_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // filter setters void set_device_volume(device_sound_interface *device,uint8_t value); diff --git a/src/devices/sound/tc8830f.cpp b/src/devices/sound/tc8830f.cpp index f9f65975347..56e4c89be92 100644 --- a/src/devices/sound/tc8830f.cpp +++ b/src/devices/sound/tc8830f.cpp @@ -24,7 +24,7 @@ // device type definition DEFINE_DEVICE_TYPE(TC8830F, tc8830f_device, "tc8830f", "Toshiba TC8830F") -tc8830f_device::tc8830f_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tc8830f_device::tc8830f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TC8830F, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), m_playing(false), diff --git a/src/devices/sound/tc8830f.h b/src/devices/sound/tc8830f.h index 0a447b02dba..abed8b26787 100644 --- a/src/devices/sound/tc8830f.h +++ b/src/devices/sound/tc8830f.h @@ -21,7 +21,7 @@ class tc8830f_device : public device_t, { public: // construction/destruction - tc8830f_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tc8830f_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void reset(); void write_p(uint8_t data); diff --git a/src/devices/sound/tiaintf.cpp b/src/devices/sound/tiaintf.cpp index 5a64db7bb4c..ea7f1ba3996 100644 --- a/src/devices/sound/tiaintf.cpp +++ b/src/devices/sound/tiaintf.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(TIA, tia_device, "tia_sound", "Atari TIA (Sound)") // tia_device - constructor //------------------------------------------------- -tia_device::tia_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tia_device::tia_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TIA, tag, owner, clock), device_sound_interface(mconfig, *this), m_channel(nullptr), diff --git a/src/devices/sound/tiaintf.h b/src/devices/sound/tiaintf.h index 8ef5d0341f7..1ea6c6a0f96 100644 --- a/src/devices/sound/tiaintf.h +++ b/src/devices/sound/tiaintf.h @@ -14,7 +14,7 @@ class tia_device : public device_t, public device_sound_interface { public: - tia_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tia_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void tia_sound_w(offs_t offset, uint8_t data); diff --git a/src/devices/sound/tms3615.cpp b/src/devices/sound/tms3615.cpp index 3f595c8a97b..1d4da0533c2 100644 --- a/src/devices/sound/tms3615.cpp +++ b/src/devices/sound/tms3615.cpp @@ -18,7 +18,7 @@ DEFINE_DEVICE_TYPE(TMS3615, tms3615_device, "tms3615", "TMS3615") // tms3615_device - constructor //------------------------------------------------- -tms3615_device::tms3615_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms3615_device::tms3615_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMS3615, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_channel(nullptr) diff --git a/src/devices/sound/tms3615.h b/src/devices/sound/tms3615.h index a1eeaab5318..9b93cdefe77 100644 --- a/src/devices/sound/tms3615.h +++ b/src/devices/sound/tms3615.h @@ -19,7 +19,7 @@ public: static constexpr unsigned FOOTAGE_8 = 0; static constexpr unsigned FOOTAGE_16 = 1; - tms3615_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms3615_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void enable_w(int enable); diff --git a/src/devices/sound/tms36xx.cpp b/src/devices/sound/tms36xx.cpp index 08df1d03f51..477fca324f4 100644 --- a/src/devices/sound/tms36xx.cpp +++ b/src/devices/sound/tms36xx.cpp @@ -320,7 +320,7 @@ DEFINE_DEVICE_TYPE(TMS36XX, tms36xx_device, "tms36xx", "TMS36XX") // tms36xx_device - constructor //------------------------------------------------- -tms36xx_device::tms36xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms36xx_device::tms36xx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMS36XX, tag, owner, clock), device_sound_interface(mconfig, *this), m_subtype(nullptr), diff --git a/src/devices/sound/tms36xx.h b/src/devices/sound/tms36xx.h index 5693e3b8e7c..854d04c47fd 100644 --- a/src/devices/sound/tms36xx.h +++ b/src/devices/sound/tms36xx.h @@ -24,7 +24,7 @@ public: TMS3617 = 17 // Monster Bash (13 notes, six outputs) }; - tms36xx_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms36xx_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_subtype(subtype type) { diff --git a/src/devices/sound/tms5110.cpp b/src/devices/sound/tms5110.cpp index a9d3395a4d2..e91a65f4471 100644 --- a/src/devices/sound/tms5110.cpp +++ b/src/devices/sound/tms5110.cpp @@ -1433,12 +1433,12 @@ DEFINE_DEVICE_TYPE(TMS5110A, tms5110a_device, "tms5110a", "TMS5110A") DEFINE_DEVICE_TYPE(M58817, m58817_device, "m58817", "M58817") -tms5110_device::tms5110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms5110_device::tms5110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5110_device(mconfig, TMS5110, tag, owner, clock, TMS5110_IS_TMS5110A) { } -tms5110_device::tms5110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int variant) +tms5110_device::tms5110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int variant) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_table(*this, DEVICE_SELF) @@ -1452,49 +1452,49 @@ tms5110_device::tms5110_device(const machine_config &mconfig, device_type type, } -tms5100_device::tms5100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms5100_device::tms5100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5110_device(mconfig, TMS5100, tag, owner, clock, TMS5110_IS_TMC0281) { } -tmc0281_device::tmc0281_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmc0281_device::tmc0281_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5110_device(mconfig, TMC0281, tag, owner, clock, TMS5110_IS_TMC0281) { } -tms5100a_device::tms5100a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms5100a_device::tms5100a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5110_device(mconfig, TMS5100A, tag, owner, clock, TMS5110_IS_TMC0281D) { } -tmc0281d_device::tmc0281d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmc0281d_device::tmc0281d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5110_device(mconfig, TMC0281D, tag, owner, clock, TMS5110_IS_TMC0281D) { } -cd2801_device::cd2801_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cd2801_device::cd2801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5110_device(mconfig, CD2801, tag, owner, clock, TMS5110_IS_CD2801) { } -cd2802_device::cd2802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cd2802_device::cd2802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5110_device(mconfig, CD2802, tag, owner, clock, TMS5110_IS_CD2802) { } -tms5110a_device::tms5110a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms5110a_device::tms5110a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5110_device(mconfig, TMS5110A, tag, owner, clock, TMS5110_IS_TMS5110A) { } -m58817_device::m58817_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m58817_device::m58817_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5110_device(mconfig, M58817, tag, owner, clock, TMS5110_IS_M58817) { } @@ -1502,7 +1502,7 @@ m58817_device::m58817_device(const machine_config &mconfig, const char *tag, dev DEFINE_DEVICE_TYPE(TMSPROM, tmsprom_device, "tmsprom", "TMSPROM") -tmsprom_device::tmsprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tmsprom_device::tmsprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMSPROM, tag, owner, clock), m_rom(*this, DEVICE_SELF), m_prom(*this, finder_base::DUMMY_TAG), diff --git a/src/devices/sound/tms5110.h b/src/devices/sound/tms5110.h index 9d907668a70..8d2f05199ce 100644 --- a/src/devices/sound/tms5110.h +++ b/src/devices/sound/tms5110.h @@ -33,7 +33,7 @@ public: static constexpr uint8_t CMD_READ_BRANCH = 12; /* 1 1 0 x | 1 */ static constexpr uint8_t CMD_TEST_TALK = 14; /* 1 1 1 x | 3 */ - tms5110_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms5110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto m0() { return m_m0_cb.bind(); } auto m1() { return m_m1_cb.bind(); } @@ -50,7 +50,7 @@ public: int romclk_hack_r(); protected: - tms5110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int variant); + tms5110_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int variant); // device-level overrides virtual void device_start() override; @@ -187,56 +187,56 @@ private: class tms5100_device : public tms5110_device { public: - tms5100_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms5100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tmc0281_device : public tms5110_device { public: - tmc0281_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmc0281_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms5100a_device : public tms5110_device { public: - tms5100a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms5100a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tmc0281d_device : public tms5110_device { public: - tmc0281d_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmc0281d_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cd2801_device : public tms5110_device { public: - cd2801_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cd2801_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cd2802_device : public tms5110_device { public: - cd2802_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cd2802_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms5110a_device : public tms5110_device { public: - tms5110a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms5110a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class m58817_device : public tms5110_device { public: - m58817_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m58817_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t status_r(); }; @@ -259,7 +259,7 @@ DECLARE_DEVICE_TYPE(M58817, m58817_device) class tmsprom_device : public device_t { public: - tmsprom_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tmsprom_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_region(const char *region) { m_prom.set_tag(region); } void set_rom_size(uint32_t rom_size) { m_rom_size = rom_size; } diff --git a/src/devices/sound/tms5220.cpp b/src/devices/sound/tms5220.cpp index 77622b12fef..be059840e05 100644 --- a/src/devices/sound/tms5220.cpp +++ b/src/devices/sound/tms5220.cpp @@ -2085,18 +2085,18 @@ DEFINE_DEVICE_TYPE(TMS5200, tms5200_device, "tms5200", "TMS5200") DEFINE_DEVICE_TYPE(CD2501ECD, cd2501ecd_device, "cd2501ecd", "CD2501ECD") -tms5220c_device::tms5220c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms5220c_device::tms5220c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5220_device(mconfig, TMS5220C, tag, owner, clock, TMS5220_IS_5220C) { } -tms5220_device::tms5220_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms5220_device::tms5220_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5220_device(mconfig, TMS5220, tag, owner, clock, TMS5220_IS_5220) { } -tms5220_device::tms5220_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int variant) +tms5220_device::tms5220_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int variant) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_variant(variant) @@ -2112,19 +2112,19 @@ tms5220_device::tms5220_device(const machine_config &mconfig, device_type type, } -cd2501e_device::cd2501e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cd2501e_device::cd2501e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5220_device(mconfig, CD2501E, tag, owner, clock, TMS5220_IS_CD2501E) { } -tms5200_device::tms5200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms5200_device::tms5200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5220_device(mconfig, TMS5200, tag, owner, clock, TMS5220_IS_5200) { } -cd2501ecd_device::cd2501ecd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cd2501ecd_device::cd2501ecd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms5220_device(mconfig, CD2501ECD, tag, owner, clock, TMS5220_IS_CD2501ECD) { } diff --git a/src/devices/sound/tms5220.h b/src/devices/sound/tms5220.h index 82a589c486d..9a4fab8e24f 100644 --- a/src/devices/sound/tms5220.h +++ b/src/devices/sound/tms5220.h @@ -23,7 +23,7 @@ public: WS=1 }; - tms5220_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms5220_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // IRQ callback function, active low, i.e. state=0 auto irq_cb() { return m_irq_handler.bind(); } @@ -65,7 +65,7 @@ public: READ_LINE_MEMBER( intq_r ); protected: - tms5220_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int variant); + tms5220_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int variant); // device-level overrides virtual void device_start() override; @@ -249,28 +249,28 @@ private: class tms5220c_device : public tms5220_device { public: - tms5220c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms5220c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cd2501e_device : public tms5220_device { public: - cd2501e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cd2501e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms5200_device : public tms5220_device { public: - tms5200_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms5200_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cd2501ecd_device : public tms5220_device { public: - cd2501ecd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cd2501ecd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/sound/tt5665.cpp b/src/devices/sound/tt5665.cpp index 363481669ff..46228a3d02c 100644 --- a/src/devices/sound/tt5665.cpp +++ b/src/devices/sound/tt5665.cpp @@ -117,7 +117,7 @@ const stream_buffer::sample_t tt5665_device::s_volume_table[16] = // tt5665_device - constructor //------------------------------------------------- -tt5665_device::tt5665_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tt5665_device::tt5665_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TT5665, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/tt5665.h b/src/devices/sound/tt5665.h index 5d3f0a155bc..83498aff951 100644 --- a/src/devices/sound/tt5665.h +++ b/src/devices/sound/tt5665.h @@ -35,13 +35,13 @@ public: }; // construction/destruction - tt5665_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, ss_state ss, u8 s0_s1) + tt5665_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, ss_state ss, u8 s0_s1) : tt5665_device(mconfig, tag, owner, clock) { config_ss(ss); config_s0_s1(s0_s1); } - tt5665_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tt5665_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration helpers void config_ss(ss_state ss) { assert(!started()); m_ss_state = ss; } diff --git a/src/devices/sound/uda1344.cpp b/src/devices/sound/uda1344.cpp index 183ba51fd36..51e783c198a 100644 --- a/src/devices/sound/uda1344.cpp +++ b/src/devices/sound/uda1344.cpp @@ -24,7 +24,7 @@ DEFINE_DEVICE_TYPE(UDA1344, uda1344_device, "ud1344", "Philips UDA1344 Codec") -uda1344_device::uda1344_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +uda1344_device::uda1344_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UDA1344, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr) diff --git a/src/devices/sound/uda1344.h b/src/devices/sound/uda1344.h index 7bb07856df7..eeac89d53cc 100644 --- a/src/devices/sound/uda1344.h +++ b/src/devices/sound/uda1344.h @@ -14,7 +14,7 @@ class uda1344_device : public device_t, public device_sound_interface { public: - uda1344_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + uda1344_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void l3_addr_w(offs_t offset, uint8_t data); void l3_data_w(offs_t offset, uint8_t data); diff --git a/src/devices/sound/upd1771.cpp b/src/devices/sound/upd1771.cpp index 4e865ea2c42..554bfa68890 100644 --- a/src/devices/sound/upd1771.cpp +++ b/src/devices/sound/upd1771.cpp @@ -237,7 +237,7 @@ const unsigned char noise_tbl[]= DEFINE_DEVICE_TYPE(UPD1771C, upd1771c_device, "upd1771c", "NEC uPD1771C 017") -upd1771c_device::upd1771c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd1771c_device::upd1771c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD1771C, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_ack_handler(*this) diff --git a/src/devices/sound/upd1771.h b/src/devices/sound/upd1771.h index 7c5cc5f7f95..432da4003bb 100644 --- a/src/devices/sound/upd1771.h +++ b/src/devices/sound/upd1771.h @@ -18,7 +18,7 @@ class upd1771c_device : public device_t, public device_sound_interface { public: - upd1771c_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd1771c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto ack_handler() { return m_ack_handler.bind(); } diff --git a/src/devices/sound/upd7752.cpp b/src/devices/sound/upd7752.cpp index 7c063fbee95..31949384492 100644 --- a/src/devices/sound/upd7752.cpp +++ b/src/devices/sound/upd7752.cpp @@ -43,7 +43,7 @@ void upd7752_device::upd7752_ram(address_map &map) // upd7752_device - constructor //------------------------------------------------- -upd7752_device::upd7752_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd7752_device::upd7752_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD7752, tag, owner, clock), device_sound_interface(mconfig, *this), device_memory_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/upd7752.h b/src/devices/sound/upd7752.h index 9693ee99f4d..d143f7e73f2 100644 --- a/src/devices/sound/upd7752.h +++ b/src/devices/sound/upd7752.h @@ -16,7 +16,7 @@ class upd7752_device : public device_t, public device_sound_interface, public de { public: // construction/destruction - upd7752_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7752_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations void write(offs_t offset, uint8_t data); diff --git a/src/devices/sound/upd7759.cpp b/src/devices/sound/upd7759.cpp index ea1790a40b5..58f12396431 100644 --- a/src/devices/sound/upd7759.cpp +++ b/src/devices/sound/upd7759.cpp @@ -147,7 +147,7 @@ #define FRAC_MASK (FRAC_ONE - 1) -upd775x_device::upd775x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +upd775x_device::upd775x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) @@ -183,13 +183,13 @@ upd775x_device::upd775x_device(const machine_config &mconfig, device_type type, DEFINE_DEVICE_TYPE(UPD7759, upd7759_device, "upd7759", "NEC uPD7759") -upd7759_device::upd7759_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd7759_device::upd7759_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd7759_device(mconfig, UPD7759, tag, owner, clock) { } -upd7759_device::upd7759_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +upd7759_device::upd7759_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : upd775x_device(mconfig, type, tag, owner, clock) , m_drqcallback(*this) , m_timer(nullptr) @@ -199,12 +199,12 @@ upd7759_device::upd7759_device(const machine_config &mconfig, device_type type, DEFINE_DEVICE_TYPE(UPD7756, upd7756_device, "upd7756", "NEC uPD7756") -upd7756_device::upd7756_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd7756_device::upd7756_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : upd7756_device(mconfig, UPD7756, tag, owner, clock) { } -upd7756_device::upd7756_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +upd7756_device::upd7756_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : upd775x_device(mconfig, type, tag, owner, clock) { } diff --git a/src/devices/sound/upd7759.h b/src/devices/sound/upd7759.h index f23bdb51ac3..7a9dcbd127c 100644 --- a/src/devices/sound/upd7759.h +++ b/src/devices/sound/upd7759.h @@ -18,7 +18,7 @@ class upd775x_device : public device_t, public device_rom_interface<17> { public: - enum : u32 { STANDARD_CLOCK = 640'000 }; + static constexpr XTAL STANDARD_CLOCK = XTAL::u(640'000); DECLARE_WRITE_LINE_MEMBER( reset_w ); DECLARE_WRITE_LINE_MEMBER( start_w ); @@ -63,7 +63,7 @@ protected: MODE_SLAVE }; - upd775x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + upd775x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -128,12 +128,12 @@ class upd7759_device : public upd775x_device public: auto drq() { return m_drqcallback.bind(); } - upd7759_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = STANDARD_CLOCK); + upd7759_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = STANDARD_CLOCK); DECLARE_WRITE_LINE_MEMBER( md_w ); protected: - upd7759_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + upd7759_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -152,10 +152,10 @@ protected: class upd7756_device : public upd775x_device { public: - upd7756_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = STANDARD_CLOCK); + upd7756_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = STANDARD_CLOCK); protected: - upd7756_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + upd7756_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_reset() override; diff --git a/src/devices/sound/upd934g.cpp b/src/devices/sound/upd934g.cpp index b57886685e1..5bb84d6745d 100644 --- a/src/devices/sound/upd934g.cpp +++ b/src/devices/sound/upd934g.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(UPD934G, upd934g_device, "upd934g", "NEC uPD934G") // upd934g_device - constructor //------------------------------------------------- -upd934g_device::upd934g_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +upd934g_device::upd934g_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD934G, tag, owner, clock), device_sound_interface(mconfig, *this), m_data_cb(*this), diff --git a/src/devices/sound/upd934g.h b/src/devices/sound/upd934g.h index 1340dd7bf60..77bf9fa3083 100644 --- a/src/devices/sound/upd934g.h +++ b/src/devices/sound/upd934g.h @@ -24,7 +24,7 @@ public: static constexpr feature_type imperfect_features() { return feature::SOUND; } // construction/destruction - upd934g_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd934g_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration auto data_callback() { return m_data_cb.bind(); } diff --git a/src/devices/sound/vgm_visualizer.cpp b/src/devices/sound/vgm_visualizer.cpp index bab3c909ddf..ac5287330bf 100644 --- a/src/devices/sound/vgm_visualizer.cpp +++ b/src/devices/sound/vgm_visualizer.cpp @@ -52,7 +52,7 @@ DEFINE_DEVICE_TYPE(VGMVIZ, vgmviz_device, "vgmviz", "VGM Visualizer") // vgmviz_device - constructor //------------------------------------------------- -vgmviz_device::vgmviz_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +vgmviz_device::vgmviz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VGMVIZ, tag, owner, clock) , device_mixer_interface(mconfig, *this, 2) , m_screen(*this, "screen") diff --git a/src/devices/sound/vgm_visualizer.h b/src/devices/sound/vgm_visualizer.h index 516e4e4bfad..e4001dd53a2 100644 --- a/src/devices/sound/vgm_visualizer.h +++ b/src/devices/sound/vgm_visualizer.h @@ -39,11 +39,7 @@ class vgmviz_device : public device_t, public device_mixer_interface { public: // construction/destruction - vgmviz_device(const machine_config &mconfig, const char *tag, device_t *owner) - : vgmviz_device(mconfig, tag, owner, 0) - { - } - vgmviz_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + vgmviz_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual ~vgmviz_device(); void cycle_viz_mode(); diff --git a/src/devices/sound/vlm5030.cpp b/src/devices/sound/vlm5030.cpp index 15f302f307e..e2502ffbb7d 100644 --- a/src/devices/sound/vlm5030.cpp +++ b/src/devices/sound/vlm5030.cpp @@ -159,7 +159,7 @@ static const int vlm5030_speed_table[8] = DEFINE_DEVICE_TYPE(VLM5030, vlm5030_device, "vlm5030", "Sanyo VLM5030") -vlm5030_device::vlm5030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vlm5030_device::vlm5030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VLM5030, tag, owner, clock), device_sound_interface(mconfig, *this), device_rom_interface(mconfig, *this), diff --git a/src/devices/sound/vlm5030.h b/src/devices/sound/vlm5030.h index 1eddcdc45bf..aaa8aebb9cd 100644 --- a/src/devices/sound/vlm5030.h +++ b/src/devices/sound/vlm5030.h @@ -10,7 +10,7 @@ class vlm5030_device : public device_t, public device_sound_interface, public device_rom_interface<16> { public: - vlm5030_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vlm5030_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); /* get BSY pin level */ DECLARE_READ_LINE_MEMBER( bsy ); diff --git a/src/devices/sound/votrax.cpp b/src/devices/sound/votrax.cpp index 1ec2343f72f..237db849a9b 100644 --- a/src/devices/sound/votrax.cpp +++ b/src/devices/sound/votrax.cpp @@ -75,7 +75,7 @@ const double votrax_sc01_device::s_glottal_wave[9] = }; -votrax_sc01_device::votrax_sc01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +votrax_sc01_device::votrax_sc01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VOTRAX_SC01, tag, owner, clock), device_sound_interface(mconfig, *this), m_stream(nullptr), diff --git a/src/devices/sound/votrax.h b/src/devices/sound/votrax.h index 2dcc7d087da..58ab20af024 100644 --- a/src/devices/sound/votrax.h +++ b/src/devices/sound/votrax.h @@ -20,7 +20,7 @@ public: static constexpr feature_type imperfect_features() { return feature::SOUND; } // construction/destruction - votrax_sc01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + votrax_sc01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto ar_callback() { return m_ar_cb.bind(); } diff --git a/src/devices/sound/vrc6.cpp b/src/devices/sound/vrc6.cpp index d9b36f5b8a6..e43d3a43c04 100644 --- a/src/devices/sound/vrc6.cpp +++ b/src/devices/sound/vrc6.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(VRC6, vrc6snd_device, "vrc6snd", "Konami 053329 VRC VI (Sound // vrc6snd_device - constructor //------------------------------------------------- -vrc6snd_device::vrc6snd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +vrc6snd_device::vrc6snd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VRC6, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_freqctrl(0), m_pulsectrl{ 0, 0 }, m_sawrate(0), m_master_freq(0) diff --git a/src/devices/sound/vrc6.h b/src/devices/sound/vrc6.h index eb17dabff82..5464d869fa9 100644 --- a/src/devices/sound/vrc6.h +++ b/src/devices/sound/vrc6.h @@ -22,7 +22,7 @@ class vrc6snd_device : public device_t, public device_sound_interface { public: // construction/destruction - vrc6snd_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + vrc6snd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, u8 data); diff --git a/src/devices/sound/vrender0.cpp b/src/devices/sound/vrender0.cpp index fd86b56adea..4e630cbf1ea 100644 --- a/src/devices/sound/vrender0.cpp +++ b/src/devices/sound/vrender0.cpp @@ -121,7 +121,7 @@ DEFINE_DEVICE_TYPE(SOUND_VRENDER0, vr0sound_device, "vr0sound", "MagicEyes VRend // vr0sound_device - constructor //------------------------------------------------- -vr0sound_device::vr0sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +vr0sound_device::vr0sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SOUND_VRENDER0, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_memory_interface(mconfig, *this) diff --git a/src/devices/sound/vrender0.h b/src/devices/sound/vrender0.h index 1e234232c69..9667a8d9ece 100644 --- a/src/devices/sound/vrender0.h +++ b/src/devices/sound/vrender0.h @@ -27,7 +27,7 @@ public: static constexpr feature_type imperfect_features() { return feature::SOUND; } - vr0sound_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + vr0sound_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_callback() { return m_irq_cb.bind(); } diff --git a/src/devices/sound/wave.cpp b/src/devices/sound/wave.cpp index 1a53aaa95f7..3adea26793d 100644 --- a/src/devices/sound/wave.cpp +++ b/src/devices/sound/wave.cpp @@ -25,7 +25,7 @@ DEFINE_DEVICE_TYPE(WAVE, wave_device, "wave", "Cassette Sound") -wave_device::wave_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +wave_device::wave_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, WAVE, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_cass(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/sound/wave.h b/src/devices/sound/wave.h index 73c9b94873a..e374717bad9 100644 --- a/src/devices/sound/wave.h +++ b/src/devices/sound/wave.h @@ -23,11 +23,11 @@ class wave_device : public device_t, public device_sound_interface public: template <typename T> wave_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cassette_tag) - : wave_device(mconfig, tag, owner, uint32_t(0)) + : wave_device(mconfig, tag, owner) { m_cass.set_tag(std::forward<T>(cassette_tag)); } - wave_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + wave_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> void set_cassette_tag(T &&cassette_tag) { m_cass.set_tag(std::forward<T>(cassette_tag)); } diff --git a/src/devices/sound/x1_010.cpp b/src/devices/sound/x1_010.cpp index d18f40c5f84..c56a6be63b5 100644 --- a/src/devices/sound/x1_010.cpp +++ b/src/devices/sound/x1_010.cpp @@ -86,7 +86,7 @@ struct X1_010_CHANNEL DEFINE_DEVICE_TYPE(X1_010, x1_010_device, "x1_010", "Seta X1-010") -x1_010_device::x1_010_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +x1_010_device::x1_010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, X1_010, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/x1_010.h b/src/devices/sound/x1_010.h index a107534d4ae..4cdab69865c 100644 --- a/src/devices/sound/x1_010.h +++ b/src/devices/sound/x1_010.h @@ -10,7 +10,7 @@ class x1_010_device : public device_t, public device_sound_interface, public device_rom_interface<20> { public: - x1_010_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + x1_010_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 read(offs_t offset); void write(offs_t offset, u8 data); diff --git a/src/devices/sound/xt446.cpp b/src/devices/sound/xt446.cpp index 9dc3053f1ff..b4cd6cbacd2 100644 --- a/src/devices/sound/xt446.cpp +++ b/src/devices/sound/xt446.cpp @@ -35,7 +35,7 @@ ROM_START( xt446 ) ROM_LOAD32_WORD( "xt463a0.ic38", 0x1000002, 0x400000, CRC(cce5f8d3) SHA1(bdca8c5158f452f2b5535c7d658c9b22c6d66048) ) ROM_END -xt446_device::xt446_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +xt446_device::xt446_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, XT446, tag, owner, clock) , device_mixer_interface(mconfig, *this, 2) , m_maincpu(*this, "maincpu") diff --git a/src/devices/sound/xt446.h b/src/devices/sound/xt446.h index 5404dfd3466..c845f4ad776 100644 --- a/src/devices/sound/xt446.h +++ b/src/devices/sound/xt446.h @@ -18,7 +18,7 @@ class xt446_device : public device_t, public device_mixer_interface { public: - xt446_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + xt446_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void midi_w(int state) { m_midi_serial->rx_w(state); } diff --git a/src/devices/sound/ym2154.cpp b/src/devices/sound/ym2154.cpp index 287529aeeec..9dec45d504f 100644 --- a/src/devices/sound/ym2154.cpp +++ b/src/devices/sound/ym2154.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(YM2154, ym2154_device, "ym2154", "YM2154 (RYP4)") // ym2154_device - constructor //------------------------------------------------- -ym2154_device::ym2154_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2154_device::ym2154_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, YM2154, tag, owner, clock), device_sound_interface(mconfig, *this), device_memory_interface(mconfig, *this), diff --git a/src/devices/sound/ym2154.h b/src/devices/sound/ym2154.h index e7f287409fa..613a27abd47 100644 --- a/src/devices/sound/ym2154.h +++ b/src/devices/sound/ym2154.h @@ -19,7 +19,7 @@ class ym2154_device : public device_t, public device_sound_interface, public dev public: // internal constructor - ym2154_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2154_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq_handler() { return m_update_irq.bind(); } diff --git a/src/devices/sound/ymf271.cpp b/src/devices/sound/ymf271.cpp index 886d6d516d5..bbb36481fa5 100644 --- a/src/devices/sound/ymf271.cpp +++ b/src/devices/sound/ymf271.cpp @@ -1788,7 +1788,7 @@ void ymf271_device::rom_bank_pre_change() DEFINE_DEVICE_TYPE(YMF271, ymf271_device, "ymf271", "Yamaha YMF271 OPX") -ymf271_device::ymf271_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ymf271_device::ymf271_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, YMF271, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/ymf271.h b/src/devices/sound/ymf271.h index 04d49c57f09..c3113e8c707 100644 --- a/src/devices/sound/ymf271.h +++ b/src/devices/sound/ymf271.h @@ -12,7 +12,7 @@ class ymf271_device : public device_t, public device_sound_interface, public dev public: static constexpr feature_type imperfect_features() { return feature::SOUND; } - ymf271_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ymf271_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq_handler() { return m_irq_handler.bind(); } diff --git a/src/devices/sound/ymfm_mame.h b/src/devices/sound/ymfm_mame.h index d0161426619..27a7d002b18 100644 --- a/src/devices/sound/ymfm_mame.h +++ b/src/devices/sound/ymfm_mame.h @@ -30,7 +30,7 @@ class ym_generic_device : public device_t, public device_sound_interface, public { public: // constructor - ym_generic_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, device_type type) : + ym_generic_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, device_type type) : device_t(mconfig, type, tag, owner, clock), device_sound_interface(mconfig, *this), m_timer{ nullptr, nullptr }, @@ -177,7 +177,7 @@ protected: public: // constructor - ymfm_device_base(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, device_type type) : + ymfm_device_base(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, device_type type) : ym_generic_device(mconfig, tag, owner, clock, type), m_stream(nullptr), m_chip(*this) @@ -201,7 +201,7 @@ protected: ym_generic_device::device_start(); // allocate our stream - m_stream = device_sound_interface::stream_alloc(0, OUTPUTS, m_chip.sample_rate(device_t::clock())); + m_stream = device_sound_interface::stream_alloc(0, OUTPUTS, XTAL::u(m_chip.sample_rate(device_t::clock().value()))); // compute the size of the save buffer by doing an initial save ymfm::ymfm_saved_state state(m_save_blob, true); @@ -221,7 +221,7 @@ protected: virtual void device_clock_changed() override { if (m_stream != nullptr) - m_stream->set_sample_rate(m_chip.sample_rate(device_t::clock())); + m_stream->set_sample_rate(XTAL::u(m_chip.sample_rate(device_t::clock().value()))); } // handle pre-saving by filling the blob @@ -303,7 +303,7 @@ class ymfm_ssg_device_base : public ymfm_device_base<ChipClass> public: // constructor - ymfm_ssg_device_base(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, device_type type) : + ymfm_ssg_device_base(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, device_type type) : ymfm_device_base<ChipClass>(mconfig, tag, owner, clock, type) { } diff --git a/src/devices/sound/ymopl.cpp b/src/devices/sound/ymopl.cpp index 92e9eb99928..e647e6fd4bf 100644 --- a/src/devices/sound/ymopl.cpp +++ b/src/devices/sound/ymopl.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(YM3526, ym3526_device, "ym3526", "YM3526 OPL") // ym3526_device - constructor //------------------------------------------------- -ym3526_device::ym3526_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym3526_device::ym3526_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym3526>(mconfig, tag, owner, clock, YM3526) { } @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(Y8950, y8950_device, "y8950", "Y8950 OPL MSX-Audio") // y8950_device - constructor //------------------------------------------------- -y8950_device::y8950_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +y8950_device::y8950_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::y8950>(mconfig, tag, owner, clock, Y8950), device_rom_interface(mconfig, *this) { @@ -89,7 +89,7 @@ DEFINE_DEVICE_TYPE(YM3812, ym3812_device, "ym3812", "YM3812 OPL2") // ym3812_device - constructor //------------------------------------------------- -ym3812_device::ym3812_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym3812_device::ym3812_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym3812>(mconfig, tag, owner, clock, YM3812) { } @@ -106,7 +106,7 @@ DEFINE_DEVICE_TYPE(YMF262, ymf262_device, "ymf262", "YMF262 OPL3") // ymf262_device - constructor //------------------------------------------------- -ymf262_device::ymf262_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ymf262_device::ymf262_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ymf262>(mconfig, tag, owner, clock, YMF262) { } @@ -123,7 +123,7 @@ DEFINE_DEVICE_TYPE(YMF278B, ymf278b_device, "ymf278b", "YMF278B OPL4") // ymf278b_device - constructor //------------------------------------------------- -ymf278b_device::ymf278b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ymf278b_device::ymf278b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ymf278b>(mconfig, tag, owner, clock, YMF278B), device_rom_interface(mconfig, *this) { @@ -192,7 +192,7 @@ DEFINE_DEVICE_TYPE(YM2413, ym2413_device, "ym2413", "YM2413 OPLL") // ym2413_device - constructor //------------------------------------------------- -ym2413_device::ym2413_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2413_device::ym2413_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym2413>(mconfig, tag, owner, clock, YM2413), m_internal(*this, "internal") { @@ -240,7 +240,7 @@ DEFINE_DEVICE_TYPE(YM2423, ym2423_device, "ym2423", "YM2423 OPLL-X") // ym2423_device - constructor //------------------------------------------------- -ym2423_device::ym2423_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2423_device::ym2423_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym2423>(mconfig, tag, owner, clock, YM2423), m_internal(*this, "internal") { @@ -288,7 +288,7 @@ DEFINE_DEVICE_TYPE(YMF281, ymf281_device, "ymf281", "YMF281 OPLLP") // ymf281_device - constructor //------------------------------------------------- -ymf281_device::ymf281_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ymf281_device::ymf281_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ymf281>(mconfig, tag, owner, clock, YMF281), m_internal(*this, "internal") { @@ -336,7 +336,7 @@ DEFINE_DEVICE_TYPE(DS1001, ds1001_device, "ds1001", "Yamaha DS1001 / Konami 0539 // ds1001_device - constructor //------------------------------------------------- -ds1001_device::ds1001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ds1001_device::ds1001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ds1001>(mconfig, tag, owner, clock, DS1001), m_internal(*this, "internal") { diff --git a/src/devices/sound/ymopl.h b/src/devices/sound/ymopl.h index 6d5f279be03..e44627db955 100644 --- a/src/devices/sound/ymopl.h +++ b/src/devices/sound/ymopl.h @@ -19,7 +19,7 @@ class ym3526_device : public ymfm_device_base<ymfm::ym3526> { public: // constructor - ym3526_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym3526_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -33,7 +33,7 @@ class y8950_device : public ymfm_device_base<ymfm::y8950>, public device_rom_int public: // constructor - y8950_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + y8950_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto io_read() { return io_read_handler(0); } @@ -63,7 +63,7 @@ class ym3812_device : public ymfm_device_base<ymfm::ym3812> { public: // constructor - ym3812_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym3812_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -75,7 +75,7 @@ class ymf262_device : public ymfm_device_base<ymfm::ymf262> { public: // constructor - ymf262_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ymf262_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional register writes void address_hi_w(u8 data) { update_streams().write_address_hi(data); } @@ -93,7 +93,7 @@ class ymf278b_device : public ymfm_device_base<ymfm::ymf278b>, public device_rom public: // constructor - ymf278b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ymf278b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional register reads uint8_t data_pcm_r() { return update_streams().read_data_pcm(); } @@ -128,7 +128,7 @@ class ym2413_device : public ymfm_device_base<ymfm::ym2413> public: // constructor - ym2413_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2413_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -150,7 +150,7 @@ class ym2423_device : public ymfm_device_base<ymfm::ym2423> public: // constructor - ym2423_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2423_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -172,7 +172,7 @@ class ymf281_device : public ymfm_device_base<ymfm::ymf281> public: // constructor - ymf281_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ymf281_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides @@ -194,7 +194,7 @@ class ds1001_device : public ymfm_device_base<ymfm::ds1001> public: // constructor - ds1001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ds1001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/sound/ymopm.cpp b/src/devices/sound/ymopm.cpp index a75da72b449..1f73821a48e 100644 --- a/src/devices/sound/ymopm.cpp +++ b/src/devices/sound/ymopm.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(YM2151, ym2151_device, "ym2151", "YM2151 OPM") // ym2151_device - constructor //------------------------------------------------- -ym2151_device::ym2151_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2151_device::ym2151_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym2151>(mconfig, tag, owner, clock, YM2151), m_reset_state(1) { @@ -75,7 +75,7 @@ DEFINE_DEVICE_TYPE(YM2164, ym2164_device, "ym2164", "YM2164 OPP") // ym2164_device - constructor //------------------------------------------------- -ym2164_device::ym2164_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2164_device::ym2164_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym2164>(mconfig, tag, owner, clock, YM2164) { } diff --git a/src/devices/sound/ymopm.h b/src/devices/sound/ymopm.h index ce4a7c87f51..f156f40397c 100644 --- a/src/devices/sound/ymopm.h +++ b/src/devices/sound/ymopm.h @@ -20,7 +20,7 @@ class ym2151_device : public ymfm_device_base<ymfm::ym2151> public: // constructor - ym2151_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2151_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers, handled by the interface auto port_write_handler() { return io_write_handler(); } @@ -47,7 +47,7 @@ class ym2164_device : public ymfm_device_base<ymfm::ym2164> { public: // constructor - ym2164_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2164_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers, handled by the interface auto port_write_handler() { return io_write_handler(); } diff --git a/src/devices/sound/ymopn.cpp b/src/devices/sound/ymopn.cpp index de18330fa89..9f373941145 100644 --- a/src/devices/sound/ymopn.cpp +++ b/src/devices/sound/ymopn.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(YM2203, ym2203_device, "ym2203", "YM2203 OPN") // ym2203_device - constructor //------------------------------------------------- -ym2203_device::ym2203_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2203_device::ym2203_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_ssg_device_base<ymfm::ym2203>(mconfig, tag, owner, clock, YM2203) { } @@ -46,7 +46,7 @@ DEFINE_DEVICE_TYPE(YM2608, ym2608_device, "ym2608", "YM2608 OPNA") // ym2608_device - constructor //------------------------------------------------- -ym2608_device::ym2608_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2608_device::ym2608_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_ssg_device_base<ymfm::ym2608>(mconfig, tag, owner, clock, YM2608), device_rom_interface(mconfig, *this), m_internal(*this, "internal") @@ -147,7 +147,7 @@ void ym2608_device::ymfm_external_write(ymfm::access_class type, uint32_t offset //------------------------------------------------- template<typename ChipClass> -ym2610_device_base<ChipClass>::ym2610_device_base(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, device_type type) : +ym2610_device_base<ChipClass>::ym2610_device_base(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, device_type type) : ymfm_ssg_device_base<ChipClass>(mconfig, tag, owner, clock, type), device_memory_interface(mconfig, *this), m_adpcm_a_config("adpcm_a", ENDIANNESS_LITTLE, 8, 24, 0), @@ -227,7 +227,7 @@ DEFINE_DEVICE_TYPE(YM2610, ym2610_device, "ym2610", "YM2610 OPNB") // ym2610_device - constructor //------------------------------------------------- -ym2610_device::ym2610_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2610_device::ym2610_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ym2610_device_base<ymfm::ym2610>(mconfig, tag, owner, clock, YM2610) { } @@ -243,7 +243,7 @@ DEFINE_DEVICE_TYPE(YM2610B, ym2610b_device, "ym2610b", "YM2610B OPNB2") // ym2610b_device - constructor //------------------------------------------------- -ym2610b_device::ym2610b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2610b_device::ym2610b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ym2610_device_base<ymfm::ym2610b>(mconfig, tag, owner, clock, YM2610B) { } @@ -260,7 +260,7 @@ DEFINE_DEVICE_TYPE(YM2612, ym2612_device, "ym2612", "YM2612 OPN2") // ym2612_device - constructor //------------------------------------------------- -ym2612_device::ym2612_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2612_device::ym2612_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym2612>(mconfig, tag, owner, clock, YM2612) { } @@ -277,7 +277,7 @@ DEFINE_DEVICE_TYPE(YM3438, ym3438_device, "ym3438", "YM3438 OPN2C") // ym3438_device - constructor //------------------------------------------------- -ym3438_device::ym3438_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym3438_device::ym3438_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym3438>(mconfig, tag, owner, clock, YM3438) { } @@ -294,7 +294,7 @@ DEFINE_DEVICE_TYPE(YMF276, ymf276_device, "ymf276", "YMF276 OPN2L") // ymf276_device - constructor //------------------------------------------------- -ymf276_device::ymf276_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ymf276_device::ymf276_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ymf276>(mconfig, tag, owner, clock, YMF276) { } diff --git a/src/devices/sound/ymopn.h b/src/devices/sound/ymopn.h index 93b0999be8c..65cbde934e0 100644 --- a/src/devices/sound/ymopn.h +++ b/src/devices/sound/ymopn.h @@ -21,7 +21,7 @@ class ym2203_device : public ymfm_ssg_device_base<ymfm::ym2203> public: // constructor - ym2203_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2203_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers, handled by the interface auto port_a_read_callback() { return io_read_handler(0); } @@ -48,7 +48,7 @@ class ym2608_device : public ymfm_ssg_device_base<ymfm::ym2608>, public device_r public: // constructor - ym2608_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2608_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers, handled by the interface auto port_a_read_callback() { return io_read_handler(0); } @@ -92,7 +92,7 @@ class ym2610_device_base : public ymfm_ssg_device_base<ChipClass>, public device public: // constructor - ym2610_device_base(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, device_type type); + ym2610_device_base(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, device_type type); // additional register reads u8 data_r() { return update_streams().read_data(); } @@ -131,7 +131,7 @@ DECLARE_DEVICE_TYPE(YM2610, ym2610_device); class ym2610_device : public ym2610_device_base<ymfm::ym2610> { public: - ym2610_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2610_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -142,7 +142,7 @@ DECLARE_DEVICE_TYPE(YM2610B, ym2610b_device); class ym2610b_device : public ym2610_device_base<ymfm::ym2610b> { public: - ym2610b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2610b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -154,7 +154,7 @@ class ym2612_device : public ymfm_device_base<ymfm::ym2612> { public: // constructor - ym2612_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2612_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional register writes void address_hi_w(u8 data) { update_streams().write_address_hi(data); } @@ -170,7 +170,7 @@ class ym3438_device : public ymfm_device_base<ymfm::ym3438> { public: // constructor - ym3438_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym3438_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional register writes void address_hi_w(u8 data) { update_streams().write_address_hi(data); } @@ -186,7 +186,7 @@ class ymf276_device : public ymfm_device_base<ymfm::ymf276> { public: // constructor - ymf276_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ymf276_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // additional register writes void address_hi_w(u8 data) { update_streams().write_address_hi(data); } diff --git a/src/devices/sound/ymopq.cpp b/src/devices/sound/ymopq.cpp index 3286dd7cf3b..4bc5fb21252 100644 --- a/src/devices/sound/ymopq.cpp +++ b/src/devices/sound/ymopq.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(YM3806, ym3806_device, "ym3806", "YM3806 OPQ") // ym3806_device - constructor //------------------------------------------------- -ym3806_device::ym3806_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym3806_device::ym3806_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym3806>(mconfig, tag, owner, clock, YM3806) { } @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(YM3533, ym3533_device, "ym3533", "YM3533 OPQ") // ym3533_device - constructor //------------------------------------------------- -ym3533_device::ym3533_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym3533_device::ym3533_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym3533>(mconfig, tag, owner, clock, YM3533) { } diff --git a/src/devices/sound/ymopq.h b/src/devices/sound/ymopq.h index 39a76e7307d..f2d7f31608e 100644 --- a/src/devices/sound/ymopq.h +++ b/src/devices/sound/ymopq.h @@ -18,7 +18,7 @@ class ym3806_device : public ymfm_device_base<ymfm::ym3806> { public: // constructor - ym3806_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym3806_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -30,7 +30,7 @@ class ym3533_device : public ymfm_device_base<ymfm::ym3533> { public: // constructor - ym3533_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym3533_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; #endif // MAME_SOUND_YMOPQ_H diff --git a/src/devices/sound/ymopz.cpp b/src/devices/sound/ymopz.cpp index cf629cb7779..c503592dfd1 100644 --- a/src/devices/sound/ymopz.cpp +++ b/src/devices/sound/ymopz.cpp @@ -16,7 +16,7 @@ DEFINE_DEVICE_TYPE(YM2414, ym2414_device, "ym2414", "YM2414 OPZ") // ym2414_device - constructor //------------------------------------------------- -ym2414_device::ym2414_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ym2414_device::ym2414_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymfm_device_base<ymfm::ym2414>(mconfig, tag, owner, clock, YM2414) { } diff --git a/src/devices/sound/ymopz.h b/src/devices/sound/ymopz.h index 133da4160f4..33d3cf3292a 100644 --- a/src/devices/sound/ymopz.h +++ b/src/devices/sound/ymopz.h @@ -20,7 +20,7 @@ class ym2414_device : public ymfm_device_base<ymfm::ym2414> public: // constructor - ym2414_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ym2414_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers, handled by the interface auto port_write_handler() { return io_write_handler(); } diff --git a/src/devices/sound/ymz280b.cpp b/src/devices/sound/ymz280b.cpp index ef4e9bf1190..d0a2750aa7a 100644 --- a/src/devices/sound/ymz280b.cpp +++ b/src/devices/sound/ymz280b.cpp @@ -551,7 +551,7 @@ void ymz280b_device::device_start() compute_tables(); /* initialize the rest of the structure */ - m_master_clock = (double)clock() / 384.0; + m_master_clock = clock() / 384; m_irq_handler.resolve(); for (int i = 0; i < 8; i++) @@ -641,7 +641,7 @@ void ymz280b_device::device_reset() void ymz280b_device::device_clock_changed() { - m_master_clock = (double)clock() / 384.0; + m_master_clock = clock() / 384; m_stream->set_sample_rate(INTERNAL_SAMPLE_RATE); } @@ -908,7 +908,7 @@ void ymz280b_device::write(offs_t offset, u8 data) DEFINE_DEVICE_TYPE(YMZ280B, ymz280b_device, "ymz280b", "Yamaha YMZ280B PCMD8") -ymz280b_device::ymz280b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ymz280b_device::ymz280b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, YMZ280B, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_rom_interface(mconfig, *this) diff --git a/src/devices/sound/ymz280b.h b/src/devices/sound/ymz280b.h index 319f85b83f4..29f648c38e6 100644 --- a/src/devices/sound/ymz280b.h +++ b/src/devices/sound/ymz280b.h @@ -19,7 +19,7 @@ class ymz280b_device : public device_t, public device_sound_interface, public device_rom_interface<24> { public: - ymz280b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ymz280b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq_handler() { return m_irq_handler.bind(); } @@ -104,7 +104,7 @@ private: devcb_write_line m_irq_handler; /* IRQ callback */ - double m_master_clock; /* master clock frequency */ + XTAL m_master_clock; /* master clock frequency */ sound_stream *m_stream; /* which stream are we using */ std::unique_ptr<s16[]> m_scratch; #if YMZ280B_MAKE_WAVS diff --git a/src/devices/sound/ymz770.cpp b/src/devices/sound/ymz770.cpp index b19c21514e5..87e2807832d 100644 --- a/src/devices/sound/ymz770.cpp +++ b/src/devices/sound/ymz770.cpp @@ -48,12 +48,12 @@ DEFINE_DEVICE_TYPE(YMZ774, ymz774_device, "ymz774", "Yamaha YMZ774 AMMS2C") // ymz770_device - constructor //------------------------------------------------- -ymz770_device::ymz770_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ymz770_device::ymz770_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymz770_device(mconfig, YMZ770, tag, owner, clock, 16000) { } -ymz770_device::ymz770_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t sclock) +ymz770_device::ymz770_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t sclock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_stream(nullptr) @@ -456,7 +456,7 @@ void ymz770_device::internal_reg_write(uint8_t reg, uint8_t data) // ymz774_device //------------------------------------------------- -ymz774_device::ymz774_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ymz774_device::ymz774_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ymz770_device(mconfig, YMZ774, tag, owner, clock, 44100) { // calculate volume increments, fixed point values, fractions of 0x20000 diff --git a/src/devices/sound/ymz770.h b/src/devices/sound/ymz770.h index c8850b2e2bc..219e08e6da1 100644 --- a/src/devices/sound/ymz770.h +++ b/src/devices/sound/ymz770.h @@ -24,7 +24,7 @@ class ymz770_device : public device_t, public device_sound_interface { public: // construction/destruction - ymz770_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ymz770_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void write(offs_t offset, uint8_t data); @@ -41,7 +41,7 @@ protected: virtual void sequencer(); uint8_t get_rom_byte(uint32_t offset) { return m_rom[offset % m_rom.bytes()]; } // need optimise or its good as is ? - ymz770_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t sclock); + ymz770_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t sclock); sound_stream *m_stream; uint32_t m_sclock; @@ -111,7 +111,7 @@ class ymz774_device : public ymz770_device { public: // construction/destruction - ymz774_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ymz774_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); diff --git a/src/devices/sound/zsg2.cpp b/src/devices/sound/zsg2.cpp index 518d765ccc3..dca71a28f97 100644 --- a/src/devices/sound/zsg2.cpp +++ b/src/devices/sound/zsg2.cpp @@ -115,7 +115,7 @@ DEFINE_DEVICE_TYPE(ZSG2, zsg2_device, "zsg2", "ZOOM ZSG-2") // zsg2_device - constructor //------------------------------------------------- -zsg2_device::zsg2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +zsg2_device::zsg2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ZSG2, tag, owner, clock) , device_sound_interface(mconfig, *this) , m_mem_base(*this, DEVICE_SELF) diff --git a/src/devices/sound/zsg2.h b/src/devices/sound/zsg2.h index 0239f6ff03d..49982ec2d4a 100644 --- a/src/devices/sound/zsg2.h +++ b/src/devices/sound/zsg2.h @@ -15,7 +15,7 @@ class zsg2_device : public device_t, public device_sound_interface { public: - zsg2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + zsg2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto ext_read() { return m_ext_read_handler.bind(); } diff --git a/src/devices/video/315_5124.cpp b/src/devices/video/315_5124.cpp index 7bb4fd18407..2604b18c352 100644 --- a/src/devices/video/315_5124.cpp +++ b/src/devices/video/315_5124.cpp @@ -248,13 +248,13 @@ void sega315_5124_device::sega315_5124(address_map &map) } -sega315_5124_device::sega315_5124_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sega315_5124_device::sega315_5124_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega315_5124_device(mconfig, SEGA315_5124, tag, owner, clock, SEGA315_5124_CRAM_SIZE, 0x00, 0x0f, 4, 8, line_315_5124) { } -sega315_5124_device::sega315_5124_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing) +sega315_5124_device::sega315_5124_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing) : device_t(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , device_video_interface(mconfig, *this) @@ -278,26 +278,26 @@ sega315_5124_device::sega315_5124_device(const machine_config &mconfig, device_t } -sega315_5246_device::sega315_5246_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sega315_5246_device::sega315_5246_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega315_5124_device(mconfig, SEGA315_5246, tag, owner, clock, SEGA315_5124_CRAM_SIZE, 0x00, 0x0f, 8, 8, line_315_5124) { } -sega315_5246_device::sega315_5246_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing) +sega315_5246_device::sega315_5246_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing) : sega315_5124_device(mconfig, type, tag, owner, clock, cram_size, palette_offset, reg_num_mask, max_sprite_zoom_hcount, max_sprite_zoom_vcount, line_timing) { } // Embedded mode 4 support of the 315-5313 VDP (see 315_5313.cpp), used by Sega Genesis/Mega Drive -sega315_5313_mode4_device::sega315_5313_mode4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing) +sega315_5313_mode4_device::sega315_5313_mode4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing) : sega315_5246_device(mconfig, type, tag, owner, clock, cram_size, palette_offset, reg_num_mask, max_sprite_zoom_hcount, max_sprite_zoom_vcount, line_timing) { } -sega315_5377_device::sega315_5377_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sega315_5377_device::sega315_5377_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sega315_5246_device(mconfig, SEGA315_5377, tag, owner, clock, SEGA315_5377_CRAM_SIZE, 0x10, 0x0f, 8, 8, line_315_5377) { } diff --git a/src/devices/video/315_5124.h b/src/devices/video/315_5124.h index 913fdb71e18..8ffd614da7c 100644 --- a/src/devices/video/315_5124.h +++ b/src/devices/video/315_5124.h @@ -53,7 +53,7 @@ public: // construction/destruction - sega315_5124_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sega315_5124_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_hcounter_divide(unsigned divide) { m_hcounter_divide = divide; } void set_is_pal(bool is_pal) { m_is_pal = is_pal; } @@ -88,7 +88,7 @@ protected: static constexpr unsigned SEGA315_5377_CRAM_SIZE = 0x40; /* 32 colors x 2 bytes per color = 64 bytes */ static constexpr unsigned SEGA315_5124_CRAM_SIZE = 0x20; /* 32 colors x 1 bytes per color = 32 bytes */ - sega315_5124_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing); + sega315_5124_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing); // device-level overrides virtual void device_post_load() override; @@ -211,10 +211,10 @@ protected: class sega315_5246_device : public sega315_5124_device { public: - sega315_5246_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sega315_5246_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - sega315_5246_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing); + sega315_5246_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing); virtual void device_add_mconfig(machine_config &config) override; @@ -233,12 +233,12 @@ private: class sega315_5377_device : public sega315_5246_device { public: - sega315_5377_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sega315_5377_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void set_sega315_5124_compatibility_mode(bool sega315_5124_compatibility_mode) override; protected: - sega315_5377_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing); + sega315_5377_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing); virtual void device_reset() override; virtual void device_add_mconfig(machine_config &config) override; @@ -260,7 +260,7 @@ public: void stop_timers(); protected: - sega315_5313_mode4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing); + sega315_5313_mode4_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 cram_size, u8 palette_offset, u8 reg_num_mask, int max_sprite_zoom_hcount, int max_sprite_zoom_vcount, const u8 *line_timing); virtual void device_add_mconfig(machine_config &config) override; diff --git a/src/devices/video/315_5313.cpp b/src/devices/video/315_5313.cpp index 9d79b2dc396..38428915220 100644 --- a/src/devices/video/315_5313.cpp +++ b/src/devices/video/315_5313.cpp @@ -174,7 +174,7 @@ int sega315_5313_device::screen_hpos() { return screen().hpos() / (m_lcm_scaling DEFINE_DEVICE_TYPE(SEGA315_5313, sega315_5313_device, "sega315_5313", "Sega 315-5313 Megadrive VDP") -sega315_5313_device::sega315_5313_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +sega315_5313_device::sega315_5313_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) // mode 4 support, for SMS compatibility, is implemented in 315_5124.cpp : sega315_5313_mode4_device(mconfig, SEGA315_5313, tag, owner, clock, SEGA315_5124_CRAM_SIZE, 0x00, 0x1f, 0, 0, line_315_5313_mode4) , device_gfx_interface(mconfig, *this, nullptr, "gfx_palette") diff --git a/src/devices/video/315_5313.h b/src/devices/video/315_5313.h index 23bd51f3f33..acb8a51caf2 100644 --- a/src/devices/video/315_5313.h +++ b/src/devices/video/315_5313.h @@ -16,13 +16,13 @@ public: static constexpr unsigned PALETTE_PER_FRAME = 64 * 313 * 2; // 313 total scanlines for PAL systems, *2 for interlaced template <typename T> - sega315_5313_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&cpu_tag) + sega315_5313_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag) : sega315_5313_device(mconfig, tag, owner, clock) { m_cpu68k.set_tag(std::forward<T>(cpu_tag)); } - sega315_5313_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sega315_5313_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); typedef device_delegate<void (int x, u32 priority, u32 &lineptr)> md_32x_scanline_delegate; typedef device_delegate<void (int scanline, int irq6)> md_32x_interrupt_delegate; diff --git a/src/devices/video/am8052.cpp b/src/devices/video/am8052.cpp index e97e2488b9f..3bdd8adbee5 100644 --- a/src/devices/video/am8052.cpp +++ b/src/devices/video/am8052.cpp @@ -27,7 +27,7 @@ DEFINE_DEVICE_TYPE(AM8052, am8052_device, "am8052", "Am8052 CRTC") // am8052_device - constructor //------------------------------------------------- -am8052_device::am8052_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +am8052_device::am8052_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, AM8052, tag, owner, clock) , m_pointer(0x1f) { diff --git a/src/devices/video/am8052.h b/src/devices/video/am8052.h index 74fee1ea69f..3ec372a2cf0 100644 --- a/src/devices/video/am8052.h +++ b/src/devices/video/am8052.h @@ -21,7 +21,7 @@ class am8052_device : public device_t { public: // device constructor - am8052_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + am8052_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // read/write handlers void pointer_w(u16 data); diff --git a/src/devices/video/avgdvg.cpp b/src/devices/video/avgdvg.cpp index ba3ddff0d11..db47ea23dfc 100644 --- a/src/devices/video/avgdvg.cpp +++ b/src/devices/video/avgdvg.cpp @@ -26,7 +26,7 @@ * *************************************/ -#define MASTER_CLOCK (12096000) +#define MASTER_CLOCK XTAL::u(12096000) #define VGSLICE (10000) #define VGVECTOR 0 #define VGCLIP 1 @@ -1417,7 +1417,7 @@ void avg_bzone_device::device_start() } -avgdvg_device_base::avgdvg_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +avgdvg_device_base::avgdvg_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_vector(*this, finder_base::DUMMY_TAG), m_memspace(*this, finder_base::DUMMY_TAG, -1), @@ -1443,46 +1443,46 @@ avgdvg_device_base::avgdvg_device_base(const machine_config &mconfig, device_typ { } -dvg_device::dvg_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +dvg_device::dvg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avgdvg_device_base(mconfig, DVG, tag, owner, clock) { } -avg_device::avg_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +avg_device::avg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avg_device(mconfig, AVG, tag, owner, clock) { } -avg_device::avg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +avg_device::avg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : avgdvg_device_base(mconfig, type, tag, owner, clock) { } -avg_tempest_device::avg_tempest_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +avg_tempest_device::avg_tempest_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avg_device(mconfig, AVG_TEMPEST, tag, owner, clock), m_colorram(*this, "colorram") { } -avg_mhavoc_device::avg_mhavoc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +avg_mhavoc_device::avg_mhavoc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avg_device(mconfig, AVG_MHAVOC, tag, owner, clock), m_colorram(*this, "colorram"), m_bank_region(*this, DEVICE_SELF) { } -avg_starwars_device::avg_starwars_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +avg_starwars_device::avg_starwars_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avg_device(mconfig, AVG_STARWARS, tag, owner, clock) { } -avg_quantum_device::avg_quantum_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +avg_quantum_device::avg_quantum_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avg_device(mconfig, AVG_QUANTUM, tag, owner, clock), m_colorram(*this, "colorram") { } -avg_bzone_device::avg_bzone_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +avg_bzone_device::avg_bzone_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : avg_device(mconfig, AVG_BZONE, tag, owner, clock) { } diff --git a/src/devices/video/avgdvg.h b/src/devices/video/avgdvg.h index e77dff1e9a2..43dc92dc391 100644 --- a/src/devices/video/avgdvg.h +++ b/src/devices/video/avgdvg.h @@ -45,7 +45,7 @@ protected: int status; }; - avgdvg_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + avgdvg_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -118,7 +118,7 @@ private: class dvg_device : public avgdvg_device_base { public: - dvg_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dvg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -144,10 +144,10 @@ private: class avg_device : public avgdvg_device_base { public: - avg_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + avg_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - avg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + avg_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -185,7 +185,7 @@ protected: class avg_tempest_device : public avg_device { public: - avg_tempest_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + avg_tempest_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int handler_6() override; @@ -200,7 +200,7 @@ private: class avg_mhavoc_device : public avg_device { public: - avg_mhavoc_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + avg_mhavoc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -226,7 +226,7 @@ private: class avg_starwars_device : public avg_device { public: - avg_starwars_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + avg_starwars_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int handler_6() override; @@ -238,7 +238,7 @@ protected: class avg_quantum_device : public avg_device { public: - avg_quantum_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + avg_quantum_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual int handler_0() override; @@ -260,7 +260,7 @@ private: class avg_bzone_device : public avg_device { public: - avg_bzone_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + avg_bzone_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/video/bt431.cpp b/src/devices/video/bt431.cpp index a4a32e98716..570c4f6239e 100644 --- a/src/devices/video/bt431.cpp +++ b/src/devices/video/bt431.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(BT431, bt431_device, "bt431", "Bt431 64x64 Pixel Cursor Generator") -bt431_device::bt431_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +bt431_device::bt431_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BT431, tag, owner, clock) { } diff --git a/src/devices/video/bt431.h b/src/devices/video/bt431.h index 1ea71b56794..782457c78e3 100644 --- a/src/devices/video/bt431.h +++ b/src/devices/video/bt431.h @@ -9,7 +9,7 @@ class bt431_device : public device_t { public: - bt431_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + bt431_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); enum register_number : unsigned { diff --git a/src/devices/video/bt459.cpp b/src/devices/video/bt459.cpp index 1f2a48d968b..d394e02baca 100644 --- a/src/devices/video/bt459.cpp +++ b/src/devices/video/bt459.cpp @@ -32,7 +32,7 @@ void bt459_device::map(address_map &map) map(0x03, 0x03).rw(FUNC(bt459_device::palette_r), FUNC(bt459_device::palette_w)); } -bt459_device::bt459_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bt459_device::bt459_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, BT459, tag, owner, clock) , device_palette_interface(mconfig, *this) { diff --git a/src/devices/video/bt459.h b/src/devices/video/bt459.h index 2d525383378..0479cf768d5 100644 --- a/src/devices/video/bt459.h +++ b/src/devices/video/bt459.h @@ -8,7 +8,7 @@ class bt459_device : public device_t, public device_palette_interface { public: - bt459_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bt459_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static const u8 BT459_ID = 0x4a; // magic number found in the id register static const u8 BT459_REV = 0xb0; // device revision B found in revision register diff --git a/src/devices/video/bt45x.cpp b/src/devices/video/bt45x.cpp index 26594307513..1f71e606b38 100644 --- a/src/devices/video/bt45x.cpp +++ b/src/devices/video/bt45x.cpp @@ -85,59 +85,59 @@ void bt455_device::map(address_map &map) map(0x03, 0x03).rw(FUNC(bt455_device::overlay_r), FUNC(bt455_device::overlay_w)); } -bt45x_device_base::bt45x_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const u32 palette_colors, const u32 overlay_colors) +bt45x_device_base::bt45x_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const u32 palette_colors, const u32 overlay_colors) : device_t(mconfig, type, tag, owner, clock) , m_palette_colors(palette_colors) , m_overlay_colors(overlay_colors) { } -bt45x_rgb_device_base::bt45x_rgb_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const u32 palette_colors, const u32 overlay_colors) +bt45x_rgb_device_base::bt45x_rgb_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const u32 palette_colors, const u32 overlay_colors) : bt45x_device_base(mconfig, type, tag, owner, clock, palette_colors, overlay_colors) , device_palette_interface(mconfig, *this) { } -bt45x_mono_device_base::bt45x_mono_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const u32 palette_colors, const u32 overlay_colors) +bt45x_mono_device_base::bt45x_mono_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const u32 palette_colors, const u32 overlay_colors) : bt45x_device_base(mconfig, type, tag, owner, clock, palette_colors, overlay_colors) { } -bt451_device::bt451_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bt451_device::bt451_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bt45x_rgb_device_base(mconfig, BT451, tag, owner, clock, 256, 4) { } -bt453_device::bt453_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bt453_device::bt453_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bt45x_rgb_device_base(mconfig, BT453, tag, owner, clock, 256, 4) { } -bt454_device::bt454_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bt454_device::bt454_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bt45x_rgb_device_base(mconfig, BT454, tag, owner, clock, 16, 1) { } -bt455_device::bt455_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bt455_device::bt455_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bt45x_mono_device_base(mconfig, BT455, tag, owner, clock, 16, 1) { } -bt457_device::bt457_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bt457_device::bt457_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bt45x_mono_device_base(mconfig, BT457, tag, owner, clock, 256, 4) { } -bt458_device::bt458_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +bt458_device::bt458_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : bt45x_rgb_device_base(mconfig, type, tag, owner, clock, 256, 4) { } -bt458_device::bt458_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bt458_device::bt458_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bt458_device(mconfig, BT458, tag, owner, clock) { } -bt467_device::bt467_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +bt467_device::bt467_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : bt458_device(mconfig, BT467, tag, owner, clock) { } diff --git a/src/devices/video/bt45x.h b/src/devices/video/bt45x.h index 33cd63abd56..cb689a79bc5 100644 --- a/src/devices/video/bt45x.h +++ b/src/devices/video/bt45x.h @@ -45,7 +45,7 @@ public: virtual void map(address_map &map); protected: - bt45x_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const u32 palette_colors, const u32 overlay_colors); + bt45x_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const u32 palette_colors, const u32 overlay_colors); virtual void device_start() override; virtual void device_reset() override; @@ -80,7 +80,7 @@ protected: class bt45x_rgb_device_base : public bt45x_device_base, public device_palette_interface { protected: - bt45x_rgb_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const u32 palette_colors, const u32 overlay_colors); + bt45x_rgb_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const u32 palette_colors, const u32 overlay_colors); virtual void device_start() override; @@ -107,7 +107,7 @@ public: } protected: - bt45x_mono_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const u32 palette_colors, const u32 overlay_colors); + bt45x_mono_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const u32 palette_colors, const u32 overlay_colors); virtual void device_start() override; @@ -122,7 +122,7 @@ protected: class bt451_device : public bt45x_rgb_device_base { public: - bt451_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bt451_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: /* @@ -135,7 +135,7 @@ protected: class bt453_device : public bt45x_rgb_device_base { public: - bt453_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bt453_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; }; @@ -143,7 +143,7 @@ public: class bt454_device : public bt45x_rgb_device_base { public: - bt454_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bt454_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; }; @@ -151,7 +151,7 @@ public: class bt455_device : public bt45x_mono_device_base { public: - bt455_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bt455_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; }; @@ -159,7 +159,7 @@ public: class bt457_device : public bt45x_mono_device_base { public: - bt457_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bt457_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual u8 palette_r(address_space &space) override; @@ -173,16 +173,16 @@ protected: class bt458_device : public bt45x_rgb_device_base { public: - bt458_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bt458_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - bt458_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + bt458_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); }; class bt467_device : public bt458_device { public: - bt467_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + bt467_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(BT451, bt451_device) diff --git a/src/devices/video/bt47x.cpp b/src/devices/video/bt47x.cpp index d5aea56a400..49bdc31fbce 100644 --- a/src/devices/video/bt47x.cpp +++ b/src/devices/video/bt47x.cpp @@ -65,7 +65,7 @@ void bt475_device_base::map(address_map &map) map(0x06, 0x06).rw(FUNC(bt475_device_base::command_r), FUNC(bt475_device_base::command_w)); } -bt47x_device_base::bt47x_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, unsigned const palette_colors, unsigned const overlay_colors, unsigned const color_bits) +bt47x_device_base::bt47x_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, unsigned const palette_colors, unsigned const overlay_colors, unsigned const color_bits) : device_t(mconfig, type, tag, owner, clock) , device_palette_interface(mconfig, *this) , m_palette_colors(palette_colors) @@ -74,32 +74,32 @@ bt47x_device_base::bt47x_device_base(machine_config const &mconfig, device_type { } -bt475_device_base::bt475_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, unsigned const palette_colors, unsigned const overlay_colors, unsigned const color_bits) +bt475_device_base::bt475_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, unsigned const palette_colors, unsigned const overlay_colors, unsigned const color_bits) : bt47x_device_base(mconfig, type, tag, owner, clock, palette_colors, overlay_colors, color_bits) { } -bt471_device::bt471_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +bt471_device::bt471_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : bt47x_device_base(mconfig, BT471, tag, owner, clock, 256, 16, 6) { } -bt475_device::bt475_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +bt475_device::bt475_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : bt475_device_base(mconfig, BT475, tag, owner, clock, 256, 16, 6) { } -bt476_device::bt476_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +bt476_device::bt476_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : bt47x_device_base(mconfig, BT476, tag, owner, clock, 256, 0, 6) { } -bt477_device::bt477_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +bt477_device::bt477_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : bt475_device_base(mconfig, BT477, tag, owner, clock, 256, 16, 8) { } -bt478_device::bt478_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +bt478_device::bt478_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : bt47x_device_base(mconfig, BT478, tag, owner, clock, 256, 16, 8) { } diff --git a/src/devices/video/bt47x.h b/src/devices/video/bt47x.h index a51fe2c3df8..97163cca35b 100644 --- a/src/devices/video/bt47x.h +++ b/src/devices/video/bt47x.h @@ -17,7 +17,7 @@ public: virtual void map(address_map &map); protected: - bt47x_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, unsigned const palette_colors, unsigned const overlay_colors, unsigned const color_bits); + bt47x_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, unsigned const palette_colors, unsigned const overlay_colors, unsigned const color_bits); // device_t overrides virtual void device_start() override; @@ -60,7 +60,7 @@ public: virtual void map(address_map &map) override; protected: - bt475_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock, unsigned const palette_colors, unsigned const overlay_colors, unsigned const color_bits); + bt475_device_base(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock, unsigned const palette_colors, unsigned const overlay_colors, unsigned const color_bits); // device_t overrides virtual void device_start() override; @@ -85,25 +85,25 @@ protected: class bt471_device : public bt47x_device_base { public: - bt471_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + bt471_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class bt475_device : public bt475_device_base { public: - bt475_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + bt475_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class bt476_device : public bt47x_device_base { public: - bt476_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + bt476_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; class bt477_device : public bt475_device_base { public: - bt477_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + bt477_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); protected: virtual unsigned color_bits() const override { return (m_command & D1) ? 8 : 6; } @@ -112,7 +112,7 @@ protected: class bt478_device : public bt47x_device_base { public: - bt478_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + bt478_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(BT471, bt471_device) diff --git a/src/devices/video/bufsprite.cpp b/src/devices/video/bufsprite.cpp index 1c7180ec8cd..408a63b5c4f 100644 --- a/src/devices/video/bufsprite.cpp +++ b/src/devices/video/bufsprite.cpp @@ -29,7 +29,7 @@ buffered_spriteram_device<Type>::buffered_spriteram_device( device_type type, const char *tag, device_t *owner, - uint32_t clock) + const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_spriteram(*this, DEVICE_SELF) { @@ -48,28 +48,28 @@ void buffered_spriteram_device<Type>::device_start() -buffered_spriteram8_device::buffered_spriteram8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +buffered_spriteram8_device::buffered_spriteram8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : buffered_spriteram_device<u8>(mconfig, BUFFERED_SPRITERAM8, tag, owner, clock) { } -buffered_spriteram16_device::buffered_spriteram16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +buffered_spriteram16_device::buffered_spriteram16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : buffered_spriteram_device<u16>(mconfig, BUFFERED_SPRITERAM16, tag, owner, clock) { } -buffered_spriteram32_device::buffered_spriteram32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +buffered_spriteram32_device::buffered_spriteram32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : buffered_spriteram_device<u32>(mconfig, BUFFERED_SPRITERAM32, tag, owner, clock) { } -buffered_spriteram64_device::buffered_spriteram64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +buffered_spriteram64_device::buffered_spriteram64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : buffered_spriteram_device<u64>(mconfig, BUFFERED_SPRITERAM64, tag, owner, clock) { } diff --git a/src/devices/video/bufsprite.h b/src/devices/video/bufsprite.h index 6716592d0c5..2baf5cd8dd5 100644 --- a/src/devices/video/bufsprite.h +++ b/src/devices/video/bufsprite.h @@ -66,7 +66,7 @@ protected: device_type type, const char *tag, device_t *owner, - uint32_t clock); + const XTAL &clock); // first-time setup virtual void device_start() override; @@ -84,7 +84,7 @@ class buffered_spriteram8_device : public buffered_spriteram_device<uint8_t> { public: // construction - buffered_spriteram8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + buffered_spriteram8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; @@ -94,7 +94,7 @@ class buffered_spriteram16_device : public buffered_spriteram_device<uint16_t> { public: // construction - buffered_spriteram16_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + buffered_spriteram16_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; @@ -104,7 +104,7 @@ class buffered_spriteram32_device : public buffered_spriteram_device<uint32_t> { public: // construction - buffered_spriteram32_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + buffered_spriteram32_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; @@ -114,7 +114,7 @@ class buffered_spriteram64_device : public buffered_spriteram_device<uint64_t> { public: // construction - buffered_spriteram64_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + buffered_spriteram64_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; diff --git a/src/devices/video/catseye.cpp b/src/devices/video/catseye.cpp index 46eeb917f37..f3a49dfa994 100644 --- a/src/devices/video/catseye.cpp +++ b/src/devices/video/catseye.cpp @@ -13,7 +13,7 @@ DEFINE_DEVICE_TYPE(CATSEYE, catseye_device, "catseye", "HP Catseye ASIC") -catseye_device::catseye_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +catseye_device::catseye_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t{mconfig, type, tag, owner, clock}, m_vram{*this, { "^vram_video", "^vram_overlay"}}, m_int_write_func{*this}, @@ -60,7 +60,7 @@ catseye_device::catseye_device(const machine_config &mconfig, device_type type, { } -catseye_device::catseye_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +catseye_device::catseye_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : catseye_device(mconfig, CATSEYE, tag, owner, clock) { } diff --git a/src/devices/video/catseye.h b/src/devices/video/catseye.h index 8c66eb257c7..77f80ecb7d2 100644 --- a/src/devices/video/catseye.h +++ b/src/devices/video/catseye.h @@ -10,7 +10,7 @@ class catseye_device: public device_t public: static constexpr feature_type imperfect_features() { return feature::GRAPHICS; } - catseye_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + catseye_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t vram_r(offs_t offset, uint16_t mem_mask = ~0); void vram_w(offs_t offset, u16 data, u16 mem_mask = ~0); @@ -43,7 +43,7 @@ public: protected: required_shared_ptr_array<u8, 2> m_vram; - catseye_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + catseye_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); devcb_write8 m_int_write_func; TIMER_CALLBACK_MEMBER(blink_callback); diff --git a/src/devices/video/cdp1861.cpp b/src/devices/video/cdp1861.cpp index e19074045aa..69139782146 100644 --- a/src/devices/video/cdp1861.cpp +++ b/src/devices/video/cdp1861.cpp @@ -70,7 +70,7 @@ DEFINE_DEVICE_TYPE(CDP1861, cdp1861_device, "cdp1861", "RCA CDP1861") // cdp1861_device - constructor //------------------------------------------------- -cdp1861_device::cdp1861_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cdp1861_device::cdp1861_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDP1861, tag, owner, clock) , device_video_interface(mconfig, *this) , m_write_int(*this) diff --git a/src/devices/video/cdp1861.h b/src/devices/video/cdp1861.h index c038223a50e..2fcaa7792f1 100644 --- a/src/devices/video/cdp1861.h +++ b/src/devices/video/cdp1861.h @@ -62,7 +62,7 @@ public: static constexpr unsigned SCANLINE_EFX_BOTTOM_END = SCANLINE_DISPLAY_END; // construction/destruction - cdp1861_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1861_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto int_cb() { return m_write_int.bind(); } auto dma_out_cb() { return m_write_dma_out.bind(); } diff --git a/src/devices/video/cdp1862.cpp b/src/devices/video/cdp1862.cpp index 66fa8d9e684..9ebc9c790a8 100644 --- a/src/devices/video/cdp1862.cpp +++ b/src/devices/video/cdp1862.cpp @@ -78,7 +78,7 @@ inline void cdp1862_device::initialize_palette() // cdp1862_device - constructor //------------------------------------------------- -cdp1862_device::cdp1862_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cdp1862_device::cdp1862_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CDP1862, tag, owner, clock), device_video_interface(mconfig, *this), m_read_rd(*this), diff --git a/src/devices/video/cdp1862.h b/src/devices/video/cdp1862.h index 57aab81b21a..6d1046ff859 100644 --- a/src/devices/video/cdp1862.h +++ b/src/devices/video/cdp1862.h @@ -40,7 +40,7 @@ class cdp1862_device : public device_t, { public: // construction/destruction - cdp1862_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cdp1862_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto rdata_cb() { return m_read_rd.bind(); } auto bdata_cb() { return m_read_bd.bind(); } diff --git a/src/devices/video/cesblit.cpp b/src/devices/video/cesblit.cpp index 7e0e6a2085b..5253d06edae 100644 --- a/src/devices/video/cesblit.cpp +++ b/src/devices/video/cesblit.cpp @@ -70,7 +70,7 @@ DEFINE_DEVICE_TYPE(CESBLIT, cesblit_device, "cesblit", "CES Blitter FPGA") // cesblit_device - constructor //------------------------------------------------- -cesblit_device::cesblit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +cesblit_device::cesblit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CESBLIT, tag, owner, clock), device_video_interface(mconfig, *this), device_memory_interface(mconfig, *this), diff --git a/src/devices/video/cesblit.h b/src/devices/video/cesblit.h index 2a00d601067..529eacca5ab 100644 --- a/src/devices/video/cesblit.h +++ b/src/devices/video/cesblit.h @@ -27,13 +27,13 @@ public: // construction/destruction template <typename T> - cesblit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) + cesblit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : cesblit_device(mconfig, tag, owner, clock) { set_screen(std::forward<T>(screen_tag)); } - cesblit_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cesblit_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration void set_compute_addr(compute_addr_t compute_addr) { m_compute_addr = compute_addr; } diff --git a/src/devices/video/clgd542x.cpp b/src/devices/video/clgd542x.cpp index 978e38e792e..13de6633704 100644 --- a/src/devices/video/clgd542x.cpp +++ b/src/devices/video/clgd542x.cpp @@ -46,22 +46,22 @@ DEFINE_DEVICE_TYPE(CIRRUS_GD5430, cirrus_gd5430_device, "clgd5430", "Cirrus Logi DEFINE_DEVICE_TYPE(CIRRUS_GD5446, cirrus_gd5446_device, "clgd5446", "Cirrus Logic GD5446") -cirrus_gd5428_device::cirrus_gd5428_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cirrus_gd5428_device::cirrus_gd5428_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cirrus_gd5428_device(mconfig, CIRRUS_GD5428, tag, owner, clock) { } -cirrus_gd5428_device::cirrus_gd5428_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +cirrus_gd5428_device::cirrus_gd5428_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : svga_device(mconfig, type, tag, owner, clock) { } -cirrus_gd5430_device::cirrus_gd5430_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cirrus_gd5430_device::cirrus_gd5430_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cirrus_gd5428_device(mconfig, CIRRUS_GD5430, tag, owner, clock) { } -cirrus_gd5446_device::cirrus_gd5446_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cirrus_gd5446_device::cirrus_gd5446_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : cirrus_gd5428_device(mconfig, CIRRUS_GD5446, tag, owner, clock) { } diff --git a/src/devices/video/clgd542x.h b/src/devices/video/clgd542x.h index 6177b95c845..ee7bef78eb2 100644 --- a/src/devices/video/clgd542x.h +++ b/src/devices/video/clgd542x.h @@ -16,7 +16,7 @@ class cirrus_gd5428_device : public svga_device { public: // construction/destruction - cirrus_gd5428_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cirrus_gd5428_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t port_03c0_r(offs_t offset) override; virtual void port_03c0_w(offs_t offset, uint8_t data) override; @@ -30,7 +30,7 @@ public: virtual uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect) override; protected: - cirrus_gd5428_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + cirrus_gd5428_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -111,7 +111,7 @@ private: class cirrus_gd5430_device : public cirrus_gd5428_device { public: - cirrus_gd5430_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cirrus_gd5430_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -120,7 +120,7 @@ protected: class cirrus_gd5446_device : public cirrus_gd5428_device { public: - cirrus_gd5446_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cirrus_gd5446_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/video/crt9007.cpp b/src/devices/video/crt9007.cpp index 347a06382a1..67e961f353f 100644 --- a/src/devices/video/crt9007.cpp +++ b/src/devices/video/crt9007.cpp @@ -453,7 +453,7 @@ inline void crt9007_device::recompute_parameters() // crt9007_device - constructor //------------------------------------------------- -crt9007_device::crt9007_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +crt9007_device::crt9007_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CRT9007, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/video/crt9007.h b/src/devices/video/crt9007.h index 433ca521f01..36a88e08dbe 100644 --- a/src/devices/video/crt9007.h +++ b/src/devices/video/crt9007.h @@ -49,7 +49,7 @@ class crt9007_device : public device_t, { public: // construction/destruction - crt9007_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crt9007_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto int_callback() { return m_write_int.bind(); } auto dmar_callback() { return m_write_dmar.bind(); } diff --git a/src/devices/video/crt9021.cpp b/src/devices/video/crt9021.cpp index 6f1bc8102e2..f65bbd15b31 100644 --- a/src/devices/video/crt9021.cpp +++ b/src/devices/video/crt9021.cpp @@ -59,7 +59,7 @@ DEFINE_DEVICE_TYPE(CRT9021, crt9021_device, "crt9021", "SMC CRT9021 VAC") // crt9021_device - constructor //------------------------------------------------- -crt9021_device::crt9021_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +crt9021_device::crt9021_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CRT9021, tag, owner, clock), device_video_interface(mconfig, *this), m_display_cb(*this), diff --git a/src/devices/video/crt9021.h b/src/devices/video/crt9021.h index 1d071da00df..ea35f860671 100644 --- a/src/devices/video/crt9021.h +++ b/src/devices/video/crt9021.h @@ -51,7 +51,7 @@ public: typedef device_delegate<void (bitmap_rgb32 &bitmap, int y, int x, uint8_t video, int intout)> draw_character_delegate; // construction/destruction - crt9021_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crt9021_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename... T> void set_display_callback(T &&... args) { m_display_cb.set(std::forward<T>(args)...); } diff --git a/src/devices/video/crt9028.cpp b/src/devices/video/crt9028.cpp index 94cc2429e13..60ac9263ffe 100644 --- a/src/devices/video/crt9028.cpp +++ b/src/devices/video/crt9028.cpp @@ -42,7 +42,7 @@ DEFINE_DEVICE_TYPE(CRT9028_000, crt9028_000_device, "crt9028_000", "CRT9028-000 // crt9028_device - constructor //------------------------------------------------- -crt9028_device::crt9028_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, +crt9028_device::crt9028_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int dots_per_char, int chars_per_row, int horiz_blanking, int hsync_delay, int hsync_width, bool hsync_active, int char_rows, int scans_per_char, bool vsync_active, int vert_blanking, int vsync_delay, int vsync_width, @@ -100,7 +100,7 @@ crt9028_device::crt9028_device(const machine_config &mconfig, device_type type, // crt9028_000_device - constructor //------------------------------------------------- -crt9028_000_device::crt9028_000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +crt9028_000_device::crt9028_000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : crt9028_device(mconfig, CRT9028_000, tag, owner, clock, 7, 80, 20, 4, 8, false, 24, 10, false, diff --git a/src/devices/video/crt9028.h b/src/devices/video/crt9028.h index d8aa637c06a..3086465e55b 100644 --- a/src/devices/video/crt9028.h +++ b/src/devices/video/crt9028.h @@ -56,7 +56,7 @@ public: protected: // base type constructor - crt9028_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, + crt9028_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int dots_per_char, int chars_per_row, int horiz_blanking, int hsync_delay, int hsync_width, bool hsync_active, int char_rows, int scans_per_char, bool vsync_active, int vert_blanking, int vsync_delay, int vsync_width, @@ -129,7 +129,7 @@ class crt9028_000_device : public crt9028_device { public: // device constructor - crt9028_000_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + crt9028_000_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-specific overrides diff --git a/src/devices/video/crt9212.cpp b/src/devices/video/crt9212.cpp index 5bbcd8aaac7..5043d81f41c 100644 --- a/src/devices/video/crt9212.cpp +++ b/src/devices/video/crt9212.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(CRT9212, crt9212_device, "crt9212", "SMC CRT9212 DRB") // crt9212_device - constructor //------------------------------------------------- -crt9212_device::crt9212_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +crt9212_device::crt9212_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CRT9212, tag, owner, clock), m_write_dout(*this), m_write_rof(*this), diff --git a/src/devices/video/crt9212.h b/src/devices/video/crt9212.h index bf32b311c2d..a4ea8324bb6 100644 --- a/src/devices/video/crt9212.h +++ b/src/devices/video/crt9212.h @@ -38,7 +38,7 @@ class crt9212_device : public device_t { public: // construction/destruction - crt9212_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crt9212_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_wen2(int state) { m_wen2 = state; } auto dout() { return m_write_dout.bind(); } diff --git a/src/devices/video/crtc_ega.cpp b/src/devices/video/crtc_ega.cpp index 4c9a738c110..4df2077565e 100644 --- a/src/devices/video/crtc_ega.cpp +++ b/src/devices/video/crtc_ega.cpp @@ -20,7 +20,7 @@ DEFINE_DEVICE_TYPE(CRTC_EGA, crtc_ega_device, "crtc_ega", "IBM EGA CRT Controller") -crtc_ega_device::crtc_ega_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crtc_ega_device::crtc_ega_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, CRTC_EGA, tag, owner, clock), device_video_interface(mconfig, *this, false) , m_res_out_de_cb(*this), m_res_out_hsync_cb(*this), m_res_out_vsync_cb(*this), m_res_out_vblank_cb(*this) , m_res_out_irq_cb(*this), m_begin_update_cb(*this), m_row_update_cb(*this), m_end_update_cb(*this) diff --git a/src/devices/video/crtc_ega.h b/src/devices/video/crtc_ega.h index 62bcac8c5c3..266735e45cd 100644 --- a/src/devices/video/crtc_ega.h +++ b/src/devices/video/crtc_ega.h @@ -27,7 +27,7 @@ public: typedef device_delegate<void (bitmap_ind16 &bitmap, const rectangle &cliprect)> end_update_delegate; - crtc_ega_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crtc_ega_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto res_out_de_callback() { return m_res_out_de_cb.bind(); } auto res_out_hsync_callback() { return m_res_out_hsync_cb.bind(); } diff --git a/src/devices/video/decsfb.cpp b/src/devices/video/decsfb.cpp index 528c9897cdc..8c1dde741a7 100644 --- a/src/devices/video/decsfb.cpp +++ b/src/devices/video/decsfb.cpp @@ -36,7 +36,7 @@ DEFINE_DEVICE_TYPE(DECSFB, decsfb_device, "decsfb", "Digital Equipment Corporation Smart Frame Buffer") -decsfb_device::decsfb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +decsfb_device::decsfb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DECSFB, tag, owner, clock), m_int_cb(*this) { diff --git a/src/devices/video/decsfb.h b/src/devices/video/decsfb.h index 9181ae84dbf..45d36cb17f9 100644 --- a/src/devices/video/decsfb.h +++ b/src/devices/video/decsfb.h @@ -9,7 +9,7 @@ class decsfb_device : public device_t { public: - decsfb_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + decsfb_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto int_cb() { return m_int_cb.bind(); } diff --git a/src/devices/video/dl1416.cpp b/src/devices/video/dl1416.cpp index 4321192e981..e128c692b6b 100644 --- a/src/devices/video/dl1416.cpp +++ b/src/devices/video/dl1416.cpp @@ -95,7 +95,7 @@ u16 const dl1416t_segments[128] = { class dl1414t_device : public dl1414_device { public: - dl1414t_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) + dl1414t_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : dl1414_device(mconfig, DL1414T, tag, owner, clock) { } @@ -111,7 +111,7 @@ protected: class dl1416b_device : public dl1416_device { public: - dl1416b_device(machine_config const &mconfig, const char *tag, device_t *owner, u32 clock) + dl1416b_device(machine_config const &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dl1416_device(mconfig, DL1416B, tag, owner, clock) { } @@ -135,7 +135,7 @@ protected: class dl1416t_device : public dl1416_device { public: - dl1416t_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) + dl1416t_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dl1416_device(mconfig, DL1416T, tag, owner, clock) { } @@ -183,7 +183,7 @@ dl1414_device::dl1414_device( device_type type, char const *tag, device_t *owner, - u32 clock) + const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_wr_in(true) , m_addr_in(0x00) @@ -199,7 +199,7 @@ dl1416_device::dl1416_device( device_type type, char const *tag, device_t *owner, - u32 clock) + const XTAL &clock) : dl1414_device(mconfig, type, tag, owner, clock) , m_ce_in(true) , m_ce_latch(true) diff --git a/src/devices/video/dl1416.h b/src/devices/video/dl1416.h index ce1d61071f4..1e8882e8e82 100644 --- a/src/devices/video/dl1416.h +++ b/src/devices/video/dl1416.h @@ -49,7 +49,7 @@ protected: device_type type, char const *tag, device_t *owner, - u32 clock); + const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -84,7 +84,7 @@ protected: device_type type, char const *tag, device_t *owner, - u32 clock); + const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/video/dm9368.cpp b/src/devices/video/dm9368.cpp index 4702430403b..be6de598687 100644 --- a/src/devices/video/dm9368.cpp +++ b/src/devices/video/dm9368.cpp @@ -36,7 +36,7 @@ const u8 dm9368_device::s_segment_data[16] = // LIVE DEVICE //************************************************************************** -dm9368_device::dm9368_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +dm9368_device::dm9368_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DM9368, tag, owner, clock), m_update_cb(*this), m_rbo_cb(*this), diff --git a/src/devices/video/dm9368.h b/src/devices/video/dm9368.h index fb376541a07..e09625d4a90 100644 --- a/src/devices/video/dm9368.h +++ b/src/devices/video/dm9368.h @@ -36,7 +36,7 @@ public: auto rbo_cb() { return m_rbo_cb.bind(); } // construction/destruction - dm9368_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dm9368_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void a_w(u8 data); diff --git a/src/devices/video/dp8350.cpp b/src/devices/video/dp8350.cpp index e93960b5662..2ba87d22580 100644 --- a/src/devices/video/dp8350.cpp +++ b/src/devices/video/dp8350.cpp @@ -69,7 +69,7 @@ DEFINE_DEVICE_TYPE(DP835X_A, dp835x_a_device, "dp835x_a", "DP835X CRTC (option A // dp835x_device - constructor //------------------------------------------------- -dp835x_device::dp835x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, +dp835x_device::dp835x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int char_width, int char_height, int chars_per_row, int rows_per_frame, int vsync_delay_f1, int vsync_width_f1, int vblank_interval_f1, int vsync_delay_f0, int vsync_width_f0, int vblank_interval_f0, @@ -127,7 +127,7 @@ dp835x_device::dp835x_device(const machine_config &mconfig, device_type type, co // dp8350_device - constructor //------------------------------------------------- -dp8350_device::dp8350_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dp8350_device::dp8350_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dp835x_device(mconfig, DP8350, tag, owner, clock, 7, 10, 80, 24, 4, 10, 20, @@ -143,7 +143,7 @@ dp8350_device::dp8350_device(const machine_config &mconfig, const char *tag, dev // dp8367_device - constructor //------------------------------------------------- -dp8367_device::dp8367_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dp8367_device::dp8367_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dp835x_device(mconfig, DP8367, tag, owner, clock, 9, 15, 80, 26, 0, 19, 25, @@ -159,7 +159,7 @@ dp8367_device::dp8367_device(const machine_config &mconfig, const char *tag, dev // dp835x_a_device - constructor //------------------------------------------------- -dp835x_a_device::dp835x_a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dp835x_a_device::dp835x_a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dp835x_device(mconfig, DP835X_A, tag, owner, clock, 9, 14, 80, 25, 0, 14, 20, // sync parameters guessed @@ -277,9 +277,9 @@ void dp835x_device::reconfigure_screen() logerror("Frame rate refresh: %.2f Hz (f%d); horizontal rate scan: %.4f kHz; character rate: %.4f MHz; dot rate: %.5f MHz\n", refresh.as_hz(), m_60hz_refresh ? 1 : 0, - clock() / (m_dots_per_line * 1000.0), - clock() / (m_char_width * 1000000.0), - clock() / 1000000.0); + clock().value() / (m_dots_per_line * 1000.0), + clock().value() / (m_char_width * 1000000.0), + clock().value() / 1000000.0); // get current screen position (note that this method is more accurate than calling hpos and vpos separately) u32 dpos = attotime_to_clocks(refresh - screen().time_until_pos(lines_per_frame - 1, m_dots_per_row * (m_half_shift ? 2 : 1))); diff --git a/src/devices/video/dp8350.h b/src/devices/video/dp8350.h index 3a5c16bbf6a..242ad1ae547 100644 --- a/src/devices/video/dp8350.h +++ b/src/devices/video/dp8350.h @@ -73,7 +73,7 @@ public: protected: // base type constructor - dp835x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, + dp835x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int char_width, int char_height, int chars_per_row, int rows_per_frame, int vsync_delay_f1, int vsync_width_f1, int vblank_interval_f1, int vsync_delay_f0, int vsync_width_f0, int vblank_interval_f0, @@ -158,7 +158,7 @@ class dp8350_device : public dp835x_device { public: // device constructor - dp8350_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dp8350_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> dp8367_device @@ -167,7 +167,7 @@ class dp8367_device : public dp835x_device { public: // device constructor - dp8367_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dp8367_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> dp835x_a_device @@ -176,7 +176,7 @@ class dp835x_a_device : public dp835x_device { public: // device constructor - dp835x_a_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dp835x_a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type declarations diff --git a/src/devices/video/dp8510.cpp b/src/devices/video/dp8510.cpp index a98ea433322..9626a5f559b 100644 --- a/src/devices/video/dp8510.cpp +++ b/src/devices/video/dp8510.cpp @@ -36,7 +36,7 @@ const char *const dp8510_device::BITBLT_OP[] = { "s & d", "~s ^ ~d", "d", "~s | d", "s", "s | ~d", "s | d", "1" }; -dp8510_device::dp8510_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +dp8510_device::dp8510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, DP8510, tag, owner, clock) , m_line_drawing(CLEAR_LINE) , m_barrel_input_select(CLEAR_LINE) diff --git a/src/devices/video/dp8510.h b/src/devices/video/dp8510.h index 04a0c2b1676..5605af70cb4 100644 --- a/src/devices/video/dp8510.h +++ b/src/devices/video/dp8510.h @@ -9,7 +9,7 @@ class dp8510_device : public device_t { public: - dp8510_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + dp8510_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static const char *const BITBLT_OP[]; static const int FIFO_SIZE = 16; diff --git a/src/devices/video/ef9340_1.cpp b/src/devices/video/ef9340_1.cpp index deb26990e16..8cf4725877a 100644 --- a/src/devices/video/ef9340_1.cpp +++ b/src/devices/video/ef9340_1.cpp @@ -35,7 +35,7 @@ TODO: DEFINE_DEVICE_TYPE(EF9340_1, ef9340_1_device, "ef9340_1", "Thomson EF9340+EF9341") -ef9340_1_device::ef9340_1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +ef9340_1_device::ef9340_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EF9340_1, tag, owner, clock) , device_video_interface(mconfig, *this) , m_charset(*this, "ef9340_1") diff --git a/src/devices/video/ef9340_1.h b/src/devices/video/ef9340_1.h index ec7e41d16de..aec8122ee7b 100644 --- a/src/devices/video/ef9340_1.h +++ b/src/devices/video/ef9340_1.h @@ -46,7 +46,7 @@ class ef9340_1_device : public device_t, public: // construction/destruction template <typename T> - ef9340_1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&screen_tag) + ef9340_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : ef9340_1_device(mconfig, tag, owner, clock) { set_screen(std::forward<T>(screen_tag)); @@ -57,7 +57,7 @@ public: auto write_exram() { return m_write_exram.bind(); } // ADR0-ADR3 in a0-a3, B in a4-a11, A in a12-a19 auto read_exram() { return m_read_exram.bind(); } // " - ef9340_1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + ef9340_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); inline bitmap_ind16 *get_bitmap() { return &m_tmp_bitmap; } u32 screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); diff --git a/src/devices/video/ef9345.cpp b/src/devices/video/ef9345.cpp index df596e7f7a4..5f86f2c9a74 100644 --- a/src/devices/video/ef9345.cpp +++ b/src/devices/video/ef9345.cpp @@ -105,12 +105,12 @@ inline void ef9345_device::inc_y(uint8_t r) // ef9345_device - constructor //------------------------------------------------- -ef9345_device::ef9345_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ef9345_device::ef9345_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ef9345_device(mconfig, EF9345, tag, owner, clock, EF9345_MODE::TYPE_EF9345) { } -ef9345_device::ef9345_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, EF9345_MODE variant) : +ef9345_device::ef9345_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, EF9345_MODE variant) : device_t(mconfig, type, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), @@ -121,7 +121,7 @@ ef9345_device::ef9345_device(const machine_config &mconfig, device_type type, co { } -ts9347_device::ts9347_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ts9347_device::ts9347_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ef9345_device(mconfig, TS9347, tag, owner, clock, EF9345_MODE::TYPE_TS9347) { } diff --git a/src/devices/video/ef9345.h b/src/devices/video/ef9345.h index 05db63cc150..80f5210c0b7 100644 --- a/src/devices/video/ef9345.h +++ b/src/devices/video/ef9345.h @@ -28,7 +28,7 @@ class ef9345_device : public device_t, { public: // construction/destruction - ef9345_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ef9345_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration template <typename T> void set_palette_tag(T &&tag) { m_palette.set_tag(std::forward<T>(tag)); } @@ -47,7 +47,7 @@ protected: }; // pass-through constructor - ef9345_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, EF9345_MODE variant); + ef9345_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, EF9345_MODE variant); // device-level overrides virtual void device_start() override; @@ -124,7 +124,7 @@ private: class ts9347_device : public ef9345_device { public: - ts9347_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ts9347_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/video/ef9364.cpp b/src/devices/video/ef9364.cpp index 1b6ad09bab2..532f19b9066 100644 --- a/src/devices/video/ef9364.cpp +++ b/src/devices/video/ef9364.cpp @@ -63,7 +63,7 @@ device_memory_interface::space_config_vector ef9364_device::memory_space_config( // ef9364_device - constructor //------------------------------------------------- -ef9364_device::ef9364_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ef9364_device::ef9364_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EF9364, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/video/ef9364.h b/src/devices/video/ef9364.h index 3fce51cf29c..a4a574f9c27 100644 --- a/src/devices/video/ef9364.h +++ b/src/devices/video/ef9364.h @@ -34,7 +34,7 @@ public: static constexpr unsigned MAX_TXTPLANES = 2; // construction/destruction - ef9364_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ef9364_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration template <typename T> void set_palette_tag(T &&tag) { m_palette.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/video/ef9365.cpp b/src/devices/video/ef9365.cpp index bb1495836c9..e8703abccbd 100644 --- a/src/devices/video/ef9365.cpp +++ b/src/devices/video/ef9365.cpp @@ -193,7 +193,7 @@ device_memory_interface::space_config_vector ef9365_device::memory_space_config( // ef9365_device - constructor //------------------------------------------------- -ef9365_device::ef9365_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ef9365_device::ef9365_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EF9365, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/video/ef9365.h b/src/devices/video/ef9365.h index fd3e7497e11..d8bae49bbf7 100644 --- a/src/devices/video/ef9365.h +++ b/src/devices/video/ef9365.h @@ -37,7 +37,7 @@ public: static constexpr int DISPLAY_MODE_64x64 = 0x04; // construction/destruction - ef9365_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ef9365_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration template <typename T> void set_palette_tag(T &&tag) { m_palette.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/video/ef9369.cpp b/src/devices/video/ef9369.cpp index 5f61544cc55..78b3fdcfb1a 100644 --- a/src/devices/video/ef9369.cpp +++ b/src/devices/video/ef9369.cpp @@ -28,7 +28,7 @@ DEFINE_DEVICE_TYPE(EF9369, ef9369_device, "ef9369", "Thomson EF9369 Single Chip // ef9369_device - constructor //------------------------------------------------- -ef9369_device::ef9369_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ef9369_device::ef9369_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EF9369, tag, owner, clock) , m_color_update_cb(*this) , m_address(0) diff --git a/src/devices/video/ef9369.h b/src/devices/video/ef9369.h index 457e47f3264..9d2646cca19 100644 --- a/src/devices/video/ef9369.h +++ b/src/devices/video/ef9369.h @@ -43,7 +43,7 @@ public: typedef device_delegate<void (int entry, bool m, uint8_t ca, uint8_t cb, uint8_t cc)> color_update_delegate; // construction/destruction - ef9369_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ef9369_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration template <typename... T> void set_color_update_callback(T &&... args) { m_color_update_cb.set(std::forward<T>(args)...); } diff --git a/src/devices/video/epic12.cpp b/src/devices/video/epic12.cpp index d0dfbf1fcae..b66215e4c3e 100644 --- a/src/devices/video/epic12.cpp +++ b/src/devices/video/epic12.cpp @@ -8,7 +8,7 @@ DEFINE_DEVICE_TYPE(EPIC12, epic12_device, "epic12", "EPIC12 Blitter") -epic12_device::epic12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +epic12_device::epic12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, EPIC12, tag, owner, clock) , device_video_interface(mconfig, *this) , m_ram16(nullptr), m_gfx_size(0), m_bitmaps(nullptr), m_use_ram(nullptr) diff --git a/src/devices/video/epic12.h b/src/devices/video/epic12.h index 82e58d07e9b..1d3100a2902 100644 --- a/src/devices/video/epic12.h +++ b/src/devices/video/epic12.h @@ -11,7 +11,7 @@ class epic12_device : public device_t, public device_video_interface { public: - epic12_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + epic12_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_cpu(T &&maintag) { m_maincpu.set_tag(std::forward<T>(maintag)); } auto port_r_callback() { return m_port_r_cb.bind(); } diff --git a/src/devices/video/fixfreq.cpp b/src/devices/video/fixfreq.cpp index cf4c4bb5517..46e0cd2c508 100644 --- a/src/devices/video/fixfreq.cpp +++ b/src/devices/video/fixfreq.cpp @@ -232,7 +232,7 @@ fixedfreq_device::fixedfreq_device( device_type type, const char *tag, device_t *owner, - uint32_t clock) + const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_video_interface(mconfig, *this, false) , m_enable(*this, "ENABLE") @@ -248,7 +248,7 @@ fixedfreq_device::fixedfreq_device( const machine_config &mconfig, const char *tag, device_t *owner, - uint32_t clock) + const XTAL &clock) : fixedfreq_device(mconfig, FIXFREQ, tag, owner, clock) { } @@ -273,7 +273,7 @@ void fixedfreq_device::device_config_complete() if (!screen().refresh_attoseconds()) { screen().set_raw( - m_monitor.m_monitor_clock, m_monitor.htotal(), 0, + XTAL::u(m_monitor.m_monitor_clock), m_monitor.htotal(), 0, m_monitor.htotal(), m_monitor.vtotal(), 0, m_monitor.vtotal()); } diff --git a/src/devices/video/fixfreq.h b/src/devices/video/fixfreq.h index 482016ba97e..5d940019e5d 100644 --- a/src/devices/video/fixfreq.h +++ b/src/devices/video/fixfreq.h @@ -255,12 +255,12 @@ public: using time_type = fixedfreq_monitor_state::time_type; // construction/destruction - fixedfreq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + fixedfreq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration helpers - fixedfreq_device &set_monitor_clock(uint32_t clock) + fixedfreq_device &set_monitor_clock(const XTAL &clock) { - m_monitor.m_monitor_clock = clock; + m_monitor.m_monitor_clock = clock.value(); return *this; } fixedfreq_device &set_fieldcount(int count) @@ -304,7 +304,7 @@ public: // 799 858 480 486 492 525 interlace // -hsync -vsync { - set_monitor_clock(13500000); + set_monitor_clock(XTAL::u(13500000)); set_horz_params(720, 736, 799, 858); set_vert_params(480, 486, 492, 525); set_fieldcount(2); @@ -314,7 +314,7 @@ public: fixedfreq_device &set_mode_ntsc704() // ModeLine "704x480@30i" 13.5 704 728 // 791 858 480 486 492 525 { - set_monitor_clock(13500000); + set_monitor_clock(XTAL::u(13500000)); set_horz_params(704, 728, 791, 858); set_vert_params(480, 486, 492, 525); set_fieldcount(2); @@ -340,7 +340,7 @@ protected: device_type type, const char *tag, device_t *owner, - uint32_t clock); + const XTAL &clock); // device-level overrides virtual void device_config_complete() override; diff --git a/src/devices/video/gb_lcd.cpp b/src/devices/video/gb_lcd.cpp index ac81c1398f3..ba10b39d158 100644 --- a/src/devices/video/gb_lcd.cpp +++ b/src/devices/video/gb_lcd.cpp @@ -318,7 +318,7 @@ DEFINE_DEVICE_TYPE(CGB_PPU, cgb_ppu_device, "cgb_ppu", "CGB PPU") -dmg_ppu_device::dmg_ppu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size) +dmg_ppu_device::dmg_ppu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size) : device_t(mconfig, type, tag, owner, clock) , device_video_interface(mconfig, *this) , m_lr35902(*this, finder_base::DUMMY_TAG) @@ -328,25 +328,25 @@ dmg_ppu_device::dmg_ppu_device(const machine_config &mconfig, device_type type, { } -dmg_ppu_device::dmg_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +dmg_ppu_device::dmg_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmg_ppu_device(mconfig, DMG_PPU, tag, owner, clock, 0x2000) { m_enable_experimental_engine = true; } -mgb_ppu_device::mgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mgb_ppu_device::mgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmg_ppu_device(mconfig, MGB_PPU, tag, owner, clock, 0x2000) { m_enable_experimental_engine = true; } -sgb_ppu_device::sgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sgb_ppu_device::sgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmg_ppu_device(mconfig, SGB_PPU, tag, owner, clock, 0x2000) { m_enable_experimental_engine = false; } -cgb_ppu_device::cgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cgb_ppu_device::cgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : dmg_ppu_device(mconfig, CGB_PPU, tag, owner, clock, 0x4000) { m_enable_experimental_engine = false; diff --git a/src/devices/video/gb_lcd.h b/src/devices/video/gb_lcd.h index 418868e5ce0..03ad47d1780 100644 --- a/src/devices/video/gb_lcd.h +++ b/src/devices/video/gb_lcd.h @@ -20,11 +20,11 @@ class dmg_ppu_device : public device_t, public device_video_interface public: template <typename T> dmg_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag) - : dmg_ppu_device(mconfig, tag, owner, u32(0)) + : dmg_ppu_device(mconfig, tag, owner) { set_lr35902_tag(std::forward<T>(cpu_tag)); } - dmg_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + dmg_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename T> void set_lr35902_tag(T &&tag) { m_lr35902.set_tag(std::forward<T>(tag)); } @@ -75,7 +75,7 @@ protected: virtual void update_sprites(); virtual void update_scanline(uint32_t cycles_to_go); - dmg_ppu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size); + dmg_ppu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size); // device-level overrides virtual void device_start() override; @@ -239,11 +239,11 @@ class mgb_ppu_device : public dmg_ppu_device public: template <typename T> mgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag) - : mgb_ppu_device(mconfig, tag, owner, u32(0)) + : mgb_ppu_device(mconfig, tag, owner) { set_lr35902_tag(std::forward<T>(cpu_tag)); } - mgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: @@ -257,11 +257,11 @@ class sgb_ppu_device : public dmg_ppu_device public: template <typename T> sgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag) - : sgb_ppu_device(mconfig, tag, owner, u32(0)) + : sgb_ppu_device(mconfig, tag, owner) { set_lr35902_tag(std::forward<T>(cpu_tag)); } - sgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void sgb_io_write_pal(int offs, uint8_t *data); @@ -284,11 +284,11 @@ class cgb_ppu_device : public dmg_ppu_device public: template <typename T> cgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag) - : cgb_ppu_device(mconfig, tag, owner, u32(0)) + : cgb_ppu_device(mconfig, tag, owner) { set_lr35902_tag(std::forward<T>(cpu_tag)); } - cgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cgb_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual uint8_t video_r(offs_t offset) override; virtual void video_w(offs_t offset, uint8_t data) override; diff --git a/src/devices/video/gba_lcd.cpp b/src/devices/video/gba_lcd.cpp index 1bc8a87e7fe..5057822195c 100644 --- a/src/devices/video/gba_lcd.cpp +++ b/src/devices/video/gba_lcd.cpp @@ -147,7 +147,7 @@ private: DEFINE_DEVICE_TYPE(GBA_LCD, gba_lcd_device, "gba_lcd", "GBA LCD") -gba_lcd_device::gba_lcd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gba_lcd_device::gba_lcd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GBA_LCD, tag, owner, clock) , device_video_interface(mconfig, *this) , m_int_hblank_cb(*this) diff --git a/src/devices/video/gba_lcd.h b/src/devices/video/gba_lcd.h index 421ed02f2c3..9f2fd04a32d 100644 --- a/src/devices/video/gba_lcd.h +++ b/src/devices/video/gba_lcd.h @@ -63,7 +63,7 @@ class gba_lcd_device , protected gba_registers<0x060 / 4, 0x000> { public: - gba_lcd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gba_lcd_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t video_r(offs_t offset, uint32_t mem_mask = ~0); void video_w(offs_t offset, uint32_t data, uint32_t mem_mask = ~0); diff --git a/src/devices/video/gf4500.cpp b/src/devices/video/gf4500.cpp index e695404d938..104a82a76c5 100644 --- a/src/devices/video/gf4500.cpp +++ b/src/devices/video/gf4500.cpp @@ -36,7 +36,7 @@ static inline void ATTR_PRINTF(3,4) verboselog( device_t &device, int n_level, c DEFINE_DEVICE_TYPE(GF4500, gf4500_device, "gf4500", "NVIDIA GoForce 4500") -gf4500_device::gf4500_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gf4500_device::gf4500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, GF4500, tag, owner, clock), m_data(nullptr), m_screen_x(0), m_screen_y(0), m_screen_x_max(0), m_screen_y_max(0), m_screen_x_min(0), m_screen_y_min(0) { } diff --git a/src/devices/video/gf4500.h b/src/devices/video/gf4500.h index a402881c49b..12e0a758948 100644 --- a/src/devices/video/gf4500.h +++ b/src/devices/video/gf4500.h @@ -17,7 +17,7 @@ class gf4500_device : public device_t { public: - gf4500_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gf4500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t read(offs_t offset); diff --git a/src/devices/video/gf7600gs.cpp b/src/devices/video/gf7600gs.cpp index 075c95c5628..01d1a62683e 100644 --- a/src/devices/video/gf7600gs.cpp +++ b/src/devices/video/gf7600gs.cpp @@ -17,7 +17,7 @@ void geforce_7600gs_device::map3(address_map &map) { } -geforce_7600gs_device::geforce_7600gs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +geforce_7600gs_device::geforce_7600gs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, GEFORCE_7600GS, tag, owner, clock) { } diff --git a/src/devices/video/gf7600gs.h b/src/devices/video/gf7600gs.h index db13718c6da..e1498716a50 100644 --- a/src/devices/video/gf7600gs.h +++ b/src/devices/video/gf7600gs.h @@ -9,12 +9,12 @@ class geforce_7600gs_device : public pci_device { public: - geforce_7600gs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t subdevice_id) + geforce_7600gs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t subdevice_id) : geforce_7600gs_device(mconfig, tag, owner, clock) { set_ids_agp(0x10de02e1, 0xa1, subdevice_id); } - geforce_7600gs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + geforce_7600gs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/video/hd44102.cpp b/src/devices/video/hd44102.cpp index 49d05f3a797..a802768ea38 100644 --- a/src/devices/video/hd44102.cpp +++ b/src/devices/video/hd44102.cpp @@ -54,7 +54,7 @@ DEFINE_DEVICE_TYPE(HD44102, hd44102_device, "hd44102", "Hitachi HD44102 LCD Cont // hd44102_device - constructor //------------------------------------------------- -hd44102_device::hd44102_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +hd44102_device::hd44102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HD44102, tag, owner, clock), m_sx(0), m_sy(0) diff --git a/src/devices/video/hd44102.h b/src/devices/video/hd44102.h index dfcd8ca0349..ce718f47357 100644 --- a/src/devices/video/hd44102.h +++ b/src/devices/video/hd44102.h @@ -22,7 +22,7 @@ class hd44102_device : public device_t { public: // construction/destruction - hd44102_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + hd44102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // inline configuration helpers void set_screen_offsets(int sx, int sy) { m_sx = sx; m_sy = sy; } // when using screen_update diff --git a/src/devices/video/hd44352.cpp b/src/devices/video/hd44352.cpp index 12d431b21ef..33d232058dc 100644 --- a/src/devices/video/hd44352.cpp +++ b/src/devices/video/hd44352.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(HD44352, hd44352_device, "hd44352", "Hitachi HD44352 LCD Cont // hd44352_device - constructor //------------------------------------------------- -hd44352_device::hd44352_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock): +hd44352_device::hd44352_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock): device_t(mconfig, HD44352, tag, owner, clock), m_on_cb(*this), m_char_rom(*this, DEVICE_SELF) diff --git a/src/devices/video/hd44352.h b/src/devices/video/hd44352.h index a5b311c0e9f..d0e1bcf07dc 100644 --- a/src/devices/video/hd44352.h +++ b/src/devices/video/hd44352.h @@ -21,7 +21,7 @@ class hd44352_device : public device_t { public: // construction/destruction - hd44352_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd44352_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto on_cb() { return m_on_cb.bind(); } diff --git a/src/devices/video/hd44780.cpp b/src/devices/video/hd44780.cpp index 171d9cb5780..8d6f3bf8a76 100644 --- a/src/devices/video/hd44780.cpp +++ b/src/devices/video/hd44780.cpp @@ -54,13 +54,13 @@ ROM_END // hd44780_device - constructor //------------------------------------------------- -hd44780_device::hd44780_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd44780_device::hd44780_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd44780_device(mconfig, HD44780, tag, owner, clock) { set_charset_type(CHARSET_HD44780_A00); } -hd44780_device::hd44780_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +hd44780_device::hd44780_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_pixel_update_cb(*this) , m_busy_factor(1.0) @@ -74,13 +74,13 @@ hd44780_device::hd44780_device(const machine_config &mconfig, device_type type, { } -sed1278_0b_device::sed1278_0b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sed1278_0b_device::sed1278_0b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd44780_device(mconfig, SED1278_0B, tag, owner, clock) { set_charset_type(CHARSET_SED1278_0B); } -ks0066_f05_device::ks0066_f05_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +ks0066_f05_device::ks0066_f05_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd44780_device(mconfig, KS0066_F05, tag, owner, clock) { set_charset_type(CHARSET_KS0066_F05); diff --git a/src/devices/video/hd44780.h b/src/devices/video/hd44780.h index df1db86fbe8..06df9cfe136 100644 --- a/src/devices/video/hd44780.h +++ b/src/devices/video/hd44780.h @@ -27,7 +27,7 @@ public: typedef device_delegate<void (bitmap_ind16 &bitmap, u8 line, u8 pos, u8 y, u8 x, int state)> pixel_update_delegate; // construction/destruction - hd44780_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + hd44780_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // static configuration helpers void set_lcd_size(int lines, int chars) { m_lines = lines; m_chars = chars; } @@ -53,7 +53,7 @@ public: virtual uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); protected: - hd44780_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + hd44780_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -146,7 +146,7 @@ class sed1278_0b_device : public hd44780_device { public: // construction/destruction - sed1278_0b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sed1278_0b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // ======================> ks0066_f05_device @@ -155,7 +155,7 @@ class ks0066_f05_device : public hd44780_device { public: // construction/destruction - ks0066_f05_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ks0066_f05_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; // device type definition diff --git a/src/devices/video/hd61202.cpp b/src/devices/video/hd61202.cpp index 50bbc91d0b3..abc4d0b2960 100644 --- a/src/devices/video/hd61202.cpp +++ b/src/devices/video/hd61202.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(HD61202, hd61202_device, "hd61202", "Hitachi HD61202 LCD Driv // hd61202_device - constructor //------------------------------------------------- -hd61202_device::hd61202_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +hd61202_device::hd61202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HD61202, tag, owner, clock) , m_screen_update_cb(*this) { diff --git a/src/devices/video/hd61202.h b/src/devices/video/hd61202.h index 1ae9e741242..8577aae982b 100644 --- a/src/devices/video/hd61202.h +++ b/src/devices/video/hd61202.h @@ -26,7 +26,7 @@ public: typedef device_delegate<uint32_t (bitmap_ind16 &bitmap, const rectangle &cliprect, bool lcd_on, int start_line, uint8_t *ddr)> screen_update_delegate; // construction/destruction - hd61202_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + hd61202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers template <typename... T> void set_screen_update_cb(T &&... args) { m_screen_update_cb.set(std::forward<T>(args)...); } diff --git a/src/devices/video/hd61603.cpp b/src/devices/video/hd61603.cpp index 49a21cc779b..d58c7bf164c 100644 --- a/src/devices/video/hd61603.cpp +++ b/src/devices/video/hd61603.cpp @@ -23,7 +23,7 @@ DEFINE_DEVICE_TYPE(HD61603, hd61603_device, "hd61603", "Hitachi HD61603 LCD Driv // constructor //------------------------------------------------- -hd61603_device::hd61603_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +hd61603_device::hd61603_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HD61603, tag, owner, clock), m_write_segs(*this) { } diff --git a/src/devices/video/hd61603.h b/src/devices/video/hd61603.h index 8de7c879761..24d0e777260 100644 --- a/src/devices/video/hd61603.h +++ b/src/devices/video/hd61603.h @@ -37,7 +37,7 @@ pin desc class hd61603_device : public device_t { public: - hd61603_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hd61603_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto write_segs() { return m_write_segs.bind(); } diff --git a/src/devices/video/hd61830.cpp b/src/devices/video/hd61830.cpp index 9d2a8a5eb67..adb594f0804 100644 --- a/src/devices/video/hd61830.cpp +++ b/src/devices/video/hd61830.cpp @@ -75,7 +75,7 @@ static constexpr int MODE_DISPLAY_ON = 0x20; // hd61830_device - constructor //------------------------------------------------- -hd61830_device::hd61830_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +hd61830_device::hd61830_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HD61830, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/video/hd61830.h b/src/devices/video/hd61830.h index 83f5639ca14..4c411654841 100644 --- a/src/devices/video/hd61830.h +++ b/src/devices/video/hd61830.h @@ -24,7 +24,7 @@ class hd61830_device : public device_t, { public: // construction/destruction - hd61830_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd61830_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto rd_rd_callback() { return m_read_rd.bind(); } diff --git a/src/devices/video/hd63484.cpp b/src/devices/video/hd63484.cpp index cc0f577d11f..05f6c1f0fd9 100644 --- a/src/devices/video/hd63484.cpp +++ b/src/devices/video/hd63484.cpp @@ -24,7 +24,7 @@ // hd63484_device - constructor //------------------------------------------------- -hd63484_device::hd63484_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +hd63484_device::hd63484_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HD63484, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/video/hd63484.h b/src/devices/video/hd63484.h index 67383810bf6..a296ac3052c 100644 --- a/src/devices/video/hd63484.h +++ b/src/devices/video/hd63484.h @@ -25,7 +25,7 @@ public: typedef device_delegate<void (bitmap_ind16 &bitmap, const rectangle &cliprect, int y, int x, uint16_t data)> display_delegate; // construction/destruction - hd63484_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd63484_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename... T> void set_display_callback(T &&... args) { m_display_cb.set(std::forward<T>(args)...); } void set_auto_configure_screen(bool auto_configure_screen) { m_auto_configure_screen = auto_configure_screen; } diff --git a/src/devices/video/hd66421.cpp b/src/devices/video/hd66421.cpp index 6be96c81e1f..2e7f0a97611 100644 --- a/src/devices/video/hd66421.cpp +++ b/src/devices/video/hd66421.cpp @@ -123,7 +123,7 @@ inline void hd66421_device::writebyte(offs_t address, uint8_t data) // hd66421_device - constructor //------------------------------------------------- -hd66421_device::hd66421_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd66421_device::hd66421_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HD66421, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_space_config("videoram", ENDIANNESS_LITTLE, 8, 17, 0, address_map_constructor(FUNC(hd66421_device::hd66421), this)) diff --git a/src/devices/video/hd66421.h b/src/devices/video/hd66421.h index 8a38311d8e5..86f820631a2 100644 --- a/src/devices/video/hd66421.h +++ b/src/devices/video/hd66421.h @@ -30,7 +30,7 @@ public: static constexpr unsigned HEIGHT = 100; // construction/destruction - hd66421_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + hd66421_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint8_t reg_idx_r(); void reg_idx_w(uint8_t data); diff --git a/src/devices/video/hlcd0438.cpp b/src/devices/video/hlcd0438.cpp index 64f95711c8b..36b957368f5 100644 --- a/src/devices/video/hlcd0438.cpp +++ b/src/devices/video/hlcd0438.cpp @@ -19,7 +19,7 @@ DEFINE_DEVICE_TYPE(HLCD0438, hlcd0438_device, "hlcd0438", "Hughes HLCD 0438 LCD // constructor //------------------------------------------------- -hlcd0438_device::hlcd0438_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +hlcd0438_device::hlcd0438_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HLCD0438, tag, owner, clock), m_write_segs(*this), m_write_data(*this) { diff --git a/src/devices/video/hlcd0438.h b/src/devices/video/hlcd0438.h index 19973dd8451..e2c1960c5ce 100644 --- a/src/devices/video/hlcd0438.h +++ b/src/devices/video/hlcd0438.h @@ -42,7 +42,7 @@ class hlcd0438_device : public device_t { public: - hlcd0438_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hlcd0438_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto write_segs() { return m_write_segs.bind(); } // BP pin in offset, SEG pins in data diff --git a/src/devices/video/hlcd0488.cpp b/src/devices/video/hlcd0488.cpp index 7c5d7eb4c99..6eb153005c3 100644 --- a/src/devices/video/hlcd0488.cpp +++ b/src/devices/video/hlcd0488.cpp @@ -21,7 +21,7 @@ DEFINE_DEVICE_TYPE(HLCD0488, hlcd0488_device, "hlcd0488", "Hughes HLCD 0488 LCD // constructor //------------------------------------------------- -hlcd0488_device::hlcd0488_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +hlcd0488_device::hlcd0488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HLCD0488, tag, owner, clock), m_write_cols(*this) { } diff --git a/src/devices/video/hlcd0488.h b/src/devices/video/hlcd0488.h index c2302fbc88b..0f121bb6278 100644 --- a/src/devices/video/hlcd0488.h +++ b/src/devices/video/hlcd0488.h @@ -42,7 +42,7 @@ class hlcd0488_device : public device_t { public: - hlcd0488_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + hlcd0488_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers auto write_cols() { return m_write_cols.bind(); } // COL pins in data, ROW pins in offset diff --git a/src/devices/video/hlcd0515.cpp b/src/devices/video/hlcd0515.cpp index 7af99f99657..8452ee3abfa 100644 --- a/src/devices/video/hlcd0515.cpp +++ b/src/devices/video/hlcd0515.cpp @@ -28,25 +28,25 @@ DEFINE_DEVICE_TYPE(HLCD0601, hlcd0601_device, "hlcd0601", "Hughes HLCD 0601 LCD // constructor //------------------------------------------------- -hlcd0515_device::hlcd0515_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 colmax) : +hlcd0515_device::hlcd0515_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 colmax) : device_t(mconfig, type, tag, owner, clock), m_colmax(colmax), m_write_cols(*this), m_write_data(*this) { } -hlcd0515_device::hlcd0515_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +hlcd0515_device::hlcd0515_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hlcd0515_device(mconfig, HLCD0515, tag, owner, clock, 25) { } -hlcd0569_device::hlcd0569_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +hlcd0569_device::hlcd0569_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hlcd0515_device(mconfig, HLCD0569, tag, owner, clock, 24) { } -hlcd0530_device::hlcd0530_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +hlcd0530_device::hlcd0530_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hlcd0515_device(mconfig, HLCD0530, tag, owner, clock, 24) { } -hlcd0601_device::hlcd0601_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +hlcd0601_device::hlcd0601_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hlcd0515_device(mconfig, HLCD0601, tag, owner, clock, 24) { } diff --git a/src/devices/video/hlcd0515.h b/src/devices/video/hlcd0515.h index c6ef5e118bf..403105ca54e 100644 --- a/src/devices/video/hlcd0515.h +++ b/src/devices/video/hlcd0515.h @@ -44,7 +44,7 @@ class hlcd0515_device : public device_t { public: - hlcd0515_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hlcd0515_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto write_cols() { return m_write_cols.bind(); } // COL/ROW pins (offset for ROW) @@ -56,7 +56,7 @@ public: DECLARE_READ_LINE_MEMBER(data_r) { return m_dataout; } protected: - hlcd0515_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 colmax); + hlcd0515_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 colmax); // device-level overrides virtual void device_start() override; @@ -92,7 +92,7 @@ protected: class hlcd0569_device : public hlcd0515_device { public: - hlcd0569_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hlcd0569_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void set_control() override; @@ -101,13 +101,13 @@ protected: class hlcd0530_device : public hlcd0515_device { public: - hlcd0530_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hlcd0530_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class hlcd0601_device : public hlcd0515_device { public: - hlcd0601_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + hlcd0601_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/video/hlcd0538.cpp b/src/devices/video/hlcd0538.cpp index 314644bcfd4..ba99eaadf86 100644 --- a/src/devices/video/hlcd0538.cpp +++ b/src/devices/video/hlcd0538.cpp @@ -26,16 +26,16 @@ DEFINE_DEVICE_TYPE(HLCD0539, hlcd0539_device, "hlcd0539", "Hughes HLCD 0539 LCD // constructor //------------------------------------------------- -hlcd0538_device::hlcd0538_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) : +hlcd0538_device::hlcd0538_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_write_cols(*this), m_write_interrupt(*this) { } -hlcd0538_device::hlcd0538_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +hlcd0538_device::hlcd0538_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hlcd0538_device(mconfig, HLCD0538, tag, owner, clock) { } -hlcd0539_device::hlcd0539_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +hlcd0539_device::hlcd0539_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hlcd0538_device(mconfig, HLCD0539, tag, owner, clock) { } @@ -52,7 +52,7 @@ void hlcd0538_device::device_start() // timer (when LCD pin is oscillator) m_lcd_timer = timer_alloc(FUNC(hlcd0538_device::toggle_lcd), this); - attotime period = (clock() != 0) ? attotime::from_hz(2 * clock()) : attotime::never; + attotime period = !clock().disabled() ? attotime::from_hz(2 * clock().value()) : attotime::never; m_lcd_timer->adjust(period, 0, period); // zerofill diff --git a/src/devices/video/hlcd0538.h b/src/devices/video/hlcd0538.h index add8e0e3028..43a0101109a 100644 --- a/src/devices/video/hlcd0538.h +++ b/src/devices/video/hlcd0538.h @@ -43,7 +43,7 @@ class hlcd0538_device : public device_t { public: - hlcd0538_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + hlcd0538_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers auto write_cols() { return m_write_cols.bind(); } // C/R pins (0538: d0-d7 for rows) @@ -54,7 +54,7 @@ public: DECLARE_WRITE_LINE_MEMBER(data_w) { m_data = (state) ? 1 : 0; } protected: - hlcd0538_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + hlcd0538_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -77,7 +77,7 @@ protected: class hlcd0539_device : public hlcd0538_device { public: - hlcd0539_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + hlcd0539_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; diff --git a/src/devices/video/hp1ll3.cpp b/src/devices/video/hp1ll3.cpp index 006b8823122..8de471ddd90 100644 --- a/src/devices/video/hp1ll3.cpp +++ b/src/devices/video/hp1ll3.cpp @@ -280,7 +280,7 @@ DEFINE_DEVICE_TYPE(HP1LL3, hp1ll3_device, "hp1ll3", "Hewlett-Packard 1LL3-0005 G // hp1ll3_device - constructor //------------------------------------------------- -hp1ll3_device::hp1ll3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hp1ll3_device::hp1ll3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HP1LL3, tag, owner, clock) , device_video_interface(mconfig, *this) , m_vram_size(16) diff --git a/src/devices/video/hp1ll3.h b/src/devices/video/hp1ll3.h index 1dd238fba8f..643e280358d 100644 --- a/src/devices/video/hp1ll3.h +++ b/src/devices/video/hp1ll3.h @@ -23,7 +23,7 @@ class hp1ll3_device : public device_t, public device_video_interface { public: // construction/destruction - hp1ll3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hp1ll3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // Configuration // Set VRAM size (in kw). Parameter must be <= 128 and it must be a power of 2. diff --git a/src/devices/video/huc6202.cpp b/src/devices/video/huc6202.cpp index 42ffaafef14..151d3fa016c 100644 --- a/src/devices/video/huc6202.cpp +++ b/src/devices/video/huc6202.cpp @@ -15,7 +15,7 @@ DEFINE_DEVICE_TYPE(HUC6202, huc6202_device, "huc6202", "Hudson HuC6202 VPC") -huc6202_device::huc6202_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +huc6202_device::huc6202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HUC6202, tag, owner, clock) , m_next_pixel_0_cb(*this) , m_time_til_next_event_0_cb(*this) diff --git a/src/devices/video/huc6202.h b/src/devices/video/huc6202.h index 5ef636626b0..0ca6aff6843 100644 --- a/src/devices/video/huc6202.h +++ b/src/devices/video/huc6202.h @@ -16,7 +16,7 @@ class huc6202_device : public device_t { public: // construction/destruction - huc6202_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + huc6202_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto next_pixel_0_callback() { return m_next_pixel_0_cb.bind(); } auto time_til_next_event_0_callback() { return m_time_til_next_event_0_cb.bind(); } diff --git a/src/devices/video/huc6260.cpp b/src/devices/video/huc6260.cpp index cc41b86ac1d..1c371132591 100644 --- a/src/devices/video/huc6260.cpp +++ b/src/devices/video/huc6260.cpp @@ -51,7 +51,7 @@ void huc6260_device::palette_init() DEFINE_DEVICE_TYPE(HUC6260, huc6260_device, "huc6260", "Hudson HuC6260 VCE") -huc6260_device::huc6260_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +huc6260_device::huc6260_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HUC6260, tag, owner, clock), device_palette_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/video/huc6260.h b/src/devices/video/huc6260.h index 01b1a299f45..8d55ab10904 100644 --- a/src/devices/video/huc6260.h +++ b/src/devices/video/huc6260.h @@ -25,7 +25,7 @@ public: // construction/destruction - huc6260_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + huc6260_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto next_pixel_data() { return m_next_pixel_data_cb.bind(); } auto time_til_next_event() { return m_time_til_next_event_cb.bind(); } diff --git a/src/devices/video/huc6261.cpp b/src/devices/video/huc6261.cpp index 27bd06c7e33..7748ed5769f 100644 --- a/src/devices/video/huc6261.cpp +++ b/src/devices/video/huc6261.cpp @@ -31,7 +31,7 @@ constexpr unsigned huc6261_device::LPF; DEFINE_DEVICE_TYPE(HUC6261, huc6261_device, "huc6261", "Hudson HuC6261 VCE") -huc6261_device::huc6261_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +huc6261_device::huc6261_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HUC6261, tag, owner, clock), device_video_interface(mconfig, *this), m_huc6270_a(*this, finder_base::DUMMY_TAG), diff --git a/src/devices/video/huc6261.h b/src/devices/video/huc6261.h index 9995a20673b..1bfcb2ed589 100644 --- a/src/devices/video/huc6261.h +++ b/src/devices/video/huc6261.h @@ -24,7 +24,7 @@ public: static constexpr unsigned LPF = 263; // max number of lines in a single frame // construction/destruction - huc6261_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + huc6261_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_vdc1_tag(T &&tag) { m_huc6270_a.set_tag(std::forward<T>(tag)); } template <typename T> void set_vdc2_tag(T &&tag) { m_huc6270_b.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/video/huc6270.cpp b/src/devices/video/huc6270.cpp index 09f49963ba9..53bbf2d42df 100644 --- a/src/devices/video/huc6270.cpp +++ b/src/devices/video/huc6270.cpp @@ -99,7 +99,7 @@ DEFINE_DEVICE_TYPE(HUC6270, huc6270_device, "huc6270", "Hudson HuC6270 VDC") constexpr uint8_t huc6270_device::vram_increments[4]; -huc6270_device::huc6270_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +huc6270_device::huc6270_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HUC6270, tag, owner, clock) , m_vram_size(0) , m_irq_changed_cb(*this) diff --git a/src/devices/video/huc6270.h b/src/devices/video/huc6270.h index c333e720bc7..4245d82fcc8 100644 --- a/src/devices/video/huc6270.h +++ b/src/devices/video/huc6270.h @@ -16,7 +16,7 @@ class huc6270_device : public device_t { public: // construction/destruction - huc6270_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + huc6270_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_vram_size(uint32_t vram_size) { m_vram_size = vram_size; } auto irq() { return m_irq_changed_cb.bind(); } diff --git a/src/devices/video/huc6271.cpp b/src/devices/video/huc6271.cpp index 9f90ba8c3b3..c3144eb8d11 100644 --- a/src/devices/video/huc6271.cpp +++ b/src/devices/video/huc6271.cpp @@ -33,7 +33,7 @@ void huc6271_device::data_map(address_map &map) map(0x000000, 0x0fffff).ram(); } -huc6271_device::huc6271_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +huc6271_device::huc6271_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HUC6271, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_data_space_config("data", ENDIANNESS_LITTLE, 32, 32, 0, address_map_constructor(FUNC(huc6271_device::data_map), this)) diff --git a/src/devices/video/huc6271.h b/src/devices/video/huc6271.h index a8b3eb00287..d50bd39b4a4 100644 --- a/src/devices/video/huc6271.h +++ b/src/devices/video/huc6271.h @@ -24,7 +24,7 @@ class huc6271_device : public device_t, { public: // construction/destruction - huc6271_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + huc6271_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations //void data_transfer(uint32_t offset, uint32_t data); diff --git a/src/devices/video/huc6272.cpp b/src/devices/video/huc6272.cpp index 5f4ec6b8c7a..af6870dd77e 100644 --- a/src/devices/video/huc6272.cpp +++ b/src/devices/video/huc6272.cpp @@ -63,7 +63,7 @@ void huc6272_device::kram_map(address_map &map) // huc6272_device - constructor //------------------------------------------------- -huc6272_device::huc6272_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +huc6272_device::huc6272_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, HUC6272, tag, owner, clock), device_memory_interface(mconfig, *this), m_huc6271(*this, finder_base::DUMMY_TAG), diff --git a/src/devices/video/huc6272.h b/src/devices/video/huc6272.h index db5087f7f0c..8e78ee35b5f 100644 --- a/src/devices/video/huc6272.h +++ b/src/devices/video/huc6272.h @@ -30,7 +30,7 @@ public: static constexpr feature_type imperfect_features() { return feature::SOUND | feature::GRAPHICS; } // Incorrect ADPCM and Graphics // construction/destruction - huc6272_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + huc6272_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto irq_changed_callback() { return m_irq_changed_cb.bind(); } template <typename T> void set_rainbow_tag(T &&tag) { m_huc6271.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/video/i8244.cpp b/src/devices/video/i8244.cpp index 622d5c056df..52720ba1687 100644 --- a/src/devices/video/i8244.cpp +++ b/src/devices/video/i8244.cpp @@ -32,11 +32,11 @@ DEFINE_DEVICE_TYPE(I8245, i8245_device, "i8245", "Intel 8245") // i8244_device - constructor //------------------------------------------------- -i8244_device::i8244_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +i8244_device::i8244_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8244_device(mconfig, I8244, tag, owner, clock) { } -i8244_device::i8244_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +i8244_device::i8244_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_sound_interface(mconfig, *this) , device_video_interface(mconfig, *this) @@ -44,7 +44,7 @@ i8244_device::i8244_device(const machine_config &mconfig, device_type type, cons , m_charset(*this, "cgrom") { } -i8245_device::i8245_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +i8245_device::i8245_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8244_device(mconfig, I8245, tag, owner, clock) { } diff --git a/src/devices/video/i8244.h b/src/devices/video/i8244.h index 9514f36deb5..672d2db2414 100644 --- a/src/devices/video/i8244.h +++ b/src/devices/video/i8244.h @@ -45,7 +45,7 @@ class i8244_device : public device_t { public: // construction/destruction - i8244_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + i8244_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto irq_cb() { return m_irq_func.bind(); } @@ -106,7 +106,7 @@ protected: } s; }; - i8244_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + i8244_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_config_complete() override; @@ -177,7 +177,7 @@ class i8245_device : public i8244_device { public: // construction/destruction - i8245_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + i8245_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static auto parent_rom_device_type() { return &I8244; } diff --git a/src/devices/video/i82730.cpp b/src/devices/video/i82730.cpp index ba853c41680..5341fe84b8d 100644 --- a/src/devices/video/i82730.cpp +++ b/src/devices/video/i82730.cpp @@ -36,7 +36,7 @@ DEFINE_DEVICE_TYPE(I82730, i82730_device, "i82730", "Intel 82730") // i82730_device - constructor //------------------------------------------------- -i82730_device::i82730_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i82730_device::i82730_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, I82730, tag, owner, clock), device_video_interface(mconfig, *this), m_sint_handler(*this), diff --git a/src/devices/video/i82730.h b/src/devices/video/i82730.h index 27f82eb8d5c..68e444bfe24 100644 --- a/src/devices/video/i82730.h +++ b/src/devices/video/i82730.h @@ -29,12 +29,12 @@ public: // construction/destruction template <typename T> - i82730_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&cpu_tag) + i82730_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&cpu_tag) : i82730_device(mconfig, tag, owner, clock) { m_cpu.set_tag(std::forward<T>(cpu_tag)); } - i82730_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i82730_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // callbacks auto sint() { return m_sint_handler.bind(); } diff --git a/src/devices/video/i8275.cpp b/src/devices/video/i8275.cpp index 1e080986e22..5e98108840f 100644 --- a/src/devices/video/i8275.cpp +++ b/src/devices/video/i8275.cpp @@ -98,7 +98,7 @@ DEFINE_DEVICE_TYPE(I8276, i8276_device, "i8276", "Intel 8276 CRTC") // i8275_device - constructor //------------------------------------------------- -i8275_device::i8275_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +i8275_device::i8275_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), m_write_irq(*this), @@ -129,12 +129,12 @@ i8275_device::i8275_device(const machine_config &mconfig, device_type type, cons memset(m_param, 0x00, sizeof(m_param)); } -i8275_device::i8275_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i8275_device::i8275_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8275_device(mconfig, I8275, tag, owner, clock) { } -i8276_device::i8276_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +i8276_device::i8276_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : i8275_device(mconfig, I8276, tag, owner, clock) { } diff --git a/src/devices/video/i8275.h b/src/devices/video/i8275.h index 2b49dee6362..ec0e1add6de 100644 --- a/src/devices/video/i8275.h +++ b/src/devices/video/i8275.h @@ -58,7 +58,7 @@ public: typedef device_delegate<void (bitmap_rgb32 &bitmap, int x, int y, uint8_t linecount, uint8_t charcode, uint8_t lineattr, uint8_t lten, uint8_t rvv, uint8_t vsp, uint8_t gpa, uint8_t hlgt)> draw_character_delegate; // construction/destruction - i8275_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8275_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_character_width(int value) { m_hpixels_per_column = value; } void set_refresh_hack(bool hack) { m_refresh_hack = hack; } @@ -80,7 +80,7 @@ public: uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); protected: - i8275_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + i8275_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -212,7 +212,7 @@ class i8276_device : public i8275_device { public: // construction/destruction - i8276_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + i8276_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/video/imagetek_i4100.cpp b/src/devices/video/imagetek_i4100.cpp index 5b9cc568e03..6805e169c65 100644 --- a/src/devices/video/imagetek_i4100.cpp +++ b/src/devices/video/imagetek_i4100.cpp @@ -268,7 +268,7 @@ void imagetek_i4300_device::v3_map(address_map &map) //------------------------------------------------- -imagetek_i4100_device::imagetek_i4100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool has_ext_tiles) +imagetek_i4100_device::imagetek_i4100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool has_ext_tiles) : device_t(mconfig, type, tag, owner, clock) , device_gfx_interface(mconfig, *this, has_ext_tiles ? gfxinfo_ext : gfxinfo, "palette") , device_video_interface(mconfig, *this) @@ -297,18 +297,18 @@ imagetek_i4100_device::imagetek_i4100_device(const machine_config &mconfig, devi { } -imagetek_i4100_device::imagetek_i4100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +imagetek_i4100_device::imagetek_i4100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : imagetek_i4100_device(mconfig, I4100, tag, owner, clock, false) { } -imagetek_i4220_device::imagetek_i4220_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +imagetek_i4220_device::imagetek_i4220_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : imagetek_i4100_device(mconfig, I4220, tag, owner, clock, true) { } -imagetek_i4300_device::imagetek_i4300_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +imagetek_i4300_device::imagetek_i4300_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : imagetek_i4100_device(mconfig, I4300, tag, owner, clock, true) { std::fill(std::begin(m_irq_levels), std::end(m_irq_levels), 0); diff --git a/src/devices/video/imagetek_i4100.h b/src/devices/video/imagetek_i4100.h index 8f11b055f12..04b7c35356b 100644 --- a/src/devices/video/imagetek_i4100.h +++ b/src/devices/video/imagetek_i4100.h @@ -28,7 +28,7 @@ class imagetek_i4100_device : public device_t, { public: // construction/destruction - imagetek_i4100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + imagetek_i4100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void map(address_map &map); @@ -71,7 +71,7 @@ public: u8 irq_cause_r(); protected: - imagetek_i4100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, bool has_ext_tiles); + imagetek_i4100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool has_ext_tiles); // device-level overrides //virtual void device_validity_check(validity_checker &valid) const override; @@ -230,7 +230,7 @@ class imagetek_i4220_device : public imagetek_i4100_device { public: // construction/destruction - imagetek_i4220_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + imagetek_i4220_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // needed by Blazing Tornado / Grand Striker 2 for mixing with PSAC // (it's unknown how the chip enables external sync) @@ -243,7 +243,7 @@ class imagetek_i4300_device : public imagetek_i4100_device { public: // construction/destruction - imagetek_i4300_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + imagetek_i4300_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void v3_map(address_map &map); u8 irq_vector_r(offs_t offset); diff --git a/src/devices/video/ims_cvc.cpp b/src/devices/video/ims_cvc.cpp index 0c5b62dfff4..cdae36cd5d2 100644 --- a/src/devices/video/ims_cvc.cpp +++ b/src/devices/video/ims_cvc.cpp @@ -26,7 +26,7 @@ DEFINE_DEVICE_TYPE(G300, g300_device, "g300", "INMOS G300 Colour Video Controlle DEFINE_DEVICE_TYPE(G332, g332_device, "g332", "INMOS G332 Colour Video Controller") DEFINE_DEVICE_TYPE(G364, g364_device, "g364", "INMOS G364 Colour Video Controller") -ims_cvc_device::ims_cvc_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) +ims_cvc_device::ims_cvc_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_palette_interface(mconfig, *this) , m_screen(*this, finder_base::DUMMY_TAG) @@ -34,23 +34,23 @@ ims_cvc_device::ims_cvc_device(machine_config const &mconfig, device_type type, { } -g300_device::g300_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +g300_device::g300_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : ims_cvc_device(mconfig, G300, tag, owner, clock) { } -g332_device::g332_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock) +g332_device::g332_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock) : ims_cvc_device(mconfig, type, tag, owner, clock) , m_microport(*this, "microport") { } -g332_device::g332_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +g332_device::g332_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : g332_device(mconfig, G332, tag, owner, clock) { } -g364_device::g364_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock) +g364_device::g364_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock) : g332_device(mconfig, G364, tag, owner, clock) { } @@ -362,7 +362,7 @@ void g332_device::control_a_w(u32 data) rectangle const visarea(hbend, hbend + (m_display << 2) - 1, vbend, height - 1); - u32 const dotclock = (m_boot & PLL_SELECT) ? clock() * (m_boot & PLL_MULTIPLIER) : clock(); + u32 const dotclock = (m_boot & PLL_SELECT) ? clock().value() * (m_boot & PLL_MULTIPLIER) : clock().value(); attotime const refresh = attotime::from_hz(dotclock / (width * height)); m_screen->configure(width, height, visarea, refresh.as_attoseconds()); diff --git a/src/devices/video/ims_cvc.h b/src/devices/video/ims_cvc.h index 094391e23cf..6d303b872cd 100644 --- a/src/devices/video/ims_cvc.h +++ b/src/devices/video/ims_cvc.h @@ -24,7 +24,7 @@ public: virtual void set_swapped(bool swapped) { m_swap = swapped ? 3 : 0; } protected: - ims_cvc_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + ims_cvc_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device_t overrides virtual void device_start() override; @@ -96,7 +96,7 @@ protected: class g300_device : public ims_cvc_device { public: - g300_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + g300_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; @@ -115,7 +115,7 @@ private: class g332_device : public ims_cvc_device { public: - g332_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + g332_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map) override; @@ -168,7 +168,7 @@ public: }; protected: - g332_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, u32 clock); + g332_device(machine_config const &mconfig, device_type type, char const *tag, device_t *owner, const XTAL &clock); // device_t overrides virtual void device_add_mconfig(machine_config &config) override; @@ -220,7 +220,7 @@ private: class g364_device : public g332_device { public: - g364_device(machine_config const &mconfig, char const *tag, device_t *owner, u32 clock); + g364_device(machine_config const &mconfig, char const *tag, device_t *owner, const XTAL &clock); virtual void set_swapped(bool swapped) override { m_swap = swapped ? 7 : 0; } }; diff --git a/src/devices/video/jangou_blitter.cpp b/src/devices/video/jangou_blitter.cpp index b8718b2ba20..26e89791108 100644 --- a/src/devices/video/jangou_blitter.cpp +++ b/src/devices/video/jangou_blitter.cpp @@ -35,7 +35,7 @@ DEFINE_DEVICE_TYPE(JANGOU_BLITTER, jangou_blitter_device, "jangou_blitter", "Jan // jangou_blitter_device - constructor //------------------------------------------------- -jangou_blitter_device::jangou_blitter_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +jangou_blitter_device::jangou_blitter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, JANGOU_BLITTER, tag, owner, clock) { } diff --git a/src/devices/video/jangou_blitter.h b/src/devices/video/jangou_blitter.h index e8d43c3a9f6..ed77b19bc17 100644 --- a/src/devices/video/jangou_blitter.h +++ b/src/devices/video/jangou_blitter.h @@ -17,7 +17,7 @@ class jangou_blitter_device : public device_t { public: // construction/destruction - jangou_blitter_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + jangou_blitter_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations void blit_v1_regs(address_map &map); diff --git a/src/devices/video/k051316.cpp b/src/devices/video/k051316.cpp index e38897dfaa8..eeab6a459d5 100644 --- a/src/devices/video/k051316.cpp +++ b/src/devices/video/k051316.cpp @@ -106,7 +106,7 @@ GFXDECODE_MEMBER( k051316_device::gfxinfo4_ram ) GFXDECODE_END -k051316_device::k051316_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +k051316_device::k051316_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K051316, tag, owner, clock) , device_gfx_interface(mconfig, *this, gfxinfo) , m_zoom_rom(*this, DEVICE_SELF) diff --git a/src/devices/video/k051316.h b/src/devices/video/k051316.h index 7f8b4b9e068..dc8eb36de6f 100644 --- a/src/devices/video/k051316.h +++ b/src/devices/video/k051316.h @@ -16,7 +16,7 @@ class k051316_device : public device_t, public device_gfx_interface public: using zoom_delegate = device_delegate<void (int *code, int *color)>; - k051316_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + k051316_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); static const gfx_layout charlayout4; static const gfx_layout charlayout7; diff --git a/src/devices/video/k053936.cpp b/src/devices/video/k053936.cpp index c9900430b53..1a922fa4324 100644 --- a/src/devices/video/k053936.cpp +++ b/src/devices/video/k053936.cpp @@ -229,7 +229,7 @@ void K053936_set_offset(int chip, int xoffs, int yoffs) DEFINE_DEVICE_TYPE(K053936, k053936_device, "k053936", "K053936 Video Controller") -k053936_device::k053936_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +k053936_device::k053936_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, K053936, tag, owner, clock), m_ctrl(nullptr), m_linectrl(nullptr), diff --git a/src/devices/video/k053936.h b/src/devices/video/k053936.h index 75894c2bf95..691276ef913 100644 --- a/src/devices/video/k053936.h +++ b/src/devices/video/k053936.h @@ -23,7 +23,7 @@ void K053936GP_0_zoom_draw(running_machine &machine, bitmap_rgb32 &bitmap, const class k053936_device : public device_t { public: - k053936_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + k053936_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); ~k053936_device() {} // configuration diff --git a/src/devices/video/lc7582.cpp b/src/devices/video/lc7582.cpp index f576d97ea20..6682377b096 100644 --- a/src/devices/video/lc7582.cpp +++ b/src/devices/video/lc7582.cpp @@ -22,7 +22,7 @@ DEFINE_DEVICE_TYPE(LC7582, lc7582_device, "lc7582", "Sanyo LC7582 LCD Driver") // constructor //------------------------------------------------- -lc7582_device::lc7582_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +lc7582_device::lc7582_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LC7582, tag, owner, clock), m_write_segs(*this) { } diff --git a/src/devices/video/lc7582.h b/src/devices/video/lc7582.h index 3f8dcc22bc6..3a744395829 100644 --- a/src/devices/video/lc7582.h +++ b/src/devices/video/lc7582.h @@ -34,7 +34,7 @@ pin desc class lc7582_device : public device_t { public: - lc7582_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + lc7582_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto write_segs() { return m_write_segs.bind(); } // S pins, COM1/COM2 in offset diff --git a/src/devices/video/lc7985.cpp b/src/devices/video/lc7985.cpp index ef01cbb6a2c..1d9cd154f21 100644 --- a/src/devices/video/lc7985.cpp +++ b/src/devices/video/lc7985.cpp @@ -17,7 +17,7 @@ ROM_START( lc7985 ) ROM_LOAD( "lc7985.bin", 0x0000, 0x1000, BAD_DUMP CRC(fdc64160) SHA1(8e6b54f8fb7c4c15aab2e65dd1a44729b97423b1)) // from page 12 of the LC7985D datasheet ROM_END -lc7985_device::lc7985_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +lc7985_device::lc7985_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LC7985, tag, owner, clock), m_cgrom_region(*this, DEVICE_SELF) { diff --git a/src/devices/video/lc7985.h b/src/devices/video/lc7985.h index 353822e7462..25d898508d3 100644 --- a/src/devices/video/lc7985.h +++ b/src/devices/video/lc7985.h @@ -14,7 +14,7 @@ class lc7985_device : public device_t { public: - lc7985_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + lc7985_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void ir_w(u8 data); u8 status_r(); diff --git a/src/devices/video/m50458.cpp b/src/devices/video/m50458.cpp index e2404684700..0502a469f51 100644 --- a/src/devices/video/m50458.cpp +++ b/src/devices/video/m50458.cpp @@ -179,7 +179,7 @@ inline void m50458_device::write_word(offs_t address, uint16_t data) // m50458_device - constructor //------------------------------------------------- -m50458_device::m50458_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m50458_device::m50458_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, M50458, tag, owner, clock) , device_memory_interface(mconfig, *this) , device_video_interface(mconfig, *this) diff --git a/src/devices/video/m50458.h b/src/devices/video/m50458.h index fd0eed36e22..2261a1fcbdf 100644 --- a/src/devices/video/m50458.h +++ b/src/devices/video/m50458.h @@ -25,13 +25,13 @@ class m50458_device : public device_t, public: // construction/destruction template <typename T> - m50458_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) + m50458_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : m50458_device(mconfig, tag, owner, clock) { set_screen(std::forward<T>(screen_tag)); } - m50458_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m50458_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations DECLARE_WRITE_LINE_MEMBER( write_bit ); diff --git a/src/devices/video/mb88303.cpp b/src/devices/video/mb88303.cpp index 16a24122306..c9f901e0afc 100644 --- a/src/devices/video/mb88303.cpp +++ b/src/devices/video/mb88303.cpp @@ -101,7 +101,7 @@ DEFINE_DEVICE_TYPE(MB88303, mb88303_device, "mb88303", "Fujitsu MB88303") // mb88303_device - constructor //------------------------------------------------- -mb88303_device::mb88303_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb88303_device::mb88303_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MB88303, tag, owner, clock) , m_write_vow(*this) , m_write_vobn(*this) diff --git a/src/devices/video/mb88303.h b/src/devices/video/mb88303.h index 742c6b62beb..8483fef0f4d 100644 --- a/src/devices/video/mb88303.h +++ b/src/devices/video/mb88303.h @@ -39,7 +39,7 @@ public: static constexpr unsigned VISIBLE_LINES = 9; // construction/destruction - mb88303_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb88303_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto vow_callback() { return m_write_vow.bind(); } auto vobn_callback() { return m_write_vobn.bind(); } diff --git a/src/devices/video/mb90082.cpp b/src/devices/video/mb90082.cpp index 27ef9238ec6..3f8f1658f10 100644 --- a/src/devices/video/mb90082.cpp +++ b/src/devices/video/mb90082.cpp @@ -91,7 +91,7 @@ inline void mb90082_device::write_word(offs_t address, uint16_t data) // mb90082_device - constructor //------------------------------------------------- -mb90082_device::mb90082_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb90082_device::mb90082_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MB90082, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_space_config("videoram", ENDIANNESS_LITTLE, 16, 16, 0, address_map_constructor(FUNC(mb90082_device::mb90082_vram), this)) diff --git a/src/devices/video/mb90082.h b/src/devices/video/mb90082.h index 782138ea466..50c21b4a530 100644 --- a/src/devices/video/mb90082.h +++ b/src/devices/video/mb90082.h @@ -24,7 +24,7 @@ class mb90082_device : public device_t, { public: // construction/destruction - mb90082_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb90082_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // I/O operations void write(uint8_t data); diff --git a/src/devices/video/mb_vcu.cpp b/src/devices/video/mb_vcu.cpp index 09ac807f13a..deaa60bce4f 100644 --- a/src/devices/video/mb_vcu.cpp +++ b/src/devices/video/mb_vcu.cpp @@ -147,7 +147,7 @@ inline void mb_vcu_device::write_io(offs_t address, uint8_t data) // mb_vcu_device - constructor //------------------------------------------------- -mb_vcu_device::mb_vcu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mb_vcu_device::mb_vcu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MB_VCU, tag, owner, clock) , device_memory_interface(mconfig, *this) , device_video_interface(mconfig, *this) diff --git a/src/devices/video/mb_vcu.h b/src/devices/video/mb_vcu.h index 8e9973f7433..c2902064aa8 100644 --- a/src/devices/video/mb_vcu.h +++ b/src/devices/video/mb_vcu.h @@ -20,7 +20,7 @@ class mb_vcu_device : public device_t, { public: // construction/destruction - mb_vcu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mb_vcu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration template <typename T> void set_palette_tag(T &&tag) { m_palette.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/video/mc6845.cpp b/src/devices/video/mc6845.cpp index 8c8c6e81f88..e57274e30c2 100644 --- a/src/devices/video/mc6845.cpp +++ b/src/devices/video/mc6845.cpp @@ -104,7 +104,7 @@ DEFINE_DEVICE_TYPE(MOS8568, mos8568_device, "mos8568", "MOS 8568 VDC") #define ATTR_ALTERNATE_CHARSET BIT(attr, 7) -mc6845_device::mc6845_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mc6845_device::mc6845_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_video_interface(mconfig, *this, false) , m_show_border_area(true) @@ -128,7 +128,7 @@ mc6845_device::mc6845_device(const machine_config &mconfig, device_type type, co { } -mc6845_device::mc6845_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6845_device::mc6845_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6845_device(mconfig, MC6845, tag, owner, clock) { } @@ -1624,61 +1624,61 @@ void mos8563_device::mos8563_videoram_map(address_map &map) } -r6545_1_device::r6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +r6545_1_device::r6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6845_device(mconfig, R6545_1, tag, owner, clock) { } -mc6845_1_device::mc6845_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6845_1_device::mc6845_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6845_device(mconfig, MC6845_1, tag, owner, clock) { } -hd6845s_device::hd6845s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +hd6845s_device::hd6845s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : mc6845_device(mconfig, type, tag, owner, clock) { } -hd6845s_device::hd6845s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd6845s_device::hd6845s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6845_device(mconfig, HD6845S, tag, owner, clock) { } -c6545_1_device::c6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +c6545_1_device::c6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6845_device(mconfig, C6545_1, tag, owner, clock) { } -sy6545_1_device::sy6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sy6545_1_device::sy6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6845_device(mconfig, SY6545_1, tag, owner, clock) { } -sy6845e_device::sy6845e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sy6845e_device::sy6845e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6845_device(mconfig, SY6845E, tag, owner, clock) { } -hd6345_device::hd6345_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +hd6345_device::hd6345_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : hd6845s_device(mconfig, HD6345, tag, owner, clock) { } -ams40489_device::ams40489_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ams40489_device::ams40489_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6845_device(mconfig, AMS40489, tag, owner, clock) { } -mos8563_device::mos8563_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mos8563_device::mos8563_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : mc6845_device(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , device_palette_interface(mconfig, *this) @@ -1688,13 +1688,13 @@ mos8563_device::mos8563_device(const machine_config &mconfig, device_type type, } -mos8563_device::mos8563_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8563_device::mos8563_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos8563_device(mconfig, MOS8563, tag, owner, clock) { } -mos8568_device::mos8568_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8568_device::mos8568_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos8563_device(mconfig, MOS8568, tag, owner, clock) { } diff --git a/src/devices/video/mc6845.h b/src/devices/video/mc6845.h index 1208c057bb6..4ba6cee34b6 100644 --- a/src/devices/video/mc6845.h +++ b/src/devices/video/mc6845.h @@ -60,7 +60,7 @@ public: typedef device_delegate<void (int address, int strobe)> on_update_addr_changed_delegate; // construction/destruction - mc6845_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6845_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_show_border_area(bool show) { m_show_border_area = show; } void set_visarea_adjust(int min_x, int max_x, int min_y, int max_y) @@ -126,7 +126,7 @@ public: uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); protected: - mc6845_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mc6845_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -295,7 +295,7 @@ protected: class mc6845_1_device : public mc6845_device { public: - mc6845_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6845_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -305,7 +305,7 @@ protected: class r6545_1_device : public mc6845_device { public: - r6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + r6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -315,7 +315,7 @@ protected: class c6545_1_device : public mc6845_device { public: - c6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + c6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -325,10 +325,10 @@ protected: class hd6845s_device : public mc6845_device { public: - hd6845s_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd6845s_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - hd6845s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + hd6845s_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; @@ -338,7 +338,7 @@ protected: class sy6545_1_device : public mc6845_device { public: - sy6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sy6545_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -348,7 +348,7 @@ protected: class sy6845e_device : public mc6845_device { public: - sy6845e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sy6845e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -358,7 +358,7 @@ protected: class hd6345_device : public hd6845s_device { public: - hd6345_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + hd6345_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void address_w(uint8_t data); uint8_t register_r(); @@ -393,7 +393,7 @@ protected: class ams40489_device : public mc6845_device { public: - ams40489_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ams40489_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; @@ -405,7 +405,7 @@ class mos8563_device : public mc6845_device, public device_palette_interface { public: - mos8563_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8563_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void address_w(uint8_t data); uint8_t status_r(); @@ -418,7 +418,7 @@ public: MC6845_UPDATE_ROW( vdc_update_row ); protected: - mos8563_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mos8563_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -470,7 +470,7 @@ protected: class mos8568_device : public mos8563_device { public: - mos8568_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8568_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/video/mc6847.cpp b/src/devices/video/mc6847.cpp index da0b80a5d61..df3b56248b6 100644 --- a/src/devices/video/mc6847.cpp +++ b/src/devices/video/mc6847.cpp @@ -129,7 +129,7 @@ const uint32_t mc6847_base_device::s_palette[mc6847_base_device::PALETTE_LENGTH] // ctor //------------------------------------------------- -mc6847_friend_device::mc6847_friend_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, +mc6847_friend_device::mc6847_friend_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const uint8_t *fontdata, bool is_mc6847t1, double tpfs, int field_sync_falling_edge_scanline, int divider, bool supports_partial_body_scanlines) : device_t(mconfig, type, tag, owner, clock) , device_video_interface(mconfig, *this) @@ -518,7 +518,7 @@ std::string mc6847_friend_device::describe_context() const // ctor //------------------------------------------------- -mc6847_base_device::mc6847_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const uint8_t *fontdata, double tpfs) : +mc6847_base_device::mc6847_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const uint8_t *fontdata, double tpfs) : mc6847_friend_device(mconfig, type, tag, owner, clock, fontdata, (type == MC6847T1_NTSC) || (type == MC6847T1_PAL), tpfs, 25+191, 1, true), m_input_cb(*this), m_black_and_white(false), @@ -1615,7 +1615,7 @@ DEFINE_DEVICE_TYPE(M5C6847P1, m5c6847p1_device, "m5c6847p1", "Mitsub // mc6847_ntsc_device //------------------------------------------------- -mc6847_ntsc_device::mc6847_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6847_ntsc_device::mc6847_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6847_base_device(mconfig, MC6847_NTSC, tag, owner, clock, vdg_fontdata8x12, 262.0) { } @@ -1626,7 +1626,7 @@ mc6847_ntsc_device::mc6847_ntsc_device(const machine_config &mconfig, const char // mc6847_pal_device //------------------------------------------------- -mc6847_pal_device::mc6847_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6847_pal_device::mc6847_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6847_base_device(mconfig, MC6847_PAL, tag, owner, clock, vdg_fontdata8x12, 313.0) { m_artifacter.set_pal_artifacting(true); @@ -1638,7 +1638,7 @@ mc6847_pal_device::mc6847_pal_device(const machine_config &mconfig, const char * // mc6847y_ntsc_device //------------------------------------------------- -mc6847y_ntsc_device::mc6847y_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6847y_ntsc_device::mc6847y_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6847_base_device(mconfig, MC6847Y_NTSC, tag, owner, clock, vdg_fontdata8x12, 262.5) { } @@ -1649,7 +1649,7 @@ mc6847y_ntsc_device::mc6847y_ntsc_device(const machine_config &mconfig, const ch // mc6847y_pal_device //------------------------------------------------- -mc6847y_pal_device::mc6847y_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6847y_pal_device::mc6847y_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6847_base_device(mconfig, MC6847Y_PAL, tag, owner, clock, vdg_fontdata8x12, 313.0) { m_artifacter.set_pal_artifacting(true); @@ -1661,7 +1661,7 @@ mc6847y_pal_device::mc6847y_pal_device(const machine_config &mconfig, const char // mc6847t1_ntsc_device //------------------------------------------------- -mc6847t1_ntsc_device::mc6847t1_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6847t1_ntsc_device::mc6847t1_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6847_base_device(mconfig, MC6847T1_NTSC, tag, owner, clock, vdg_t1_fontdata8x12, 262.0) { } @@ -1672,7 +1672,7 @@ mc6847t1_ntsc_device::mc6847t1_ntsc_device(const machine_config &mconfig, const // mc6847t1_pal_device //------------------------------------------------- -mc6847t1_pal_device::mc6847t1_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mc6847t1_pal_device::mc6847t1_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6847_base_device(mconfig, MC6847T1_PAL, tag, owner, clock, vdg_t1_fontdata8x12, 313.0) { m_artifacter.set_pal_artifacting(true); @@ -1684,7 +1684,7 @@ mc6847t1_pal_device::mc6847t1_pal_device(const machine_config &mconfig, const ch // s68047_device //------------------------------------------------- -s68047_device::s68047_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s68047_device::s68047_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6847_base_device(mconfig, S68047, tag, owner, clock, s68047_fontdata8x12, 262.0) { } @@ -1733,7 +1733,7 @@ const uint32_t s68047_device::s_s68047_hack_palette[16] = // m5c6847p1_device //------------------------------------------------- -m5c6847p1_device::m5c6847p1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +m5c6847p1_device::m5c6847p1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mc6847_base_device(mconfig, M5C6847P1, tag, owner, clock, vdg_fontdata8x12, 262.5) { } diff --git a/src/devices/video/mc6847.h b/src/devices/video/mc6847.h index d58f19fcd23..bab59e9271e 100644 --- a/src/devices/video/mc6847.h +++ b/src/devices/video/mc6847.h @@ -57,7 +57,7 @@ public: template <typename... T> void set_get_char_rom(T &&... args) { m_charrom_cb.set(std::forward<T>(args)...); } protected: - mc6847_friend_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, + mc6847_friend_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const uint8_t *fontdata, bool is_mc6847t1, double tpfs, int field_sync_falling_edge_scanline, int divider, bool supports_partial_body_scanlines); // fonts @@ -522,7 +522,7 @@ public: DECLARE_WRITE_LINE_MEMBER( inv_w ) { change_mode(MODE_INV, state); } protected: - mc6847_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, const uint8_t *fontdata, double tpfs); + mc6847_base_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, const uint8_t *fontdata, double tpfs); // device-level overrides virtual void device_config_complete() override; @@ -626,43 +626,43 @@ private: class mc6847_ntsc_device : public mc6847_base_device { public: - mc6847_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6847_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mc6847_pal_device : public mc6847_base_device { public: - mc6847_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6847_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mc6847y_ntsc_device : public mc6847_base_device { public: - mc6847y_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6847y_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mc6847y_pal_device : public mc6847_base_device { public: - mc6847y_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6847y_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mc6847t1_ntsc_device : public mc6847_base_device { public: - mc6847t1_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6847t1_ntsc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mc6847t1_pal_device : public mc6847_base_device { public: - mc6847t1_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mc6847t1_pal_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class s68047_device : public mc6847_base_device { public: - s68047_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s68047_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void hack_black_becomes_blue(bool flag); @@ -673,7 +673,7 @@ private: class m5c6847p1_device : public mc6847_base_device { public: - m5c6847p1_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + m5c6847p1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/video/md4330b.cpp b/src/devices/video/md4330b.cpp index f8f9ca2323a..a8f11a26174 100644 --- a/src/devices/video/md4330b.cpp +++ b/src/devices/video/md4330b.cpp @@ -23,16 +23,16 @@ DEFINE_DEVICE_TYPE(MD4332B, md4332b_device, "md4332b", "Mitel MD4332B LCD Driver // constructor //------------------------------------------------- -md4330b_device::md4330b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 qmax) : +md4330b_device::md4330b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 qmax) : device_t(mconfig, type, tag, owner, clock), m_qmax(qmax), m_write_q(*this), m_write_do(*this) { } -md4330b_device::md4330b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +md4330b_device::md4330b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md4330b_device(mconfig, MD4330B, tag, owner, clock, 30) { } -md4332b_device::md4332b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +md4332b_device::md4332b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : md4330b_device(mconfig, MD4332B, tag, owner, clock, 32) { } diff --git a/src/devices/video/md4330b.h b/src/devices/video/md4330b.h index 906c032424a..d87f417b7f0 100644 --- a/src/devices/video/md4330b.h +++ b/src/devices/video/md4330b.h @@ -42,7 +42,7 @@ class md4330b_device : public device_t { public: - md4330b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + md4330b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers auto write_q() { return m_write_q.bind(); } @@ -55,7 +55,7 @@ public: DECLARE_READ_LINE_MEMBER(do_r) { return m_do; } protected: - md4330b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 qmax); + md4330b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 qmax); // device-level overrides virtual void device_start() override; @@ -81,7 +81,7 @@ protected: class md4332b_device : public md4330b_device { public: - md4332b_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + md4332b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; diff --git a/src/devices/video/mga2064w.cpp b/src/devices/video/mga2064w.cpp index 6654aa9ec2e..1ec67829fbc 100644 --- a/src/devices/video/mga2064w.cpp +++ b/src/devices/video/mga2064w.cpp @@ -5,7 +5,7 @@ DEFINE_DEVICE_TYPE(MGA2064W, mga2064w_device, "mga2064w", "Matrox Millennium") -mga2064w_device::mga2064w_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mga2064w_device::mga2064w_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, MGA2064W, tag, owner, clock) { set_ids(0x102b0519, 0x01, 0x030000, 0x00000000); diff --git a/src/devices/video/mga2064w.h b/src/devices/video/mga2064w.h index 6766bf304a9..33c52b998f1 100644 --- a/src/devices/video/mga2064w.h +++ b/src/devices/video/mga2064w.h @@ -9,7 +9,7 @@ class mga2064w_device : public pci_device { public: - mga2064w_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mga2064w_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/video/mm5445.cpp b/src/devices/video/mm5445.cpp index 6b857ed19b3..b52b6ba5bff 100644 --- a/src/devices/video/mm5445.cpp +++ b/src/devices/video/mm5445.cpp @@ -22,25 +22,25 @@ DEFINE_DEVICE_TYPE(MM5448, mm5448_device, "mm5448", "MM5448 VFD Driver") // constructor //------------------------------------------------- -mm5445_device::mm5445_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 outpins) : +mm5445_device::mm5445_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 outpins) : device_t(mconfig, type, tag, owner, clock), m_outmask((u64(1) << outpins) - 1), m_write_output(*this) { } -mm5445_device::mm5445_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm5445_device::mm5445_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm5445_device(mconfig, MM5445, tag, owner, clock, 33) { } -mm5446_device::mm5446_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm5446_device::mm5446_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm5445_device(mconfig, MM5446, tag, owner, clock, 34) { } -mm5447_device::mm5447_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm5447_device::mm5447_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm5445_device(mconfig, MM5447, tag, owner, clock, 34) { } -mm5448_device::mm5448_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +mm5448_device::mm5448_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mm5445_device(mconfig, MM5448, tag, owner, clock, 35) { } diff --git a/src/devices/video/mm5445.h b/src/devices/video/mm5445.h index 7d16d4f2ee2..d4a5e373bb3 100644 --- a/src/devices/video/mm5445.h +++ b/src/devices/video/mm5445.h @@ -45,7 +45,7 @@ class mm5445_device : public device_t { public: - mm5445_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + mm5445_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers auto output_cb() { return m_write_output.bind(); } @@ -55,7 +55,7 @@ public: DECLARE_WRITE_LINE_MEMBER(data_w) { m_data = (state) ? 1 : 0; } protected: - mm5445_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 outpins); + mm5445_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 outpins); // device-level overrides virtual void device_start() override; @@ -77,19 +77,19 @@ protected: class mm5446_device : public mm5445_device { public: - mm5446_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm5446_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mm5447_device : public mm5445_device { public: - mm5447_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm5447_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class mm5448_device : public mm5445_device { public: - mm5448_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + mm5448_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/video/mos6566.cpp b/src/devices/video/mos6566.cpp index 80d8a7c01b6..3b6d37788f2 100644 --- a/src/devices/video/mos6566.cpp +++ b/src/devices/video/mos6566.cpp @@ -559,12 +559,12 @@ inline void mos6566_device::draw_multi( uint16_t p, uint8_t c0, uint8_t c1, uint // mos6566_device - constructor //------------------------------------------------- -mos6566_device::mos6566_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6566_device::mos6566_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6566_device(mconfig, MOS6566, tag, owner, clock, TYPE_6566) { } -mos6566_device::mos6566_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +mos6566_device::mos6566_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : device_t(mconfig, type, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), @@ -584,42 +584,42 @@ mos6566_device::mos6566_device(const machine_config &mconfig, device_type type, { } -mos6567_device::mos6567_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6567_device::mos6567_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6567_device(mconfig, MOS6567, tag, owner, clock, TYPE_6567) { } -mos6567_device::mos6567_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +mos6567_device::mos6567_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : mos6566_device(mconfig, type, tag, owner, clock, variant) { } -mos8562_device::mos8562_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8562_device::mos8562_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6567_device(mconfig, MOS8562, tag, owner, clock, TYPE_8562) { } -mos8564_device::mos8564_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8564_device::mos8564_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6567_device(mconfig, MOS8564, tag, owner, clock, TYPE_8564) { } -mos6569_device::mos6569_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos6569_device::mos6569_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6569_device(mconfig, MOS6569, tag, owner, clock, TYPE_6569) { } -mos6569_device::mos6569_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant) +mos6569_device::mos6569_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant) : mos6566_device(mconfig, type, tag, owner, clock, variant) { } -mos8565_device::mos8565_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8565_device::mos8565_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6569_device(mconfig, MOS8565, tag, owner, clock, TYPE_8565) { } -mos8566_device::mos8566_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mos8566_device::mos8566_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mos6569_device(mconfig, MOS8566, tag, owner, clock, TYPE_8566) { } @@ -2741,7 +2741,7 @@ void mos6566_device::write(offs_t offset, uint8_t data) { if (BIT(m_reg[offset], 0) != BIT(data, 0)) { - m_cpu->set_unscaled_clock(clock() << BIT(data, 0)); + m_cpu->set_unscaled_clock(clock() * (BIT(data, 0) ? 2 : 1)); } m_reg[offset] = data | 0xfc; diff --git a/src/devices/video/mos6566.h b/src/devices/video/mos6566.h index a7147295196..0e64aada3de 100644 --- a/src/devices/video/mos6566.h +++ b/src/devices/video/mos6566.h @@ -189,7 +189,7 @@ class mos6566_device : public device_t, { public: // construction/destruction - mos6566_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6566_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <class T> void set_cpu(T &&tag) { m_cpu.set_tag(tag); } auto irq_callback() { return m_write_irq.bind(); } @@ -228,7 +228,7 @@ protected: TYPE_8569 // PAL-N VIC-IIe (C128) }; - mos6566_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + mos6566_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void device_start() override; @@ -356,10 +356,10 @@ class mos6567_device : public mos6566_device { public: // construction/destruction - mos6567_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6567_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - mos6567_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + mos6567_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); }; @@ -369,7 +369,7 @@ class mos8562_device : public mos6567_device { public: // construction/destruction - mos8562_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8562_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -379,7 +379,7 @@ class mos8564_device : public mos6567_device { public: // construction/destruction - mos8564_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8564_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides @@ -394,10 +394,10 @@ class mos6569_device : public mos6566_device { public: // construction/destruction - mos6569_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos6569_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: - mos6569_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t variant); + mos6569_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t variant); // device-level overrides virtual void execute_run() override; @@ -410,7 +410,7 @@ class mos8565_device : public mos6569_device { public: // construction/destruction - mos8565_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8565_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; @@ -420,7 +420,7 @@ class mos8566_device : public mos6569_device { public: // construction/destruction - mos8566_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mos8566_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device_execute_interface overrides diff --git a/src/devices/video/msm6222b.cpp b/src/devices/video/msm6222b.cpp index ebcbfea24fe..dcd84569f7b 100644 --- a/src/devices/video/msm6222b.cpp +++ b/src/devices/video/msm6222b.cpp @@ -21,20 +21,20 @@ ROM_START( msm6222b_01 ) ROM_LOAD( "msm6222b-01.bin", 0x0000, 0x1000, CRC(8ffa8521) SHA1(e108b520e6d20459a7bbd5958bbfa1d551a690bd) ) ROM_END -msm6222b_device::msm6222b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +msm6222b_device::msm6222b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_cgrom(*this, finder_base::DUMMY_TAG), cursor_direction(false), cursor_blinking(false), two_line(false), shift_on_write(false), double_height(false), cursor_on(false), display_on(false), adc(0), shift(0) { } -msm6222b_device::msm6222b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +msm6222b_device::msm6222b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msm6222b_device(mconfig, MSM6222B, tag, owner, clock) { m_cgrom.set_tag(*this, DEVICE_SELF); } -msm6222b_01_device::msm6222b_01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +msm6222b_01_device::msm6222b_01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : msm6222b_device(mconfig, MSM6222B_01, tag, owner, clock) { // load the fixed cgrom diff --git a/src/devices/video/msm6222b.h b/src/devices/video/msm6222b.h index 7a2cb00fd89..da5c6321b80 100644 --- a/src/devices/video/msm6222b.h +++ b/src/devices/video/msm6222b.h @@ -18,7 +18,7 @@ class msm6222b_device : public device_t { public: - msm6222b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msm6222b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void control_w(uint8_t data); uint8_t control_r(); @@ -29,7 +29,7 @@ public: const uint8_t *render(); protected: - msm6222b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + msm6222b_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -49,7 +49,7 @@ private: class msm6222b_01_device : public msm6222b_device { public: - msm6222b_01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msm6222b_01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/video/msm6255.cpp b/src/devices/video/msm6255.cpp index de34d079cde..664ef16242a 100644 --- a/src/devices/video/msm6255.cpp +++ b/src/devices/video/msm6255.cpp @@ -77,7 +77,7 @@ void msm6255_device::msm6255(address_map &map) // msm6255_device - constructor //------------------------------------------------- -msm6255_device::msm6255_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +msm6255_device::msm6255_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, MSM6255, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/video/msm6255.h b/src/devices/video/msm6255.h index 8e821c7668e..85344705cb1 100644 --- a/src/devices/video/msm6255.h +++ b/src/devices/video/msm6255.h @@ -25,7 +25,7 @@ class msm6255_device : public device_t, { public: // construction/destruction - msm6255_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + msm6255_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void map(address_map &map); diff --git a/src/devices/video/nereid.cpp b/src/devices/video/nereid.cpp index 47a4c28371b..50d375d8a44 100644 --- a/src/devices/video/nereid.cpp +++ b/src/devices/video/nereid.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(NEREID, nereid_device, "nereid", "HP Nereid ASIC") -nereid_device::nereid_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +nereid_device::nereid_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), device_palette_interface(mconfig, *this), m_red(0), @@ -20,7 +20,7 @@ nereid_device::nereid_device(const machine_config &mconfig, device_type type, co { } -nereid_device::nereid_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +nereid_device::nereid_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nereid_device(mconfig, NEREID, tag, owner, clock) { } diff --git a/src/devices/video/nereid.h b/src/devices/video/nereid.h index 18717de2b22..fa3a6ee1e5c 100644 --- a/src/devices/video/nereid.h +++ b/src/devices/video/nereid.h @@ -8,7 +8,7 @@ class nereid_device : public device_t, public device_palette_interface { public: - nereid_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + nereid_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t ctrl_r(offs_t offset, uint16_t mem_mask = ~0); void ctrl_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0); @@ -16,7 +16,7 @@ public: rgb_t map_color(uint8_t input, uint8_t ovl = 0); protected: - nereid_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nereid_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; virtual u32 palette_entries() const noexcept override { return 0x200; } diff --git a/src/devices/video/nt7534.cpp b/src/devices/video/nt7534.cpp index e1065376860..bb8eb2cf06a 100644 --- a/src/devices/video/nt7534.cpp +++ b/src/devices/video/nt7534.cpp @@ -27,12 +27,12 @@ DEFINE_DEVICE_TYPE(NT7534, nt7534_device, "nt7534", "NT7534 LCD Controller // nt7534_device - constructor //------------------------------------------------- -nt7534_device::nt7534_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +nt7534_device::nt7534_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : nt7534_device(mconfig, NT7534, tag, owner, clock) { } -nt7534_device::nt7534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +nt7534_device::nt7534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_pixel_update_cb(*this) { diff --git a/src/devices/video/nt7534.h b/src/devices/video/nt7534.h index 126d5dfff92..48ed4cc5309 100644 --- a/src/devices/video/nt7534.h +++ b/src/devices/video/nt7534.h @@ -27,7 +27,7 @@ public: typedef device_delegate<void (bitmap_ind16 &bitmap, uint8_t line, uint8_t pos, uint8_t y, uint8_t x, int state)> pixel_update_delegate; // construction/destruction - nt7534_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + nt7534_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); template <typename... T> void set_pixel_update_cb(T &&... args) { m_pixel_update_cb.set(std::forward<T>(args)...); } @@ -43,7 +43,7 @@ public: virtual uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); protected: - nt7534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + nt7534_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; diff --git a/src/devices/video/pc_vga.cpp b/src/devices/video/pc_vga.cpp index 35c2f6e5d0b..87ac6bfd88b 100644 --- a/src/devices/video/pc_vga.cpp +++ b/src/devices/video/pc_vga.cpp @@ -132,7 +132,7 @@ DEFINE_DEVICE_TYPE(MACH8, mach8_device, "mach8", "Mach8") DEFINE_DEVICE_TYPE(XGA_COPRO, xga_copro_device, "xga_copro", "IBM XGA Coprocessor") DEFINE_DEVICE_TYPE(OTI111, oak_oti111_vga_device, "oti111_vga", "Oak Technologies Spitfire 64111") -vga_device::vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +vga_device::vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_video_interface(mconfig, *this) , device_palette_interface(mconfig, *this) @@ -140,63 +140,63 @@ vga_device::vga_device(const machine_config &mconfig, device_type type, const ch { } -vga_device::vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vga_device::vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : vga_device(mconfig, VGA, tag, owner, clock) { } -svga_device::svga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +svga_device::svga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : vga_device(mconfig, type, tag, owner, clock) { } -tseng_vga_device::tseng_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tseng_vga_device::tseng_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : svga_device(mconfig, TSENG_VGA, tag, owner, clock) { } -s3_vga_device::s3_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +s3_vga_device::s3_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : s3_vga_device(mconfig, S3_VGA, tag, owner, clock) { } -s3_vga_device::s3_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +s3_vga_device::s3_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ati_vga_device(mconfig, type, tag, owner, clock) { } -gamtor_vga_device::gamtor_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +gamtor_vga_device::gamtor_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : svga_device(mconfig, GAMTOR_VGA, tag, owner, clock) { } -ati_vga_device::ati_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ati_vga_device::ati_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ati_vga_device(mconfig, ATI_VGA, tag, owner, clock) { } -ati_vga_device::ati_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ati_vga_device::ati_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : svga_device(mconfig, type, tag, owner, clock) { } -ibm8514a_device::ibm8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ibm8514a_device::ibm8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : ibm8514a_device(mconfig, IBM8514A, tag, owner, clock) { } -ibm8514a_device::ibm8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +ibm8514a_device::ibm8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , m_vga(*this, finder_base::DUMMY_TAG) { } -mach8_device::mach8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +mach8_device::mach8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : ibm8514a_device(mconfig, type, tag, owner, clock) { } -mach8_device::mach8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +mach8_device::mach8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : mach8_device(mconfig, MACH8, tag, owner, clock) { } @@ -2170,13 +2170,13 @@ void vga_device::mem_linear_w(offs_t offset, uint8_t data) void ati_vga_device::device_add_mconfig(machine_config &config) { - MACH8(config, "8514a", 0).set_vga_owner(); + MACH8(config, "8514a").set_vga_owner(); EEPROM_93C46_16BIT(config, "ati_eeprom"); } void s3_vga_device::device_add_mconfig(machine_config &config) { - IBM8514A(config, "8514a", 0).set_vga_owner(); + IBM8514A(config, "8514a").set_vga_owner(); } /****************************************** @@ -5845,7 +5845,7 @@ void mach8_device::mach8_ge_ext_config_w(uint16_t data) popmessage("EEPROM enabled via 7AEE"); } -xga_copro_device::xga_copro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +xga_copro_device::xga_copro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, XGA_COPRO, tag, owner, clock) , m_var(TYPE::XGA) , m_mem_read_cb(*this) @@ -6593,7 +6593,7 @@ void xga_copro_device::device_reset() m_pelmap = 0; } -oak_oti111_vga_device::oak_oti111_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +oak_oti111_vga_device::oak_oti111_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : svga_device(mconfig, OTI111, tag, owner, clock) , m_xga(*this, "xga") { @@ -6601,7 +6601,7 @@ oak_oti111_vga_device::oak_oti111_vga_device(const machine_config &mconfig, cons void oak_oti111_vga_device::device_add_mconfig(machine_config &config) { - XGA_COPRO(config, m_xga, 0); + XGA_COPRO(config, m_xga); m_xga->mem_read_callback().set(FUNC(oak_oti111_vga_device::mem_linear_r)); m_xga->mem_write_callback().set(FUNC(oak_oti111_vga_device::mem_linear_w)); m_xga->set_type(xga_copro_device::TYPE::OTI111); diff --git a/src/devices/video/pc_vga.h b/src/devices/video/pc_vga.h index a12ef1c477c..6255498f8e4 100644 --- a/src/devices/video/pc_vga.h +++ b/src/devices/video/pc_vga.h @@ -21,7 +21,7 @@ class vga_device : public device_t, public device_video_interface, public device public: // construction/destruction - vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual void zero(); virtual uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); @@ -57,7 +57,7 @@ protected: RGB32_MODE }; - vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -255,7 +255,7 @@ public: protected: // construction/destruction - svga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + svga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void svga_vh_rgb8(bitmap_rgb32 &bitmap, const rectangle &cliprect); void svga_vh_rgb15(bitmap_rgb32 &bitmap, const rectangle &cliprect); @@ -281,7 +281,7 @@ protected: class ibm8514a_device : public device_t { public: - ibm8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ibm8514a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_vga(T &&tag) { m_vga.set_tag(std::forward<T>(tag)); } void set_vga_owner() { m_vga.set_tag(DEVICE_SELF); } @@ -397,7 +397,7 @@ public: } ibm8514; protected: - ibm8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ibm8514a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; void ibm8514_write(uint32_t offset, uint32_t src); @@ -423,7 +423,7 @@ DECLARE_DEVICE_TYPE(IBM8514A, ibm8514a_device) class mach8_device : public ibm8514a_device { public: - mach8_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + mach8_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint16_t mach8_ec0_r(); void mach8_ec0_w(uint16_t data); @@ -467,7 +467,7 @@ public: uint16_t offset() { if(mach8.ati_mode) return mach8.ge_pitch; else return 128; } protected: - mach8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + mach8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; struct { @@ -499,7 +499,7 @@ class tseng_vga_device : public svga_device { public: // construction/destruction - tseng_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tseng_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t port_03b0_r(offs_t offset) override; virtual void port_03b0_w(offs_t offset, uint8_t data) override; @@ -546,7 +546,7 @@ class ati_vga_device : public svga_device { public: // construction/destruction - ati_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ati_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t mem_r(offs_t offset) override; virtual void mem_w(offs_t offset, uint8_t data) override; @@ -560,7 +560,7 @@ public: mach8_device* get_8514() { return m_8514; } protected: - ati_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ati_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_add_mconfig(machine_config &config) override; @@ -587,7 +587,7 @@ class s3_vga_device : public ati_vga_device { public: // construction/destruction - s3_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + s3_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t port_03b0_r(offs_t offset) override; virtual void port_03b0_w(offs_t offset, uint8_t data) override; @@ -605,7 +605,7 @@ public: ibm8514a_device* get_8514() { return m_8514; } protected: - s3_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + s3_vga_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -679,7 +679,7 @@ class gamtor_vga_device : public svga_device { public: // construction/destruction - gamtor_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + gamtor_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t port_03b0_r(offs_t offset) override; @@ -704,7 +704,7 @@ public: OTI111 }; - xga_copro_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + xga_copro_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 xga_read(offs_t offset); void xga_write(offs_t offset, u8 data); @@ -760,7 +760,7 @@ DECLARE_DEVICE_TYPE(XGA_COPRO, xga_copro_device) class oak_oti111_vga_device : public svga_device { public: - oak_oti111_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + oak_oti111_vga_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); u8 xga_read(offs_t offset); void xga_write(offs_t offset, u8 data); diff --git a/src/devices/video/pcd8544.cpp b/src/devices/video/pcd8544.cpp index b0592592509..87f2254dd5a 100644 --- a/src/devices/video/pcd8544.cpp +++ b/src/devices/video/pcd8544.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(PCD8544, pcd8544_device, "pcd8544_device", "Philips PCD8544 L // pcd8544_device - constructor //------------------------------------------------- -pcd8544_device::pcd8544_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +pcd8544_device::pcd8544_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PCD8544, tag, owner, clock), m_screen_update_cb(*this) { diff --git a/src/devices/video/pcd8544.h b/src/devices/video/pcd8544.h index 6706097a4db..81a7e49cbf7 100644 --- a/src/devices/video/pcd8544.h +++ b/src/devices/video/pcd8544.h @@ -27,7 +27,7 @@ public: typedef device_delegate<void (device_t &device, bitmap_ind16 &bitmap, const rectangle &cliprect , uint8_t *vram, int inv)> screen_update_delegate; // construction/destruction - pcd8544_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + pcd8544_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename... T> void set_screen_update_cb(T &&... args) { m_screen_update_cb.set(std::forward<T>(args)...); } // device interface diff --git a/src/devices/video/pcf2100.cpp b/src/devices/video/pcf2100.cpp index ae686b98b1a..f70c12ebe7f 100644 --- a/src/devices/video/pcf2100.cpp +++ b/src/devices/video/pcf2100.cpp @@ -27,24 +27,24 @@ DEFINE_DEVICE_TYPE(PCF2112, pcf2112_device, "pcf2112", "Philips PCF2112 LCD Driv // constructor //------------------------------------------------- -pcf2100_device::pcf2100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 bpmax, u8 smax) : +pcf2100_device::pcf2100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 bpmax, u8 smax) : device_t(mconfig, type, tag, owner, clock), m_bpmax(bpmax), m_smax(smax), m_write_segs(*this) { } -pcf2100_device::pcf2100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pcf2100_device::pcf2100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pcf2100_device(mconfig, PCF2100, tag, owner, clock, 2, 20) { } -pcf2110_device::pcf2110_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pcf2110_device::pcf2110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pcf2100_device(mconfig, PCF2110, tag, owner, clock, 2, 32) { } -pcf2111_device::pcf2111_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pcf2111_device::pcf2111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pcf2100_device(mconfig, PCF2111, tag, owner, clock, 2, 32) { } -pcf2112_device::pcf2112_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pcf2112_device::pcf2112_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : pcf2100_device(mconfig, PCF2112, tag, owner, clock, 1, 32) { } diff --git a/src/devices/video/pcf2100.h b/src/devices/video/pcf2100.h index 1d0963b2896..f5372592923 100644 --- a/src/devices/video/pcf2100.h +++ b/src/devices/video/pcf2100.h @@ -33,7 +33,7 @@ BP1/BP2: backplane drivers (LCD commons) class pcf2100_device : public device_t { public: - pcf2100_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pcf2100_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto write_segs() { return m_write_segs.bind(); } @@ -43,7 +43,7 @@ public: DECLARE_WRITE_LINE_MEMBER(dlen_w) { m_dlen = (state) ? 1 : 0; } protected: - pcf2100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 bpmax, u8 smax); + pcf2100_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 bpmax, u8 smax); // device-level overrides virtual void device_start() override; @@ -71,19 +71,19 @@ protected: class pcf2110_device : public pcf2100_device { public: - pcf2110_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pcf2110_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class pcf2111_device : public pcf2100_device { public: - pcf2111_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pcf2111_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class pcf2112_device : public pcf2100_device { public: - pcf2112_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + pcf2112_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/video/ppu2c0x.cpp b/src/devices/video/ppu2c0x.cpp index d8f3ca4748b..c9fcccd0d11 100644 --- a/src/devices/video/ppu2c0x.cpp +++ b/src/devices/video/ppu2c0x.cpp @@ -85,7 +85,7 @@ void ppu2c0x_device::device_config_complete() m_latch.set(nullptr); } -ppu2c0x_device::ppu2c0x_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock, address_map_constructor internal_map) : +ppu2c0x_device::ppu2c0x_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock, address_map_constructor internal_map) : device_t(mconfig, type, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), @@ -127,45 +127,45 @@ ppu2c0x_device::ppu2c0x_device(const machine_config& mconfig, device_type type, m_security_value = 0; } -ppu2c0x_device::ppu2c0x_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock) : +ppu2c0x_device::ppu2c0x_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(ppu2c0x_device::ppu2c0x), this)) { m_paletteram_in_ppuspace = true; } -ppu2c0x_rgb_device::ppu2c0x_rgb_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock) : +ppu2c0x_rgb_device::ppu2c0x_rgb_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_device(mconfig, type, tag, owner, clock), m_palette_data(*this, "palette") { } // NTSC NES -ppu2c02_device::ppu2c02_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu2c02_device::ppu2c02_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_device(mconfig, PPU_2C02, tag, owner, clock) { } // Playchoice 10 -ppu2c03b_device::ppu2c03b_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu2c03b_device::ppu2c03b_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_rgb_device(mconfig, PPU_2C03B, tag, owner, clock) { } // Vs. Unisystem -ppu2c04_device::ppu2c04_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu2c04_device::ppu2c04_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_rgb_device(mconfig, PPU_2C04, tag, owner, clock) { } // PAL NES -ppu2c07_device::ppu2c07_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu2c07_device::ppu2c07_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_device(mconfig, PPU_2C07, tag, owner, clock) { m_scanlines_per_frame = PAL_SCANLINES_PER_FRAME; } // PAL clones -ppupalc_device::ppupalc_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppupalc_device::ppupalc_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_device(mconfig, PPU_PALC, tag, owner, clock) { m_scanlines_per_frame = PAL_SCANLINES_PER_FRAME; @@ -174,32 +174,32 @@ ppupalc_device::ppupalc_device(const machine_config& mconfig, const char* tag, d // The PPU_2C05 variants have different protection value, set at device start, but otherwise are all the same... // Vs. Unisystem (Ninja Jajamaru Kun) -ppu2c05_01_device::ppu2c05_01_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu2c05_01_device::ppu2c05_01_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_rgb_device(mconfig, PPU_2C05_01, tag, owner, clock) { m_security_value = 0x1b; // game (jajamaru) doesn't seem to ever actually check it } // Vs. Unisystem (Mighty Bomb Jack) -ppu2c05_02_device::ppu2c05_02_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu2c05_02_device::ppu2c05_02_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_rgb_device(mconfig, PPU_2C05_02, tag, owner, clock) { m_security_value = 0x3d; } // Vs. Unisystem (Gumshoe) -ppu2c05_03_device::ppu2c05_03_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu2c05_03_device::ppu2c05_03_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_rgb_device(mconfig, PPU_2C05_03, tag, owner, clock) { m_security_value = 0x1c; } // Vs. Unisystem (Top Gun) -ppu2c05_04_device::ppu2c05_04_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu2c05_04_device::ppu2c05_04_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_rgb_device(mconfig, PPU_2C05_04, tag, owner, clock) { m_security_value = 0x1b; } // Vs. Unisystem (Super Mario Bros. bootlegs) -ppu2c04_clone_device::ppu2c04_clone_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu2c04_clone_device::ppu2c04_clone_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_device(mconfig, PPU_2C04C, tag, owner, clock), m_palette_data(*this, "palette") { diff --git a/src/devices/video/ppu2c0x.h b/src/devices/video/ppu2c0x.h index 0be6231b97d..8488300aeed 100644 --- a/src/devices/video/ppu2c0x.h +++ b/src/devices/video/ppu2c0x.h @@ -136,7 +136,7 @@ public: bool in_vblanking() { return (m_scanline >= m_vblank_first_scanline - 1); } protected: - ppu2c0x_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock, address_map_constructor internal_map); + ppu2c0x_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock, address_map_constructor internal_map); // registers definition enum @@ -174,7 +174,7 @@ protected: }; // construction/destruction - ppu2c0x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c0x_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual void device_start() override; virtual void device_config_complete() override; @@ -250,7 +250,7 @@ private: class ppu2c0x_rgb_device : public ppu2c0x_device { protected: - ppu2c0x_rgb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c0x_rgb_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual void init_palette_tables() override; @@ -260,52 +260,52 @@ private: class ppu2c02_device : public ppu2c0x_device { public: - ppu2c02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ppu2c03b_device : public ppu2c0x_rgb_device { public: - ppu2c03b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c03b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ppu2c04_device : public ppu2c0x_rgb_device { public: - ppu2c04_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c04_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ppu2c07_device : public ppu2c0x_device { public: - ppu2c07_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c07_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ppupalc_device : public ppu2c0x_device { public: - ppupalc_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ppupalc_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ppu2c05_01_device : public ppu2c0x_rgb_device { public: - ppu2c05_01_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c05_01_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ppu2c05_02_device : public ppu2c0x_rgb_device { public: - ppu2c05_02_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c05_02_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ppu2c05_03_device : public ppu2c0x_rgb_device { public: - ppu2c05_03_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c05_03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ppu2c05_04_device : public ppu2c0x_rgb_device { public: - ppu2c05_04_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c05_04_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); }; class ppu2c04_clone_device : public ppu2c0x_device { public: - ppu2c04_clone_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + ppu2c04_clone_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual uint8_t read(offs_t offset) override; virtual void write(offs_t offset, uint8_t data) override; diff --git a/src/devices/video/ppu2c0x_sh6578.cpp b/src/devices/video/ppu2c0x_sh6578.cpp index a63fa2a5162..ab010dc7607 100644 --- a/src/devices/video/ppu2c0x_sh6578.cpp +++ b/src/devices/video/ppu2c0x_sh6578.cpp @@ -17,7 +17,7 @@ DEFINE_DEVICE_TYPE(PPU_SH6578, ppu_sh6578_device, "ppu_sh6578", "SH6578 PPU (NTSC)") DEFINE_DEVICE_TYPE(PPU_SH6578PAL, ppu_sh6578pal_device, "ppu_sh6578pal", "SH6578 PPU (PAL)") -ppu_sh6578_device::ppu_sh6578_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock) : +ppu_sh6578_device::ppu_sh6578_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_device(mconfig, type, tag, owner, clock, address_map_constructor(FUNC(ppu_sh6578_device::ppu_internal_map), this)) { m_paletteram_in_ppuspace = false; @@ -26,12 +26,12 @@ ppu_sh6578_device::ppu_sh6578_device(const machine_config& mconfig, device_type m_global_refresh_mask = 0xffff; } -ppu_sh6578_device::ppu_sh6578_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu_sh6578_device::ppu_sh6578_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu_sh6578_device(mconfig, PPU_SH6578, tag, owner, clock) { } -ppu_sh6578pal_device::ppu_sh6578pal_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu_sh6578pal_device::ppu_sh6578pal_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu_sh6578_device(mconfig, PPU_SH6578PAL, tag, owner, clock) { m_scanlines_per_frame = PAL_SCANLINES_PER_FRAME; diff --git a/src/devices/video/ppu2c0x_sh6578.h b/src/devices/video/ppu2c0x_sh6578.h index 34448ac9dfa..18f11b91244 100644 --- a/src/devices/video/ppu2c0x_sh6578.h +++ b/src/devices/video/ppu2c0x_sh6578.h @@ -14,7 +14,7 @@ class ppu_sh6578_device : public ppu2c0x_device { public: - ppu_sh6578_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ppu_sh6578_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual uint8_t palette_read(offs_t offset) override; virtual void palette_write(offs_t offset, uint8_t data) override; @@ -22,7 +22,7 @@ public: virtual uint8_t read_extended(offs_t offset); protected: - ppu_sh6578_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ppu_sh6578_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); void ppu_internal_map(address_map& map); @@ -48,7 +48,7 @@ private: class ppu_sh6578pal_device : public ppu_sh6578_device { public: - ppu_sh6578pal_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + ppu_sh6578pal_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(PPU_SH6578, ppu_sh6578_device) diff --git a/src/devices/video/ppu2c0x_vt.cpp b/src/devices/video/ppu2c0x_vt.cpp index 2b8b9b6e3dd..dd99c321431 100644 --- a/src/devices/video/ppu2c0x_vt.cpp +++ b/src/devices/video/ppu2c0x_vt.cpp @@ -20,7 +20,7 @@ DEFINE_DEVICE_TYPE(PPU_VT03, ppu_vt03_device, "ppu_vt03", "VT03 PPU (NTSC)") DEFINE_DEVICE_TYPE(PPU_VT03PAL, ppu_vt03pal_device, "ppu_vt03pal", "VT03 PPU (PAL)") -ppu_vt03_device::ppu_vt03_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, uint32_t clock) : +ppu_vt03_device::ppu_vt03_device(const machine_config& mconfig, device_type type, const char* tag, device_t* owner, const XTAL &clock) : ppu2c0x_device(mconfig, type, tag, owner, clock), m_is_pal(false), m_is_50hz(false), @@ -29,13 +29,13 @@ ppu_vt03_device::ppu_vt03_device(const machine_config& mconfig, device_type type { } -ppu_vt03_device::ppu_vt03_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu_vt03_device::ppu_vt03_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu_vt03_device(mconfig, PPU_VT03, tag, owner, clock) { } -ppu_vt03pal_device::ppu_vt03pal_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock) : +ppu_vt03pal_device::ppu_vt03pal_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock) : ppu_vt03_device(mconfig, PPU_VT03PAL, tag, owner, clock) { m_scanlines_per_frame = PAL_SCANLINES_PER_FRAME; diff --git a/src/devices/video/ppu2c0x_vt.h b/src/devices/video/ppu2c0x_vt.h index f63da1ebdf1..2a118328cf3 100644 --- a/src/devices/video/ppu2c0x_vt.h +++ b/src/devices/video/ppu2c0x_vt.h @@ -24,8 +24,8 @@ enum vtxx_pal_mode { class ppu_vt03_device : public ppu2c0x_device { public: - ppu_vt03_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - ppu_vt03_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + ppu_vt03_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); + ppu_vt03_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); auto read_bg() { return m_read_bg.bind(); } auto read_sp() { return m_read_sp.bind(); } @@ -96,7 +96,7 @@ private: class ppu_vt03pal_device : public ppu_vt03_device { public: - ppu_vt03pal_device(const machine_config& mconfig, const char* tag, device_t* owner, uint32_t clock); + ppu_vt03pal_device(const machine_config& mconfig, const char* tag, device_t* owner, const XTAL &clock); }; DECLARE_DEVICE_TYPE(PPU_VT03, ppu_vt03_device) diff --git a/src/devices/video/ps2gif.cpp b/src/devices/video/ps2gif.cpp index 4a8ea53db7a..1b5dc4f2fb4 100644 --- a/src/devices/video/ps2gif.cpp +++ b/src/devices/video/ps2gif.cpp @@ -14,7 +14,7 @@ DEFINE_DEVICE_TYPE(SONYPS2_GIF, ps2_gif_device, "ps2gif", "Playstation 2 GIF") -ps2_gif_device::ps2_gif_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ps2_gif_device::ps2_gif_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYPS2_GIF, tag, owner, clock) , device_execute_interface(mconfig, *this) , m_gs(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/video/ps2gif.h b/src/devices/video/ps2gif.h index 39f4f911e01..76762bd00f7 100644 --- a/src/devices/video/ps2gif.h +++ b/src/devices/video/ps2gif.h @@ -23,14 +23,14 @@ class ps2_gif_device : public device_t, public device_execute_interface { public: template <typename T, typename U> - ps2_gif_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&gs_tag, U &&vu1_tag) + ps2_gif_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&gs_tag, U &&vu1_tag) : ps2_gif_device(mconfig, tag, owner, clock) { m_gs.set_tag(std::forward<T>(gs_tag)); m_vu1.set_tag(std::forward<U>(vu1_tag)); } - ps2_gif_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ps2_gif_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~ps2_gif_device() override; uint32_t read(offs_t offset); diff --git a/src/devices/video/ps2gs.cpp b/src/devices/video/ps2gs.cpp index 1065ae0da60..c767609562a 100644 --- a/src/devices/video/ps2gs.cpp +++ b/src/devices/video/ps2gs.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(SONYPS2_GS, ps2_gs_device, "ps2gs", "Playstation 2 GS") 1, 2, 2, 3, 3, 3, 2, 1 }; -ps2_gs_device::ps2_gs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ps2_gs_device::ps2_gs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SONYPS2_GS, tag, owner, clock) , m_intc(*this, finder_base::DUMMY_TAG) , m_vu1(*this, finder_base::DUMMY_TAG) diff --git a/src/devices/video/ps2gs.h b/src/devices/video/ps2gs.h index f4ca034f688..057a572b94f 100644 --- a/src/devices/video/ps2gs.h +++ b/src/devices/video/ps2gs.h @@ -25,14 +25,14 @@ class ps2_gs_device : public device_t public: template <typename T, typename U> - ps2_gs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&intc_tag, U &&vu1_tag) + ps2_gs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&intc_tag, U &&vu1_tag) : ps2_gs_device(mconfig, tag, owner, clock) { m_intc.set_tag(std::forward<T>(intc_tag)); m_vu1.set_tag(std::forward<U>(vu1_tag)); } - ps2_gs_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ps2_gs_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); virtual ~ps2_gs_device() override; uint64_t priv_regs0_r(offs_t offset); diff --git a/src/devices/video/psx.cpp b/src/devices/video/psx.cpp index 448d384f1fe..73b4e8dadc1 100644 --- a/src/devices/video/psx.cpp +++ b/src/devices/video/psx.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(CXD8561BQ, cxd8561bq_device, "cxd8561bq", "CXD8561BQ GPU") // DEFINE_DEVICE_TYPE(CXD8561CQ, cxd8561cq_device, "cxd8561cq", "CXD8561CQ GPU") // SGRAM DEFINE_DEVICE_TYPE(CXD8654Q, cxd8654q_device, "cxd8654q", "CXD8654Q GPU") // SGRAM -psxgpu_device::psxgpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu) +psxgpu_device::psxgpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu) : psxgpu_device(mconfig, type, tag, owner, clock) { set_vram_size(vram_size); @@ -41,7 +41,7 @@ psxgpu_device::psxgpu_device(const machine_config &mconfig, device_type type, co vblank_callback().set(*cpu->subdevice<psxirq_device>("irq"), FUNC(psxirq_device::intin0)); } -psxgpu_device::psxgpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +psxgpu_device::psxgpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_video_interface(mconfig, *this) , device_palette_interface(mconfig, *this) @@ -75,62 +75,62 @@ void psxgpu_device::device_reset() gpu_reset(); } -cxd8514q_device::cxd8514q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu) +cxd8514q_device::cxd8514q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu) : psxgpu_device(mconfig, CXD8514Q, tag, owner, clock, vram_size, cpu) { } -cxd8514q_device::cxd8514q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cxd8514q_device::cxd8514q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : psxgpu_device(mconfig, CXD8514Q, tag, owner, clock) { } -cxd8538q_device::cxd8538q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu) +cxd8538q_device::cxd8538q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu) : psxgpu_device(mconfig, CXD8538Q, tag, owner, clock, vram_size, cpu) { } -cxd8538q_device::cxd8538q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cxd8538q_device::cxd8538q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : psxgpu_device(mconfig, CXD8538Q, tag, owner, clock) { } -cxd8561q_device::cxd8561q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu) +cxd8561q_device::cxd8561q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu) : psxgpu_device(mconfig, CXD8561Q, tag, owner, clock, vram_size, cpu) { } -cxd8561q_device::cxd8561q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cxd8561q_device::cxd8561q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : psxgpu_device(mconfig, CXD8561Q, tag, owner, clock) { } -cxd8561bq_device::cxd8561bq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu) +cxd8561bq_device::cxd8561bq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu) : psxgpu_device(mconfig, CXD8561BQ, tag, owner, clock, vram_size, cpu) { } -cxd8561bq_device::cxd8561bq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cxd8561bq_device::cxd8561bq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : psxgpu_device(mconfig, CXD8561BQ, tag, owner, clock) { } -cxd8561cq_device::cxd8561cq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu) +cxd8561cq_device::cxd8561cq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu) : psxgpu_device(mconfig, CXD8561CQ, tag, owner, clock, vram_size, cpu) { } -cxd8561cq_device::cxd8561cq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cxd8561cq_device::cxd8561cq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : psxgpu_device(mconfig, CXD8561CQ, tag, owner, clock) { } -cxd8654q_device::cxd8654q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu) +cxd8654q_device::cxd8654q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu) : psxgpu_device(mconfig, CXD8654Q, tag, owner, clock, vram_size, cpu) { } -cxd8654q_device::cxd8654q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +cxd8654q_device::cxd8654q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : psxgpu_device(mconfig, CXD8654Q, tag, owner, clock) { } diff --git a/src/devices/video/psx.h b/src/devices/video/psx.h index 0482369692e..ec12ee1a90c 100644 --- a/src/devices/video/psx.h +++ b/src/devices/video/psx.h @@ -45,8 +45,8 @@ protected: static constexpr unsigned MID_SHADE = 0x80; // construction/destruction - psxgpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu_tag); - psxgpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + psxgpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu_tag); + psxgpu_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_post_load() override; @@ -311,48 +311,48 @@ class cxd8514q_device : public psxgpu_device { public: // construction/destruction - cxd8514q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu); - cxd8514q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8514q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu); + cxd8514q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cxd8538q_device : public psxgpu_device { public: // construction/destruction - cxd8538q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu); - cxd8538q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8538q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu); + cxd8538q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cxd8561q_device : public psxgpu_device { public: // construction/destruction - cxd8561q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu); - cxd8561q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8561q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu); + cxd8561q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cxd8561bq_device : public psxgpu_device { public: // construction/destruction - cxd8561bq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu); - cxd8561bq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8561bq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu); + cxd8561bq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cxd8561cq_device : public psxgpu_device { public: // construction/destruction - cxd8561cq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu); - cxd8561cq_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8561cq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu); + cxd8561cq_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class cxd8654q_device : public psxgpu_device { public: // construction/destruction - cxd8654q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, uint32_t vram_size, psxcpu_device *cpu); - cxd8654q_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + cxd8654q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, uint32_t vram_size, psxcpu_device *cpu); + cxd8654q_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; #endif // MAME_VIDEO_PSX_H diff --git a/src/devices/video/pwm.cpp b/src/devices/video/pwm.cpp index 5258b204392..2f7ec798f3e 100644 --- a/src/devices/video/pwm.cpp +++ b/src/devices/video/pwm.cpp @@ -47,7 +47,7 @@ DEFINE_DEVICE_TYPE(PWM_DISPLAY, pwm_display_device, "pwm_display", "PWM Display" // constructor //------------------------------------------------- -pwm_display_device::pwm_display_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +pwm_display_device::pwm_display_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, PWM_DISPLAY, tag, owner, clock), m_out_x(*this, "%u.%u", 0U, 0U), m_out_a(*this, "%u.a", 0U), diff --git a/src/devices/video/pwm.h b/src/devices/video/pwm.h index 48a04ec9756..331695e9d83 100644 --- a/src/devices/video/pwm.h +++ b/src/devices/video/pwm.h @@ -14,7 +14,7 @@ class pwm_display_device : public device_t { public: - pwm_display_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + pwm_display_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers pwm_display_device &set_size(u8 numrows, u8 rowbits) { m_height = numrows; m_width = rowbits; return *this; } // max 64 * 64 diff --git a/src/devices/video/ramdac.cpp b/src/devices/video/ramdac.cpp index 9d749bc2c7f..22f9c23cc57 100644 --- a/src/devices/video/ramdac.cpp +++ b/src/devices/video/ramdac.cpp @@ -44,7 +44,7 @@ DEFINE_DEVICE_TYPE(RAMDAC, ramdac_device, "ramdac", "RAMDAC") // ramdac_device - constructor //------------------------------------------------- -ramdac_device::ramdac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +ramdac_device::ramdac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, RAMDAC, tag, owner, clock), device_memory_interface(mconfig, *this), m_space_config("videoram", ENDIANNESS_LITTLE, 8, 10, 0, address_map_constructor(FUNC(ramdac_device::ramdac_palram), this)), diff --git a/src/devices/video/ramdac.h b/src/devices/video/ramdac.h index d21ea4a51ee..e2ac243f72b 100644 --- a/src/devices/video/ramdac.h +++ b/src/devices/video/ramdac.h @@ -26,12 +26,12 @@ class ramdac_device : public device_t, public: // construction/destruction template <typename T> - ramdac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&palette_tag) - : ramdac_device(mconfig, tag, owner, clock) + ramdac_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&palette_tag) + : ramdac_device(mconfig, tag, owner) { m_palette.set_tag(std::forward<T>(palette_tag)); } - ramdac_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + ramdac_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration void set_color_base(uint32_t color_base) { m_color_base = color_base; } diff --git a/src/devices/video/saa5050.cpp b/src/devices/video/saa5050.cpp index 5dae957d699..c0d47a25de9 100644 --- a/src/devices/video/saa5050.cpp +++ b/src/devices/video/saa5050.cpp @@ -174,7 +174,7 @@ const tiny_rom_entry *saa5057_device::device_rom_region() const // saa5050_device - constructor //------------------------------------------------- -saa5050_device::saa5050_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +saa5050_device::saa5050_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_char_rom(*this, "chargen"), m_read_d(*this), @@ -185,42 +185,42 @@ saa5050_device::saa5050_device(const machine_config &mconfig, device_type type, { } -saa5050_device::saa5050_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saa5050_device::saa5050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5050_device(mconfig, SAA5050, tag, owner, clock) { } -saa5051_device::saa5051_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saa5051_device::saa5051_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5050_device(mconfig, SAA5051, tag, owner, clock) { } -saa5052_device::saa5052_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saa5052_device::saa5052_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5050_device(mconfig, SAA5052, tag, owner, clock) { } -saa5053_device::saa5053_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saa5053_device::saa5053_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5050_device(mconfig, SAA5053, tag, owner, clock) { } -saa5054_device::saa5054_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saa5054_device::saa5054_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5050_device(mconfig, SAA5054, tag, owner, clock) { } -saa5055_device::saa5055_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saa5055_device::saa5055_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5050_device(mconfig, SAA5055, tag, owner, clock) { } -saa5056_device::saa5056_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saa5056_device::saa5056_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5050_device(mconfig, SAA5056, tag, owner, clock) { } -saa5057_device::saa5057_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +saa5057_device::saa5057_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5050_device(mconfig, SAA5057, tag, owner, clock) { } diff --git a/src/devices/video/saa5050.h b/src/devices/video/saa5050.h index 99a0e69836f..83f8111ba97 100644 --- a/src/devices/video/saa5050.h +++ b/src/devices/video/saa5050.h @@ -39,7 +39,7 @@ class saa5050_device : public device_t { public: // construction/destruction - saa5050_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5050_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_screen_size(int cols, int rows, int size) { m_cols = cols; m_rows = rows; m_size = size; } @@ -63,7 +63,7 @@ public: uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); protected: - saa5050_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + saa5050_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -155,7 +155,7 @@ class saa5051_device : public saa5050_device { public: // construction/destruction - saa5051_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5051_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -168,7 +168,7 @@ class saa5052_device : public saa5050_device { public: // construction/destruction - saa5052_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5052_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -181,7 +181,7 @@ class saa5053_device : public saa5050_device { public: // construction/destruction - saa5053_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5053_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -194,7 +194,7 @@ class saa5054_device : public saa5050_device { public: // construction/destruction - saa5054_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5054_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -207,7 +207,7 @@ class saa5055_device : public saa5050_device { public: // construction/destruction - saa5055_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5055_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -220,7 +220,7 @@ class saa5056_device : public saa5050_device { public: // construction/destruction - saa5056_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5056_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -233,7 +233,7 @@ class saa5057_device : public saa5050_device { public: // construction/destruction - saa5057_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5057_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/video/saa5240.cpp b/src/devices/video/saa5240.cpp index a9336398a5a..ceb14491788 100644 --- a/src/devices/video/saa5240.cpp +++ b/src/devices/video/saa5240.cpp @@ -98,7 +98,7 @@ const tiny_rom_entry *saa5243e_device::device_rom_region() const // saa5240_device - constructor //------------------------------------------------- -saa5240_device::saa5240_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +saa5240_device::saa5240_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_char_rom(*this, "chargen") @@ -115,17 +115,17 @@ saa5240_device::saa5240_device(const machine_config &mconfig, device_type type, { } -saa5240a_device::saa5240a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saa5240a_device::saa5240a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5240_device(mconfig, SAA5240A, tag, owner, clock) { } -saa5240b_device::saa5240b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saa5240b_device::saa5240b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5240_device(mconfig, SAA5240B, tag, owner, clock) { } -saa5243e_device::saa5243e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +saa5243e_device::saa5243e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : saa5240_device(mconfig, SAA5243E, tag, owner, clock) { } diff --git a/src/devices/video/saa5240.h b/src/devices/video/saa5240.h index b4f2a78decd..36a0e394e02 100644 --- a/src/devices/video/saa5240.h +++ b/src/devices/video/saa5240.h @@ -58,7 +58,7 @@ class saa5240_device : { public: // construction/destruction - saa5240_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5240_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER(write_scl); DECLARE_WRITE_LINE_MEMBER(write_sda); @@ -71,7 +71,7 @@ public: uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); protected: - saa5240_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + saa5240_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -183,7 +183,7 @@ class saa5240a_device : public saa5240_device { public: // construction/destruction - saa5240a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5240a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -196,7 +196,7 @@ class saa5240b_device : public saa5240_device { public: // construction/destruction - saa5240b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5240b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; @@ -209,7 +209,7 @@ class saa5243e_device : public saa5240_device { public: // construction/destruction - saa5243e_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + saa5243e_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // optional information overrides virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/video/scn2674.cpp b/src/devices/video/scn2674.cpp index 3461a15083c..4acfde57fd9 100644 --- a/src/devices/video/scn2674.cpp +++ b/src/devices/video/scn2674.cpp @@ -29,17 +29,17 @@ void scn2674_device::scn2674_vram(address_map &map) map(0x0000, (1 << space_config(0)->addr_width()) - 1).noprw(); } -scn2672_device::scn2672_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scn2672_device::scn2672_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scn2674_device(mconfig, SCN2672, tag, owner, clock, false) { } -scn2674_device::scn2674_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +scn2674_device::scn2674_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : scn2674_device(mconfig, SCN2674, tag, owner, clock, true) { } -scn2674_device::scn2674_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool extend_addressing) +scn2674_device::scn2674_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool extend_addressing) : device_t(mconfig, type, tag, owner, clock) , device_video_interface(mconfig, *this) , device_memory_interface(mconfig, *this) diff --git a/src/devices/video/scn2674.h b/src/devices/video/scn2674.h index ebcea6915b8..011bc3d4501 100644 --- a/src/devices/video/scn2674.h +++ b/src/devices/video/scn2674.h @@ -28,7 +28,7 @@ public: template <typename... T> void set_display_callback(T &&... args) { m_display_cb.set(std::forward<T>(args)...); } - scn2674_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scn2674_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t read(offs_t offset); void write(offs_t offset, uint8_t data); @@ -40,7 +40,7 @@ public: uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); protected: - scn2674_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, bool extend_addressing); + scn2674_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, bool extend_addressing); virtual void device_start() override; virtual void device_reset() override; @@ -138,7 +138,7 @@ protected: class scn2672_device : public scn2674_device { public: - scn2672_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + scn2672_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void write_init_regs(uint8_t data) override; diff --git a/src/devices/video/sda5708.cpp b/src/devices/video/sda5708.cpp index 05453afadb7..2867fe8517e 100644 --- a/src/devices/video/sda5708.cpp +++ b/src/devices/video/sda5708.cpp @@ -58,7 +58,7 @@ DEFINE_DEVICE_TYPE(SDA5708, sda5708_device, "sda5708", "SDA570 // sda5708_device - constructor //------------------------------------------------- -sda5708_device::sda5708_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sda5708_device::sda5708_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SDA5708, tag, owner, clock) , m_dots(*this, "Dot_%u%u%u", 1U, 1U, 1U) , m_serial(0) diff --git a/src/devices/video/sda5708.h b/src/devices/video/sda5708.h index 4237675b95e..bd2a02f2f76 100644 --- a/src/devices/video/sda5708.h +++ b/src/devices/video/sda5708.h @@ -52,7 +52,7 @@ class sda5708_device : public device_t { public: // construction/destruction - sda5708_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sda5708_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); DECLARE_WRITE_LINE_MEMBER( load_w ); DECLARE_WRITE_LINE_MEMBER( data_w ); diff --git a/src/devices/video/sed1200.cpp b/src/devices/video/sed1200.cpp index 371832f579a..0dd2c20cc33 100644 --- a/src/devices/video/sed1200.cpp +++ b/src/devices/video/sed1200.cpp @@ -31,27 +31,27 @@ ROM_START( sed1200x0b ) ROM_LOAD( "sed1200-b.bin", 0x000, 0x800, CRC(d0741f51) SHA1(c8c856f1357286a2c8c806af81724a828345357e)) ROM_END -sed1200_device::sed1200_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +sed1200_device::sed1200_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), cursor_direction(false), cursor_blinking(false), cursor_full(false), cursor_on(false), display_on(false), cursor_address(0), cgram_address(0), cgrom(nullptr) { } -sed1200d0a_device::sed1200d0a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sed1200d0a_device::sed1200d0a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed1200_device(mconfig, SED1200D0A, tag, owner, clock) { } -sed1200f0a_device::sed1200f0a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sed1200f0a_device::sed1200f0a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed1200_device(mconfig, SED1200F0A, tag, owner, clock) { } -sed1200d0b_device::sed1200d0b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sed1200d0b_device::sed1200d0b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed1200_device(mconfig, SED1200D0B, tag, owner, clock) { } -sed1200f0b_device::sed1200f0b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +sed1200f0b_device::sed1200f0b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed1200_device(mconfig, SED1200F0B, tag, owner, clock) { } diff --git a/src/devices/video/sed1200.h b/src/devices/video/sed1200.h index d6590af49ab..d6f46dd7544 100644 --- a/src/devices/video/sed1200.h +++ b/src/devices/video/sed1200.h @@ -27,7 +27,7 @@ public: const uint8_t *render(); protected: - sed1200_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + sed1200_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; @@ -45,7 +45,7 @@ private: class sed1200d0a_device : public sed1200_device { public: - sed1200d0a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sed1200d0a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -53,7 +53,7 @@ protected: class sed1200f0a_device : public sed1200_device { public: - sed1200f0a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sed1200f0a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -61,7 +61,7 @@ protected: class sed1200d0b_device : public sed1200_device { public: - sed1200d0b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sed1200d0b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; @@ -69,7 +69,7 @@ protected: class sed1200f0b_device : public sed1200_device { public: - sed1200f0b_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sed1200f0b_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual const tiny_rom_entry *device_rom_region() const override; diff --git a/src/devices/video/sed1330.cpp b/src/devices/video/sed1330.cpp index 37d95caac7b..0e03ed4d428 100644 --- a/src/devices/video/sed1330.cpp +++ b/src/devices/video/sed1330.cpp @@ -148,7 +148,7 @@ inline void sed1330_device::increment_csr() // sed1330_device - constructor //------------------------------------------------- -sed1330_device::sed1330_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sed1330_device::sed1330_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SED1330, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), @@ -384,7 +384,7 @@ void sed1330_device::data_w(uint8_t data) case 5: m_lf = data + 1; LOG("SED1330 Frame Height: %u\n", m_lf); - if (clock() != 0) + if (!clock().disabled()) { attotime fr = clocks_to_attotime(m_tcr * m_lf * 9); screen().configure(m_tcr * m_fx, m_lf, screen().visible_area(), fr.as_attoseconds()); diff --git a/src/devices/video/sed1330.h b/src/devices/video/sed1330.h index c9bff82f578..13266ed295b 100644 --- a/src/devices/video/sed1330.h +++ b/src/devices/video/sed1330.h @@ -26,7 +26,7 @@ class sed1330_device : public device_t, { public: // construction/destruction - sed1330_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + sed1330_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t status_r(); void command_w(uint8_t data); diff --git a/src/devices/video/sed1356.cpp b/src/devices/video/sed1356.cpp index ccc60d94a95..7ed04aea016 100644 --- a/src/devices/video/sed1356.cpp +++ b/src/devices/video/sed1356.cpp @@ -40,7 +40,7 @@ DEFINE_DEVICE_TYPE(SED1356, sed1356_device, "sed1356", "Epson SED1356") -sed1356_device::sed1356_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sed1356_device::sed1356_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SED1356, tag, owner, clock) , device_video_interface(mconfig, *this) , m_vram(*this, "vram") diff --git a/src/devices/video/sed1356.h b/src/devices/video/sed1356.h index 98d80684253..003698ccf91 100644 --- a/src/devices/video/sed1356.h +++ b/src/devices/video/sed1356.h @@ -21,7 +21,7 @@ class sed1356_device : public device_t, { public: // construction/destruction - sed1356_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sed1356_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); void map(address_map &map); void vram_map(address_map &map); diff --git a/src/devices/video/sed1500.cpp b/src/devices/video/sed1500.cpp index 41ade315d56..f8f11992085 100644 --- a/src/devices/video/sed1500.cpp +++ b/src/devices/video/sed1500.cpp @@ -34,25 +34,25 @@ DEFINE_DEVICE_TYPE(SED1503, sed1503_device, "sed1503", "Epson SED1503 LCD Driver // constructor //------------------------------------------------- -sed1500_device::sed1500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 cmax, u8 smax) : +sed1500_device::sed1500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 cmax, u8 smax) : device_t(mconfig, type, tag, owner, clock), m_cmax(cmax), m_smax(smax), m_write_segs(*this) { } -sed1500_device::sed1500_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sed1500_device::sed1500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed1500_device(mconfig, SED1500, tag, owner, clock, 8, 42) { } -sed1501_device::sed1501_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sed1501_device::sed1501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed1500_device(mconfig, SED1501, tag, owner, clock, 10, 40) { } -sed1502_device::sed1502_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sed1502_device::sed1502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed1500_device(mconfig, SED1502, tag, owner, clock, 16, 34) { } -sed1503_device::sed1503_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +sed1503_device::sed1503_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed1500_device(mconfig, SED1503, tag, owner, clock, 8+8, 42) { } diff --git a/src/devices/video/sed1500.h b/src/devices/video/sed1500.h index a72e124f772..6cc56c2a699 100644 --- a/src/devices/video/sed1500.h +++ b/src/devices/video/sed1500.h @@ -31,7 +31,7 @@ SEG: LCD segments class sed1500_device : public device_t { public: - sed1500_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sed1500_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // configuration helpers auto write_segs() { return m_write_segs.bind(); } // common number in offset, segment data in data @@ -40,7 +40,7 @@ public: u8 read(offs_t offset); protected: - sed1500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, u8 cmax, u8 smax); + sed1500_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, u8 cmax, u8 smax); // device-level overrides virtual void device_start() override; @@ -62,19 +62,19 @@ protected: class sed1501_device : public sed1500_device { public: - sed1501_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sed1501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class sed1502_device : public sed1500_device { public: - sed1502_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sed1502_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class sed1503_device : public sed1500_device { public: - sed1503_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + sed1503_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/video/sed1520.cpp b/src/devices/video/sed1520.cpp index 9dd8017155d..944cb2ee825 100644 --- a/src/devices/video/sed1520.cpp +++ b/src/devices/video/sed1520.cpp @@ -34,7 +34,7 @@ DEFINE_DEVICE_TYPE(EPL43102, epl43102_device, "epl43102", "Elan EPL43102 LCD Dri // sed1520_device - constructor //------------------------------------------------- -sed15xx_device_base::sed15xx_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t ddr_size, uint32_t page_size) +sed15xx_device_base::sed15xx_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t ddr_size, uint32_t page_size) : device_t(mconfig, type, tag, owner, clock) , m_ddr_size(ddr_size) , m_page_size(page_size) @@ -51,24 +51,24 @@ sed15xx_device_base::sed15xx_device_base(const machine_config &mconfig, device_t { } -sed1520_device::sed1520_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sed1520_device::sed1520_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed15xx_device_base(mconfig, SED1520, tag, owner, clock, 320, 80) // 2560-bit display RAM , m_screen_update_cb(*this) { } -sed1560_device::sed1560_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t ddr_size, uint32_t page_size) +sed1560_device::sed1560_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t ddr_size, uint32_t page_size) : sed15xx_device_base(mconfig, type, tag, owner, clock, ddr_size, page_size) , m_screen_update_cb(*this) { } -sed1560_device::sed1560_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +sed1560_device::sed1560_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed1560_device(mconfig, SED1560, tag, owner, clock, 1349, 166) // 166 × 65-bit display RAM { } -epl43102_device::epl43102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +epl43102_device::epl43102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : sed1560_device(mconfig, EPL43102, tag, owner, clock, 455, 102) // 102 × 43-bit display RAM (TODO: page map is not straightforward) { } diff --git a/src/devices/video/sed1520.h b/src/devices/video/sed1520.h index 58fc364f69a..89d7a5001b0 100644 --- a/src/devices/video/sed1520.h +++ b/src/devices/video/sed1520.h @@ -38,7 +38,7 @@ public: protected: // construction/destruction - sed15xx_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t ddr_size, uint32_t page_size); + sed15xx_device_base(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t ddr_size, uint32_t page_size); // device-level overrides virtual void device_start() override; @@ -72,7 +72,7 @@ public: typedef device_delegate<uint32_t (bitmap_ind16 &bitmap, const rectangle &cliprect, bool lcd_on, uint8_t *dram, uint8_t start_line, uint8_t adc, uint8_t duty)> sed1520_update_delegate; // construction/destruction - sed1520_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sed1520_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers template <typename... T> void set_screen_update_cb(T &&... args) { m_screen_update_cb.set(std::forward<T>(args)...); } @@ -103,7 +103,7 @@ public: typedef device_delegate<uint32_t (bitmap_ind16 &bitmap, const rectangle &cliprect, bool lcd_on, uint8_t *dram, uint8_t start_line, uint8_t adc, uint8_t duty, bool reverse, bool fill, uint8_t contrast, bool line_inv, uint8_t line_inv_num)> sed1560_update_delegate; // construction/destruction - sed1560_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + sed1560_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers template <typename... T> void set_screen_update_cb(T &&... args) { m_screen_update_cb.set(std::forward<T>(args)...); } @@ -113,7 +113,7 @@ public: uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); protected: - sed1560_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint32_t ddr_size, uint32_t page_size); + sed1560_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint32_t ddr_size, uint32_t page_size); // device-level overrides virtual void device_resolve_objects() override; @@ -139,7 +139,7 @@ class epl43102_device : public sed1560_device { public: // construction/destruction - epl43102_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + epl43102_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); virtual void control_write(uint8_t data) override; diff --git a/src/devices/video/snes_ppu.cpp b/src/devices/video/snes_ppu.cpp index 9fddaa1b8d1..4e95beb3bb3 100644 --- a/src/devices/video/snes_ppu.cpp +++ b/src/devices/video/snes_ppu.cpp @@ -189,7 +189,7 @@ DEFINE_DEVICE_TYPE(SNES_PPU, snes_ppu_device, "snes_ppu", "SNES PPU") // snes_ppu_device - constructor //------------------------------------------------- -snes_ppu_device::snes_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +snes_ppu_device::snes_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, SNES_PPU, tag, owner, clock) , device_video_interface(mconfig, *this) , device_palette_interface(mconfig, *this) diff --git a/src/devices/video/snes_ppu.h b/src/devices/video/snes_ppu.h index c07f878f402..28af99e45c7 100644 --- a/src/devices/video/snes_ppu.h +++ b/src/devices/video/snes_ppu.h @@ -42,7 +42,7 @@ class snes_ppu_device : public device_t, { public: // construction/destruction - snes_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + snes_ppu_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // inline configuration helpers auto open_bus_callback() { return m_openbus_cb.bind(); } diff --git a/src/devices/video/sprite.h b/src/devices/video/sprite.h index 2ef3234b9d9..048ed3eb56f 100644 --- a/src/devices/video/sprite.h +++ b/src/devices/video/sprite.h @@ -82,7 +82,7 @@ class sprite_device : public device_t protected: // construction/destruction - only for subclasses sprite_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, int dirty_granularity = 3) - : device_t(mconfig, type, tag, owner, 0) + : device_t(mconfig, type, tag, owner) , m_xorigin(0) , m_yorigin(0) , m_spriteram(nullptr) diff --git a/src/devices/video/t6963c.cpp b/src/devices/video/t6963c.cpp index bf0841450c0..520b4c4bde0 100644 --- a/src/devices/video/t6963c.cpp +++ b/src/devices/video/t6963c.cpp @@ -32,7 +32,7 @@ ALLOW_SAVE_TYPE(t6963c_device::auto_mode); // t6963c_device - constructor //------------------------------------------------- -t6963c_device::t6963c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +t6963c_device::t6963c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, T6963C, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_display_config("display", ENDIANNESS_LITTLE, 8, 16, 0) @@ -394,7 +394,7 @@ uint32_t t6963c_device::screen_update(screen_device &screen, bitmap_ind16 &bitma // lm24014h_device - constructor //------------------------------------------------- -lm24014h_device::lm24014h_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +lm24014h_device::lm24014h_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, LM24014H, tag, owner, clock) , m_lcdc(*this, "lcdc") , m_fs(1) @@ -439,7 +439,7 @@ void lm24014h_device::lcd_palette(palette_device &palette) const void lm24014h_device::device_add_mconfig(machine_config &config) { - T6963C(config, m_lcdc, 0); // XTAL is unknown + T6963C(config, m_lcdc); // XTAL is unknown m_lcdc->set_addrmap(0, &lm24014h_device::ram_map); screen_device &screen(SCREEN(config, "screen", SCREEN_TYPE_LCD)); diff --git a/src/devices/video/t6963c.h b/src/devices/video/t6963c.h index aaaeb7c3e57..c7ddf5bb89b 100644 --- a/src/devices/video/t6963c.h +++ b/src/devices/video/t6963c.h @@ -33,7 +33,7 @@ class t6963c_device : public device_t, public device_memory_interface public: // construction/destruction - t6963c_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + t6963c_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); // CPU read/write access u8 read(offs_t offset); @@ -86,7 +86,7 @@ class lm24014h_device : public device_t { public: // construction/destruction - lm24014h_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock = 0); + lm24014h_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // CPU read/write access u8 read(offs_t offset) { return m_lcdc->read(offset); } diff --git a/src/devices/video/t6a04.cpp b/src/devices/video/t6a04.cpp index a5dc8bfa928..0ff55ec3544 100644 --- a/src/devices/video/t6a04.cpp +++ b/src/devices/video/t6a04.cpp @@ -36,7 +36,7 @@ void t6a04_device::device_validity_check(validity_checker &valid) const // t6a04_device - constructor //------------------------------------------------- -t6a04_device::t6a04_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +t6a04_device::t6a04_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, T6A04, tag, owner, clock), m_busy_flag(0), m_display_on(0), m_contrast(0), m_xpos(0), m_ypos(0), m_zpos(0), diff --git a/src/devices/video/t6a04.h b/src/devices/video/t6a04.h index 72900b171bb..5d700b7be90 100644 --- a/src/devices/video/t6a04.h +++ b/src/devices/video/t6a04.h @@ -21,7 +21,7 @@ class t6a04_device : public device_t { public: // construction/destruction - t6a04_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + t6a04_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_size(int w, int h) { diff --git a/src/devices/video/tea1002.cpp b/src/devices/video/tea1002.cpp index af80f9908a3..fd5ef980b29 100644 --- a/src/devices/video/tea1002.cpp +++ b/src/devices/video/tea1002.cpp @@ -50,7 +50,7 @@ DEFINE_DEVICE_TYPE(TEA1002, tea1002_device, "tea1002", "Mullard TEA1002 PAL colo // paula_device - constructor //------------------------------------------------- -tea1002_device::tea1002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +tea1002_device::tea1002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TEA1002, tag, owner, clock) { } diff --git a/src/devices/video/tea1002.h b/src/devices/video/tea1002.h index e208d20fb0a..fec7a9ea7f5 100644 --- a/src/devices/video/tea1002.h +++ b/src/devices/video/tea1002.h @@ -35,7 +35,7 @@ class tea1002_device : public device_t { public: // construction/destruction - tea1002_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tea1002_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); rgb_t color(int index); diff --git a/src/devices/video/tlc34076.cpp b/src/devices/video/tlc34076.cpp index 01cc9070fb3..7ebd51c7912 100644 --- a/src/devices/video/tlc34076.cpp +++ b/src/devices/video/tlc34076.cpp @@ -41,7 +41,7 @@ DEFINE_DEVICE_TYPE(TLC34076, tlc34076_device, "tlc34076", "TI TLC34076 VIP") //------------------------------------------------- // tlc34076_device - constructor //------------------------------------------------- -tlc34076_device::tlc34076_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tlc34076_device::tlc34076_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TLC34076, tag, owner, clock) , device_palette_interface(mconfig, *this) , m_dacbits(6) diff --git a/src/devices/video/tlc34076.h b/src/devices/video/tlc34076.h index c495cf82088..1e86541b2e5 100644 --- a/src/devices/video/tlc34076.h +++ b/src/devices/video/tlc34076.h @@ -30,12 +30,12 @@ public: // construction/destruction tlc34076_device(const machine_config &mconfig, const char *tag, device_t *owner, tlc34076_bits bits) - : tlc34076_device(mconfig, tag, owner, (uint32_t)0) + : tlc34076_device(mconfig, tag, owner) { set_bits(bits); } - tlc34076_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tlc34076_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configuration helpers void set_bits(tlc34076_bits bits) { m_dacbits = bits; } diff --git a/src/devices/video/tmap038.cpp b/src/devices/video/tmap038.cpp index 9b007e28a2c..f675d430bb7 100644 --- a/src/devices/video/tmap038.cpp +++ b/src/devices/video/tmap038.cpp @@ -128,7 +128,7 @@ void tilemap038_device::vram_8x8_map(address_map &map) DEFINE_DEVICE_TYPE(TMAP038, tilemap038_device, "tmap038", "038 Tilemap generator") -tilemap038_device::tilemap038_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tilemap038_device::tilemap038_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMAP038, tag, owner, clock) , m_vram_8x8(*this, "vram_8x8") , m_vram_16x16(*this, "vram_16x16") diff --git a/src/devices/video/tmap038.h b/src/devices/video/tmap038.h index cc5ba89813d..852b48e2f33 100644 --- a/src/devices/video/tmap038.h +++ b/src/devices/video/tmap038.h @@ -12,12 +12,7 @@ class tilemap038_device : public device_t public: typedef device_delegate<void (bool tiledim, u32 &color, u32 &pri, u32 &code)> tmap038_cb_delegate; - tilemap038_device(const machine_config &mconfig, const char *tag, device_t *owner) - : tilemap038_device(mconfig, tag, owner, (u32)0) - { - } - - tilemap038_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tilemap038_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); // configurations template <typename T> void set_gfxdecode_tag(T &&tag) { m_gfxdecode.set_tag(std::forward<T>(tag)); } diff --git a/src/devices/video/tms34061.cpp b/src/devices/video/tms34061.cpp index 8d987b06701..6f32777c0fc 100644 --- a/src/devices/video/tms34061.cpp +++ b/src/devices/video/tms34061.cpp @@ -32,7 +32,7 @@ DEFINE_DEVICE_TYPE(TMS34061, tms34061_device, "tms34061", "TI TMS34061 VSC") -tms34061_device::tms34061_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +tms34061_device::tms34061_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMS34061, tag, owner, clock), device_video_interface(mconfig, *this), m_rowshift(0), diff --git a/src/devices/video/tms34061.h b/src/devices/video/tms34061.h index 47cd6e68c60..e8bbc469ec8 100644 --- a/src/devices/video/tms34061.h +++ b/src/devices/video/tms34061.h @@ -31,7 +31,7 @@ public: }; // construction/destruction - tms34061_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + tms34061_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_rowshift(u8 rowshift) { m_rowshift = rowshift; } void set_vram_size(u32 vramsize) { m_vramsize = vramsize; } diff --git a/src/devices/video/tms3556.cpp b/src/devices/video/tms3556.cpp index 3088e02e685..325cb0070f6 100644 --- a/src/devices/video/tms3556.cpp +++ b/src/devices/video/tms3556.cpp @@ -108,7 +108,7 @@ inline void tms3556_device::writebyte(offs_t address, uint8_t data) // tms3556_device - constructor //------------------------------------------------- -tms3556_device::tms3556_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms3556_device::tms3556_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, TMS3556, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/video/tms3556.h b/src/devices/video/tms3556.h index a6ced908b02..0f516c991ba 100644 --- a/src/devices/video/tms3556.h +++ b/src/devices/video/tms3556.h @@ -38,7 +38,7 @@ public: static constexpr unsigned TOTAL_HEIGHT = 250 + TOP_BORDER + BOTTOM_BORDER; // construction/destruction - tms3556_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms3556_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint8_t vram_r(); void vram_w(uint8_t data); diff --git a/src/devices/video/tms9927.cpp b/src/devices/video/tms9927.cpp index 6ae31a1a9d5..c8ef0559ed3 100644 --- a/src/devices/video/tms9927.cpp +++ b/src/devices/video/tms9927.cpp @@ -36,12 +36,12 @@ DEFINE_DEVICE_TYPE(CRT5027, crt5027_device, "crt5027", "CRT5027 VTAC") DEFINE_DEVICE_TYPE(CRT5037, crt5037_device, "crt5037", "CRT5037 VTAC") DEFINE_DEVICE_TYPE(CRT5057, crt5057_device, "crt5057", "CRT5057 VTAC") -tms9927_device::tms9927_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9927_device::tms9927_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9927_device(mconfig, TMS9927, tag, owner, clock) { } -tms9927_device::tms9927_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +tms9927_device::tms9927_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock) , device_video_interface(mconfig, *this) , m_write_vsyn(*this) @@ -59,17 +59,17 @@ tms9927_device::tms9927_device(const machine_config &mconfig, device_type type, std::fill(std::begin(m_reg), std::end(m_reg), 0x00); } -crt5027_device::crt5027_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crt5027_device::crt5027_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9927_device(mconfig, CRT5027, tag, owner, clock) { } -crt5037_device::crt5037_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crt5037_device::crt5037_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9927_device(mconfig, CRT5037, tag, owner, clock) { } -crt5057_device::crt5057_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +crt5057_device::crt5057_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9927_device(mconfig, CRT5057, tag, owner, clock) { } @@ -81,7 +81,7 @@ crt5057_device::crt5057_device(const machine_config &mconfig, const char *tag, d void tms9927_device::device_start() { - assert(clock() > 0); + assert(!clock().disabled()); if (!(m_hpixels_per_column > 0)) fatalerror("TMS9927: number of pixels per column must be explicitly set using set_char_width()!\n"); // resolve callbacks @@ -127,7 +127,7 @@ void tms9927_device::device_clock_changed() void tms9927_device::device_stop() { osd_printf_debug("TMS9927: Final params: (%d, %d, %d, %d, %d, %d, %d)\n", - clock() * m_hpixels_per_column, + clock().value() * m_hpixels_per_column, m_total_hpix, 0, m_visible_hpix, m_total_vpix, @@ -331,7 +331,7 @@ void tms9927_device::recompute_parameters(bool postload) logerror("tms9927: invalid visible size (%dx%d) versus total size (%dx%d)\n", m_visible_hpix, m_visible_vpix, m_total_hpix, m_total_vpix); } - if (clock() == 0) + if (clock().disabled()) { m_valid_config = false; // TODO: make the screen refresh never, and disable the vblank and odd/even interrupts here! diff --git a/src/devices/video/tms9927.h b/src/devices/video/tms9927.h index 5b517f7f78a..2b6bd57bb52 100644 --- a/src/devices/video/tms9927.h +++ b/src/devices/video/tms9927.h @@ -13,7 +13,7 @@ class tms9927_device : public device_t, public device_video_interface { public: - tms9927_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9927_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); auto vsyn_callback() { return m_write_vsyn.bind(); } auto hsyn_callback() { return m_write_hsyn.bind(); } @@ -38,7 +38,7 @@ public: bool cursor_bounds(rectangle &bounds) const; protected: - tms9927_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + tms9927_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); // device-level overrides virtual void device_start() override; @@ -89,21 +89,21 @@ private: class crt5027_device : public tms9927_device { public: - crt5027_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crt5027_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class crt5037_device : public tms9927_device { public: - crt5037_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crt5037_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class crt5057_device : public tms9927_device { public: - crt5057_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + crt5057_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/video/tms9928a.cpp b/src/devices/video/tms9928a.cpp index dffe7b8ba72..a1e901762e1 100644 --- a/src/devices/video/tms9928a.cpp +++ b/src/devices/video/tms9928a.cpp @@ -56,7 +56,7 @@ void tms9928a_device::memmap(address_map &map) map(0x0000, 0x3fff).ram(); } -tms9928a_device::tms9928a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint16_t horz_total, bool is_50hz, bool is_reva, bool is_99) +tms9928a_device::tms9928a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint16_t horz_total, bool is_50hz, bool is_reva, bool is_99) : device_t(mconfig, type, tag, owner, clock) , device_memory_interface(mconfig, *this) , device_palette_interface(mconfig, *this) @@ -92,47 +92,47 @@ void tms9928a_device::device_config_complete() } -tms9928a_device::tms9928a_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9928a_device::tms9928a_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9928a_device(mconfig, TMS9928A, tag, owner, clock, 342, false, true, true) { } -tms9129_device::tms9129_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9129_device::tms9129_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9928a_device(mconfig, TMS9129, tag, owner, clock, 342, true, true, false) { } -tms9918_device::tms9918_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9918_device::tms9918_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9928a_device(mconfig, TMS9918, tag, owner, clock, 342, false, false, true) { } -tms9918a_device::tms9918a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9918a_device::tms9918a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9928a_device(mconfig, TMS9918A, tag, owner, clock, 342, false, true, true) { } -tms9118_device::tms9118_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9118_device::tms9118_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9928a_device(mconfig, TMS9118, tag, owner, clock, 342, false, true, false) { } -tms9128_device::tms9128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9128_device::tms9128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9928a_device(mconfig, TMS9128, tag, owner, clock, 342, false, true, false) { } -tms9929_device::tms9929_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9929_device::tms9929_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9928a_device(mconfig, TMS9929, tag, owner, clock, 342, true, false, true) { } -tms9929a_device::tms9929a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +tms9929a_device::tms9929a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9928a_device(mconfig, TMS9929A, tag, owner, clock, 342, true, true, true) { } -efo90501_device::efo90501_device( const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +efo90501_device::efo90501_device( const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : tms9928a_device(mconfig, EFO90501, tag, owner, clock, 346, true, true, true) { } diff --git a/src/devices/video/tms9928a.h b/src/devices/video/tms9928a.h index d50bec1cf4d..240ba5c364d 100644 --- a/src/devices/video/tms9928a.h +++ b/src/devices/video/tms9928a.h @@ -67,7 +67,7 @@ public: static constexpr unsigned VERT_DISPLAY_START_NTSC = 13 + 27; // construction/destruction - tms9928a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9928a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_vram_size(int vram_size) { m_vram_size = vram_size; } auto int_callback() { return m_out_int_line_cb.bind(); } @@ -89,7 +89,7 @@ public: void reset_line(int state) { if (state==ASSERT_LINE) device_reset(); } protected: - tms9928a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, uint16_t horz_total, bool is_50hz, bool is_reva, bool is_99); + tms9928a_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, uint16_t horz_total, bool is_50hz, bool is_reva, bool is_99); // device-level overrides virtual void device_config_complete() override; @@ -156,56 +156,56 @@ private: class tms9918_device : public tms9928a_device { public: - tms9918_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9918_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms9918a_device : public tms9928a_device { public: - tms9918a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9918a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms9118_device : public tms9928a_device { public: - tms9118_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9118_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms9128_device : public tms9928a_device { public: - tms9128_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9128_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms9929_device : public tms9928a_device { public: - tms9929_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9929_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms9929a_device : public tms9928a_device { public: - tms9929a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9929a_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class tms9129_device : public tms9928a_device { public: - tms9129_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + tms9129_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; class efo90501_device : public tms9928a_device { public: - efo90501_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + efo90501_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); }; diff --git a/src/devices/video/topcat.cpp b/src/devices/video/topcat.cpp index 5ba43d81e44..d917ea58271 100644 --- a/src/devices/video/topcat.cpp +++ b/src/devices/video/topcat.cpp @@ -9,7 +9,7 @@ DEFINE_DEVICE_TYPE(TOPCAT, topcat_device, "topcat", "HP Topcat ASIC") -topcat_device::topcat_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) : +topcat_device::topcat_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, type, tag, owner, clock), m_int_write_func(*this), m_cursor_timer(nullptr), @@ -17,7 +17,7 @@ topcat_device::topcat_device(const machine_config &mconfig, device_type type, co { } -topcat_device::topcat_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +topcat_device::topcat_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : topcat_device(mconfig, TOPCAT, tag, owner, clock) { } diff --git a/src/devices/video/topcat.h b/src/devices/video/topcat.h index ca08f16b9d4..96114bd0728 100644 --- a/src/devices/video/topcat.h +++ b/src/devices/video/topcat.h @@ -8,7 +8,7 @@ class topcat_device : public device_t { public: - topcat_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + topcat_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); bool has_changed() { bool ret = m_changed; m_changed = false; return ret; } void set_fb_width(int _pixels) { m_fb_width = _pixels; } void set_fb_height(int _pixels) { m_fb_height = _pixels; } @@ -27,7 +27,7 @@ public: auto irq_out_cb() { return m_int_write_func.bind(); } protected: - topcat_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); + topcat_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void device_start() override; virtual void device_reset() override; diff --git a/src/devices/video/upd3301.cpp b/src/devices/video/upd3301.cpp index 9e213a6c292..9387ce4b173 100644 --- a/src/devices/video/upd3301.cpp +++ b/src/devices/video/upd3301.cpp @@ -102,7 +102,7 @@ DEFINE_DEVICE_TYPE(UPD3301, upd3301_device, "upd3301", "NEC uPD3301") // upd3301_device - constructor //------------------------------------------------- -upd3301_device::upd3301_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd3301_device::upd3301_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD3301, tag, owner, clock) , device_video_interface(mconfig, *this) , m_write_int(*this) diff --git a/src/devices/video/upd3301.h b/src/devices/video/upd3301.h index 9343f6275b2..13a7753cd61 100644 --- a/src/devices/video/upd3301.h +++ b/src/devices/video/upd3301.h @@ -61,7 +61,7 @@ public: typedef device_delegate<std::array<u16, 80> (const std::array<u8, 41> attr_row, u8 gfx_mode, int y, u8 attr_fifo_size, u8 row_size)> fetch_attribute_delegate; // construction/destruction - upd3301_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd3301_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_character_width(int value) { m_width = value; } template <typename... T> void set_display_callback(T &&... args) { m_display_cb.set(std::forward<T>(args)...); } diff --git a/src/devices/video/upd7220.cpp b/src/devices/video/upd7220.cpp index 91a78531ea5..2efab8a780e 100644 --- a/src/devices/video/upd7220.cpp +++ b/src/devices/video/upd7220.cpp @@ -598,7 +598,7 @@ inline void upd7220_device::get_graphics_partition(int index, uint32_t *sad, uin // upd7220_device - constructor //------------------------------------------------- -upd7220_device::upd7220_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) : +upd7220_device::upd7220_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD7220, tag, owner, clock), device_memory_interface(mconfig, *this), device_video_interface(mconfig, *this), diff --git a/src/devices/video/upd7220.h b/src/devices/video/upd7220.h index af203e2fdd7..a582c75b239 100644 --- a/src/devices/video/upd7220.h +++ b/src/devices/video/upd7220.h @@ -60,7 +60,7 @@ public: using draw_text_delegate = device_delegate<void (bitmap_rgb32 &bitmap, uint32_t addr, int y, int wd, int pitch, int lr, int cursor_on, int cursor_addr)>; // construction/destruction - upd7220_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + upd7220_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename... T> void set_display_pixels(T &&... args) { m_display_cb.set(std::forward<T>(args)...); } template <typename... T> void set_draw_text(T &&... args) { m_draw_text_cb.set(std::forward<T>(args)...); } diff --git a/src/devices/video/upd7227.cpp b/src/devices/video/upd7227.cpp index f512f8832be..9d07d80f38f 100644 --- a/src/devices/video/upd7227.cpp +++ b/src/devices/video/upd7227.cpp @@ -37,7 +37,7 @@ void upd7227_device::upd7227_map(address_map &map) // upd7227_device - constructor //------------------------------------------------- -upd7227_device::upd7227_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +upd7227_device::upd7227_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, UPD7227, tag, owner, clock) , device_memory_interface(mconfig, *this) , m_space_config("videoram", ENDIANNESS_BIG, 8, 7, 0, address_map_constructor(FUNC(upd7227_device::upd7227_map), this)) diff --git a/src/devices/video/upd7227.h b/src/devices/video/upd7227.h index 1f74b8d6102..4eb6d1e4fd5 100644 --- a/src/devices/video/upd7227.h +++ b/src/devices/video/upd7227.h @@ -23,8 +23,8 @@ class upd7227_device : public device_t, public device_memory_interface { public: // construction/destruction - upd7227_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); - upd7227_device(const machine_config &mconfig, const char *tag, device_t *owner, int sx, int sy) : upd7227_device(mconfig, tag, owner, 0) + upd7227_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); + upd7227_device(const machine_config &mconfig, const char *tag, device_t *owner, int sx, int sy) : upd7227_device(mconfig, tag, owner) { set_offsets(sx, sy); } // inline configuration helpers diff --git a/src/devices/video/v9938.cpp b/src/devices/video/v9938.cpp index 906e92353f7..fea57e42973 100644 --- a/src/devices/video/v9938.cpp +++ b/src/devices/video/v9938.cpp @@ -100,7 +100,7 @@ DEFINE_DEVICE_TYPE(V9938, v9938_device, "v9938", "Yamaha V9938 VDP") DEFINE_DEVICE_TYPE(V9958, v9958_device, "v9958", "Yamaha V9958 VDP") -v99x8_device::v99x8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int model) +v99x8_device::v99x8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int model) : device_t(mconfig, type, tag, owner, clock), device_memory_interface(mconfig, *this), device_palette_interface(mconfig, *this), @@ -135,12 +135,12 @@ v99x8_device::v99x8_device(const machine_config &mconfig, device_type type, cons set_addrmap(AS_DATA, address_map_constructor(FUNC(v99x8_device::memmap), this)); } -v9938_device::v9938_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v9938_device::v9938_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v99x8_device(mconfig, V9938, tag, owner, clock, MODEL_V9938) { } -v9958_device::v9958_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +v9958_device::v9958_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : v99x8_device(mconfig, V9958, tag, owner, clock, MODEL_V9958) { } diff --git a/src/devices/video/v9938.h b/src/devices/video/v9938.h index 265cad5eac1..754599d973e 100644 --- a/src/devices/video/v9938.h +++ b/src/devices/video/v9938.h @@ -86,7 +86,7 @@ public: protected: // construction/destruction - v99x8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock, int model); + v99x8_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, int model); const address_space_config m_space_config; address_space* m_vram_space; @@ -257,7 +257,7 @@ protected: class v9938_device : public v99x8_device { public: - v9938_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v9938_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void palette_init() override; @@ -266,7 +266,7 @@ protected: class v9958_device : public v99x8_device { public: - v9958_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + v9958_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void palette_init() override; diff --git a/src/devices/video/vector.cpp b/src/devices/video/vector.cpp index aa0210eda28..6917e0b35cf 100644 --- a/src/devices/video/vector.cpp +++ b/src/devices/video/vector.cpp @@ -72,7 +72,7 @@ void vector_options::init(emu_options& options) // device type definition DEFINE_DEVICE_TYPE(VECTOR, vector_device, "vector_device", "VECTOR") -vector_device::vector_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vector_device::vector_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VECTOR, tag, owner, clock), device_video_interface(mconfig, *this), m_vector_list(nullptr), diff --git a/src/devices/video/vector.h b/src/devices/video/vector.h index 0465a7c9a43..88336a9faa5 100644 --- a/src/devices/video/vector.h +++ b/src/devices/video/vector.h @@ -31,7 +31,7 @@ public: template <typename T> static constexpr rgb_t color444(T c) { return rgb_t(pal4bit(c >> 8), pal4bit(c >> 4), pal4bit(c >> 0)); } // construction/destruction - vector_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0); + vector_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); void clear_list(); diff --git a/src/devices/video/vic4567.cpp b/src/devices/video/vic4567.cpp index 5f1c756c50d..c94b3f9bd1d 100644 --- a/src/devices/video/vic4567.cpp +++ b/src/devices/video/vic4567.cpp @@ -149,7 +149,7 @@ DEFINE_DEVICE_TYPE(VIC3, vic3_device, "vic3", "CSG 4567 VIC-III") -vic3_device::vic3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vic3_device::vic3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIC3, tag, owner, clock) , device_palette_interface(mconfig, *this) , device_video_interface(mconfig, *this) diff --git a/src/devices/video/vic4567.h b/src/devices/video/vic4567.h index 06c78f2a48e..f7c55182b1b 100644 --- a/src/devices/video/vic4567.h +++ b/src/devices/video/vic4567.h @@ -108,7 +108,7 @@ class vic3_device : public device_t, public: enum class vic3_type { NTSC, PAL }; - vic3_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vic3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); template <typename T> void set_cpu_tag(T &&tag) { m_cpu.set_tag(std::forward<T>(tag)); } void set_vic3_type(vic3_type type) { m_type = type; } diff --git a/src/devices/video/virge_pci.cpp b/src/devices/video/virge_pci.cpp index a76fc33966b..51b69fc7629 100644 --- a/src/devices/video/virge_pci.cpp +++ b/src/devices/video/virge_pci.cpp @@ -6,12 +6,12 @@ #include "screen.h" -virge_pci_device::virge_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +virge_pci_device::virge_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : virge_pci_device(mconfig, VIRGE_PCI, tag, owner, clock) { } -virge_pci_device::virge_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock) +virge_pci_device::virge_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, type, tag, owner, clock), m_vga(*this, "vga"), m_bios(*this, "bios"), @@ -19,7 +19,7 @@ virge_pci_device::virge_pci_device(const machine_config &mconfig, device_type ty { } -virgedx_pci_device::virgedx_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +virgedx_pci_device::virgedx_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : virge_pci_device(mconfig, VIRGEDX_PCI, tag, owner, clock) { } @@ -272,7 +272,7 @@ void virge_pci_device::device_add_mconfig(machine_config &config) screen.set_raw(XTAL(25'174'800), 900, 0, 640, 526, 0, 480); screen.set_screen_update("vga", FUNC(s3virge_vga_device::screen_update)); - S3VIRGE(config, m_vga, 0); + S3VIRGE(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x400000); } @@ -283,7 +283,7 @@ void virgedx_pci_device::device_add_mconfig(machine_config &config) screen.set_raw(XTAL(25'174'800), 900, 0, 640, 526, 0, 480); screen.set_screen_update("vga", FUNC(s3virge_vga_device::screen_update)); - S3VIRGEDX(config, m_vga, 0); + S3VIRGEDX(config, m_vga); m_vga->set_screen("screen"); m_vga->set_vram_size(0x400000); } diff --git a/src/devices/video/virge_pci.h b/src/devices/video/virge_pci.h index f4b6ce29009..a9bc4ce2d6c 100644 --- a/src/devices/video/virge_pci.h +++ b/src/devices/video/virge_pci.h @@ -17,7 +17,7 @@ class virge_pci_device : public pci_device { public: template <typename T> - virge_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) + virge_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : virge_pci_device(mconfig, tag, owner, clock) { set_screen_tag(std::forward<T>(screen_tag)); @@ -31,8 +31,8 @@ public: LAW_4MB }; - virge_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, uint32_t clock); - virge_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + virge_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); + virge_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void lfb_map(address_map &map); void mmio_map(address_map& map); @@ -73,12 +73,12 @@ class virgedx_pci_device : public virge_pci_device { public: template <typename T> - virgedx_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&screen_tag) + virgedx_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&screen_tag) : virgedx_pci_device(mconfig, tag, owner, clock) { set_screen_tag(std::forward<T>(screen_tag)); } - virgedx_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + virgedx_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: virtual void device_start() override; diff --git a/src/devices/video/voodoo.cpp b/src/devices/video/voodoo.cpp index 94c9a5ca7c7..182e335269f 100644 --- a/src/devices/video/voodoo.cpp +++ b/src/devices/video/voodoo.cpp @@ -663,7 +663,7 @@ bool debug_stats::update_display_state(bool key_pressed) // generic_voodoo_device - constructor //------------------------------------------------- -generic_voodoo_device::generic_voodoo_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, voodoo_model model) : +generic_voodoo_device::generic_voodoo_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, voodoo_model model) : device_t(mconfig, type, tag, owner, clock), device_video_interface(mconfig, *this), m_model(model), @@ -702,7 +702,7 @@ void generic_voodoo_device::device_start() DEFINE_DEVICE_TYPE(VOODOO_1, voodoo_1_device, "voodoo_1", "3dfx Voodoo Graphics") -voodoo_1_device::voodoo_1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, voodoo_model model) : +voodoo_1_device::voodoo_1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, voodoo_model model) : generic_voodoo_device(mconfig, type, tag, owner, clock, model), m_chipmask(1), m_init_enable(0), @@ -2347,7 +2347,7 @@ u32 voodoo_1_device::reg_swapbuffer_w(u32 chipmask, u32 regnum, u32 data) // determine how many cycles to wait; we deliberately overshoot here because // the final count gets updated on the VBLANK - return (m_vblank_swap + 1) * clock() / 10; + return (m_vblank_swap + 1) * clock().value() / 10; } diff --git a/src/devices/video/voodoo.h b/src/devices/video/voodoo.h index 94a20c0f7af..d1275bb3322 100644 --- a/src/devices/video/voodoo.h +++ b/src/devices/video/voodoo.h @@ -418,7 +418,7 @@ public: protected: // internal construction - generic_voodoo_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, voodoo::voodoo_model model); + generic_voodoo_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, voodoo::voodoo_model model); // device-level overrides virtual void device_start() override; @@ -476,14 +476,14 @@ protected: static constexpr u32 TRIANGLE_SETUP_CLOCKS = 100; // internal construction - voodoo_1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, voodoo::voodoo_model model); + voodoo_1_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, voodoo::voodoo_model model); public: // nominal clock values - static constexpr u32 NOMINAL_CLOCK = 50'000'000; + static constexpr XTAL NOMINAL_CLOCK = XTAL::u(50'000'000); // construction - voodoo_1_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : + voodoo_1_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : voodoo_1_device(mconfig, VOODOO_1, tag, owner, clock, voodoo::voodoo_model::VOODOO_1) { } // destruction diff --git a/src/devices/video/voodoo_2.cpp b/src/devices/video/voodoo_2.cpp index 56fd7cdcc65..5715356e732 100644 --- a/src/devices/video/voodoo_2.cpp +++ b/src/devices/video/voodoo_2.cpp @@ -653,7 +653,7 @@ command_fifo::packet_handler command_fifo::s_packet_handler[8] = DEFINE_DEVICE_TYPE(VOODOO_2, voodoo_2_device, "voodoo_2", "3dfx Voodoo 2") -voodoo_2_device::voodoo_2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, voodoo_model model) : +voodoo_2_device::voodoo_2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, voodoo_model model) : voodoo_1_device(mconfig, type, tag, owner, clock, model), m_sverts(0), m_cmdfifo(*this) diff --git a/src/devices/video/voodoo_2.h b/src/devices/video/voodoo_2.h index a68886b846e..a4f0c5cb908 100644 --- a/src/devices/video/voodoo_2.h +++ b/src/devices/video/voodoo_2.h @@ -173,14 +173,14 @@ class voodoo_2_device : public voodoo_1_device protected: // internal construction - voodoo_2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, voodoo::voodoo_model model); + voodoo_2_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, voodoo::voodoo_model model); public: // nominal clock value - static constexpr u32 NOMINAL_CLOCK = 90'000'000; + static constexpr XTAL NOMINAL_CLOCK = XTAL::u(90'000'000); // construction - voodoo_2_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : + voodoo_2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : voodoo_2_device(mconfig, VOODOO_2, tag, owner, clock, voodoo::voodoo_model::VOODOO_2) { } // address map and read/write helpers diff --git a/src/devices/video/voodoo_banshee.cpp b/src/devices/video/voodoo_banshee.cpp index a23311802c8..c80144798ac 100644 --- a/src/devices/video/voodoo_banshee.cpp +++ b/src/devices/video/voodoo_banshee.cpp @@ -178,7 +178,7 @@ void banshee_vga_regs::register_save(save_proxy &save) DEFINE_DEVICE_TYPE(VOODOO_BANSHEE, voodoo_banshee_device, "voodoo_banshee", "3dfx Voodoo Banshee") -voodoo_banshee_device::voodoo_banshee_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, voodoo_model model) : +voodoo_banshee_device::voodoo_banshee_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, voodoo_model model) : voodoo_2_device(mconfig, type, tag, owner, clock, model), m_cmdfifo2(*this) { @@ -1633,7 +1633,7 @@ void voodoo_banshee_device::execute_blit(u32 data) DEFINE_DEVICE_TYPE(VOODOO_3, voodoo_3_device, "voodoo_3", "3dfx Voodoo 3") -voodoo_3_device::voodoo_3_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : +voodoo_3_device::voodoo_3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : voodoo_banshee_device(mconfig, VOODOO_3, tag, owner, clock, voodoo_model::VOODOO_3) { } diff --git a/src/devices/video/voodoo_banshee.h b/src/devices/video/voodoo_banshee.h index 31afb8289ae..8c6fbd5e2a1 100644 --- a/src/devices/video/voodoo_banshee.h +++ b/src/devices/video/voodoo_banshee.h @@ -41,14 +41,14 @@ class voodoo_banshee_device : public voodoo_2_device { protected: // internal construction - voodoo_banshee_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock, voodoo::voodoo_model model); + voodoo_banshee_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock, voodoo::voodoo_model model); public: // nominal clock values - static constexpr u32 NOMINAL_CLOCK = 90'000'000; + static constexpr XTAL NOMINAL_CLOCK = XTAL::u(90'000'000); // construction - voodoo_banshee_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) : + voodoo_banshee_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : voodoo_banshee_device(mconfig, VOODOO_BANSHEE, tag, owner, clock, voodoo::voodoo_model::VOODOO_BANSHEE) { } // core address map and read/write helpers @@ -172,10 +172,10 @@ class voodoo_3_device : public voodoo_banshee_device { public: // nominal clock values - static constexpr u32 NOMINAL_CLOCK = 132'000'000; + static constexpr XTAL NOMINAL_CLOCK = XTAL::u(132'000'000); // construction - voodoo_3_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + voodoo_3_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); protected: // device-level overrides diff --git a/src/devices/video/voodoo_pci.cpp b/src/devices/video/voodoo_pci.cpp index e27413c8851..11641f0efef 100644 --- a/src/devices/video/voodoo_pci.cpp +++ b/src/devices/video/voodoo_pci.cpp @@ -55,28 +55,28 @@ void voodoo_pci_device::config_map(address_map &map) map(0x40, 0x5f).rw(FUNC(voodoo_pci_device::pcictrl_r), FUNC(voodoo_pci_device::pcictrl_w)); } -voodoo_pci_device::voodoo_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock) +voodoo_pci_device::voodoo_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock) : pci_device(mconfig, type, tag, owner, clock), m_generic_voodoo(*this, "voodoo"), m_cpu(*this, finder_base::DUMMY_TAG), m_screen(*this, finder_base::DUMMY_TAG), m_fbmem(2), m_tmumem0(0), m_tmumem1(0) { } -voodoo_1_pci_device::voodoo_1_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +voodoo_1_pci_device::voodoo_1_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : voodoo_pci_device(mconfig, VOODOO_1_PCI, tag, owner, clock), m_voodoo(*this, "voodoo") { } -voodoo_2_pci_device::voodoo_2_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +voodoo_2_pci_device::voodoo_2_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : voodoo_pci_device(mconfig, VOODOO_2_PCI, tag, owner, clock), m_voodoo(*this, "voodoo") { } -voodoo_banshee_pci_device::voodoo_banshee_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +voodoo_banshee_pci_device::voodoo_banshee_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : voodoo_pci_device(mconfig, VOODOO_BANSHEE_PCI, tag, owner, clock), m_voodoo(*this, "voodoo") { } -voodoo_3_pci_device::voodoo_3_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock) +voodoo_3_pci_device::voodoo_3_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : voodoo_pci_device(mconfig, VOODOO_3_PCI, tag, owner, clock), m_voodoo(*this, "voodoo") { } diff --git a/src/devices/video/voodoo_pci.h b/src/devices/video/voodoo_pci.h index c56358b2c2f..283432b86df 100644 --- a/src/devices/video/voodoo_pci.h +++ b/src/devices/video/voodoo_pci.h @@ -25,7 +25,7 @@ public: void vga_w(offs_t offset, u32 data, u32 mem_mask = ~0); protected: - voodoo_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, u32 clock); + voodoo_pci_device(const machine_config &mconfig, device_type type, const char *tag, device_t *owner, const XTAL &clock); virtual void map_extra(u64 memory_window_start, u64 memory_window_end, u64 memory_offset, address_space *memory_space, u64 io_window_start, u64 io_window_end, u64 io_offset, address_space *io_space) override; @@ -53,14 +53,14 @@ class voodoo_1_pci_device : public voodoo_pci_device { public: template <typename T, typename U> - voodoo_1_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&cpu_tag, U &&screen_tag) - : voodoo_1_pci_device(mconfig, tag, owner, clock) + voodoo_1_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag, U &&screen_tag) + : voodoo_1_pci_device(mconfig, tag, owner) { set_cpu(std::forward<T>(cpu_tag)); set_screen(std::forward<U>(screen_tag)); } - voodoo_1_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + voodoo_1_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void device_start() override; @@ -72,14 +72,14 @@ class voodoo_2_pci_device : public voodoo_pci_device { public: template <typename T, typename U> - voodoo_2_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&cpu_tag, U &&screen_tag) - : voodoo_2_pci_device(mconfig, tag, owner, clock) + voodoo_2_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag, U &&screen_tag) + : voodoo_2_pci_device(mconfig, tag, owner) { set_cpu(std::forward<T>(cpu_tag)); set_screen(std::forward<U>(screen_tag)); } - voodoo_2_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + voodoo_2_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void device_start() override; @@ -91,14 +91,14 @@ class voodoo_banshee_pci_device : public voodoo_pci_device { public: template <typename T, typename U> - voodoo_banshee_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&cpu_tag, U &&screen_tag) - : voodoo_banshee_pci_device(mconfig, tag, owner, clock) + voodoo_banshee_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag, U &&screen_tag) + : voodoo_banshee_pci_device(mconfig, tag, owner) { set_cpu(std::forward<T>(cpu_tag)); set_screen(std::forward<U>(screen_tag)); } - voodoo_banshee_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + voodoo_banshee_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void device_start() override; @@ -113,14 +113,14 @@ class voodoo_3_pci_device : public voodoo_pci_device { public: template <typename T, typename U> - voodoo_3_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock, T &&cpu_tag, U &&screen_tag) - : voodoo_3_pci_device(mconfig, tag, owner, clock) + voodoo_3_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, T &&cpu_tag, U &&screen_tag) + : voodoo_3_pci_device(mconfig, tag, owner) { set_cpu(std::forward<T>(cpu_tag)); set_screen(std::forward<U>(screen_tag)); } - voodoo_3_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, u32 clock); + voodoo_3_pci_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock = XTAL()); protected: virtual void device_start() override; diff --git a/src/devices/video/vrender0.cpp b/src/devices/video/vrender0.cpp index 8a0e7c9319c..1347aa30639 100644 --- a/src/devices/video/vrender0.cpp +++ b/src/devices/video/vrender0.cpp @@ -30,7 +30,7 @@ DEFINE_DEVICE_TYPE(VIDEO_VRENDER0, vr0video_device, "vr0video", "MagicEyes VRender0 Video Engine") -vr0video_device::vr0video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +vr0video_device::vr0video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, VIDEO_VRENDER0, tag, owner, clock) , device_video_interface(mconfig, *this) , m_idleskip_cb(*this) diff --git a/src/devices/video/vrender0.h b/src/devices/video/vrender0.h index 3414721a5e7..ef332e6eae1 100644 --- a/src/devices/video/vrender0.h +++ b/src/devices/video/vrender0.h @@ -14,7 +14,7 @@ class vr0video_device : public device_t, public device_video_interface { public: - vr0video_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + vr0video_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); void set_areas(uint16_t *textureram, uint16_t *frameram); void regs_map(address_map &map); diff --git a/src/devices/video/x1_001.cpp b/src/devices/video/x1_001.cpp index 59ea53bd062..1c03dc4b811 100644 --- a/src/devices/video/x1_001.cpp +++ b/src/devices/video/x1_001.cpp @@ -49,7 +49,7 @@ DEFINE_DEVICE_TYPE(X1_001, x1_001_device, "x1_001", "Seta X1-001 Sprites") -x1_001_device::x1_001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +x1_001_device::x1_001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, X1_001, tag, owner, clock) , device_gfx_interface(mconfig, *this) , m_gfxbank_cb(*this) diff --git a/src/devices/video/x1_001.h b/src/devices/video/x1_001.h index 74cdb239be0..8bf8f11b1b4 100644 --- a/src/devices/video/x1_001.h +++ b/src/devices/video/x1_001.h @@ -12,8 +12,8 @@ typedef device_delegate<int (uint16_t code, uint8_t color)> gfxbank_cb_delegate; class x1_001_device : public device_t, public device_gfx_interface { public: - x1_001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); - template <typename T> x1_001_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock, T &&palette_tag, const gfx_decode_entry *gfxinfo) + x1_001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); + template <typename T> x1_001_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock, T &&palette_tag, const gfx_decode_entry *gfxinfo) : x1_001_device(mconfig, tag, owner, clock) { set_info(gfxinfo); diff --git a/src/devices/video/zeus2.cpp b/src/devices/video/zeus2.cpp index 300b5ad2d0c..7093b2700f3 100644 --- a/src/devices/video/zeus2.cpp +++ b/src/devices/video/zeus2.cpp @@ -27,7 +27,7 @@ zeus2_renderer::zeus2_renderer(zeus2_device *state) DEFINE_DEVICE_TYPE(ZEUS2, zeus2_device, "zeus2", "Midway Zeus2") -zeus2_device::zeus2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock) +zeus2_device::zeus2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock) : device_t(mconfig, ZEUS2, tag, owner, clock) , device_video_interface(mconfig, *this) , m_vblank(*this), m_irq(*this), m_atlantis(0) diff --git a/src/devices/video/zeus2.h b/src/devices/video/zeus2.h index 459fff99799..1dcff6e0746 100644 --- a/src/devices/video/zeus2.h +++ b/src/devices/video/zeus2.h @@ -104,7 +104,7 @@ typedef zeus2_renderer::extent_t z2_poly_extent; class zeus2_device : public device_t, public device_video_interface { public: - zeus2_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock); + zeus2_device(const machine_config &mconfig, const char *tag, device_t *owner, const XTAL &clock); uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect); uint32_t zeus2_r(offs_t offset); |